?
Solved

what is the value for IOCTL_SERIAL_GET_COMMSTATUS

Posted on 2011-03-22
5
Medium Priority
?
608 Views
Last Modified: 2013-12-17
I am trying to make a call using this value but am unable to find the number for this or the reference I would need to put in to the "using" clause so my program would know what it is.

Are these values listed anywhere?
0
Comment
Question by:jetbet
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 35194974
According to this file, is a macro function.
0
 

Author Comment

by:jetbet
ID: 35195496
Do you know how I could use the following code to clear any pending communication errors?
C# Signature:

[DllImport("kernel32.dll", ExactSpelling = true, SetLastError = true, CharSet = CharSet.Auto)]
static extern bool DeviceIoControl(IntPtr hDevice, uint dwIoControlCode,
IntPtr lpInBuffer, uint nInBufferSize,
IntPtr lpOutBuffer, uint nOutBufferSize,
out uint lpBytesReturned, IntPtr lpOverlapped);

Open in new window

0
 
LVL 41

Accepted Solution

by:
graye earned 2000 total points
ID: 35195626
0
 

Author Comment

by:jetbet
ID: 35202131
That looks good although when I run the code the comm port cannot be opened as (according to getlasterror) "The system cannot find the file specified".

This may be due to using a usb to serial adaptor.

I will leave this question open for another day while I try and find the solution to this, and then assign the points to you.
0
 

Author Closing Comment

by:jetbet
ID: 35286626
Thanks for your help. It seams OK if you only use Com1
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

800 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