PSoC4 CAN behavior changes with debugger attached

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

cross mob
PaSw_2578827
Level 4
Level 4
25 replies posted 10 replies posted 10 questions asked

Hi,

I'm using a CY8C4247 for a CANBus based motor controller. Occasionally the system hangs completely and become unresponsive to any CAN messages, it seems like a firmware bug somewhere but I cannot get it to behave this way while debugging which is what is confusing me. Not every device on the bus hangs all the time, but occasionally they will (only tested it with 2 devices so far). I put an LED toggle in the CAN_ISR and it when it hangs it doesn't appear to be hitting the ISR.

I'm working through to see if there is a sequence of commands that cause my firmware to lock up, but I'm curious what could change in debug mode? FWIW with the debugger hardware attached but not debugging it still hangs (so it doesn't appear to be a power or ground issue). Could the presence of the SWDCLK possibly be helping the HFCLK accuracy? I only ask as the only known hardware issue on the design right now is a missing WCO so I'm running the CAN at it's slowest speed and hoping for the best, so far it appears to be working ok (next hardware Rev will have WCO).

Regards

0 Likes
1 Reply
himam_31
Employee
Employee
50 likes received 25 likes received 10 likes received

Please attach the project and schematic.

Thanks,

Hima

0 Likes