Thread View: comp.windows.ms.programmer
4 messages
4 total messages
Started by Xvosil Rained
Thu, 18 Apr 1996 00:00
Programming COM/LPT ports under Windows
Author: Xvosil Rained
Date: Thu, 18 Apr 1996 00:00
Date: Thu, 18 Apr 1996 00:00
18 lines
1842 bytes
1842 bytes
Hello. I have a question for MS Windows programming experts. So, the question is: "Is it possible to operate on the API level with COM and LPT ports under Windows?" My motivation is: I've got a device with a specific communication interface and I need to create a Windows application which will be able to control this device by means of COM or LPT port. In the other terms, I need to set and check zero/one voltage levels on a concrete port pin over a constant time interval. Any ideas/advises/references will be very appreciated. Thanks in advance, Xvosil Rained.
Re: Programming COM/LPT ports under Windows
Author: Henrik Haftmann
Date: Sat, 20 Apr 1996 00:00
Date: Sat, 20 Apr 1996 00:00
14 lines
2041 bytes
2041 bytes
In article <4l5rl4$q9@kadri.ut.ee>, xvosil@rubiin.physic.ut.ee says... > "Is it possible to operate on the API level > with COM and LPT ports under Windows?" >In the other terms, I need to set and check zero/one voltage >levels on a concrete port pin over a constant time interval. You can access freely (almost) to the port addresses with inp()/outp() (except under Win32). But to prevent other windows apps for accessing the same port, you should "allocate" the port with OpenComm(). If you want to prevent access by DOS boxes, I think you have to write a VxD. Good luck. -- Henrik Haftmann | email: henrik.haftmann@e-technik.tu-chemnitz.de Reichenhainer Str. 51/105 | www: http://www.tu-chemnitz.de/~heha D - 09126 Chemnitz | hobby: teletext in WWW at ~heha/toaster/vtnet.htm
Re: Programming COM/LPT ports under Windows
Author: Karl Schultz
Date: Thu, 25 Apr 1996 00:00
Date: Thu, 25 Apr 1996 00:00
32 lines
2359 bytes
2359 bytes
Xvosil Rained wrote: > > Hello. > I have a question for MS Windows programming experts. > So, the question is: > "Is it possible to operate on the API level > with COM and LPT ports under Windows?" There is a group of about a dozen functions in the Win API that handle the COM and LPT ports. > My motivation is: I've got a device with a specific > communication interface and I need to create a Windows > application which will be able to control this device by > means of COM or LPT port. Yup, you can do this. For example, Windows applications exist that are used to program ham radios by sending frequency data over a COM port through a wire that is plugged into the radio. > In the other terms, I need to set and check zero/one voltage > levels on a concrete port pin over a constant time interval. I don't know what a concrete port pin is, but you can read the state of certain status bits on the COM port to detect levels on the DTR line, etc. Now I have a question: Does anyone know of any freely available source code that implements a C++ class for COM ports?
Re: Programming COM/LPT ports under Windows
Author: Scott
Date: Fri, 26 Apr 1996 00:00
Date: Fri, 26 Apr 1996 00:00
15 lines
1659 bytes
1659 bytes
Karl Schultz wrote: > > Now I have a question: > > Does anyone know of any freely available source code that > implements a C++ class for COM ports? Karl, There is a book, _Serial Communications: A C++ Developer's Guide_, by Mark Nelson and published by M&T Books, which has good class-oriented communications guide. The modem class is buggy but its generally good. Scott L.
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads