This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSPM0L1106: Not able to achieve 1uA on standby mode - sysconfig having Timer, I2C, ADC, UART and GPIO

Part Number: MSPM0L1106
Other Parts Discussed in Thread: SYSCONFIG, TPS8804

Hi TI Team,

Summary: 
Please suggest conditions to get 1uA consumption on standby mode.

Details:

Circuit : 
    Input Volt to Circuit: 24V
    Circuit contains : DC-DC converter, AFE IC-TI TPS 8804, MCU
    DC-DC converter consumes: 60uA
    Based on data sheet AFE by disabling Input Amplifier, Phot gain Amplifier, LED LDO SLC Tx and SLC      RX, AFE consumes 15uA (MCU LDO enabled for supplying MCU volt)

We tried MCU 1uA current consumption on standby mode for the below code.
Main()
{
1. In sysconfig enabled the UART,I2C, GPIO and ADC, Timer and standby 0
2. MCU connected with AFE IC - TI TPS8804
3. In code:
    a. Power Init ( Init of all peripheral)
    b. Disable AFE Blocks - Input Amplifier, Photo gain Amplifier, LED LDO SLC Tx and SLC RX
    c. Call DL_SYSCTL_enableSleepOnExit();
    d. Disable power to I2C, ADC and UART
    f. start timer of standby
    g. While (1) {
           WFI();
      } 
}

#if 1 
void TIMER_0_INST_IRQHandler(void)
{
    
    switch (DL_TimerG_getPendingInterrupt(TIMER_0_INST)) {
        case DL_TIMER_IIDX_ZERO:
           
            DL_TimerG_stopCounter(TIMER_0_INST);


            DL_GPIO_togglePins(GPIO_LEDS_PORT,GPIO_LEDS_LD1_LED1_PIN);
            
            
            DL_Timer_setLoadValue(TIMER_0_INST, TIMER_VALUE_5000_MILLISECONDS);
           
            DL_TimerG_startCounter(TIMER_0_INST);
            break;
        default:
            break;
    }
}
#endif
Enclosed the code: StandbyCode.c 


Based on this,
Expected Current is: 60+15+1 = 76uA
Actual Current we are getting: 120uA.

Please guide us to acheive 1uA (Totally 76uA) on standby mode.

