CDC Virtual Serial Com Port doesn't pnp on USB.

Discussion in 'Windows Vista Drivers' started by revo, Dec 1, 2004.

  1. revo

    revo Guest

    We have a working CDC device that used default windows and linux cdc
    drivers to form a logical virtual serial port.

    All we use is an inf file and the device works and we can open
    hyperterminal(HT) and talk to the device.

    If we unplug the device and HT is still running and we don't close the
    port the USB device enumerates as another comport. So HT must close the
    port previously used and restart, then we have to plug the device out
    again o have it reenumerate as the com port it was before. Now HT can open
    the port again.

    We have another serialtousb adapter that needs a driver. If open the port
    with HT and (un)plug the device the port stays open and when I connect it
    again HT still works on the same port.

    Our device needs to stay on the same comm port even when the application
    still has it openend. But the CDC driver seems not to support that.

    Can anyone shed some light in this matter? Do I need to build my own
    driver, and if I do what to do to have it keep the same port connecting to
    the application again.

    (picture the cashier dropping the scanner and having to reboot the whole
    register because the usb connection was lost for a while. Can't have that..)
    revo, Dec 1, 2004
    1. Advertisements

  2. revo

    Pavel A. Guest

    Maybe the another device has a "USB serial number"
    Pavel A., Dec 1, 2004
    1. Advertisements

  3. revo

    revo Guest

    Op Wed, 01 Dec 2004 11:17:06 -0800, schreef Pavel A.:
    The iSerialNumber does have a value, and the string works ok.

    I think the enumeration and connection to the actual virtual port is
    different, like the driver (from the device that does connect) after usb
    attach connects again to the virtual comport driver, and the windows cdc
    virtual port driver does not allow a device to reattach on the same port.

    Someone have any idea how to solve this?
    revo, Dec 2, 2004
  4. Seems like an issue in CDC driver. During removal of device, the driver has
    to remove symbolic link name for existing device. If it doesnt, this issue
    can happen.
    Sajan Wilfred, Dec 2, 2004
  5. revo

    revo Guest

    So what do I do ? I've been testing but there is just no communication

    revo, Dec 2, 2004
  6. In your SURPRISE_REMOVAL handler, you need to delete symbolic links and
    disable interfaces. Make sure NOT to do it again in REMOVE_DEVICE handler

    Don't use fixed names for your device objects, too.
    Alexander Grigoriev, Dec 2, 2004
  7. The iSerialNumber does have a value, and the string works ok.

    Such a string must never repeat in 2 hardware pieces. Otherwise, attaching both
    these pieces will BSOD the OS.
    Maxim S. Shatskih, Dec 5, 2004
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.