[ECOS] gdb/insight questions

Jonathan Larmour jlarmour@cygnus.co.uk
Tue Dec 5 20:15:00 GMT 2000


"Lewin A.R.W. Edwards" wrote:
> 
> Q1: I don't understand where console I/O goes by default; I would have
> assumed to the gdb console but it seems not? My hello world app has a
> printf in it; by default, where does this output go? Can someone please
> verify to me that this is the right process:
> 
> * compile
> * arm-elf-gdb -nw a.out
> * (gdb) set remotebaud 38400
> * (gdb) target remote com1
> * (gdb) load
> * (gdb) continue

Jesper then said "Problem is that GDB hides any output that is not in
O-packet
format. HAL diag will normally wrap ASCII output in O-packets, but raw
serial output does not (for obvious reasons)."

but isn't the problem above that printf() isn't working by default? Or has
Lewin changed the configuration from the default to use haldiag, to serial
drivers; or changed haldiag to output packets that aren't O-packetized.

My point is that *by default* printf() should work and display output on
GDB.
 
> I also tried enabling serial port 2 and fprintfing a message to /dev/ttys2
> or whatever it is, and I get my output message on the second port so the
> program is definitely running (yay!).
> 
> Q2: (Relatively minor) I can only run command-line gdb, not insight. I even
> tried recompiling insight but when I run it I get an MB_ICONSTOP messagebox
> that says:
> 
> Can't find a usable main.tcl in the following directories:
> C:/CYGWIN/TOOLS/share/gdbctl C:/CYGWIN/TOOLS/gdbtcl
> C:/CYGWIN/TOOLS/gdb/gdbtk/library C:/CYGWIN/TOOLS/gdb1.0/gdbtk/library
> 
> C:/CYGWIN/TOOLS/share/gdbtcl/main.tcl: can't read "errMsg": no such variable
> can't read "errMsg": no such variable
> while executing "tk_messageBox -title Error -message "Could not find the
> lwidgets libraries. Got nameofexec: [info nameofexecutable]
> Error(s) were :\n$errMsg" -icon e..."
> invoked from within
> "if {![find_iwidgets_library]} {
> tk_messageBox....................
> 
> (lots more stuff).

I seem to recall this coming up before. Are you using Win98? See my earlier
reply at http://sources.redhat.com/ml/ecos-discuss/2000-10/msg00137.html
which recommends to upgrade both your cygwin and insight versions.

[ I decided not to update the FAQ in the end because this isn't
sufficiently frequent, and will be less so as time goes on. ]

Jifl
-- 
Red Hat, 35 Cambridge Place, Cambridge, UK. CB2 1NS  Tel: +44 (1223) 728762
"Plan to be spontaneous tomorrow."  ||  These opinions are all my own fault


More information about the Ecos-discuss mailing list