This is the mail archive of the
mailing list for the GDB project.
Re: Problem with COM1 port from with GDB 5.3 under Cygwin 1.5.3-1
- From: Creighton MacDonnell <creighton at macdonnell dot ca>
- To: gdb at sources dot redhat dot com
- Cc: Thomas Doerfler <Thomas dot Doerfler at imd-systems dot de>
- Date: Wed, 10 Sep 2003 08:55:18 -0600
- Subject: Re: Problem with COM1 port from with GDB 5.3 under Cygwin 1.5.3-1
- References: <3F5F2C94.31945.291668BC@localhost>
Thanks for responding.
The obvious thing to do (I think) would be to run a program under Cygwin
1.5.3 to exercise the serial ports using the "com?", "/dev.com?" and
"/dev/ttyS?" names first to see that they actually work under Cygwin.
But I cannot find any Cygwin package that uses the serial port in the
set of standard Cygwin packages that "setup" knows about. Nor have I
found one anywhere else. I could not get mincom to compile under Cygwin,
even after several hacks at the code.
I tried just using "cat com1" and "echo ??? > com1" to communicate with
my board as a test, but the results are erratic even under the old Cygwin.
When I have time, I plan to learn how to right some very simple code to
use the serial port, and run it on both of my serial ports.. In my
posting to the Cygwin list I asked if anyone had some code like this.
But I got no response. If anyone on this list can offer some simple code
for this, please do.
I do notice that under the old Cygwin I get this:
$ ls -l com1
crw-rw-rw- 1 0 0 7, 0 Sep 10 08:33 com1
But under the new Cygwin I get this:
$ ls -l com1
---------- 0 ???????? ???????? 0 Dec 31 1969 com1
I did get one response on the Cygwin list that "com1" no longer works.
We are supposed to use "/dev/com1". I do not know how knowledgable this
person was. The Cygwin user guide says "com1" should work. But it also
says that "/dev/com1" and "/dev/ttyS0" should work.
One notable difference on Cygwin is that "ls /dev" or "ls /dev/*"
produce nothing. There is no actual "/dev" directory. The user guide
says that you just go ahead and open the device name.
An the thing is though, I was never able to get GDB to use "/dev/ttyS0"
even under the old Cygwin. This is a nuisance because I also use Linux,
and there I have GDB scripts that use "/dev/ttyS0".
I am pusuing this on this list because the previous fact suggests that
GDB might benefit from some Cygwin specific code in this area and
because I felt I was more likely to find someone else affected by this
problem on this list. Also, the Cygwin list is swamped right now with
other problems related to the 1.5.3 upgrade.
Again let me say to anyone with knowledge of the GDB code concerning
serial ports, I have a test environment and I am willing to try any
hacks or patches you may provide. But I do not have time right now to
comb over the serial port GDB code and try to understand it.
Thomas Doerfler wrote:
I have read your posting to the gdb mailing list. Some days
now I have a similar problem with a M68K-GDB5.2 working with
the serial remote protocol under cygwin 1.5.3.
My gdb complains, that COM1 is "not a typewriter", and it will
open the alternative deivces "/dev/ttyS0" only in vary rare
I will try to downgrade my cygwin installation and try