- تكلفه فاتورة الكهرباء
- Electrical Energy Consumption
- Parallel and Series Resistor Calculator
- LED Resistor Calculator
- UPS Battery Backup Calculator
- Voltage Divider Calculator
- Resistor Color Code Calculator
- Ohm’s Law Calculator
- Current Divider Calculator
- Number System Conversion Calculator
- Boost Converter Calculator
- MOSFET Threshold Voltage Calculator
- Apparent Power Calculator (kVA & VA)
- 555 Timer Calculator
- Buck Converter Calculator
- Capacitors in Series or Parallel Calculator
- Low Pass Filter Calculator
- RMS Voltage Calculator
- Universal Data Converter
- RMS Voltage Calculator
- Capacitor Code Converter
- Series Inductors Calculator
MP3-TF-16P SD Card MP3 Module with Serial Port

MP3-TF-16P SD Card MP3 Module with Serial Port
Compact Audio Playback Solution for Arduino and Microcontroller Projects
Introduction
The MP3-TF-16P module is a low-cost, high-quality audio playback solution that supports MP3 and WAV files from micro SD cards. Featuring a built-in DAC and amplifier, this module provides simple serial control and requires minimal external components.
Key Features
Audio Formats
Supports MP3 and WAV files (8-320kbps)
Storage
Micro SD card slot (up to 32GB supported)
Simple Interface
UART serial control (9600 baud default)
Built-in Amplifier
3W output (requires 5V power)
Technical Specifications
Model | MP3-TF-16P |
---|---|
Control Interface | UART Serial (TTL level) |
Audio Output | Mono 3W (8Ω speaker) |
Operating Voltage | 3.2-5V (5V recommended) |
Supported Cards | Micro SD (FAT16/FAT32) |
Standby Current | <20mA |
Pin Configuration

Pin | Label | Description | Connection |
---|---|---|---|
1 | VCC | Power (5V recommended) | 5V |
2 | RX | Serial Receive | Arduino TX |
3 | TX | Serial Transmit | Arduino RX |
4 | DAC_R | Right Audio (not used) | – |
5 | DAC_L | Left Audio Output | Speaker+ |
6 | GND | Ground | GND |
7 | SPK1 | Amplifier Output+ | Speaker+ |
8 | SPK2 | Amplifier Output- | Speaker- |
9 | IO1 | GPIO (optional) | – |
10 | IO2 | GPIO (optional) | – |
11 | ADKEY1 | Analog Key 1 | – |
12 | ADKEY2 | Analog Key 2 | – |
13 | BUSY | Playback Status | Digital Input |
14 | RESET | Active Low Reset | – |
15 | GND | Ground | GND |
16 | GND | Ground | GND |
Note: For basic playback, you only need to connect VCC, GND, RX, and speaker pins
Basic Wiring with Arduino

