PWM audio output (with optional noise shaping and error diffusion) using the PIO.
More...
PWM audio output (with optional noise shaping and error diffusion) using the PIO.
This library uses the hardware_pio system to implement a PWM audio interface
◆ audio_pwm_setup()
const audio_format_t* audio_pwm_setup |
( |
const audio_format_t * |
intended_audio_format, |
|
|
int32_t |
max_latency_ms, |
|
|
const audio_pwm_channel_config_t * |
channel_config0, |
|
|
|
... |
|
) |
| |
max_latency_ms may be -1 (for don't care)
- Parameters
-
intended_audio_format | |
max_latency_ms | |
channel_config0 | |
... | |
- Returns
◆ audio_pwm_default_connect()
- Parameters
-
producer_pool | |
dedicate_core_1 | attempt a default mapping of producer buffers to pio pwm pico_audio output dedicate_core_1 to have core 1 set aside entirely to do work offloading as much stuff from the producer side as possible todo also allow IRQ handler to do it I guess |
◆ audio_pwm_set_enabled()
void audio_pwm_set_enabled |
( |
bool |
enabled | ) |
|
- Parameters
-
enable | true to enable the PWM audio, false to disable |
◆ audio_pwm_set_correction_mode()
bool audio_pwm_set_correction_mode |
( |
enum audio_correction_mode |
mode | ) |
|
Set the PWM correction mode.
- Parameters
-
◆ audio_pwm_get_correction_mode()
enum audio_correction_mode audio_pwm_get_correction_mode |
( |
| ) |
|
Get the PWM correction mode.
- Returns
- mode