From: DickGrier on 31 Dec 2009 13:07 Hi, You can use WMI to obtain the port description for installed ports. I have code examples for this in my book (below). I also provide a modified version of MSComm32.ocx that allows you to open ports higher than 16, which often happens these days. If you send me email, I will reply with that OCX attached. However... USB serial adapters are used just like any other serial adapter. Do you really need to know whether or not is is USB (virtual serial port) vs. hardware? You just set the CommPort number and Settings, (etc.), and go. In answer to your other question, I tend to prefer USB serial adapters that are based on the FTDI chipset. These seem to be reliable across all OS -- Richard Grier, Consultant, Hard & Software 12962 West Louisiana Avenue Lakewood, CO 80228 303-986-2179 (voice) Homepage: www.hardandsoftware.net Author of Visual Basic Programmer's Guide to Serial Communications, 4th Edition ISBN 1-890422-28-2 (391 pages) published July 2004, Revised July 2006.
From: DanS on 31 Dec 2009 13:12 > a good USB to Serial RS232 converter? Isn't that an oxymoron ?!?!?!?!!?
From: Bee on 31 Dec 2009 16:13 Huh? I need to know if a PC has one usable real serial RS232 port or more. If it does not, then I will suggest a USB to serial RS232 converter. If it has a real serial RS232 port I will test it to see if the hardware I expect is attached. Does not the USB to Serial driver look like a serial RS232 port so I can just try it as if it is an RS232 port? "Nobody" wrote: > "Bee" <Bee(a)discussions.microsoft.com> wrote in message > news:E0C57B85-8A3E-4889-B989-2F5860FCA234(a)microsoft.com... > >I need to know if a port is Serial (RS232) or USB or whatever not just a > > count although a count is useful. > > Why do you need to know that? I can't think of any reason to limit a > software from using USB-to-Serial converters. For you, they behave the same. > > > . >
From: Bee on 31 Dec 2009 16:21 I have used WMI but do not know how to interpret the data to determine if: (1) true hardware serial RS232 (2) USB port (3) USB port with USB to Serial dongle. (4) other In my case, I see my Sprint dongle showing up in that serial area. But I do not see a generic descriptor. Hope I do not have to sort through millions of different devices to determine what is attached. I need somthing distributable! Suggestions please. And thanks for the tip on the FTDI chipset! That really helps me. For example: (this laptop has no Serial RS232 port) Name Sprint Connection Manager NMEA Port (COM7) Status OK PNP Device ID NMEA\PORTB\1&5&NMEAAPP0 Maximum Input Buffer Size 0 Maximum Output Buffer Size No Settable Baud Rate Yes Settable Data Bits Yes Settable Flow Control Yes Settable Parity Yes Settable Parity Check Yes Settable Stop Bits Yes Settable RLSD Yes Supports RLSD Yes Supports 16 Bit Mode No Supports Special Characters No Baud Rate 9600 Bits/Byte 8 Stop Bits 1 Parity None Busy No Abort Read/Write on Error No Binary Mode Enabled Yes Continue XMit on XOff No CTS Outflow Control No Discard NULL Bytes No DSR Outflow Control 0 DSR Sensitivity 0 DTR Flow Control Type Enable EOF Character 26 Error Replace Character 0 Error Replacement Enabled No Event Character 0 Parity Check Enabled No RTS Flow Control Type Disable XOff Character 19 XOffXMit Threshold 512 XOn Character 17 XOnXMit Threshold 2048 XOnXOff InFlow Control 0 XOnXOff OutFlow Control 0 Driver c:\windows\system32\drivers\pctnullport.sys (2.0.2.0, 37.77 KB (38,680 bytes), 12/2/2009 12:12 PM)
From: CY on 31 Dec 2009 16:22 On 31 Dec, 19:12, DanS <t.h.i.s.n.t.h....(a)r.o.a.d.r.u.n.n.e.r.c.o.m> wrote: > > a good USB to Serial RS232 converter? > > Isn't that an oxymoron ?!?!?!?!!? Yep, USB is serial... as RS-485, RS-422 (Still handy, like the cable length/multidrop and still async), and the new nice hard drives connect with SATA. Serial isnt all, can be parallel like IEEE-1284 (Centronics port if anyone remember, If my memory dont fail me) and you still can talk to them. For the Q about nr of zerials , look at my earlier post. You have to test it, I cant! (Or, I wont ;) Happy New Year) //CY
First
|
Prev
|
Next
|
Last
Pages: 1 2 3 4 Prev: Set backcolor in a StatusBar ? Next: MSDN((VB6) won't install |