Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Apr 1999 08:53:22 +0200
From:      Thomas Page <ThomasP@cat.co.za>
To:        "'freebsd-questions@FreeBSD.org'" <freebsd-questions@FreeBSD.org>
Subject:   Using SIGIO
Message-ID:  <81F5585A3B93D111A8D10080ADB4CBB9055A0B@DC>

next in thread | raw e-mail | index | archive | help
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------ =_NextPart_001_01BE907A.A4229E20
Content-Type: text/plain

Hi,
I am having trouble setting up a SIGIO for the serial port,
the point in question is that when I do a fcntl(fd,F_GETOWN)
or fcntl(fd,F_SETOWN,...), I get an "Inappropriate ioctl for
device". I have used "signal" and a signal handler, and have
set the serial port to "O_ASYNC", but this third requirment
(as per all the books I have) just will not work. Is it a
user rights issue, or am I way off track?

I have tried various other ideas, fcntl(fd,FASYNC),
ioctl(fd,TIOSPGRP)..., etc, etc, but all with various error
messages. I have even tried locking the fd, then unlocking
afterwards, no change.

Thanks


Thomas Page
CAT (Pty) Ltd - Advanced security Technology
thomasp@cat.co.za   (tompage@hotmail.com) +27 31 560 6556

"The proper 'office' of a friend is to side with you when
you are wrong. Nearly everyone will side with you when you
are right."	Mark Twain


------ =_NextPart_001_01BE907A.A4229E20
Content-Type: text/html
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3DUS-ASCII">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.0.1460.9">
<TITLE>Using SIGIO</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=3D2 FACE=3D"Arial">Hi,</FONT>
<BR><FONT SIZE=3D2 FACE=3D"Arial">I am having trouble setting up a =
SIGIO for the serial port, the point in question is that when I do a =
fcntl(fd,F_GETOWN) or fcntl(fd,F_SETOWN,...), I get an =
&quot;Inappropriate ioctl for device&quot;. I have used =
&quot;signal&quot; and a signal handler, and have set the serial port =
to &quot;O_ASYNC&quot;, but this third requirment (as per all the books =
I have) just will not work. Is it a user rights issue, or am I way off =
track?</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">I have tried various other ideas, =
fcntl(fd,FASYNC), ioctl(fd,TIOSPGRP)..., etc, etc, but all with various =
error messages. I have even tried locking the fd, then unlocking =
afterwards, no change.</FONT></P>

<P><FONT SIZE=3D2 FACE=3D"Arial">Thanks</FONT>
</P>
<BR>

<P><FONT FACE=3D"Tahoma">Thomas Page<I></I></FONT><I></I>
<BR><I><FONT COLOR=3D"#000000" SIZE=3D5 FACE=3D"Arial =
Black">CAT</FONT></I><FONT COLOR=3D"#000000" SIZE=3D1 =
FACE=3D"Arial"></FONT><I> <FONT COLOR=3D"#000000" SIZE=3D1 =
FACE=3D"Arial">(Pty) Ltd</FONT></I><FONT COLOR=3D"#000000" SIZE=3D1 =
FACE=3D"Arial"> -</FONT><I> <FONT COLOR=3D"#000000" SIZE=3D1 =
FACE=3D"Arial">Advanced security Technology</FONT></I>
<BR><FONT SIZE=3D1 FACE=3D"Tahoma">thomasp@cat.co.za&nbsp;&nbsp; =
(tompage@hotmail.com) +27 31 560 6556</FONT>
</P>

<P ALIGN=3DCENTER><FONT SIZE=3D1 FACE=3D"Tahoma">&quot;The proper =
'office' of a friend is to side with you when you are wrong. Nearly =
everyone will side with you when you are =
right.&quot;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Mark =
Twain</FONT></P>

</BODY>
</HTML>
------ =_NextPart_001_01BE907A.A4229E20--


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?81F5585A3B93D111A8D10080ADB4CBB9055A0B>