//
// Created by ilya on 09.01.24.
//

#ifndef NAU88U10YG_REGS_H
#define NAU88U10YG_REGS_H

//0b00110100

#define NAU88U10YG_ADDRESS_READ 0x35
#define NAU88U10YG_ADDRESS_WRITE 0x34
#define NAU88U10YG_IO_TIMEOUT 0xFFFF

//// Register Bits ////

#define NAU88U10YG_REG_SOFTWARE_RESET 0x00
// POWER MANAGEMENT //
#define NAU88U10YG_REG_POWER_MANAGEMENT_1 0x01
#define NAU88U10YG_REG_POWER_MANAGEMENT_2 0x02
#define NAU88U10YG_REG_POWER_MANAGEMENT_3 0x03
// AUDIO CONTROL //
#define NAU88U10YG_REG_AUDIO_INTERFACE 0x04
#define NAU88U10YG_REG_COMPANDING 0x05
#define NAU88U10YG_REG_CLOCK_CONTROL_1 0x06
#define NAU88U10YG_REG_CLOCK_CONTROL_2 0x07
#define NAU88U10YG_REG_DAC_CTRL 0x0A
#define NAU88U10YG_REG_DAC_VOLUME 0x0B
#define NAU88U10YG_REG_ADC_CTRL 0x0E
#define NAU88U10YG_REG_ADC_VOLUME 0x0F
// EQUALISER //
#define NAU88U10YG_REG_EQ1_LOW_CUTOFF 0x12
#define NAU88U10YG_REG_EQ2_PEAK1 0x13
#define NAU88U10YG_REG_EQ3_PEAK2 0x14
#define NAU88U10YG_REG_EQ4_PEAK3 0x15
#define NAU88U10YG_REG_EQ5_HIGH_CUTOFF 0x16
// DIGITAL TO ANALOG (DAC) LIMITER //
#define NAU88U10YG_REG_DAC_LIMITER1 0x17
#define NAU88U10YG_REG_DAC_LIMITER2 0x18
// NOTCH FILTER //
#define NAU88U10YG_REG_NOTCH_FILTER_HIGH_1 0x1B
#define NAU88U10YG_REG_NOTCH_FILTER_LOW_1 0x1C
#define NAU88U10YG_REG_NOTCH_FILTER_HIGH_2 0x1D
#define NAU88U10YG_REG_NOTCH_FILTER_LOW_2 0x1E
// ALC CONTROL //
#define NAU88U10YG_REG_ALC_CTRL_1 0x20
#define NAU88U10YG_REG_ALC_CTRL_2 0x21
#define NAU88U10YG_REG_ALC_CTRL_3 0x22
#define NAU88U10YG_REG_NOISE_GATE 0x23
// PLL CONTROL //
#define NAU88U10YG_REG_PLL_N_CTRL 0x24
#define NAU88U10YG_REG_PLL_K_1 0x25
#define NAU88U10YG_REG_PLL_K_2 0x26
#define NAU88U10YG_REG_PLL_K_3 0x27
// INPUT, OUTPUT & MIXER CONTROL //
#define NAU88U10YG_REG_ATTENUATION_CTRL 0x28
#define NAU88U10YG_REG_INPUT_CTRL 0x2C
#define NAU88U10YG_REG_PGA_GAIN 0x2D
#define NAU88U10YG_REG_ADC_BOOST 0x2F
#define NAU88U10YG_REG_OUTPUT_CTRL 0x31
#define NAU88U10YG_REG_MIXER_CTRL 0x32
#define NAU88U10YG_REG_SPKOUT_VOLUME 0x36
#define NAU88U10YG_REG_MONO_MIXER_CONTROL 0x38
// LOW POWER CONTROL //
#define NAU88U10YG_REG_POWER_MANAGEMENT_4 0x3A
// PCM TIME SLOT & ADCOUT IMPEDANCE OPTION CONTROL //
#define NAU88U10YG_REG_POWER_TIME_SLOT 0x3B
#define NAU88U10YG_REG_POWER_ADCOUT_DRIVE 0x3C
// REGISTER ID //
#define NAU88U10YG_REG_POWER_SILCON_REVISION 0x3E
#define NAU88U10YG_REG_POWER_2WIRE_ID 0x3F
#define NAU88U10YG_REG_POWER_ADDITIONAL_ID 0x40
#define NAU88U10YG_REG_POWER_RESERVED 0x41
#define NAU88U10YG_REG_POWER_HIGH_VOLTAGE_CTRL 0x45
#define NAU88U10YG_REG_POWER_ALC_ENHANCEMENT_1 0x46
#define NAU88U10YG_REG_POWER_ALC_ENHANCEMENT_2 0x47
#define NAU88U10YG_REG_POWER_ADDITIONAL_IF_CTRL 0x49
#define NAU88U10YG_REG_POWER_POWERTIEOFF_CTRL 0x4B
#define NAU88U10YG_REG_AGC_P2P_DETECTOR 0x4C
#define NAU88U10YG_REG_AGC_PEAK_DETECTOR 0x4D
#define NAU88U10YG_REG_CONTROL_AND_STATUS 0x4E
#define NAU88U10YG_REG_OUTPUT_TIEOFF_CTRL 0x4F




#endif //NAU88U10YG_REGS_H
