soundout.h File Reference
SoundOut MOD-1007 (Somo-14D) audio player interface.
More...
Go to the source code of this file.
Detailed Description
Library for accessing the functionality of the WTV .ad4 audio player
Put the following into your config.h
- - - - - - - - - - - - - - - - - - - - SoundOut defines
- - - - - - - - - - - - - - - - - - - -
define soundout_clk_port PORTA define soundout_clk_pin 1
define soundout_data_port PORTA define soundout_data_pin 2
don't define these if you don't want to use them
define soundout_reset_port PORTA define soundout_reset_pin 3
define soundout_busy_port PORTA define soundout_busy_pin 4
- - - - - - - - - - - - - - - - - - - -
Define Documentation
#define soundout_PLAY_PAUSE_CMD 0xfffe |
#define soundout_STOP_CMD 0xffff |
#define soundout_VOLUME_CMD 0xfff0 |
Function Documentation
uns8 soundout_is_busy |
( |
|
) |
|
00123 {
00124 #ifdef soundout_busy_port
00125 return test_pin(soundout_busy_port, soundout_busy_pin);
00126 #else
00127 return 0;
00128 #endif
00129 }
void soundout_play_pause |
( |
|
) |
|
00057 {
00058 #ifdef soundout_reset_port
00059 clear_pin(soundout_reset_port, soundout_reset_pin);
00060 delay_ms(10);
00061 set_pin(soundout_reset_port, soundout_reset_pin);
00062 #endif
00063 }
void soundout_set_file_id |
( |
uns16 |
file_id |
) |
|
void soundout_set_volume |
( |
uns8 |
level |
) |
|
void soundout_setup_io |
( |
|
) |
|
00041 {
00042
00043 make_output(soundout_clk_port, soundout_clk_pin);
00044 set_pin(soundout_clk_port, soundout_clk_pin);
00045
00046 make_output(soundout_data_port, soundout_data_pin);
00047
00048 #ifdef soundout_reset_port
00049 make_output(soundout_reset_port, soundout_reset_pin);
00050 set_pin(soundout_reset_port, soundout_reset_pin);
00051 #endif
00052 #ifdef soundout_busy_port
00053 make_input(soundout_busy_port, soundout_busy_pin);
00054 #endif
00055 }
void soundout_standby |
( |
|
) |
|
00065 {
00066 #ifdef soundout_reset_port
00067 clear_pin(soundout_reset_port, soundout_reset_pin);
00068
00069
00070
00071 #endif
00072 }
00073 {
00074 #ifdef soundout_reset_port
00075 set_pin(soundout_reset_port, soundout_reset_pin);
00076 #endif
00077 }