Thread: Win32 Serial Communication & DeviceIoControl()

  1. #1
    Registered User
    Join Date
    Nov 2005
    Posts
    0

    Win32 Serial Communication & DeviceIoControl()

    Is it possible to use the DeviceIoControl() function to send commands directly to the driver for a COM port?

    I am developing a time sensitive Win32 serial port application where I periodically need to change the parity of my serial data. Calls to Get_Comm_State() & Set_Comm_State() to update the parity are taking too long. I observed (using a serial port monitor) that these get and set methods do alot of unnessecary things like seting the baud rate etc.

    It would be nice if I could use the DeviceIoControl function along with the IOCTL_SERIAL_SET_LINE_CONTROL command (or similar) to quickly change the parity from within my application. Am I living in a fantasy world or is this a possibility?

    Many thanks

    B_B

  2. #2
    Registered User
    Join Date
    Sep 2004
    Location
    California
    Posts
    3,268
    I don't believe there is any device control code which can be used to change the parity on a COM device.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Duplex communication thro serial port
    By Priyachu in forum Networking/Device Communication
    Replies: 1
    Last Post: 05-30-2009, 04:24 AM
  2. Serial port Communication
    By vin_pll in forum C++ Programming
    Replies: 23
    Last Post: 01-07-2009, 09:32 AM
  3. Please help with serial communication problem - Long
    By spdylude in forum Windows Programming
    Replies: 3
    Last Post: 04-06-2005, 09:41 AM
  4. Serial communication packets
    By Roaring_Tiger in forum C Programming
    Replies: 3
    Last Post: 04-26-2003, 08:33 AM
  5. Serial Communications with win32 api
    By Blackthorne in forum C Programming
    Replies: 1
    Last Post: 01-26-2003, 12:45 PM