[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: modm0dev and stty/mintnet



Ulrich Kuehn wrote:

> I used the stty supplied with modm0dev and I got my opinion from the
> trace output of mint, where the cua_ioctl function printed something
> like 0x5402  invalid mode

This is normal. This message is printed by modm0dev itself.

> and I could not set the tty to raw mode, in fact, I could not even set any
> of the flags besides the baud rate.

...but this isn't. The Fcntl() call itself should succeed. I suggest you
have a closer look to dosfile.c: if, for some ioctl, the device driver
returns EINVFN (this is the case here) and the device is a tty (also the
case), Fcntl() will fallback to tty_ioctl() which will do the Right
Thing.  Of course, this is some kind of "internal interface" of MiNT, so
one cannot guarantee that it'll work with all the patched 1.11 versions
floating around, but in ERS' latest sources, it still seems to work that
way. Note also that all bios devices are implemented like this; you just
need to provide the low-level ioctl's, but certainly not TIOC[GS]ETP.

It is also possible that the flags are reset when you close the device.
I don't remember such a thing, however...

Thierry.