11static const uint8_t PCM5122_REG_PAGE_SELECT = 0x00;
12static const uint8_t PCM5122_REG_RESET = 0x01;
13static const uint8_t PCM5122_REG_MUTE = 0x03;
14static const uint8_t PCM5122_REG_GPIO_ENABLE = 0x08;
15static const uint8_t PCM5122_REG_PLL_REF = 0x0D;
16static const uint8_t PCM5122_REG_ERROR_DETECT = 0x25;
17static const uint8_t PCM5122_REG_AUDIO_FORMAT = 0x28;
18static const uint8_t PCM5122_REG_DVOL_LEFT = 0x3D;
19static const uint8_t PCM5122_REG_DVOL_RIGHT = 0x3E;
20static const uint8_t PCM5122_REG_GPIO_OUTPUT_SELECT = 0x50;
21static const uint8_t PCM5122_GPIO_OUTPUT_SELECT_REGISTER = 0x02;
22static const uint8_t PCM5122_REG_GPIO_OUTPUT = 0x56;
23static const uint8_t PCM5122_REG_GPIO_INVERT = 0x57;
24static const uint8_t PCM5122_REG_GPIO_INPUT = 0x77;
27static const uint8_t PCM5122_RESET_MODULES = 0x10;
28static const uint8_t PCM5122_AUDIO_FORMAT_I2S = 0x00;
30static const uint8_t PCM5122_AUDIO_FORMAT_ALEN_16BIT = 0x00;
31static const uint8_t PCM5122_AUDIO_FORMAT_ALEN_24BIT = 0x02;
32static const uint8_t PCM5122_AUDIO_FORMAT_ALEN_32BIT = 0x03;
33static const uint8_t PCM5122_ERROR_DETECT_IGNORE_CLKHALT = (1 << 3);
34static const uint8_t PCM5122_ERROR_DETECT_DISABLE_DIV_AUTOSET = (1 << 1);
35static const uint8_t PCM5122_PLL_REF_MASK = (7 << 4);
36static const uint8_t PCM5122_PLL_REF_SOURCE_BCK = (1 << 4);
46 void setup()
override;
This Class provides the methods to read/write bytes from/to an i2c device.
bool set_volume(float volume) override
bool set_mute_on() override
bool set_mute_off() override
void dump_config() override
bool select_page_(uint8_t page)
float get_setup_priority() const override
void set_bits_per_sample(PCM5122BitsPerSample bits_per_sample)
PCM5122BitsPerSample bits_per_sample_
@ PCM5122_BITS_PER_SAMPLE_16
@ PCM5122_BITS_PER_SAMPLE_32
@ PCM5122_BITS_PER_SAMPLE_24
constexpr float IO
For components that represent GPIO pins like PCF8573.