// Basic Connections: // MP3 Module VCC → Arduino 5V // MP3 Module GND → Arduino GND // MP3 Module RX → Arduino TX (Pin 11) // MP3 Module TX → Arduino RX (Pin 10) // Speaker+ → SPK1 or DAC_L // Speaker- → SPK2 or GND
Library Setup
- Install the DFRobotDFPlayerMini library via Arduino Library Manager
- Include the library and SoftwareSerial in your sketch:
#include "SoftwareSerial.h" #include "DFRobotDFPlayerMini.h"
- Set up the serial connection:
SoftwareSerial mySoftwareSerial(10, 11); // RX, TX DFRobotDFPlayerMini myDFPlayer;
Basic Playback Example
#include "SoftwareSerial.h" #include "DFRobotDFPlayerMini.h" //Inicia a serial por software nos pinos 10 e 11 SoftwareSerial mySoftwareSerial(10, 11); // RX, TX DFRobotDFPlayerMini myDFPlayer; char command; int pausa = 0; void setup() { delay (2000); //Comunicacao serial com o modulo mySoftwareSerial.begin(9600); //Inicializa a serial do Arduino Serial.begin(115200); //Verifica se o modulo esta respondendo e se o //cartao SD foi encontrado Serial.println(); Serial.println(F("DFRobot DFPlayer Mini")); Serial.println(F("Initializing DFPlayer module ... Wait!")); if (!myDFPlayer.begin(mySoftwareSerial)) { Serial.println(F("Not initialized:")); Serial.println(F("1. Check the DFPlayer Mini connections")); Serial.println(F("2. Insert an SD card")); while (true); } Serial.println(); Serial.println(F("DFPlayer Mini module initialized!")); //Definicoes iniciais myDFPlayer.setTimeOut(500); //Timeout serial 500ms myDFPlayer.volume(5); //Volume 5 myDFPlayer.EQ(0); //Equalizacao normal menu_opcoes(); } void loop() { //Waits for data entry via serial while (Serial.available() > 0) { command = Serial.read(); if ((command >= '1') && (command <= '9')) { Serial.print("Music reproduction"); Serial.println(command); command = command - 48; myDFPlayer.play(command); menu_opcoes(); } //Reproduction //Stop if (command == 's') { myDFPlayer.stop(); Serial.println("Music Stopped!"); menu_opcoes(); } //Pausa/Continua a music if (command == 'p') { pausa = !pausa; if (pausa == 0) { Serial.println("Continue..."); myDFPlayer.start(); } if (pausa == 1) { Serial.println("Music Paused!"); myDFPlayer.pause(); } menu_opcoes(); } //Increases volume if (command == '+') { myDFPlayer.volumeUp(); Serial.print("Current volume:"); Serial.println(myDFPlayer.readVolume()); menu_opcoes(); } if (command == '<') { myDFPlayer.previous(); Serial.println("Previous:"); Serial.print("Current track:"); Serial.println(myDFPlayer.readCurrentFileNumber()-1); menu_opcoes(); } if (command == '>') { myDFPlayer.next(); Serial.println("next:"); Serial.print("Current track:"); Serial.println(myDFPlayer.readCurrentFileNumber()+1); menu_opcoes(); } //Decreases volume if (command == '-') { myDFPlayer.volumeDown(); Serial.print("Current Volume:"); Serial.println(myDFPlayer.readVolume()); menu_opcoes(); } } } void menu_opcoes() { Serial.println(); Serial.println(F("==================================================================================================================================")); Serial.println(F("Commands:")); Serial.println(F(" [1-3] To select the MP3 file")); Serial.println(F(" [s] stopping reproduction")); Serial.println(F(" [p] pause/continue music")); Serial.println(F(" [+ or -] increases or decreases the volume")); Serial.println(F(" [< or >] forwards or backwards the track")); Serial.println(); Serial.println(F("=================================================================================================================================")); }
File Preparation
- Format micro SD card as FAT32
- Create a folder named mp3 in the root directory
- Name your audio files as 0001.mp3, 0002.mp3, etc.
- Insert card into module before powering on
Tip: Files are played in numerical order (0001.mp3, 0002.mp3, etc.)
Advanced Features
Volume Control
myDFPlayer.volume(10); // 0-30 myDFPlayer.volumeUp(); // Increase myDFPlayer.volumeDown();// Decrease
Playback Modes
myDFPlayer.play(1); // Play specific track myDFPlayer.next(); // Next track myDFPlayer.previous(); // Previous track myDFPlayer.pause(); // Pause playback myDFPlayer.start(); // Resume playback
Equalizer Settings
// Available presets: // Normal, Pop, Rock, Jazz, Classic, Bass myDFPlayer.EQ(DFPLAYER_EQ_BASS);
Playback Status
uint16_t track = myDFPlayer.readCurrentFileNumber(); uint16_t volume = myDFPlayer.readVolume(); uint16_t state = myDFPlayer.readState();
Troubleshooting
No Sound Output
- Check speaker connections
- Verify SD card is properly inserted
- Confirm files are named correctly (0001.mp3, etc.)
- Check volume setting (myDFPlayer.volume(20))
Module Not Responding
- Verify power supply (5V recommended)
- Check serial connections (RX/TX swapped?)
- Ensure proper baud rate (9600 default)
- Try resetting the module
File Playback Issues
- Reformat SD card as FAT32
- Check file format (MP3 or WAV)
- Ensure files are in /mp3 folder
- Try different bitrates (128kbps works well)