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.

RTOS/MSP432-RTOS: MSP432-RTOS wake up from deepsleep (LPM3)

Part Number: MSP432-RTOS

Tool/software: TI-RTOS

Hello,

I am playing around with the development board MSP-EXP432P401R (black) and try to put the device into deepsleep (LPM3).

I activated the watchdog in interval mode as clock source (Clock.tickSource = Clock.TickSource_USER). Watchdog is driven by ACLK. My ACLK is the external 32kHz crystal oszillator.

The watchdog calls an interrupt routine which calls Clock_tick().

Working with an active debug session everything works fine. After reset a task is started which displays a hello message on a display. After a few seconds the display is cleared, the task ends and the device falls into sleep. In a power notify routine I switch an output to see when the device wakes up and falls asleep. This output toggles with each wake/sleep event.  

If I stop the debug session and reset the device the hello message task runs like supposed. But when it ends and the device falls into deepsleep it never wakes up again. The ACLK which drives the watchdog intervaltimer stops. The device consumes only a few microamperes like supposed but sleeps forever.

The watchdog timer should not have been stopped in lpm3 but unfortunately it is stopped. 

  • User,

    I'd like to suggest a couple things for you to look into.

    Are you using our most up to date software (SimpleLink MSP432 SDK)? If not, please upgrade to this.

    Second, do you have a red launchpad to try out? The black launchpad contains experimental, pre-released silicon that has since been updated in a number of ways. The black launchpad contains Rev B material while, released material is at least Rev C or Rev D. You can find more information for both of these points in Section 3 of http://www.ti.com/.../slaa700

    Our recommendation is to always get the latest hardware: http://www.ti.com/tool/msp-exp432p401r


    That said, it personally doesn't sound like you are setting ACLK to be sourced by LFXT as I believe you are trying to. Have you checked to make sure that the LFXT is active in debug and the source for ACLK and that WDT CLK source is ACLK?

    The behavior you've described sounds like somehow the WDT is being sourced by SMCLK or REFOCLK. I say this because when you are in debug mode, the device simulates LPM3, as debug functionality is not retained in LPM3, so in order to test functionality the device only simulates LPM3. Therefore, in debug mode, the device's clock system will stay active even when going to "LPM3". But when the device is set off on it's own, the device will actually go into LPM3, shut off the clock system, and you will see an alternate functionality as the device won't actually wake up if LFXT != ACLK != WDTCLK.

    Those suggestions should help you move forward, I'm going to close this post for now.

  • After looking into this a bit more, this section in the TRM might be of use. 

    Have you tried using BCLK or VLOCLK? I believe this may be a more accurate cause of what you're seeing, but I'd be interested to know what you see. 

    I also assume you used this as a reference?: processors.wiki.ti.com/.../TI-RTOS_MSP432_Timer

  • Hello Evan,

    the link processors.wiki.ti.com/.../TI-RTOS_MSP432_Timer was exactly what I used to build my test application. Thanks for your reply. I read the extract of the TRM and changed the line

    WDT_A_initIntervalTimer(WDT_A_CLOCKSOURCE_ACLK, WDT_A_CLOCKITERATIONS_64)

    in my main to

    WDT_A_initIntervalTimer(WDT_A_CLOCKSOURCE_BCLK, WDT_A_CLOCKITERATIONS_64)

    like described. This gave a compiler error because WDT_A_CLOCKSOURCE_BCLK is defined as WDT_A_CTL_SSEL_4 which didnt exists for MSP432! Then I changed BCLK to XCLK and it was compiled successfully!

    Now everything works as expected. The CPU wakes up periodically calls the notifyfxn and goes to sleep again.

    In MSP_EXPP401R_initGeneral I init ACLK and BCLK with LFXT using

    CS_startLFXT(CS_CTL2_LFXTDRIVE_1);
    CS_initClockSignal(CS_ACLK, CS_LFXTCLK_SELECT, CS_CLOCK_DIVIDER_1);
    CS_initClockSignal(CS_BCLK, CS_LFXTCLK_SELECT, CS_CLOCK_DIVIDER_1);

    So everything looks like I am using external 32kHz oszillator and not internal VLOCLK.

    At the end of my "Hello" Task I screw down the watchdog interval using
    WDT_A_initIntervalTimer(WDT_A_CLOCKSOURCE_XCLK, WDT_A_CLOCKITERATIONS_512);

    This reduces the supply current to 68µA which is okay for the test.

**Attention** This is a public forum