element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Design for a Cause - Design Challenge
  • Challenges & Projects
  • Design Challenges
  • Design for a Cause - Design Challenge
  • More
  • Cancel
Design for a Cause - Design Challenge
Blog Interesting Situation
  • Blog
  • Forum
  • Documents
  • Polls
  • Files
  • Events
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: roborob1266
  • Date Created: 17 Aug 2018 5:26 PM Date Created
  • Views 1670 views
  • Likes 4 likes
  • Comments 2 comments
  • adafruit vs1053 mp3 player
  • design for a cause - design challenge
  • uno
  • mkr1000
  • challenges
  • adafruit ra8875
Related
Recommended

Interesting Situation

roborob1266
roborob1266
17 Aug 2018

Hello all

Here is an update as to what is going on with this project...

 

When I connect the RA8875 to the MKR, here are the specifics for communications (that work):

// Connect SCLK to MKR1000 #09 (Hardware SPI clock)

// Connect MISO to MKR1000 #10 (Hardware SPI MISO)

// Connect MOSI to MKR1000 #08 (Hardware SPI MOSI)

#define RA8875_INT 3

#define RA8875_CS 6

#define RA8875_RESET 2

 

I am able to get my sketch run just fine and have touch screen buttons that are detected when pushed.

 

Now when I disconnect the RA8875 from the MKR1000 and connect the VS1053 to the MKR1000, here are the specifics for communications (that work):

//#define CLK 13       // SPI Clock, shared with SD card

//#define MISO 12      // Input data, from VS1053/SD card

//#define MOSI 11      // Output data, to VS1053/SD card

 

// These are the pins used for the breakout example

#define BREAKOUT_RESET  9      // VS1053 reset pin (output)

#define BREAKOUT_CS     7     // VS1053 chip select pin (output)

#define BREAKOUT_DCS    5      // VS1053 Data/command select pin (output)

#define CARDCS 4     // VS1053 CCS - Card chip select pin

#define DREQ 0       // VS1053 DREQ - Data request, ideally an Interrupt pin

 

As you can see that the only pins that are the same are for the SPI clock, MISO and MOSI.

I get verification that the SD card is read and then it plays the audio files I have on that SD card.

 

When I connect the VS1053 along with the RA8875 to the MKR1000 and power it on, the TFT does not display the back light on power up, the last sketch executed for the RA8875 does not run and the audio files do not play on the VS1053 and the Serial monitor. I haven't even executed any sketches, just what is in memory on both devices but nothing is running.

 

My next step is to have the VS1053 be connected to the UNO I have and the RA8875 connected to the MKR1000 and try I2C or TX/RX connections between the two and see if they communicate that way.

 

I tried I2C recently and the devices were not communicating.

Here are the sketches for both:

 

MASTER:

#include <SPI.h>

#include "Adafruit_GFX.h"

#include "Adafruit_RA8875.h"

#include <Wire.h>

 

 

// I2C Master

 

 

int x = 0;

 

 

void setup() {

  // Start the I2C Bus as Master

  Wire.begin();

}

 

 

void loop() {

  Wire.beginTransmission(9); // transmit to device #9

  Wire.write(x);              // sends x

  Wire.endTransmission();    // stop transmitting

 

  x++; // Increment x

  if (x > 5) x = 0; // `reset x once it gets 6

 

  delay(500);

}

-------------------------------------------

SLAVE:

#include <SPI.h>

#include <Adafruit_VS1053.h>

#include <SD.h>

#include <Wire.h>

 

 

int LED = 13;

int x = 0;

 

 

void setup() {

  // Define the LED pin as Output

  pinMode (LED, OUTPUT);

  // Start the I2C Bus as Slave on address 9

  Wire.begin(9);

  // Attach a function to trigger when something is received.

  Wire.onReceive(receiveEvent);

}

 

 

void receiveEvent(int bytes) {

  x = Wire.read();    // read one character from the I2C

}

 

 

void loop() {

  //If value received is 0 blink LED for 200 ms

  if (x == '0') {

    digitalWrite(LED, HIGH);

    delay(200);

    digitalWrite(LED, LOW);

    delay(200);

  }

  //If value received is 3 blink LED for 400 ms

  if (x == '3') {

    digitalWrite(LED, HIGH);

    delay(400);

    digitalWrite(LED, LOW);

    delay(400);

  }

}

  • Sign in to reply
  • jessivessi
    jessivessi over 2 years ago in reply to jendyt

    It's only due to other stories and reviews posted by users which kind of got me motivated just knowing that it works just perfectly good for my own work done by AOU assignment help. Anyways thanks for solution.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • jendyt
    jendyt over 2 years ago

    For the time and work you put into territorial io producing this essay, I would want to thank you. In the future, I hope to see the same top-notch work from you. In fact, I'm now starting my own BlogEngine blog because of your unique writing skills.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube