;; -*- scheme -*- ;; DESCRIPTOR RECORDS ;; see code and docs in brood/usb.ss ;; i'm going to try it this way: put as little information as possible ;; in this file (no redundancy) and try to generate all the ;; descriptors from it. if things need to be numbered, they use a ;; simple sequence starting at 0 or 1, whichever is appropriate. ;; wherever possible, standard names are used. prefixes are separated ;; for easier parsing though. (compile-device ' ((bcd USB #x110) (b DeviceClass 0) (b DeviceSubClass 0) (b DeviceProtocol 0) (b MaxPacketSize 8) (id Vendor #x04D8) ; microchip (id Product #x0001) (bcd Device 0) ;; device release number (i Manufacturer "Microchip Technology, Inc.") (i ProductName "USB Hack") (i SerialNumber "0.0") (l NumConfigurations (((i Configuration "Default Configuration") (b ConfigurationValue 0) ;; ??? (bm Attributes #xA0) ;; remote wakeup (b MaxPower #x32) ;; 100 mA (w TotalLength -1) ;; conf + int + endp (l NumInterfaces (((i Interface "Default Interface") (b InterfaceNumber 1) ;; ??? (b InterfaceClass 3) ;; HID (b InterfaceSubClass 1) ;; Boot (b InterfaceProtocol 1) ;; Keyboard (b AlternateSetting 0) ;; ??? (l NumEndpoints (((bm Attributes #xA0) (b EndpointAddress #x80) (w MaxPacketSize 8) (b Interval 0))))))))))))