Revision History Version Date Changes 4 June 2014 Wording Correction 16 November 2013 Image chaged, Usage with Arduino added 3 October 2013 Original Version Venus Supply Co., Ltd. Page 1...
Page 3
48 kHz sampling rate. The user can use any MCU to control the module using parallel or serial interface. With MP3 files stored on a SD card, the user can select a sound folder, select a file, start playback and control play volume using simple serial or parallel commands. The SD card can be as large as 32 GByte.
Features - Support stereo MP3 files - 2 interface modes: serial and parallel - Support FAT32 and FAT16 file system - Accept micro SD Card with SDHC supported (maximum 32 GB) - Sampling rates: 8 kHz - 48 kHz. Accept 5 VDC power supply Use 20-pin 2.54mm-pitch header for interface...
Page 6
The file names in each folder must be 001.mp3, 002.mp3 … 199.mp3. So there can be 199 files in a folder. And there can be 15 folders on a SD card with names: 02, 03 …...
Page 7
- Folder ordering example From figure above, there are 5 folders including the root directory. The folder 11 is counted as the folder, to get into it, use command 0xF4 (Change to folder 4). As illustrated, it’s recommended to name all files and folders sequentially. 2.
Page 8
8-bit data, PL and BUSY. Optionally, +VOL and –VOL can be connected to switches for increasing or decreasing the volume directly. Data In 8 Bits BUSY PL Switch -Vol Switch +Vol HP_L HP_R The connections are described below: MP3 module Device Arduino Arduino P0–P7 D2-D9 Arduino BUSY...
Page 9
From the circuit above, control signals are P0-P7, PL and BUSY. Whenever that BUSY is “High”, the module is ready to accept new parallel command. The user can send a command to P0-P7 then send a “Low” strobe pulse on PL. Commands are listed below: Command Word Function P7 P6 P5 P4 P3 P2 P1 P0...
Page 10
Example 1 In parallel mode, send a command to play 001.mp3. const int P0 = 2; const int P1 = 3; const int P2 = 4; const int P3 = 5; const int P4 = 6; 1. Pin assignments const int P5 = 7;...
Page 11
Code description: void set_port() { pinMode(P0, OUTPUT); pinMode(P1, OUTPUT); pinMode(P2, OUTPUT); pinMode(P3, OUTPUT); pinMode(P4, OUTPUT); pinMode(P5, OUTPUT); pinMode(P6, OUTPUT); pinMode(P7, OUTPUT); pinMode(PL, OUTPUT); pinMode(BUSY,INPUT); Function set_port () is used to initialized pins to be output or input. void setup() set_port(); Function setup() is used for initialization.
Page 12
Example 2 In parallel mode, send a command to play 002.mp3 in folder 03. const int P0 = 2; const int P1 = 3; const int P2 = 4; const int P3 = 5; const int P4 = 6; 1. Pin assignments const int P5 = 7;...
Page 13
When logic on BUSY pin becomes “High” and cmd_stop is false, a command 0xF3 will be sent to change directory to 03. Then wait until BUSY becomes “High” again and a command 0x02 is sent to play 002.mp3. Venus Supply Co., Ltd.
Page 15
In this example, a software serial is used by setting D3 to be RX and D4 to be TX. The communication is configured to: Baud rate: 9600, Data Bit : 8, Stop Bit :1, Parity : None Commands are exactly the same as used in parallel mode: Command word Function 0x01...
Page 16
Example 1 In serial mode, send a command to play 001.mp3. #include <SoftwareSerial.h> SoftwareSerial mySerial(3, 4); // RX, TX const int BUSY = 5; boolean cmd_stop =false; void setup() { pinMode(BUSY, INPUT); mySerial.begin(9600); void loop() { if ((digitalRead(BUSY) == HIGH) && (cmd_stop == false)) { Serial.write(0x01);...
Page 17
Example 2 In serial mode, send a command to play 002.mp3 in folder 03. #include <SoftwareSerial.h> SoftwareSerial mySerial(3, 4); // RX, TX const int BUSY = 5; boolean cmd_stop =false ; void setup() { pinMode(BUSY, INPUT); mySerial.begin(9600); void loop() { if ((digitalRead(BUSY) == HIGH) &&...
Need help?
Do you have a question about the MP3 and is the answer not in the manual?
Questions and answers