Struct SYN_Buzzer¶
Non-blocking piezo buzzer context.
#include <syn_buzzer.h>
Public Attributes¶
| Type | Name |
|---|---|
| bool | active_high |
| uint32_t | duration_ms |
| uint32_t | elapsed_ms |
| uint32_t | freq_hz |
| bool | is_playing |
| size_t | pattern_count |
| const uint16_t * | pattern_durs |
| const uint16_t * | pattern_freqs |
| size_t | pattern_index |
| SYN_GPIO_Pin | pin |
Public Attributes Documentation¶
variable active_high¶
True if logic HIGH activates buzzer
variable duration_ms¶
Current tone duration in milliseconds
variable elapsed_ms¶
Time elapsed for current tone
variable freq_hz¶
Current tone frequency in Hz
variable is_playing¶
True if currently outputting tone
variable pattern_count¶
Number of notes in pattern
variable pattern_durs¶
Sequence of durations for melody/pattern
variable pattern_freqs¶
Sequence of frequencies for melody/pattern
variable pattern_index¶
Active note index
variable pin¶
GPIO Pin identifier
The documentation for this class was generated from the following file src/syntropic/output/syn_buzzer.h