Xref: utzoo comp.unix.wizards:25226 comp.unix.internals:2668 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!spool.mu.edu!mips!tecate.mips.com!trevc From: trevc@tecate.mips.com (Trevor Cotton) Newsgroups: comp.unix.wizards,comp.unix.internals Subject: Re: Getting status of DCE device from a DTE device Message-ID: <2767@spim.mips.COM> Date: 29 Apr 91 17:02:30 GMT References: <8283@alpha.cam.nist.gov> Sender: news@mips.COM Reply-To: trevc@mips.com Followup-To: comp.unix.wizards Organization: Mips Computer Systems Inc., Sunnyvale, CA Lines: 26 Nntp-Posting-Host: tecate.mips.com In article <8283@alpha.cam.nist.gov>, coleman@cam.nist.gov (Sean Sheridan Coleman X5672) writes: |> Is there a way from inside a C program to find out if |> DATA CARRIER DETECT is high on the Data communication devices? |> |> I want my program to see if there is a modem device on the |> other end of the cable before it tries to use that port. |> I am trying to make sure that the port plugged into the |> back of my Sparc Station is hooked into something. |> |> |> Thanks |> |> Sean Coleman |> NIST |> coleman@bldrdoc.gov Sun Release 4.0 Last change: 22 March 1989 20 TERMIO(4) DEVICES AND NETWORK INTERFACES TERMIO(4) TIOCMGET The argument is a pointer to an int. The current state of the modem status lines is fetched and stored in the int pointed to by the argument. This call is allowed from a background process.