How to switch power mode to WAIT ?

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

How to switch power mode to WAIT ?

1,224 Views
snowholgi
Contributor I

We do the following in our driver:

    // switch to WAIT mode

    g_pGPC->LPMR = GPC_LPMR_CLPCR(0x1);

    OALWFI();

    output("g_pGPC->PGSR=0x%x\r\n", pGPC->PGSR) ;

But pGPC->PGSR is always 0. Means previous power mode is RUN and current power mode is also RUN.

I expected that previous power mode will be 0x1 = WAIT.

Do you have an explanation?

Is there another register which we have to set before setting LPMR to 0x1 ?

Beside this, we don’t see significant power reduction during WFI.

Thanks for your help

Holger

0 Kudos
Reply
5 Replies

967 Views
davidconnelly
Contributor III

Hi,

You are correct in your implementation of WAIT mode.  In the available sample code, I can confirm WAIT and STOP mode entry and exit with SW1 button press on the Tower board.  I have confirmed the behavior of the GPC->PGSR not getting updated with WAIT or STOP modes, and always reflecting RUN mode.  I will follow up with our internal team to investigate.

** Edit:  Also make sure CCM->CLPCR is not masking the core from entering WAIT mode ***

Regards,

David

967 Views
snowholgi
Contributor I

Hello,

I have again tested the WAIT mode and checked CCM->CLPCR.

All seems right, but I don't get a significant power reduction.

If I look to the sample code, I see that all PLLs are switched off before entering WAIT mode.

So it's clear why we can measure power reduction in this case.

Is there a way to check if core really switch to WFI ?

Thanks,

Holger

0 Kudos
Reply

967 Views
karina_valencia
NXP Apps Support
NXP Apps Support

timesyssupport can you help on this case?

0 Kudos
Reply

967 Views
timesyssupport
Senior Contributor II

davidconnelly - What was the sample code that you used? We can try to reproduce the issue with this. Were there any further details found from your internal investigation?

Regards,

Timesys Support

0 Kudos
Reply

967 Views
karina_valencia
NXP Apps Support
NXP Apps Support

davidconnelly do you have an update of this  case?

0 Kudos
Reply