[En-Nut-Discussion] ethernut3 debugging with openocd

Andreas Helmcke ahnews01 at ela-soft.com
Thu Jul 19 15:23:29 CEST 2007


On 18.07.2007 15:04, Dave Warren wrote:
> Hi Joerg,
> 
> I have had something simular. I was using Nut 4.2.1 on the AT91SAM7X256. 
> When I broke in with JTAG I found the crash was a data abort (bad address 
> for data read). I never did understand it but increasing the size of the 
> stack in my threads made it go away. I don't understand why. Also I 
> discovered that you need a standard out device even if this is only the null 
> device.
> 
That is quite normal. Stackoverflow of one thread is a secure way to
crash the complete system.
The stack is located directly above the control-block of the next
thread. So a stack overflow will overwrite this control-block and the
next thread switch will crash the OS.

We had this problem with the DHCP thread of some of the exapmle
applications which needs 516 bytes while it is defined with 512 bytes.

Andreas




More information about the En-Nut-Discussion mailing list