This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
GDB stubs problem
- To: <ecos-discuss at sources dot redhat dot com>
- Subject: [ECOS] GDB stubs problem
- From: "xavier" <xavierwang at ms19 dot url dot com dot tw>
- Date: Mon, 28 May 2001 20:13:22 +0800
- Reply-To: "xavier" <xavierwang at ms19 dot url dot com dot tw>
Hi,
I'm trying GDB stubs support in eCos. I build both gdb_module.img and
a test program with GDB stubs included. When the gdb_module.img
starts in the target, it sends the following packet:
++$T0525:a0307a34;1d:80005420;#2
It seems OK. The gdb_module is waiting for a connection. Then I connect
GDB to the target. The target receives the following packet:
+$H9$Hc9$Hc9$Hc9---+$4$qC4$qC4$qC4---+$b$qOb$qOb$qOb---+
(gdb) target remote com1
Remote debugging using com1
Ignoring packet error, continuing...
Ignoring packet error, continuing...
Ignoring packet error, continuing...
Couldn't establish connection to remote target
Malformed response to offset query, timeout
(gdb)
I looked into the source code and found that in getpacket() in generic-stubs.c,
__add_char_to_packet() expects a '#' character to finish a packet but there is
no '#' character sent from GDB. So getpacket() ran forever.
Any suggestion?