Solved

How to get status of serial lines (CTS, DSR) with Windows 3.1 Communications API

Posted on 1998-03-16
3
400 Views
Last Modified: 2013-12-03
Hi all genius. I have programmed a program in Windows 95 that uses serial ports. Under that platform, I used GetModemCommStatus to get the status of Clear To Send and Data Set Ready lines of RS-232. That function doesn't exist in 16 bits Windows. How can I do the same in Windows 3.1? I've used GetCommError but this doesn't work :(

Thanks in advance,
Jaime
0
Comment
Question by:DaThiN
  • 2
3 Comments
 
LVL 1

Expert Comment

by:JamieR
Comment Utility
Jaime,

Use EscapeComm under Win16.
Use EscapeCommFunction under Win32.

Jamie!
0
 

Author Comment

by:DaThiN
Comment Utility
That functions let me set or clear, for example, DTR and RTS signals. That isn't what I wanted to do. I want to know in what state (high or low, 1 or 0) is the signals CTS and DSR. Under win32 I used GetCommModemStatus. But it isn't supported by Win16.

Thanks
Jaime
0
 
LVL 1

Accepted Solution

by:
JamieR earned 30 total points
Comment Utility
Mmmm, should have read the question. I can only suggest that you use the GetCommEventMask facility to get notification when the flags change.

Jamie
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

This article shows a few slightly more advanced techniques for Windows 7 gadget programming, including how to save and restore user settings for your gadget and how to populate the "details" panel that is displayed in the Windows 7 gadget gallery.  …
For a while now I'v been searching for a circular progress control, much like the one you get when first starting your Silverlight application. I found a couple that were written in WPF and there were a few written in Silverlight, but all appeared o…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now