Using STOP0 mode with Pretended Networking mode in S32K142

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Using STOP0 mode with Pretended Networking mode in S32K142

2,962件の閲覧回数
ARP123
Contributor I

Hi,

I am facing problem in wakeup of s32k142 from STOP0(low power) mode with Pretended Networking mode of FlexCAN0 module when CAN frames are comming on CAN bus.
I am also trying to enter STOP mode seprately first without Pretended Networking mode were, I can see the status to CoreM4 changes to sleeping from Running but the LPMACK bit in CAN0_MCR register is not getting set in debug window.
So I am not sure if entry to STOP0 mode is also made correctly?

The flow of my software is as follows:
1. Disable all interruts of s32k142
2. Enable CAN0 wakeup interrupt
3. Enter Freeze Mode
4. Configure the Pretended Networking mode configuration and Enable mode
5. Set STOP0 low power mode (Not sure if it is entered properly)

I basically want to enter stop mode and wakeup chip on a specific CAN frame on CAN bus. Can I get any sample working code for this?

Thanks,
Akshay

0 件の賞賛
返信
5 返答(返信)

2,946件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport
0 件の賞賛
返信

2,930件の閲覧回数
ARP123
Contributor I

Hi @PetrS ,

 I tried using your code at following link :

https://community.nxp.com/t5/S32K-Knowledge-Base/Example-S32K144-FlexCAN-Pretended-Networking-STOP-m...

 

Also I made following changes to code to use in my application:

1. Disabled timeout wakeup in CTRL1_PN.

2. Used CAN wakeup ID specific to my requirement.

 

Results:

1. Controller is going to STOP mode and wakeup when the CAN frame is arrived with Wakeup ID.  But this works only in debug mode and when the debugger is disconnected, Wakeup doesn't work. 

2. Also I see current consumption difference in Power supply in STOP mode with and without debugger connected

    1. 26 mA  (Debugger connected)

    2. 17 mA  (Debugger Not connected)

 

So, Can I get the solution to wakeup the controller even if debugger is not connected.

Also I have following doubt after going through the example code shared:

Example code have used STOP2 mode with Pretended Networking mode on FlexCAN0 which is not matching the User manual. User manual says that STOP1 will work with Pretended Networking mode to wakeup with CAN.

 

Thanks,

Akshay.

0 件の賞賛
返信

2,894件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

I tried that example as is on S32K144EVB and after loading the code it is functional without debugger as well.

As per Table 39-4. PNET is supported for both STOP modes.

PetrS_0-1650962351547.png

 

BR, Petr

2,878件の閲覧回数
ARP123
Contributor I

Hi @PetrS

 Example code is working separately. But when I use example code in my software, the timeout of 8 msec happens very fast in almost less then 1 sec and also wakeup on CAN doesn't work. 

 Is this problem because of System clock frequency switching? So do I need to follow some process before calling your function calls in my application.

Is it possible to setup a short call between us So that I can explain you the actual problem?

 

Thanks,

Akshay.

0 件の賞賛
返信

2,860件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

if needed, share your simplified example showing an issue so we can check/test it on the EVB.

BR, Petr

0 件の賞賛
返信