Fail to enter LLS3 power saving mode

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Fail to enter LLS3 power saving mode

1,134 Views
zahidul3
Contributor III

I have developed battery operated IoT product but am unable set my application to the lowest power mode. This is the code I am using in a FreeRTOS task to set to sleep mode:

 

    			// Enter LLS3 STOP mode
    			lls_config.subMode        = kSMC_StopSub3;
    			lls_config.enableLpoClock = true;
    			SMC_PreEnterStopModes();
    			if(SMC_SetPowerModeLls(SMC, &lls_config) != kStatus_Success)
    				PRINTF("FAIL SMC_SetPowerModeLls FAIL!!!\n\r");
    			SMC_PostExitStopModes();

 

BTW, I am running my application in FEI mode by default. Let me know if it is possible to enter into deep low power mode in this state. Let me know if you need further info.

0 Kudos
6 Replies

878 Views
zahidul3
Contributor III

I was able to make it work. It goes to LLS3 mode inside a task, and wakes up on an interrupt signal from external processor.

0 Kudos

1,112 Views
zahidul3
Contributor III

UPDATE: I got it to get out of low power mode after disabling low power tickless mode.

#define configUSE_PREEMPTION                    1
#define configUSE_TICKLESS_IDLE                 0
#define configCPU_CLOCK_HZ                      (SystemCoreClock)
#define configTICK_RATE_HZ                      ((TickType_t)1000)
#define configMAX_PRIORITIES                    5 // lower number -> lower priority
#define configMINIMAL_STACK_SIZE                ((unsigned short)256)
#define configMAX_TASK_NAME_LEN                 20
#define configUSE_16_BIT_TICKS                  0
#define configIDLE_SHOULD_YIELD                 1
#define configUSE_TASK_NOTIFICATIONS            1
#define configUSE_MUTEXES                       1
#define configUSE_RECURSIVE_MUTEXES             1
#define configUSE_COUNTING_SEMAPHORES           1
#define configUSE_ALTERNATIVE_API               0 /* Deprecated! */
#define configQUEUE_REGISTRY_SIZE               8
#define configUSE_QUEUE_SETS                    0
#define configUSE_TIME_SLICING                  1
#define configUSE_NEWLIB_REENTRANT              0
#define configENABLE_BACKWARD_COMPATIBILITY     0
#define configNUM_THREAD_LOCAL_STORAGE_POINTERS 5
#define configOVERRIDE_DEFAULT_TICK_CONFIGURATION 1

 by setting configUSE_TICKLESS_IDLE from 2 to 0.

1,114 Views
zahidul3
Contributor III

I am using a custom board and custom application using K82 CPU. I am using frdmk82f_power_manager project as reference for power saving mode.

0 Kudos

1,115 Views
zahidul3
Contributor III

Hi,

I am using a custom board with a custom application using MK82 CPU. But I am using the frdmk82f_power_manager project as reference. 

0 Kudos

1,123 Views
zahidul3
Contributor III

Update: Now I am able to enter LLS3 mode (after de-initializing the QSPI). Now the problem is, it seems to be stuck in LLS3 mode, is there more steps to take to return back to FEI running mode? For some reason, the debugger gets disconnected after waking up from low power mode so hard to see where the issue is.

0 Kudos

1,120 Views
Julián_AragónM
NXP TechSupport
NXP TechSupport

Hi @zahidul3

Could please you tell me which board are you using or if it is a custom board? And did you use any SDK examples?

Best regards, Julian

0 Kudos