Following is a simple application that I have created. It has no softdevice and the configuration is very similar to blinky freeRTOS example.
All tasks are activated once but then I get a hardfault and it is rather tedious to debug this on gcc/eclipse environment as I get no stack trace for the hard fault.
Kindly let me know what could be wrong?
EDIT : All functions RT_RE_xxxxxxxxxx are blank functions.
Here is some further insight into the issue as I refer this FreeRTOS_Debug link.
HARDFAULT:ERROR:START OF FULL LOG
HARDFAULT:ERROR:R0 R1 R2 R3 R12 : 0x0 0x20001950 0x10000 0x200020c8 0xa5a5a5a5
HARDFAULT:ERROR:LR PC PSR BFSR : 0x8 0x8 0x6000000b 0x200
HARDFAULT:ERROR:CFSR HFSR DFSR AFSR MMAR BFAR : 0x20000 0x40000000 0x0 0x0 0xe000ed34 0xe000ed38
HARDFAULT:ERROR:END OF FULL LOG
What chipset and SDK version are you using?
I think there is code on the web for a hard fault handler that gives more information about the fault by putting the PC and other info (even a full stack trace?) in memory where you can examine it from the debugger. Does the hard fault handler from Nordic (in their /library directory of the SDK?) give more information than the default hard fault handler? Its not simple and it is tedious, but it is possible to examine the stack from the debugger.
I have already added that code to hard fault handler which generated additional log like stacked registers and trap related registers in cortex m4.
I have got the software working. It was with the compiler options.
I had following compiler option other than blinky freeRTOS project:
I removed this option and the tasks arrive without glitches.
(Similarly for ASMFLAGS)
So, in conclusion, do not enable softdevice if your project doesn't use it.