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.

MSPM0G3507: Disable Power while putting device in sleep or low power mode

Part Number: MSPM0G3507

Tool/software:

Hi,

I am trying to put my device (MSPM0G3507) in low power mode by below lines:

Before putting my device into sleep mode i also need to disable respective peripherals to maintain 3uA consumption in sleep mode.

I have written following code to maintain consumption of 3uA. 

So, my question is : Is it necessary to do all these setting to peripherals while entering into low power mode? or am i doing something wrong. 

  • Hi, 

    Do you use syscfg? (system configuration tool)
    If you are using syscfg, you can directly reset all peripherals like this:

    Fullscreen
    1
    2
    3
    DL_GPIO_reset(GPIOA);
    DL_GPIO_reset(GPIOB);
    DL_MCAN_reset(MCAN0_INST);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    And then after waking up, call syscfg generated function to configure all peripherals:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    SYSCONFIG_WEAK void SYSCFG_DL_init(void)
    {
    SYSCFG_DL_initPower();
    SYSCFG_DL_GPIO_init();
    /* Module-Specific Initializations*/
    SYSCFG_DL_SYSCTL_init();
    SYSCFG_DL_MCAN0_init();
    SYSCFG_DL_SYSCTL_CLK_init();
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Regards,

    Helic

  • Hello ,

    Thanks for your reply.

    Yes, we are using syscfg.

    As per your suggestion, I have modified my code as below.

    But still while entering into low power mode, consumption is 500-600uA .

    So, is there any more commands that is required?

    Regards,

    Meet

  • Hi, 

    The method I mentioned didn't reset the IOMUX function.

    Only shutdown the M0's internal peripherals.

    I think there is still some consumption from IO.

    Try to configure these IOMUX configuration like what you previous does.

    Such as code below to add pulldown resistor:

    Fullscreen
    1
    IOMUX->SECCFG.PINCM[pincmIndex] = ((IOMUX->SECCFG.PINCM[pincmIndex])&(0xFFFCFFFF))|(0x00030000);
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Regards,

    Helic

  • Hello ,

    But we have observed,  For the different peripherals we need to do custom code. for example 

    /*sleep I2C_0*/
    DL_I2C_disableController(I2C_0_INST);
    DL_GPIO_initPeripheralInputFunctionFeatures(GPIO_I2C_0_IOMUX_SDA,
    GPIO_I2C_0_IOMUX_SDA_FUNC, DL_GPIO_INVERSION_DISABLE,
    DL_GPIO_RESISTOR_PULL_DOWN, DL_GPIO_HYSTERESIS_DISABLE,
    DL_GPIO_WAKEUP_DISABLE);
    DL_GPIO_initPeripheralInputFunctionFeatures(GPIO_I2C_0_IOMUX_SCL,
    GPIO_I2C_0_IOMUX_SCL_FUNC, DL_GPIO_INVERSION_DISABLE,
    DL_GPIO_RESISTOR_PULL_DOWN, DL_GPIO_HYSTERESIS_DISABLE,
    DL_GPIO_WAKEUP_DISABLE);

    /*sleep SPI_1*/
    DL_GPIO_initPeripheralOutputFunction(
    GPIO_SPI_1_IOMUX_SCLK, DL_GPIO_RESISTOR_PULL_DOWN);
    DL_GPIO_initPeripheralOutputFunction(
    GPIO_SPI_1_IOMUX_PICO, DL_GPIO_RESISTOR_PULL_DOWN);
    DL_GPIO_initPeripheralInputFunction(
    GPIO_SPI_1_IOMUX_POCI, DL_GPIO_RESISTOR_PULL_DOWN);

    /*sleep Uart_0*/
    DL_UART_Main_disable(UART_0_INST);
    DL_GPIO_initPeripheralInputFunction(
    GPIO_UART_0_IOMUX_RX, IOMUX_PINCM22_PF_UNCONNECTED);
    DL_GPIO_initPeripheralInputFunction(
    GPIO_UART_0_IOMUX_TX, IOMUX_PINCM21_PF_UNCONNECTED);

    So this is required or we are doing something wrong. or is there any shortcut.?

  • Hi, 

    Configure IOMUX before entering Low Power mode is right~

    Nothing need to done.

    Regards,

    Helic

  • Hi Helic,

    Thanks for the information.

    One more question.

    Is there any way to check which peripheral is consuming more current in sleep mode.?

  • Hi, 

    Now ,we don't have a official data about peripheral's consumption.

    You can test it by your self by shutting down peripheral one by one.

    Also, Another tips you need to notice is that consumption also related to peripheral's clock source, communication speed, etc...

    Regards,

    Helic