Page 1 of 1
Nasm usb driver
Posted: Thu Sep 26, 2024 1:07 pm
by MikyBart
Re: Nasm usb driver
Posted: Thu Sep 26, 2024 3:38 pm
by BenLunt
Hi,
I highly suggest that you do not write a USB driver in assembly. The code can get quite complex and a single error, syntax or otherwise, will be very difficult to find.
On that note though, quite a while ago I did write a simple example in assembly to find a UHCI device.
https://www.fysnet.net/usb.htm
Please note that it does very little error checking, has a lot of assumptions, and was for information purposes only.
Ben
-
https://www.fysnet.net/osdesign_book_series.htm
Re: Nasm usb driver
Posted: Mon Sep 30, 2024 10:44 am
by GoingNuts
I've just started off with usb keyboard driver and got as far as getting device and configuration descriptors but got stuck on several fronts here as I'm running my o/s in virtualbox under windows 11 which generates 2 different results compared to vmware pro; ie: set_configuration is acknowledged in vmware but not in virtualbox. Another issue is both interfaces (for keyboard & mouse) in vmware's configuration descriptor only give Classcode=3 but Subclass and Protocol are 0x00 and on top of all that both vms only allow 1 msi interrupt compared to 8 on baremetal. Yea... a bit of hassle for now.