Hi,

I ran into a strange problem when trying to debug a TOSSIM application with gdb running under cygwin. A SIGSEGV is generated when I invoke any tiny-os application(including samples like Blink,Sense) using gdb. However, the applications run just fine when invoked from command line. This is indeed strange because I used gdb to step through my application a few days ago. I haven't modified the environment since( cygwin or Tiny OS version ). The backtrace(bt command in gdb) is of not much help either as the file name that causes SEGV is not being printed though I compiled the application with debug option ( make pc debug ).

Any pointers on how to solve this problem is much appreciated.

Thanks,
Vinai.

********* GDB TRACE *********
This GDB was configured as "i686-pc-cygwin"...
(gdb) run 2
Starting program: /home/...../tinyos-1.x/apps/Blink/build/pc/main.exe 2
SIM: EEPROM system initialized.
SIM: event queue initialized.
SIM: Random seed is 849740
SIM: Initializing sockets
SIM: Created server socket listening on port 10584.
SIM: Created server socket listening on port 10585.
SIM: eventAcceptThread running.
SIM: commandReadThread running.
SIM: Time for mote 0 initialized to 24182616.
SIM: Time for mote 1 initialized to 28938372.
1: BOOT: Scheduling for boot at 0:0:6.04565400.
1: BOOT: Scheduling for boot at 0:0:7.23459300.
1: Popping event for mote 0 with time 0:0:6.04565400.

Program received signal SIGSEGV, Segmentation fault.
---Type <return> to continue, or q <return> to quit---
0x7c809f64 in KERNEL32!IsBadWritePtr ()
  from /cygdrive/c/WINDOWS/system32/kernel32.dll
(gdb) bt
#0  0x7c809f64 in KERNEL32!IsBadWritePtr ()
  from /cygdrive/c/WINDOWS/system32/kernel32.dll
#1  0x00000013 in ?? ()
#2  0x0022eb74 in ?? ()
#3  0x00000012 in ?? ()
#4  0x0022e000 in ?? ()
#5  0x0022e000 in ?? ()
#6  0x0022d5bc in ?? ()
#7  0x0a050020 in ?? ()
#8  0x0022eff0 in ?? ()
#9  0x7c8399f3 in KERNEL32!FindAtomW ()
  from /cygdrive/c/WINDOWS/system32/kernel32.dll
#10 0x7c809f90 in KERNEL32!IsBadWritePtr ()
  from /cygdrive/c/WINDOWS/system32/kernel32.dll
(gdb)
********** END OF GDB TRACE*************
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to