mp3 2.0.0.0
Public function

Functions

void mp3_cfg_setup (mp3_cfg_t *cfg)
 Config Object Initialization function.
 
err_t mp3_init (mp3_t *ctx, mp3_cfg_t *cfg)
 Initialization function.
 
void mp3_reset (mp3_t *ctx)
 Functions for reset MP3 module.
 
uint8_t mp3_is_busy (mp3_t *ctx)
 Function that checks whether busy mp3.
 
void mp3_cmd_write (mp3_t *ctx, uint8_t address, uint16_t input)
 Function writes one byte (command) to MP3.
 
uint16_t mp3_cmd_read (mp3_t *ctx, uint8_t address)
 Function reads command from MP3.
 
err_t mp3_data_write (mp3_t *ctx, uint8_t input)
 Function writes one byte ( data ) to MP3.
 
err_t mp3_data_write_32 (mp3_t *ctx, uint8_t *input32)
 Function Write 32 bytes ( data ) to MP3.
 
void mp3_set_volume (mp3_t *ctx, uint8_t vol_left, uint8_t vol_right)
 Function set volume to MP3 click for left and right channels.
 

Detailed Description

Function Documentation

◆ mp3_cfg_setup()

void mp3_cfg_setup ( mp3_cfg_t * cfg)

Config Object Initialization function.

Parameters
cfgClick configuration structure.

This function initializes click configuration structure to init state.

Note
All used pins will be set to unconnected state.

◆ mp3_cmd_read()

uint16_t mp3_cmd_read ( mp3_t * ctx,
uint8_t address )

Function reads command from MP3.

Parameters
ctxClick object.
Returns
command that is read

◆ mp3_cmd_write()

void mp3_cmd_write ( mp3_t * ctx,
uint8_t address,
uint16_t input )

Function writes one byte (command) to MP3.

Parameters
ctxClick object.
addressadddress of register whitch be written
inputcommand which be written

◆ mp3_data_write()

err_t mp3_data_write ( mp3_t * ctx,
uint8_t input )

Function writes one byte ( data ) to MP3.

Parameters
ctxClick object.
inputdata which be written

◆ mp3_data_write_32()

err_t mp3_data_write_32 ( mp3_t * ctx,
uint8_t * input32 )

Function Write 32 bytes ( data ) to MP3.

Parameters
ctxClick object.
input32buffer of 32 bytes which be written

◆ mp3_init()

err_t mp3_init ( mp3_t * ctx,
mp3_cfg_t * cfg )

Initialization function.

Parameters
mp3Click object.
cfgClick configuration structure.

This function initializes all necessary pins and peripherals used for this click.

◆ mp3_is_busy()

uint8_t mp3_is_busy ( mp3_t * ctx)

Function that checks whether busy mp3.

Parameters
ctxClick object.
Returns
1 - is Busy / 0 - is not busy

◆ mp3_reset()

void mp3_reset ( mp3_t * ctx)

Functions for reset MP3 module.

◆ mp3_set_volume()

void mp3_set_volume ( mp3_t * ctx,
uint8_t vol_left,
uint8_t vol_right )

Function set volume to MP3 click for left and right channels.

Parameters
ctxClick object.
vol_leftVolume level for left channel.
vol_rightVolume level for right channel.
Note
Maximum volume is 0x00 and total silence is 0xFE.