Advertisement
Guest User

http://darylrobotproject.wordpress.com Arduino MP3 Shield

a guest
Apr 1st, 2013
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.34 KB | None | 0 0
  1. #include <MP3.h>
  2.  
  3. /** define mp3 class */
  4. MP3 mp3;
  5.  
  6. void setup() {
  7.  
  8.   /** begin function */
  9.   mp3.begin();
  10.  
  11.   /** set MP3 Shield CYCLE mode */
  12.   mp3.set_mode(MP3::SINGLE);
  13.  
  14.   /** set volume */
  15.   mp3.volume(0x1F);
  16.  
  17.   /** play music in USB Disk */
  18.   mp3.play_usb_disk(0x0001);
  19.    
  20. }
  21.  
  22. void loop() {
  23.  
  24.   delay(10);
  25.    
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement