CHGame 0.3.0
Libraries for the CHGame handheld
Loading...
Searching...
No Matches
audio::Step Struct Reference

An effect step in three bytes. More...

#include <chgame/Audio.h>

Public Attributes

uint8_t hz
 The pitch in 20 Hz units; 0 = a rest.
 
uint8_t endHz
 The pitch it sweeps to, in 20 Hz units; 0 = none (holds hz).
 
uint8_t ms
 The length in 2 ms units.
 

Detailed Description

An effect step in three bytes.

Write them with AUDIO_STEP() and AUDIO_REST().

20 Hz is under half a percent of a piezo's 1-4 kHz: no ear hears it, and the tables are half the size. A step lasts at most 510 ms.

Member Data Documentation

◆ hz

uint8_t audio::Step::hz

The pitch in 20 Hz units; 0 = a rest.

◆ endHz

uint8_t audio::Step::endHz

The pitch it sweeps to, in 20 Hz units; 0 = none (holds hz).

◆ ms

uint8_t audio::Step::ms

The length in 2 ms units.


The documentation for this struct was generated from the following file: