Use an Arduino or Arduino-clone to test or update uMP3 firmwareUse this following sketch to test the uMP3 using the serial port connection on the Arduino and Arduino-clones. /************************************************** * Simple pass-through serial application for * Arduino and Arduino-clones. * You can use this for testing and * updating the Rogue Robotics * uMMC Serial Data Module or * uMP3 Playback Module. * * You will need the "NewSoftSerial" library * available at the Arduino website. * http://arduino.cc/ * http://arduino.cc/en/Reference/Libraries ***************************************************/ #include <NewSoftSerial.h> // You can set this to whatever pins you have the uMMC or uMP3 connected. // e.g. 4 is connected to uMMC "T", 5 is connected to uMMC "R" NewSoftSerial out(4, 5); // If you are using this to update the firmware on the uMMC or uMP3, // you will have to make sure that both the Serial connection and the // out connection are set to 9600 bps. void setup() { out.begin(9600); Serial.begin(9600); pinMode(13, OUTPUT); digitalWrite(13, 0); } void loop() { digitalWrite(13, 0); if(out.available()) { digitalWrite(13, 1); Serial.print((uint8_t)out.read()); } if(Serial.available()) { digitalWrite(13, 1); out.print((uint8_t)Serial.read()); } } |