MP3 2 Cliquez sur le tableau
MP3 2 Cliquez sur le tableau
Overview
La carte MP3 2 Click Board™ est une carte d'extension de décodeur audio avec un emplacement pour carte microSD intégré, qui vous permet de créer votre propre système de lecture audio. Elle contient le KT403A, une solution de puce SOC avec MCU intégré, décodeur audio matériel MP3/WAV et DSP, de Shenzhen Qianle Microelectronics Technology Co. Ltd.
Tous les composants matériels intégrés mentionnés permettent à la carte MP3 2 Click Board™ de garantir une bonne stabilité et une bonne qualité sonore. Vous pouvez utiliser la communication série UART pour contrôler cette carte et effectuer diverses opérations avec des fichiers musicaux à partir de cartes microSD telles que Lecture, Pause, Volume haut/bas et bien d'autres. Ces fonctionnalités font de la carte MP3 2 Click Board™ la solution idéale pour les appareils audio, dans toute application nécessitant un module de lecture audio pour MP3, WAV.
How Does The MP3 2 Click Board™ Work?
The MP3 2 Click Board™ is equipped with the KT403A as a main integrated circuit, micro SD card connector, and 3.5mm Audio Jack connector. Basically, it is a complete solution for a DAP (digital audio player) on a Click board, which can be controlled over the UART communication interface, using RX and TX pins of the mikroBUS™ socket. The default baud rate is 9600bps and it is customizable.
On the MP3 2 Click Board™, the KT403A serves as a brain. It is complete SOC, which integrates16-bit MCU, audio decoder, and a 24-bit DSP. It also integrates the complete SD card interface and therefore, this click board contains the connector onboard for an external micro SD card. Thanks to that, the user can insert a fair amount of memory if the long, continuous playback time is needed.
The MP3 2 Click Board™ has two status indication LEDs, onboard. The first one is named "SD Card" and it serves as an indication that the SD Card is present in the slot. The other one is "Chip Correct" and it indicates that the SD Card is correct and that the communication between the KT403A and the SD Card sucseeded. Besides the indicatora, there is one 3.5mm headphone jack onboard, so that MP3 2 Click can be connected directly to the next stage of the music playback system, ie. audio amplifier.
Using the predefined command set, the MP3 2 Click Board™ can be fully controlled. One can Play/Pause a song, play a specific track, change a Volume Up and Volume Down between 0% and 100%, play the next or the previous song, repeat the current song, and more. Besides that, several sound effects are also supported, mentioned for different types of music: Normal, Jazz, Classic, Pop, and Rock.
The MP3 2 Click Board™ can be supplied and interfaced with both 3.3V and 5V without the need for any external components. The onboard SMD jumper labeled as VCC SEL allows voltage selection for supply IC, but this Click Board™ communication interface and is designed to be operated only with a 3.3V logic level.
SPECIFICATIONS
Type | MP3 |
Applications | Digital music players, camcorders, speakers, headphones, toys, and more. |
On-board modules | KT403A serial MP3 module, from Shenzhen Qianle Microelectronics Technology Co. Ltd. |
Key Features | MP3 Player, Streaming support for MP3 and WAV. |
Interface | UART |
Compatibility | mikroBUS |
Click board size | M (42.9 x 25.4 mm) |
Input Voltage | 3.3V or 5V |
PINOUT DIAGRAM
This table shows how the pinout on the MP3 2 Click Board™ corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Notes | Pin | Pin | Notes | ||||
---|---|---|---|---|---|---|---|
NC | 1 | AN | PWM | 16 | NC | ||
Reset | RST | 2 | RST | INT | 15 | NC | |
NC | 3 | CS | RX | 14 | TX | UART TX | |
NC | 4 | SCK | TX | 13 | RX | UART RX | |
NC | 5 | MISO | SCL | 12 | NC | ||
NC | 6 | MOSI | SDA | 11 | NC | ||
Power Supply | 3.3V | 7 | 3.3V | 5V | 10 | 5V | Power |
Ground | GND | 8 | GND | GND | 9 | GND | Ground |
ONBOARD SETTINGS AND INDICATORS
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | - | Power LED Indicator |
JP1 | VCC SEL | Left | Power Supply Voltage Selection: Left position 3V3, right position 5V |
LD2 | CHIP CORRECT | - | Chip correct LED indicator |
LD3 | SD CON | - | SD Card connect LED indicator |
Software Support
We provide a library for the MP3 2 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
The library covers all the necessary functions to control the MP3 2 Click Board™. A library performs the communication with the KT403A chip which integrate 16-bit MCU, and audio decoder, a DSP especial for decoding via UART interface.
Key Functions
void mp32_play_mode ( void )
- Play mode function.void mp32_play_next ( void )
- Play next function.void mp32_volume_up ( void )
- Volume up function.
Example Description
The application is composed of three sections :
- System Initialization - Initializes UART, RST pin as output and begins to write log.
- Application Initialization - Initialization driver enables - UART, reset the device, set specify a device play tracks inside ( SD Card ), set volume lvl ( 50% ), set equalizer to normal mode and set commmand for specifying a track to play.
- Application Task - (code snippet) This is an example which demonstrates the use of MP3 2 Click board. Waits for valid user input and executes functions based on set of valid commands. Results are being sent to the Usart Terminal where you can track their changes.
- Commands : 'c' - command list 'p' - play 'o' - pause 's' - stop 'n' - play next 'l' - play previous '+' - volume up '-' - volume down
void application_task ( ) { char received_data; if ( UART_Rdy_Ptr() ) { received_data = UART_Rd_Ptr( ); switch ( received_data ) { case 'c' : { command_list( ); break; } case 'p' : { mp32_play_mode( ); mikrobus_logWrite( " >>> Play", _LOG_LINE ); break; } case 'o' : { mp32_pause_mode( ); mikrobus_logWrite( " >>> Pause", _LOG_LINE ); break; } case 's' : { mp32_stop_mode( ); mikrobus_logWrite( " >>> Stop", _LOG_LINE ); break; } case 'n' : { mp32_play_next( ); mikrobus_logWrite( " >>> Play next", _LOG_LINE ); break; } case 'l' : { mp32_play_previous( ); mikrobus_logWrite( " >>> Play previous", _LOG_LINE ); break; } case '+' : { mp32_volume_up( ); mikrobus_logWrite( " >>> Volume Up", _LOG_LINE ); break; } case '-' : { mp32_volume_down( ); mikrobus_logWrite( " >>> Volume Down", _LOG_LINE ); break; } default : { command_list( ); break; } } } Delay_ms( 1000 ); }
Key Functions
command_list( )
- Display the list of commands.
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- UART
Additional Notes and Information
Depending on the development board you are using, you may need a USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The MP3 2 Click Board™ is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
Software Support
We provide a library for the MP3 2 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Library Description
The library covers all the necessary functions to control the MP3 2 Click Board™. A library performs the communication with the KT403A chip which integrate 16-bit MCU, and audio decoder, a DSP especial for decoding via UART interface.
Key Functions
void mp32_play_mode ( void )
- Play mode function.void mp32_play_next ( void )
- Play next function.void mp32_volume_up ( void )
- Volume up function.
Example Description
The application is composed of three sections :
- System Initialization - Initializes UART, RST pin as output and begins to write log.
- Application Initialization - Initialization driver enables - UART, reset the device, set specify a device play tracks inside ( SD Card ), set volume lvl ( 50% ), set equalizer to normal mode and set commmand for specifying a track to play.
- Application Task - (code snippet) This is an example which demonstrates the use of MP3 2 Click board. Waits for valid user input and executes functions based on set of valid commands. Results are being sent to the Usart Terminal where you can track their changes.
- Commands : 'c' - command list 'p' - play 'o' - pause 's' - stop 'n' - play next 'l' - play previous '+' - volume up '-' - volume down
void application_task ( ) { char received_data; if ( UART_Rdy_Ptr() ) { received_data = UART_Rd_Ptr( ); switch ( received_data ) { case 'c' : { command_list( ); break; } case 'p' : { mp32_play_mode( ); mikrobus_logWrite( " >>> Play", _LOG_LINE ); break; } case 'o' : { mp32_pause_mode( ); mikrobus_logWrite( " >>> Pause", _LOG_LINE ); break; } case 's' : { mp32_stop_mode( ); mikrobus_logWrite( " >>> Stop", _LOG_LINE ); break; } case 'n' : { mp32_play_next( ); mikrobus_logWrite( " >>> Play next", _LOG_LINE ); break; } case 'l' : { mp32_play_previous( ); mikrobus_logWrite( " >>> Play previous", _LOG_LINE ); break; } case '+' : { mp32_volume_up( ); mikrobus_logWrite( " >>> Volume Up", _LOG_LINE ); break; } case '-' : { mp32_volume_down( ); mikrobus_logWrite( " >>> Volume Down", _LOG_LINE ); break; } default : { command_list( ); break; } } } Delay_ms( 1000 ); }
Key Functions
command_list( )
- Display the list of commands.
The full application code, and ready to use projects can be found on our LibStock page.
Other mikroE Libraries used in the example:
- UART
Additional Notes and Information
Depending on the development board you are using, you may need a USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The MP3 2 Click Board™ is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.