Crate wm8731

Source
Expand description

A simple HAL for the Cirrus Logic/Wolfson WM8731 audio codec

This crate provides simple abstractions for the various control registers on the WM8731.

Each function returns a Register struct, representing the address and value for the register. With the exception of active and reset, registers accept a function for configuration.

For example, to power on/off certain features, we can call power_down:

WM8731::power_down(|c| {
    c.line_input().power_off();
    c.adc().power_off();
    c.dac().power_off();
});

Re-exports§

pub use enable_disable::EnableDisable;

Modules§

active
Control to activate/deactivate interface
analog_audio_path
Configuration for analog audio path
digital_audio_interface_format
Configuration for the digital audio interface
digital_audio_path
Configuration for digital audio path
enable_disable
headphone_out
Configuration for headphone outputs
line_in
Configuration for line inputs
power_down
Configuration for power to different parts of the device
sampling
Configuration for sampling
sampling_rate

Structs§

Register
WM8731
A simple HAL for the Cirrus Logic/ Wolfson WM8731 audio codec