AR-175IntermediatePremium
Arduino MP3 Player: A Music Player With Buttons and a Volume Knob (DFPlayer Mini + Potentiometer + Speaker)
An MP3 player for your own music with three buttons and a volume knob. The DFPlayer Mini plays MP3 files from a microSD card through a speaker. The previous, play/pause and next buttons move between tracks, and the potentiometer sets the volume from 0 to 30. When a track ends the next one starts, and after the last it goes back to the first. A long press on play turns on shuffle. The Serial Monitor shows the track and the volume.
0.0(0)

Picture a little music box you built yourself: you put your favourite tracks on a microSD card, step through them with buttons and turn a knob to make it louder. The sound comes from real MP3 files, so you can play your own music, recordings or an audiobook. Along the way you learn how to control an MP3 module over serial, how to filter button bounce and tell a short press from a long one, and how to read a potentiometer without sending needless commands.
Source Code
Premium Content
The source code, block version and FAQ of this project are open to Premium members.
- All Project Code
- Block version
- Frequently Asked Questions
