Mail Archives: djgpp/1999/01/12/14:35:22
> > I need to use the open() function, and I've tried
> > COM1, /dev/com1/, /dev/tty00, /dev/ttyS0, and /dev/cua0--none of them
> > work.
>
> The first two, COM1 and /dev/com1, should have worked. What exactly
> do you mean by ``none of them work''? Did the call to `open' fail?
> If so, how exactly did you call `open' (a code fragment would be nice)
> and what was the failure code (errno value) ?
Actually, I should have been more specific: open() seemed to open a
file/device, but tcgetattr() failed. That's why I thought it didn't work. But
your explanation (and old posts I eventually found in the archives) cleared
up why.
> > I need to use open() because my code uses tcgetattr(), tcsetattr(),
> > and select().
>
> `select' will work, once you open the port, but `tcgetattr' and
> `tcsetattr' won't. The DJGPP implementation of termios is minimal and
> currently only works for terminal devices.
I think I tried stdaux, but I don't think it worked. One question I have is,
if I set the COM port attributes through the Control Panel, does DOS (and
DJGPP) inherit those properties, or does DJGPP set some (other) arbitrary
attributes?
To solve my problem, I've been looking at 3 packages. I first looked at
CYGWIN, but its serial support is buggy at best. I got something to kind of
work, but it was a real kludge. I also looked at UWIN. My test program
compiled and worked flawlessly, but as far as I know it doesn't have a
FORTRAN compiler (which I ultimately need). I'm also looking at DJGPP
(obviously).
> The filesystem extensions feature is described in the library
> reference; type "info libc alpha 'File System'" from the DOS prompt
> (the quotes around File System are important!).
Will this work under NT?
Thanks for the response,
Dan
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
- Raw text -