|
-
January 4th, 2005, 04:29 AM
#1
How to access serial port in VC++
Hello All,
The requirement is simple. I want to access serial port and do read and write operation on it.
If anybody having sample code it is really great
Please help me
thanks and regards
Raghavendra H
-
January 4th, 2005, 06:57 AM
#2
Re: How to access serial port in VC++
Depending on what you are trying to do take a look at the functions
Code:
BuildCommDCB()
ClearCommError()
CreateFile()
EscapeCommFunction()
GetCommModemStatus()
GetCommState()
GetCommTimeouts()
GetOverlappedResult()
ReadFile()
SetCommMask()
SetCommTimeouts()
WaitCommEvent()
WriteFile()
Additionally, the MSDN provides a detailed article about serial communication in Windows. Open MSDN, choose Index and type "Serial Communications". There are several subitems, choose 'Win32'... (it's also available online).
-
January 4th, 2005, 06:09 PM
#3
Re: How to access serial port in VC++
You could use JH.CommBase. Try looking at this article http://www.codeproject.com/csharp/freakshow.asp
Lloydy
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|