Can someone confirm that the design of Haiku does NOT support the concept of a general usb device driver as is typically found in Linux or MS Windows?
I gather from looking at the documentation that Haiku is oriented fully in the direction of application program being its own USB device driver and only talking to its device through calls to the USB sub-system rather than opening something like “/dev/usb/mydevice” and making blocking IO requests to a usb device through a provided device driver.
If Haiku does support general device drives, then can someone in the developer community point me to a representative example?
Haiku has devices like that… but they may or may not be what you want?
I think you’d have to add support in haiku for the various subsystems of which only mass storage really has much support at all. There is some inital support for UVC and sound devices and maybe a special driver for a wimax card IIRC.
The USB Kit which is documented in the Haiku Book is similar in bothdesign and goal to libusb. It is not a complete replacement for standard device drivers, which we also have. However, the driver APIs are not as well documented as the application-side ones, which is why the USB Kit is more visible.
One difference with Linux is that our drivers tend to handle a whole class of devices, rather than a single one. For example, we have a single usb_serial driver for FTDI, Prolific, Silicon Labs and standard USB CDC devices. Linux has four different drivers.
All drivers in Haiku are located in src/add-ons/kernel/drivers. You can look at audio/usb, disk/usb, input/usb_hid, midi/usb_midi, network/usb_asix, network/usb_davicom, network/usb_ecm, ports/usb_serial, printer/usb, and video/usb_vision.
The usb_midi, usb_serial and the network ones are rather simple and standard examples, and not too hard to understand. I don't know the others, so I can't comment on them.