2018-02-17 08:21 AM
Hello Everyone,
I am currently working on SPC560C50L3 controller with SPC5 studio. How do I differentiate between different resets for Eg. watchdog reset, power ON reset etc.
Through code I want the controller to identify the source of reset.In the reference manual, they have mentioned RGM register (RGM.FES & RGM.DES), which will help the controller to identify the type of reset. But my question is, how to use this register? I tried to read the RGM register in the start of my main function, but every time I was getting 0. There must be some way to use this register to identify the cause of last reset.Regards,
Vishrut.
2018-02-19 07:06 AM
Hello vishrut ,
i think that it is correct
Did you use a test application from SPC5Studio ?
if yes , we remove the status after each reset
/* RGM errors clearing.*/
RGM.FES.R = 0xFFFFU;
RGM.DES.R = 0xFFFFU;�?�?�?
Best regards
Erwan