r65emu/sound.h

16 lines
267 B
C
Raw Normal View History

2018-09-06 08:18:23 +00:00
#ifndef __SOUND_H__
#define __SOUND_H__
class Sound {
public:
void begin(unsigned pin, unsigned freq);
const uint8_t *play(const uint8_t *bytes, unsigned size);
2018-09-06 12:25:24 +00:00
void on_tick();
private:
volatile const uint8_t *_bytes;
volatile unsigned _size, _off;
2018-09-06 08:18:23 +00:00
};
#endif