User`s manual
120 www.rabbit.com Applications Programming
flexToneLoad
int flexToneLoad(char *buffer, int bufsize, char repeat);
DESCRIPTION
Loads tone samples to be played into the tone driver buffer. This sample will be played repeatedly
for the specified number of repeats. If the number of repeats is negative, the clip will be repeated
indefinitely until flexToneStop() is called.
PARAMETERS
buffer Pointer to an array of bytes to be loaded.
bufsize Number of bytes in the buffer.
repeat Number of times the buffer contents will be repeated. A value >128 will re-
peat the buffer indefinitely. A value of 0 or 1 will play the tone once.
RETURN VALUE
The number of bytes actually loaded into the driver. This number may be smaller than the request-
ed bufsize or it may even be 0 because of limits on the size of the audio driver's internal buffer.
SEE ALSO
flexSpeakerPWM, flexToneActivate, flexToneShutdown,
flexToneStop
flexToneStop
void flexToneStop();
DESCRIPTION
Immediately stops any tone that is playing.
RETURN VALUE
None.
SEE ALSO
flexSpeakerPWM, flexToneActivate, flexToneShutdown,
flexToneLoad