Author Topic: USB to 232 CDC driver vs. manufacturer driver on Windows  (Read 9719 times)

JimmieC

  • Member
  • ***
  • Posts: 2
USB to 232 CDC driver vs. manufacturer driver on Windows
« on: February 27, 2013, 02:18:23 pm »
Hello All,

I have a point of curiosity that has annoyed me for a long time. I found this forum and it looks like exactly the place to have it solved.

I am an embedded software developer. However, I am not currently working on a USB project. Also, my question really applies to Windows and the driver, not an embedded application. As I said, it is just that this has been a point of curiosity for me for a long time.

I understand that there is a Windows class driver for USB-232 interfaces, usbser.sys, that conforms to the CDC specification.

However, I have used some USB to RS-232 converters in the past that required me to download the driver from the manufacturer. This definitely occurred on XP and I am pretty sure it occurred on Windows 7 as well.

One of those converters that required a manufacturer driver was the Targus PA088. Another was from Sewell where I downloaded the file "SW-1301_v1.2.1.zip" which when unzipped had the following executable inside: "PL2303_Prolific_DriverInstaller_v1210.exe," apparently from Prolific Semiconductor.

Also, I am curious if some of the manufacturer drivers aren't really just .INF files that somehow register the device to use the CDC drivers? But, this would not make much sense as it pretty much defeats the idea of a class driver.

I perused the "USB Complete 3rd Edition" book. And, while I did not read all of it, I did check the sections:

---> Device Classes 177
  |--> Standard or Custom Driver? 226
  |--> Converting from RS-232      227

Neither of these chapters really answers my questions thoroughly.

Standard or Custom Driver? 226:
Explains that special functions will not have a class driver, that I understand. It does not explain why a manufacturer would make a device, RS-232 in this case, yet still provide a custom driver and not use the class driver.

Converting from RS-232      227:
Provides an example how the FTDI chip can be used to create an RS-232 converter. It mentions that a modem should use a class driver and that pointing devices should be HIDs. But, it never states why the RS-232 should or should-not be made to utilize the class driver and what dictates that decision. Furthermore, why so many converters do NOT use the class driver.

Any light you can shed on this would be greatly appreciated.

Regards,
Jim




 

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 2825
    • Lakeview Research
Re: USB to 232 CDC driver vs. manufacturer driver on Windows
« Reply #1 on: February 27, 2013, 08:43:09 pm »
The vendor-provided drivers generally have better performance and more capabilities compared to the Windows CDC-class driver. For example, the CDC class doesn't define a way for the host to read an RS-232 CTS signal.

JimmieC

  • Member
  • ***
  • Posts: 2
Re: USB to 232 CDC driver vs. manufacturer driver on Windows
« Reply #2 on: February 28, 2013, 03:00:28 pm »
Hi Jan,

Thanks for your reply.

I still have some questions as I still do not have a "good feel" for the market and the way it all fits together. Maybe, I can keep questioning you and the forum community until I get the "BIG PICTURE" through my head ;-)

See questions below.

Regards,
Jim

//-------------------------------------------------------------------------
So, does this mean that all USB IC's that are used to create a USB-to-232 converter (dongle) are capable of being made to use the CDC driver? That is, the hardware does NOT dictate a limitation to being CDC compliant?

       If so, then what indicates to the OS that the device is NOT CDC compliant?
             My guess is that this is related to an ID string or code.

//-------------------------------------------------------------------------
Do the silicon vendors, such as FTDI and Prolific, create the custom drivers because they feel the better performance (or the need to use CTS) is in demand?

         That is, the baud rates are not that high compared to
         multi-megabyte communications such as TCP\IP. Additionally,
         all of my RS-232\RS-485 implementations have used "no hardware
         flow control." However, I am not involved with the telecom or
         automation industry so I realize that I might not have a "BIG
         PICTURE" view of the serial landscape, as it were.

         Also, it seems to me that the convenience of the class driver to the
         casual customer would be a big benefit.  That is, the average
         consumer really doesn't even know what a driver is and may not
         be adept at installing them correctly.

//-------------------------------------------------------------------------
Are there serial converters that can operate from custom drivers or class CDC drivers?

       If so, how does it indicate to the OS which type it would prefer act as?

       If so, is this common implementation from vendors such as FTDI and Prolific?



Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 2825
    • Lakeview Research
Re: USB to 232 CDC driver vs. manufacturer driver on Windows
« Reply #3 on: February 28, 2013, 05:34:56 pm »
The host PC determines what driver to use by looking for a match between the information in the device's descriptors and the information in the host PC's INF files (assuming Windows).

A CDC-class device will declare the CDC class in its descriptors. A device that uses a vendor-provided driver will declare no standard class.

Yes, the FTDI and similar chips have better performance and added features.

Devices that use the CDC driver can use the system's driver but still require an INF file with the Vendor ID and Product ID.

I'm not aware of any USB/serial converter chips that use the CDC driver. (That doesn't mean they don't exist.) A general-purpose microcontroller with USB support could be programmed to use the CDC driver however.