![]() |
roneos
Operating System for the r-one robot
|
Files for controlling audio speaker and MIDI files. More...
#include "VS1053_PatchTable.h"
Go to the source code of this file.
Functions | |
void | audioInit (void) |
Initialize audio chip. More... | |
void | audioNoteOn (uint8 instrument, uint8 key, uint8 velocity, uint32 duration) |
Plays given note for given time. This will schedule a note off message for the sound chip. More... | |
void | audioNoteOff (uint8 instrument, uint8 key) |
Turns off given note. More... | |
void | audioNoteOffAll (void) |
Turns off all notes. More... | |
void | audioVolume (uint8 volume) |
Set the volume level. More... | |
void | soundChipTest (uint8 test) |
Turns off sound. Sends audioMIDINoteOff data through SSI to soundchip. More... | |
void | playMajorChord (uint8 instrument, uint8 baseNote, uint8 volume, uint32 duration) |
Plays a three note major chord. More... | |
void | playMinorChord (uint8 instrument, uint8 baseNote, uint8 volume, uint32 duration) |
Plays a three note minor chord. More... | |
Files for controlling audio speaker and MIDI files.
void audioInit | ( | void | ) |
Initialize audio chip.
void audioNoteOff | ( | uint8 | instrument, |
uint8 | key | ||
) |
Turns off given note.
instrument | Instrument to stop |
key | Note to turn off |
void audioNoteOffAll | ( | void | ) |
Turns off all notes.
void audioNoteOn | ( | uint8 | instrument, |
uint8 | key, | ||
uint8 | velocity, | ||
uint32 | duration | ||
) |
Plays given note for given time. This will schedule a note off message for the sound chip.
instrument | Instrument to play |
key | Note to play |
velocity | the velocity (volume) to play. range is from 0-127 |
duration | Duration of the note (ms) |
void audioVolume | ( | uint8 | volume) |
Set the volume level.
volume | the output level for left and right channels. 0 = total silence, 255 = max volume |
void playMajorChord | ( | uint8 | instrument, |
uint8 | baseNote, | ||
uint8 | volume, | ||
uint32 | duration | ||
) |
Plays a three note major chord.
instrument | |
baseNote | root of the chord (played at baseNote + middleC) |
volume | the output level for left and right channels. 0 = total silence, 255 = max volume |
duration | Duration of the note (ms) |
void playMinorChord | ( | uint8 | instrument, |
uint8 | baseNote, | ||
uint8 | volume, | ||
uint32 | duration | ||
) |
Plays a three note minor chord.
instrument | |
baseNote | root of the chord (played at baseNote + middleC) |
volume | the output level for left and right channels. 0 = total silence, 255 = max volume |
duration | Duration of the note (ms) |
void soundChipTest | ( | uint8 | test) |
Turns off sound. Sends audioMIDINoteOff data through SSI to soundchip.
test |