_______________________________________________ Boost-users mailing list Boost...@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
From: Boost-users [mailto:boost-use...@lists.boost.org] On Behalf Of Vincent Boucher
Sent: 10 April 2013 13:40
To: boost...@lists.boost.org
Subject: [Boost-users] Asio Serial ports: enumerating all the devices
"vendor id, product id "What's that ?I mean for a serial device. If they are present in the device protocol then fine, but that depends on the individual devices and their protocols.You can check whether there has been any traffic, which might be useful, but serial connections are just streams of bytes.
Yes, quite possibly.
That's quite close to what I was trying to say with respect to the /dev contents.
All that is probably possible would be to enumerate is serial interfaces (COM ports, in Windows parlance).
Or to enumerate all devices then somehow query them for their type to ascertain that they are serial ports.
There's no way to determine the connected devices.
A quick Google search tells me FTDI devices are serial-ports accessed via USB. ComTrol devices are similar in that they are serial ports accessed via Ethernet. I guess there are other ways of making a serial port available.
Regards,
Richard.
Richard Kerry
BNCS Engineer
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
This e-mail and the documents attached are confidential and intended solely for the addressee; it may also be privileged. If you receive this e-mail in error, please notify the sender immediately and destroy it. As its integrity cannot be secured on the Internet, the Atos group liability cannot be triggered for the message content. Although the sender endeavours to maintain a computer virus-free network, the sender does not warrant that this transmission is virus-free and will not be liable
Vincent,
Please can you make absolutely clear to us whether you are asking about serial ports, or serially-connected devices ?
(The serial ports themselves may be integral parts of the computer, or they may be accessed via USB, or Ethernet, or some other means)
The OS can know about serial ports - indeed I think it has to.
I think this is what is present in /dev. (if this is not so please can someone with Linux knowledge elaborate)
There is no way the OS can know about the serially-connected devices.
And no way of guaranteeing you can safely query devices.
When you meet a person you've never met before, and who speaks another language, you may think you are offering a respectful greeting, but the other person may hear an insult against his mother....
When you send your query message to a serially-connected device where you don't know what messages the device understands you may think you are saying "are you there ?" but the device may hear "launch the missiles". I leave it to you and your lawyers to consider whether you can accept this risk.
But if what you mean is serial ports, then all this is moot, and the OS can know, and ASIO might be able to enumerate them for you.
Helpfully,
Hopeully,
Richard.
Richard Kerry
BNCS Engineer
Room EBX 301, BBC Television Centre, Wood Lane, London, W12 7RJ
This e-mail and the documents attached are confidential and intended solely for the addressee; it may also be privileged. If you receive this e-mail in error, please notify the sender immediately and destroy it. As its integrity cannot be secured on the Internet, the Atos group liability cannot be triggered for the message content. Although the sender endeavours to maintain a computer virus-free network, the sender does not warrant that this transmission is virus-free and will not be liable