Aducm3029: Enable low power mode for the reference buffer by setting the RBUFLP bit in Register ADC_CFG1

Hi there,

I want to keep MCU in Flexi mode while using ADC module for power optimization. 

Please let me know how do I set RBUFLP bit in Register ADC_CFG1 in Aducm3029(EVCOG3029LZ board)?

I couldn't find any API for it in the driver. Also, I am unable to set it manually. 



  • Also Please let me know how to set the CNVDONE bit to 1 in the ADC interrupt enable register (Register ADC_IRQ_EN) to enable the interrupt function when the conversion is complete.

  • +1
    •  Analog Employees 
    on Mar 18, 2019 7:36 AM

    Hello ,

    • To set RBUFLP, just add this line before enabling the ADC.

    • The CNVDONE bit in ADC_IRQ_EN is already set in the function adi_adc_Open();



  • Hello ,

    Thank you very much. That worked successfully.

    Now My processor is consuming 1.06mA in flexi mode. 

    I have one question though.

    As per reference manual, We can wake up the controller from the flexi mode ("exception 62"). 

    1. I am still confused that this "exception 62" is to wake up the controller( from flexi to active mode in our case) when there is some analog input data at ADC0 pin? Please correct me if I am wrong. If yes, Can you help me with a sample code or guide me? (I cant keep threshold comparator here since I need to keep processor in low power consumption mode)

    2. I am trying to wake up the controller with let's say function generator Sine wave with 3 Vpp with 200mSec cycle. So how much starting portion of signal I may lose(10% or more?). Actually my task is to wake up the controller with Analog excitation and write digital values in the file for further analysis. Rest of the time controller will be in sleep/flexi mode for low power consumption.

    Please let me know. Waiting for your reply.


    Gopal Vishwakarma

  • +1
    •  Analog Employees 
    on Mar 21, 2019 6:45 AM in reply to Gopal@9028

    Hi ,

    You may use the adi_adc_SetHighLimit and adi_adc_EnableDigitalComparator while still consuming low power. Just make sure to enable only the ALERT in the pREG_ADC0_IRQ_EN register.

    // Enable only the ALERT interrupt
    *pREG_ADC0_IRQ_EN = 0x1000;
    // Configure the comparator
    adi_adc_SetHighLimit(hDevice, ADI_ADC_CHANNEL_0, true, 1024);
    adi_adc_EnableDigitalComparator(hDevice, true);
    // Enter Flexi mode
    adi_pwr_EnterLowPowerMode(ADI_PWR_MODE_FLEXI, NULL, 0);


  • Thanks .  Your answer helped.

    Now it is consuming 0.7mA in flexi mode.

    Let me read now adc signal and store in file.