Re: How to CreateFile a COM port twice more ?



On Jun 10, 1:17 am, Kid <K...@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:

I found CreateFile can only open my device "\\\\.\\COMx" once , how can I
modify source to support app open two more handle ?

Not possible. Serial ports are exclusive open, and for good reason --
they're backed by a read buffer, so if two applications are reading
from one port, how could they each independently make any sense of the
data they received?
.



Relevant Pages

  • Re: How to change baud rate of an RS232 port?
    ... [direct hardware access code deleted] ... apart from needing root for no good reason, ... most serial ports are usb-attached now and it won't work on ...
    (comp.os.linux.development.apps)
  • Re: Serial console on ttyS4
    ... > I'm trying to set Linux up to use a serial console on ttyS4. ... There is a reason for this. ... In the default PC hardware configuration, ... are only two interrrupts assigned to serial ports: ...
    (comp.os.linux.misc)
  • Re: Loss of serial ports after upgrade.
    ... Maybe my mind is a little hazy. ... Maybe I had a reason at ... >the time to disable the serial ports. ... Maybe because 4.6 kernel config does not have "options UCONSOLE"? ...
    (freebsd-stable)
  • Re: How to CreateFile a COM port twice more ?
    ... can I modify source to support app open two more handle? ... Serial ports are exclusive open, and for good reason -- ... It wouldn't make sense for a physical UART, but a virtual COM port can ...
    (microsoft.public.development.device.drivers)
  • Re: Seriel port profiles in Blutooth?
    ... two BT serial ports - reading from a GPS while reading from a data device ... stack but is there a workaroud to this problem? ...
    (microsoft.public.dotnet.framework.compactframework)

Loading