[En-Nut-Discussion] Debugging Problems

Henrik Maier hmlists at focus-sw.com
Tue Nov 15 12:09:09 CET 2005


I am using the debugger every now and then and it works reasonably well 
with Nut/OS.

Nut/OS is tweaking the main symbol by redefining it (see avr.h) to point 
to it's own NutAppMain function. The debugger is not aware of this and 
never breaks at main aka NutAppMain.

Try to set a breakpoint a few lines after main. This will work.

Henrik Maier

Joachim Skale wrote:
> Hi *, 
> 
> has anybody recognized any Debugging Problems with Ethernut 2.1 , AVRSTUDIO 4.11 and AVR JTAG ICE ?
> i run with 3 Mhz debug freq. After downloading the ELF File, i could wait until tomorrow but i 'll never the Entry Breakpoint at 
> 
> int main(void)
> {
> 	u_long baud = 115200;
> 	int nRet = 0;
> 
> 	if(NutRegisterDevice(&devUart0, 0, 0) == 0)
> 	{
>         nRet |= UART_OK;
>         if(freopen("uart0", "w", stdout))
> 		{
>             nRet |= STDOUT_OK;
>             if(_ioctl(_fileno(stdout), UART_SETSPEED, &baud) == 0)
> 			{
>                 nRet |= BAUDRATE_OK;
>             }
>         }
> 
> 
> the dwarf-2 option is enable and also -O0.
> 
> Can anyone help ?
> 
> 
> Regards
> Joachim
> _______________________________________________
> En-Nut-Discussion mailing list
> En-Nut-Discussion at egnite.de
> http://www.egnite.de/mailman/listinfo.cgi/en-nut-discussion
> 
> 
> 




More information about the En-Nut-Discussion mailing list