DA7212 init sequence for ard-audio-da7212

Hi,

Got a ard-audio-da7212 and trying to have the DA7212 initialized in the following setup

Slave, full duplex (record/playback), stereo, 16bit, 48KHz samplerate, 24.576MHz MCLK

Recording from biased mic, playback on headphones.

Is it possible for someone to provide me with the register values/sequence for that ?

Hope someone could help,

Regards,

Aristarchos

  • Stereo MIC single ended to HP and DAI via ADC and DAC.txt
    //************************ COPYRIGHT INFORMATION **************************// 
    //                                                                         //
    // This program contains proprietary information which is a trade secret   //
    // of Dialog Semiconductor and is also protected as an published work      //
    // under applicable Copyright laws. Recipient is to retain this program    //
    // in confidence and is not permitted to use or make copies thereof other  //
    // than as permitted in a written agreement with Dialog Semiconductor.     //
    //                                                                         //
    //*************************************************************************//
    
    //***************************** FILE HEADER *******************************//
    //                                                                         //
    // Filename:    Stereo MIC single ended to ADC DAC to HP.txt    				   // 
    // Author:		Barry Mcadam                                      //
    // Date:		15-Aug-22                                               //
    // Description:	This script setups the Microphone to I2S path.      	   //
    //				A stereo microphone should be connected to J30. The output //
    //				will be present on the I2S interface.					   //
    //				The gain of the microphone inputs can be set via registers //
    //				0x39, 0x3A, 0x34, 0x35.									   // 
    //*************************************************************************//
    
    WRITE DA7212 0x92	0x00 //Set Ramp rate to default
    
    DELAY 40
    
    WRITE DA7212 0x90	0x80 //Enable Digital LDO
    WRITE DA7212 0x29	0xCC //Enable AIF 32bit I2S mode
    WRITE DA7212 0x22	0x0B //Set incoming sample rate to 48kHz
    WRITE DA7212 0x94	0x02 //Set PC sync to resync
    WRITE DA7212 0x27	0x04 //PLL_CTRL PLL disabled
     
    WRITE DA7212 0x90	0x80 //Enable Digital LDO
    WRITE DA7212 0x92	0x02 //Set Ramp rate to 1 second
    WRITE DA7212 0x29	0xC0 //Enable AIF 16bit I2S mode
    WRITE DA7212 0x22	0x08 //Set incoming sample rate to 48kHz
    WRITE DA7212 0x94	0x02 //Set PC sync to resync
    WRITE DA7212 0x27	0x08 //PLL for 24.576 MHZ
    
    DELAY 500
    
    WRITE DA7212 0x2A	0x10 //Route ADC to DAC
    WRITE DA7212 0x62	0x19 //Enable MICBIAS at 2.2V
    WRITE DA7212 0x32	0x02 //MIXIN_L input from MIC1
    WRITE DA7212 0x33	0x02 //MIXIN_R input from MIC2
    WRITE DA7212 0x4B	0x08 //MIXOUT_L input from DACL
    WRITE DA7212 0x4C	0x08 //MIXOUT_R input from DACR
    WRITE DA7212 0x47	0xF1 //Enable charge pump, signal size mode
    WRITE DA7212 0x95	0x36 //Set CP threshold to 0x36
    WRITE DA7212 0x96	0xA5 //Set CP Tau DELAY to 64ms
    WRITE DA7212 0x48	0x2D //Set volume to -12dB
    WRITE DA7212 0x49	0x2D //Set volume to -12dB
    WRITE DA7212 0x50	0xFC //Enable MIC, Mix and ADC
    WRITE DA7212 0x51	0xF1 //Enable DAC, Mix and HP
    
    DELAY 500
    
    WRITE DA7212 0x63	0x84 //Set Mic1 to be single ended from MIC1_SE connector
    WRITE DA7212 0x64	0x84 //Set Mic2 to be single ended from MIC1_SE connector
    WRITE DA7212 0xB5	0x60 //Set tone gen gain to -18dB
    
    

    Hi, please see attached Thanks JE_REN