Restart both CPU CM0 and CM4 , programmatically.

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
MSS
Level 3
Level 3
5 likes given 50 sign-ins 10 replies posted

Hi, 

I have DFU running in CM0 and  Application running in CM4.

I want to restart the PSOC , both cores, How to do it programmatically.

 

Regards,

Madhav

 

0 Likes
1 Solution
Ekta
Moderator
Moderator
Moderator
750 replies posted First like given 250 solutions authored

You cannot reset CM0+ core from CM4, however, if you call NVIC_SystemReset from CM4 core it will reset only the CM4.

Calling NVIC_SystemReset from CM0+ will reset the entire system.

View solution in original post

0 Likes
4 Replies
MSS
Level 3
Level 3
5 likes given 50 sign-ins 10 replies posted

@Jayden 

Thanks for the answer.

I forgot to mention , I am using   Modus toolbox. Which header file to include for the above code?

I believe the steps you gave may work with Psoc Creator. 

Can you tell me steps for Modus Toolbox?

 

Regards,

Madhav

 

0 Likes
Ekta
Moderator
Moderator
Moderator
750 replies posted First like given 250 solutions authored

Hi @MSS 

I guess by restart you mean reset.

If you want to reset only CM4 core, then it is possible to do so using the PDL API call Cy_SysLib_SoftResetCM4()

If you want to reset both CM0+ core and CM4 core then you would need to call NVIC_SystemReset API from CM0+ core. Resetting CM0p causes the CM4 also to be reset because it enables the CM4 processor.

Best Regards
Ekta


0 Likes
MSS
Level 3
Level 3
5 likes given 50 sign-ins 10 replies posted

Thanks for the reply.

I am confused.

My requirement is "can  code running in CM4 core, reset CM0 or CM4 " if yes how?

Regards

Madhav

 

0 Likes
Ekta
Moderator
Moderator
Moderator
750 replies posted First like given 250 solutions authored

You cannot reset CM0+ core from CM4, however, if you call NVIC_SystemReset from CM4 core it will reset only the CM4.

Calling NVIC_SystemReset from CM0+ will reset the entire system.

0 Likes