In this tutorial we will learn how to play a mp3 song using arduino an the DF PLAYER MINI module. Watch the Video!
Things used in this project
Software apps and online services
In this tutorial we will learn how to play a mp3 song using arduino an the DF PLAYER MINI module.
Watch the Video!
Step 1: What You Will Need
-Arduino UNO (or any other Arduino)
-DF PLAYER MINI module
-1K ohm resistor
-SD card with the mp3 song
-Visuino program: Download Visuino
Step 2: The Circuit
-Connect the 5V output from Arduino to the VCC pin of the MP3 player module
-Connect Arduino pin [GND] to the MP3 player module pin [GND]
-Connect Arduino pin [RX] to the MP3 player module pin [TX]
-Connect Arduino pin [TX] to the 1K ohm resistor, the other side of the resistor connect to MP3 player module pin [RX]
-For a mono speaker, connect one wire to SPK1 and the other to SPK2.
-For a stereo speaker or headphones connect Left side wire to MP3 player module pin [DACL] and Right side wire to MP3 player module pin [DACR] and GND wire to the MP3 player module pin [GND]
Note: When uploading to Arduino Disconnect Arduino pin [RX] and after the upload connect it back
Step 3: Start Visuino, and Select the Arduino UNO Board Type
The Visuino: https://www.visuino.eu also needs to be installed. Download Free version or register for a Free Trial.
Start Visuino as shown in the first picture Click on the "Tools" button on the Arduino component (Picture 1) in Visuino When the dialog appears, select "Arduino UNO" as shown on Picture 2
Step 4: In Visuino Add Components and Connect
-Add "DFRobot Serial MP3 Player" component
-Add "Start" component
-Connect "Start1" pin [Out] to "MP3Player1" pin [Next]
-Connect "MP3Player1" pin [Out] to Arduino Serial  In
Step 5: Generate, Compile, and Upload the Arduino Code
In Visuino, at the bottom click on the "Build" Tab, make sure the correct port is selected, then click on the "Compile/Build and Upload" button.
Step 6: Play
Put your SD card into the MP3 player module and If you power the Arduino UNO module, the MP3 player module will start to Play the song.
Congratulations! You have completed your project with Visuino. Also attached is the Visuino project, that I created for this tutorial. You can download and open it in Visuino: https://www.visuino.eu