llvm-mos-sdk
Functions
sound.h File Reference
#include <stdbool.h>
#include <stdint.h>
#include <neo6502.h>
Include dependency graph for sound.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void neo_sound_reset (void)
 Reset the sound system. More...
 
void neo_sound_reset_channel (uint8_t channel)
 Reset the specified sound channel. More...
 
void neo_sound_beep (void)
 Play the startup beep. More...
 
void neo_sound_queue (uint8_t channel, uint16_t frequency, uint16_t duration, uint16_t slide, uint8_t target)
 Queue a sound. More...
 
void neo_sound_play_effect (uint8_t channel, uint8_t id)
 Play the sound effect. More...
 
uint8_t neo_sound_status (uint8_t channel)
 Query the status of the specified channel. More...
 
uint8_t neo_sound_channel_count (void)
 Query the number of channels. More...
 

Function Documentation

◆ neo_sound_beep()

void neo_sound_beep ( void  )

Play the startup beep.

◆ neo_sound_channel_count()

uint8_t neo_sound_channel_count ( void  )

Query the number of channels.

◆ neo_sound_play_effect()

void neo_sound_play_effect ( uint8_t  channel,
uint8_t  id 
)

Play the sound effect.

Clears the channel queue for the specified channel.

Parameters
channelChannel
idSound effect ID

◆ neo_sound_queue()

void neo_sound_queue ( uint8_t  channel,
uint16_t  frequency,
uint16_t  duration,
uint16_t  slide,
uint8_t  target 
)

Queue a sound.

◆ neo_sound_reset()

void neo_sound_reset ( void  )

Reset the sound system.

◆ neo_sound_reset_channel()

void neo_sound_reset_channel ( uint8_t  channel)

Reset the specified sound channel.

◆ neo_sound_status()

uint8_t neo_sound_status ( uint8_t  channel)

Query the status of the specified channel.

Parameters
channelChannel
Returns
Number of remaining notes in the queue, including the currently played one if any.