I'm using a breadboard and double checked the connections and they are all fine.. Could the issue be the SD card if the test tone works?(musicPlayer.sineTest(0x45, 2000); // Make a tone to indicate VS1053 is working)adafruit_support_bill wrote:Same advice then: Post photos showing your soldering and all your connections to the Arduino. Also, check the Serial Monitor output while you are running the sample code. If there are any SD card reading errors, they will be printed there.Hi I have this EXACT same problem
My code:
Code: Select all
// include SPI, MP3 and SD libraries
#include <SPI.h>
#include <Adafruit_VS1053.h>
#include <SD.h>
// define the pins used
#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
// Connect CLK, MISO and MOSI to hardware SPI pins.
// See http://arduino.cc/en/Reference/SPI "Connections"
// These can be any pins:
#define RESET 9 // VS1053 reset pin (output)
#define CS 10 // VS1053 chip select pin (output)
#define DCS 8 // VS1053 Data/command select pin (output)
#define CARDCS 4 // Card chip select pin
// DREQ should be an Int pin, see http://arduino.cc/en/Reference/attachInterrupt
#define DREQ 3 // VS1053 Data request, ideally an Interrupt pin
//Adafruit_VS1053_FilePlayer musicPlayer = Adafruit_VS1053_FilePlayer(RESET, CS, DCS, DREQ, CARDCS);
Adafruit_VS1053_FilePlayer musicPlayer = Adafruit_VS1053_FilePlayer(MOSI, MISO, CLK, RESET, CS, DCS, DREQ, CARDCS);
void setup() {
Serial.begin(9600);
Serial.println("Adafruit VS1053 Simple Test");
musicPlayer.begin(); // initialise the music player
SD.begin(CARDCS); // initialise the SD card
musicPlayer.sineTest(0x45, 2000); // Make a tone to indicate VS1053 is working
// Set volume for left, right channels. lower numbers == louder volume!
musicPlayer.setVolume(20,20);
//musicPlayer.useInterrupt(VS1053_FILEPLAYER_TIMER0_INT); // timer int
musicPlayer.useInterrupt(VS1053_FILEPLAYER_PIN_INT); // DREQ int
// Play one file, don't return until complete
musicPlayer.playFullFile("track001.mp3");
// Play another file in the background, REQUIRES interrupts!
musicPlayer.startPlayingFile("track002.mp3");
}
void loop() {
// File is playing in the background
if (! musicPlayer.playingMusic)
Serial.println("Done playing music");
delay(1000);
}