gpsd-dev
[Top][All Lists]
Advanced

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

Re: [gpsd-dev] What is our current bug state?


From: Eric S. Raymond
Subject: Re: [gpsd-dev] What is our current bug state?
Date: Mon, 2 Feb 2015 00:33:38 -0500
User-agent: Mutt/1.5.23 (2014-03-12)

Hal Murray <address@hidden>:
> 
> address@hidden said:
> > Interesting.  I tried just removing O_NOBLOCK from gpsd's tty opens, and it
> > turns out that both gpsd and gpsmon work fine without that flag. 
> 
> Most likely, you are lucky and the TTY is already in CLOCAL.  Try turning it 
> off with stty or such.

We probaly *don't* want to set CLOCAL.

Macro: tcflag_t CLOCAL

    If this bit is set, it indicates that the terminal is connected
    "locally" and that the modem status lines (such as carrier detect)
    should be ignored.

    On many systems if this bit is not set and you call open without
    the O_NONBLOCK flag set, open blocks until a modem connection is
    established.

    If this bit is not set and a modem disconnect is detected, a
    SIGHUP signal is sent to the controlling process group for the
    terminal (if it has one). Normally, this causes the process to
    exit; see 24. Signal Handling. Reading from the terminal after a
    disconnect causes an end-of-file condition, and writing causes an
    EIO error to be returned. The terminal device must be closed and
    reopened to clear the condition.

If I'm reading that right, setting CLOCAl would make PPS events invisible.

But it's OK.  It turns out that justb removing O_NONBLOCK works; see
my previous email to Gary. 
-- 
                <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]