Question

I'm trying to build and run some project from 3rd party sources for bare-metal(no OS)ARM Cortex M3.

I build it with arm-none-eabi-gcc(success) with newlib.

I run it under simulator of TI Code Composer Studio.

The problem:

When I run it, it fails into hard fault (entering into corresponding ISR) on the first call to the runtime library function

Till now I sow it failing on calls to memmove or memcpy. When tracing the disassembly I see that it fails exactly on the instruction

BLX memset

The question: What can cause the fault and how to debug it ???

Was it helpful?

Solution

Are you using both ARM and Thumb? 'BLX label' calls the label, (using link register for return address), and changes to Thumb mode. Are you linking with the correct version of the library?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top