This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Same codes and project file, but hardfault on other PCs

Hello Devzome Users,

I have a problem with running my codes on other computers. The project runs on my PC very well which I coded original.

I would like to test it on other computers. I got always hardfault problem. If I want to debug it, I have to select or open thumb_crt0.s.

I could see the file in the project folder which doesn't actually have it and also the other folders.

If I select the file, the code goes into Hardfault.

Can someone answer it why it happens and how to solve it?

Segger Embedded Studio for ARM 5.50b

SDK: nRF5 SDK 17.0.2

Softdevice: s140

Best regards

it0406

Parents Reply Children
  • Thank you for the reply.

    Add your own HardFault_Handler() to your code. This way the code won't end up in the default Handler. Can help debugging if - and only if - the stack was still OK.

    As I know, hardfault means unrecoverable system failures.

    Can I ignore it just with a hardfault handler? Or do you mean some hardfault cases in the handler and should the debug be stopped in this handler?

    The default handler for faults (and undefined interrupts) resides in thumb_crt0.s source file IIRC.

    Should I modify something in the file?

Related