request usb id

This forum is dedicated to feedback, discussions about ongoing or future developments, ideas and suggestions regarding the ChibiOS projects are welcome. This forum is NOT for support.
Post Reply
broucari
Posts: 15
Joined: Mon Aug 17, 2015 3:23 pm
Been thanked: 2 times

request usb id

Post by broucari »

Hi,

I volontuer to request usb id from openmoko (https://wiki.openmoko.org/wiki/USB_Product_IDs) for chibios implementation of usb cdc.

Are you interested ?

Bastien
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: request usb id

Post by Giovanni »

Sure, it would be nice.

Giovanni
broucari
Posts: 15
Joined: Mon Aug 17, 2015 3:23 pm
Been thanked: 2 times

Re: request usb id

Post by broucari »

Ok will request for now:
- ChibiOS virtual serial console shell
- ChibiOS virtual serial port

If I can code the null modem stuff I will request:
- ChibiOS virtual null modem master
- ChibiOS virtual null modem slave

And I will implement a usb2uart bridge so I need two more:
- ChibiOS usb2uart bridge basic
- ChibiOS usb2serial (include flow)

What do you think ?
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: request usb id

Post by Giovanni »

Hi,

I would just request codes by device types: CDC, HID, MSC (mass storage if I remember well). It is a finite pool so better don't take too much.

Serial, shell etc are all CDCs.

Giovanni
electronic_eel
Posts: 95
Joined: Sat Mar 19, 2016 8:07 pm
Has thanked: 8 times
Been thanked: 23 times

Re: request usb id

Post by electronic_eel »

Aren't the USB ids per device type? Within one device, you can have endpoints with several classes, like CDC, HID, MSC. You can differentiate based on class, so to differentiate between a CDC and HID, you wouldn't need different USB ids.

The issue is more that you have multiple devices that implement an endpoint with the same class, like CDC, connected to the same host. One implements for example a shell on CDC, the other the USB to UART bridge on CDC. Now you want to differentiate between them. That is the point where different device ids can make sense.

But on linux this doesn't really matter anymore, because you usually will write udev rules anyway. And then you can use other things in the descriptor than the precious device ids, like the device name or serial number, to differentiate. On windows you'd use the generic CDC driver provided by windows. That will assign a COMnn: device with unknown and unstable number nn. You'd then use a program or powershell script or similar to find the right one, based on data in the usb descriptors again.

So I don't think there is really need for more than one ChibiOS device id.
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: request usb id

Post by Giovanni »

I tend to agree, one is sufficient, eventually we can ask for more should necessity arise. Additionally, you can have multiple device types on the same USB.

Giovanni
Post Reply