Project #16: Sound – Mini MP3 Player – Mk26

Project #16: Sound – Mini MP3 Player – Mk26

 

Web

 

https://www.donluc.com/?p=4571

 

Facebook

 

https://www.facebook.com/share/v/1Q6Tw8CcTu/

 

YouTube

 

https://youtu.be/9HeErpiNI0o

 

#DonLucElectronics #DonLuc #MiniMP3Player #IoT #Project #Fritzing #Programming #Electronics #Microcontrollers #Consultant

Mini MP3 Player

 

Mini MP3 Player  is a compact and inexpensive MP3 module that can be connected directly to the speaker. The module can be used alone with a battery power supply, speaker, and keypad, or through the serial port control, as the Arduino UNO compatible board or any microcontroller with a serial port module. The module itself perfectly integrated hardware decodes MP3, WAV, and WMA's. The software supports TF card drivers to support FAT16, FAT32 file systems. This can be done by the simple serial command that plays the specified music, as well as how to play music and other functions, easy to use, stable and reliable.

 

Play next MP3 every 8 second.

 

1.mp3 - William Shakespeare
2.mp3 - Albert Einstein
3.mp3 - Luc Paquin
4.mp3 - Carl Sagan
5.mp3 - Dalek

 

DL2510Mk02

 

1 x SparkFun RedBoard Qwiic
1 x Mini MP3 Player
1 x Speaker
1 x USB Battery Pack
1 x USB-A to Micro-B Cable

 

DL2510Mk02p

 

DL2510Mk02p.ino

CODE
/****** Don Luc Electronics © ******
Software Version Information
Project #16: Sound – Mini MP3 Player – Mk26
16-26
DL2509Mk02p.ino
DL2509Mk02
1 x SparkFun RedBoard Qwiic
1 x Mini MP3 Player
1 x Speaker
1 x USB Battery Pack
1 x USB-A to Micro-B Cable
*/

// Include the Library Code
// EEPROM Library to Read and Write EEPROM
// with Unique ID for Unit
#include "EEPROM.h"
// Arduino
#include "Arduino.h"
// Software Serial
#include "SoftwareSerial.h"
// DFRobot DFPlayer Mini
#include "DFRobotDFPlayerMini.h"

// Software Serial RX, TX
SoftwareSerial mySoftwareSerial(10, 11);
// DFRobot DFPlayer Mini
DFRobotDFPlayerMini myDFPlayer;

// EEPROM Unique ID Information
String uid = "";

// Software Version Information
String sver = "16-26";

void loop() {
  
  // isMP3
  isMP3();

}

getEEPROM.ino

CODE
// EEPROM
// isUID EEPROM Unique ID
void isUID() {
  
  // Is Unit ID
  uid = "";
  for (int x = 0; x < 7; x++)
  {
    uid = uid + char(EEPROM.read(x));
  }

}

getMiniMP3.ino

CODE
// Mini MP3
// isSetupMP3
void isSetupMP3(){

  // Mini MP3
  myDFPlayer.begin(mySoftwareSerial);
  
  // Set volume value. From 0 to 30
  myDFPlayer.volume(20);
  
  // Play the first MP3
  myDFPlayer.play(1);
  
}
// isMP3
void isMP3(){
  
  // Timer
  static unsigned long timer = millis();
  
  // isMp3
  if (millis() - timer > 8000) {
    
    // Time
    timer = millis();
    
    // Play next mp3 every 8 second
    myDFPlayer.next();

  }

  myDFPlayer.available();
  
}

setup.ino

CODE
// Setup
void setup()
{
 
  // Delay
  delay( 100 );

  // EEPROM Unique ID
  isUID();

  // Delay
  delay( 100 );

  // Software Serial
  mySoftwareSerial.begin(9600);

  // Delay
  delay( 100 );

  // isSetupMP3
  isSetupMP3();
    
  // Delay 1 Second
  delay( 1000 );

}

People can contact us: http://www.donluc.com/?page_id=1927

 

Consultant, R&D, Electronics, IoT, Teacher and Instructor

 

-Programming Language
-Microcontrollers (PIC, Arduino, Raspberry Pi, Arm, Silicon Labs, Espressif, Etc...)
-IoT
-Wireless (Radio Frequency, Bluetooth, WiFi, Etc...)
-Robotics
-Automation
-Camera and Video Capture Receiver Stationary, Wheel/Tank , Underwater and UAV Vehicle
-Unmanned Vehicles Terrestrial,  Marine and UAV
-Machine Learning
-Artificial Intelligence (AI)
-RTOS
-Sensors, eHealth Sensors, Biosensor, and Biometric
-Research & Development (R & D)
-Consulting
-Etc...

 

Follow Us

 

Luc Paquin – Curriculum Vitae - 2025
https://www.donluc.com/luc/

 

Web: https://www.donluc.com/
Facebook: https://www.facebook.com/neosteam.labs.9/
YouTube: https://www.youtube.com/@thesass2063
Twitter: https://twitter.com/labs_steam
Pinterest: https://www.pinterest.com/NeoSteamLabs/
Instagram: https://www.instagram.com/neosteamlabs/
DFRobot: https://learn.dfrobot.com/user-10186.html
Elecrow: https://www.elecrow.com/share/sharepj/center/no/760816d385ebb1edc0732fd873bfbf13
TikTok: https://www.tiktok.com/@luc.paquin
Hackster: https://www.hackster.io/luc-paquin
LinkedIn: https://www.linkedin.com/in/jlucpaquin/

 

Don Luc

icon DL2510Mk02.zip 207KB Download(0)
License
All Rights
Reserved
licensBg
0