Thanks
Selvam

  • Hi Selvam,
    I believe you can try using STANDBY1 instead of STANDBY0. This is one of our lowest power modes we have in the device while the device is still functional.

    Best Regards,

    Diego Abad

  • Hi Diego,

    we tried with STANDBY1 too, still we are getting 120uA.

    Please suggest on Do we need to disable any other driver before entering into standby mode?

    Thanks

    Selvam

  • Hi Selvam,
    Can you provide the .sysconfig file you use in your application? I should be able to replicate the issue on the bench and possibly find a recommendation to reduce power consumption.
    Best Regards,
    Diego Abad

  • Hi Diego,

    Please have .sysconfig file used in application (Saved and as text) and thanks for the help.

    .

    /**
     * These arguments were used when this file was generated. They will be automatically applied on subsequent loads
     * via the GUI or CLI. Run CLI with '--help' for additional information on how to override these arguments.
     * @cliArgs --device "MSPM0L110X" --part "Default" --package "VQFN-32(RHB)" --product "mspm0_sdk@2.10.00.04"
     * @v2CliArgs --device "MSPM0L1106" --package "VQFN-32(RHB)" --product "mspm0_sdk@2.10.00.04"
     * @versions {"tool":"1.26.2+4477"}
     */
    
    /**
     * Import the modules used in this configuration.
     */
    const ADC12  = scripting.addModule("/ti/driverlib/ADC12", {}, false);
    const ADC121 = ADC12.addInstance();
    const Board  = scripting.addModule("/ti/driverlib/Board");
    const GPIO   = scripting.addModule("/ti/driverlib/GPIO", {}, false);
    const GPIO1  = GPIO.addInstance();
    const I2C    = scripting.addModule("/ti/driverlib/I2C", {}, false);
    const I2C1   = I2C.addInstance();
    const PWM    = scripting.addModule("/ti/driverlib/PWM", {}, false);
    const PWM1   = PWM.addInstance();
    const SYSCTL = scripting.addModule("/ti/driverlib/SYSCTL");
    const TIMER  = scripting.addModule("/ti/driverlib/TIMER", {}, false);
    const TIMER1 = TIMER.addInstance();
    const TIMER2 = TIMER.addInstance();
    const UART   = scripting.addModule("/ti/driverlib/UART", {}, false);
    const UART1  = UART.addInstance();
    const VREF   = scripting.addModule("/ti/driverlib/VREF");
    
    /**
     * Write custom configuration values to the imported modules.
     */
    ADC121.$name                      = "ADC12_0";
    ADC121.sampClkSrc                 = "DL_ADC12_CLOCK_ULPCLK";
    ADC121.powerDownMode              = "DL_ADC12_POWER_DOWN_MODE_MANUAL";
    ADC121.adcMem0chansel             = "DL_ADC12_INPUT_CHAN_2";
    ADC121.sampleTime0                = "12us";
    ADC121.adcMem0vref                = "VREF";
    ADC121.adcMem0avgen               = true;
    ADC121.adcMem1vref                = "VREF";
    ADC121.adcMem1chansel             = "DL_ADC12_INPUT_CHAN_8";
    ADC121.enabledInterrupts          = ["DL_ADC12_INTERRUPT_MEM0_RESULT_LOADED","DL_ADC12_INTERRUPT_MEM1_RESULT_LOADED"];
    ADC121.enableHWAverage            = false;
    ADC121.startAdd                   = 1;
    ADC121.enabledADCMems             = [0,1];
    ADC121.adcPin8Config.$name        = "ti_driverlib_gpio_GPIOPinGeneric6";
    ADC121.peripheral.$assign         = "ADC0";
    ADC121.peripheral.adcPin2.$assign = "PA25";
    ADC121.peripheral.adcPin8.$assign = "PA16";
    ADC121.adcPin2Config.$name        = "ti_driverlib_gpio_GPIOPinGeneric0";
    
    Board.peripheral.$assign          = "DEBUGSS";
    Board.peripheral.swclkPin.$assign = "PA20";
    Board.peripheral.swdioPin.$assign = "PA19";
    
    GPIO1.$name                          = "GPIO_LEDS";
    GPIO1.port                           = "PORTA";
    GPIO1.associatedPins.create(4);
    GPIO1.associatedPins[0].$name        = "USER_LED_1";
    GPIO1.associatedPins[0].initialValue = "SET";
    GPIO1.associatedPins[0].assignedPin  = "26";
    GPIO1.associatedPins[0].pin.$assign  = "PA26";
    GPIO1.associatedPins[1].assignedPin  = "4";
    GPIO1.associatedPins[1].$name        = "LD1_LED2";
    GPIO1.associatedPins[1].initialValue = "SET";
    GPIO1.associatedPins[1].pin.$assign  = "PA4";
    GPIO1.associatedPins[2].$name        = "LD1_LED1";
    GPIO1.associatedPins[2].assignedPin  = "1";
    GPIO1.associatedPins[2].pin.$assign  = "PA1";
    GPIO1.associatedPins[3].$name        = "RI_LED";
    GPIO1.associatedPins[3].assignedPin  = "5";
    GPIO1.associatedPins[3].pin.$assign  = "PA5";
    
    I2C1.$name                     = "I2C_0";
    I2C1.advAnalogGlitchFilter     = "DISABLED";
    I2C1.basicEnableController     = true;
    I2C1.peripheral.$assign        = "I2C0";
    I2C1.peripheral.sdaPin.$assign = "PA10";
    I2C1.peripheral.sclPin.$assign = "PA11";
    I2C1.sdaPinConfig.$name        = "ti_driverlib_gpio_GPIOPinGeneric4";
    I2C1.sclPinConfig.$name        = "ti_driverlib_gpio_GPIOPinGeneric5";
    
    PWM1.$name                              = "PWM_1";
    PWM1.clockPrescale                      = 20;
    PWM1.ccIndex                            = [0];
    PWM1.timerCount                         = 4000;
    PWM1.PWM_CHANNEL_0.$name                = "ti_driverlib_pwm_PWMTimerCC0";
    PWM1.PWM_CHANNEL_0.dutyCycle            = 5;
    PWM1.ccp0PinConfig.$name                = "ti_driverlib_gpio_GPIOPinGeneric3";
    PWM1.ccp0PinConfig.direction            = scripting.forceWrite("OUTPUT");
    PWM1.ccp0PinConfig.hideOutputInversion  = scripting.forceWrite(false);
    PWM1.ccp0PinConfig.onlyInternalResistor = scripting.forceWrite(false);
    PWM1.ccp0PinConfig.passedPeripheralType = scripting.forceWrite("Digital");
    PWM1.peripheral.$assign                 = "TIMG1";
    PWM1.peripheral.ccp0Pin.$assign         = "PA14";
    
    SYSCTL.MFCLKEn     = true;
    SYSCTL.MFPCLKEn    = true;
    SYSCTL.powerPolicy = "STANDBY0";
    SYSCTL.SYSOSC_Freq = 4000000;
    
    TIMER1.interrupts         = ["ZERO"];
    TIMER1.timerMode          = "PERIODIC";
    TIMER1.$name              = "LP_PRE_Timer_TIMG4";
    TIMER1.timerClkPrescale   = 50;
    TIMER1.timerClkDiv        = 2;
    TIMER1.timerPeriod        = "500 ms";
    TIMER1.peripheral.$assign = "TIMG4";
    
    TIMER2.$name              = "TIMER_0";
    TIMER2.interrupts         = ["ZERO"];
    TIMER2.timerMode          = "PERIODIC";
    TIMER2.timerPeriod        = "500 ms";
    TIMER2.timerClkPrescale   = 33;
    TIMER2.timerClkSrc        = "LFCLK";
    TIMER2.peripheral.$assign = "TIMG0";
    
    UART1.$name             = "UART_0";
    UART1.txPinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric1";
    UART1.rxPinConfig.$name = "ti_driverlib_gpio_GPIOPinGeneric2";
    
    VREF.basicIntVolt       = "DL_VREF_BUFCONFIG_OUTPUT_2_5V";
    VREF.peripheral.$assign = "VREF";
    
    const ProjectConfig              = scripting.addModule("/ti/project_config/ProjectConfig", {}, false);
    ProjectConfig.migrationCondition = true;
    
    /**
     * Pinmux solution for unlocked pins/peripherals. This ensures that minor changes to the automatic solver in a future
     * version of the tool will not impact the pinmux you originally saw.  These lines can be completely deleted in order to
     * re-solve from scratch.
     */
    SYSCTL.peripheral.$suggestSolution      = "SYSCTL";
    UART1.peripheral.$suggestSolution       = "UART0";
    UART1.peripheral.rxPin.$suggestSolution = "PA18";
    UART1.peripheral.txPin.$suggestSolution = "PA17";
    

    Thanks

    Selvam

  • Hi Selvam,
    I confirmed that the example you provided consumes more than an empty project. I believe it could be due to the GPIOs being driven in the application. My recommendation is to narrow down which modules in your system consume the most power, and disable the module's functionality and power, as mentioned in the Technical Reference Manual, to see the current decrease in the application. 
    Best Regards,
    Diego Abad

  • Good day Diego,

    Thanks for the confirmation.

    As of now we are disabling the module's power using the below functions

    DL_GPIO_disablePower(GPIOA);
    DL_I2C_disablePower(I2C_0_INST);
    DL_ADC12_disablePower(ADC12_0_INST);
    DL_UART_disablePower(UART_0_INST);

    Apart from these,
    Do we need to disable the module's functionality like below
    DL_I2C_disableController(I2C_0_INST);
    DL_UART_Main_disable(UART_0_INST);
    DL_ADC12_disableConversions(ADC12_0_INST);

    Or do we have any function like I2C_DeInit or I2C_Close();

    Please suggest.

    Thanks
    Selvam

  • Hi Selvam,
    I think disabling the modules and then disabling the power will be a good way to do so. As for the I2C, I recommend the reset the peripheral, disable the module, and disable the power. 

    Best Regards,

    Diego Abad

**Attention** This is a public forum