Subject: Re: b20: serial port bugs
From: [email-masked] (Sanjay Waghray)

7 Nov 1998 13:16:54 -0800
Message-ID: <[email-masked]>
References: <[email-masked]>
To: [email-masked]

Let me add another data point and a "standard"
test case: gdb serial cross-debugging.

I'm not providing code since the code is
available in the standard gdb distribution.
The files in question are:
gdb-4.16/gdb/rdi-share/unixcomm.[ch]
This code runs fine on b18, but does not
work on b19 and b20.

I have a gdb built for arm-coff (gdb 4.16)
to debug an ARM target over a serial line
(talking to the ARM Angel Debug Monitor using the ARM RDI protocol). The gdb works fine with
cygwin b18, but not with b19 and b20.
The serial line support is broken.

select always returns 0 both under b19 and b20,
as noted in the mail I'm responding to.

Anyone has a fix for this? Any workarounds?
Looking through the mailing list archives, this bug has been reported several times in the past. I haven't yet had a chance to play with the winsup source to see what might be broken.

As much as I like b20 it's unusable to me without
the serial support; so for now I have to stick
with b18.

Thanks in advance for any suggestions.

I use NT 4.0 SP3 and Cygwin B20.
> 
> CSIZE and CBAUD use one same bit. Therefore CS8 sets a bit that is used
> for B57600 and B115200.
> 
> select() never tells that something is available for read from a serial
> port.
> 
> When select returns with timeout, the read bitmask (at least) still has
> all the bits set. I think they should be zeroed, since the descriptors
> are not available for read.
> 
> Even read() never gives any characters from serial port.
> 
> ioctl TCGETA and TCSETA return error.
> 
> I have set using tcsetattr() the following settings:
> c_iflag = IGNBRK | INPCK;
> c_oflag =  0;
> c_cflag = B9600 | CS8 | CREAD |CLOCAL | HUPCL | PARENB;
> c_lflag =  0;
> c_cc[VMIN] = 0;
> c_cc[VTIME] = 0;
> 
> I tried VMIN = 1. It seemed not to block as it is supposed to, but
> read() returned with 0 when there was no characters. However, with this
> setting I was able to read characters for a while, but after a couple of
> characters it seemed to stop. I have given up debugging for now.
> 
> Ctrl-C in gdb seems to kill the gdb.
> 
> 
> -
> For help on using this list (especially unsubscribing), send a message to
> "[email-masked]" with one line of text: "help".
> 
> 

-----
See the original message at http://www.egroups.com/list/gnu-win32/?start=8753
--
Free e-mail group hosting at http://www.eGroups.com/
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".