delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com> |
List-Archive: | <http://sourceware.cygnus.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT sourceware DOT cygnus DOT com> |
List-Help: | <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs> |
Sender: | cygwin-owner AT sourceware DOT cygnus DOT com |
Delivered-To: | mailing list cygwin AT sourceware DOT cygnus DOT com |
Message-ID: | <389D9A79.91C096E2@handshake.de> |
Date: | Sun, 06 Feb 2000 14:59:53 +0000 |
From: | Daniel Kroening <kroening AT handshake DOT de> |
X-Mailer: | Mozilla 4.7 [de] (Win98; U) |
X-Accept-Language: | de |
MIME-Version: | 1.0 |
To: | cygwin AT sourceware DOT cygnus DOT com |
Subject: | DCD on serial ports, was: ioctl() function |
Hello, I know it´s an old mail, but I have the very same problem. I need a function call which allows to detect if DCD on a serial port is active. Linux offers the TIOCMGET and TIOCM_CAR extention to ioctl(). Anyone with a solution? > I was trying to port some unix code and it uses ioctl() for serial comms. > sys/ioctl.h was either missing or blank - I can't remember. > I added some #defs from linux. > and now the code appears to read and write to/from the port. > The code I have checks if DCD is active to see if a call is being made to a > modem. > But this is where things don't work. > > ioctl(portfd, TIOCMGET, &stat) returns -1 > so it never detects carrier. where can I get correct values for ioctl.h or > should I be using a different call under NT?? > (NT4, sp3, 64MB) Daniel Kröning -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |