]> rtime.felk.cvut.cz Git - lincan.git/blob - embedded/libs4c/usb/more/usb/usb_loader.h
Embedded code-base updated to actual version from uLan repository.
[lincan.git] / embedded / libs4c / usb / more / usb / usb_loader.h
1 #include <usb/usb.h>
2
3 #ifndef _USB_LOADER_H
4 #define _USB_LOADER_H
5
6 #define USB_VENDOR_GET_CAPABILITIES  0x00 // get capabilities
7 #define USB_VENDOR_RESET_DEVICE      0x08
8 // #define USB_VENDOR_SET_BYTE          0x10
9 // #define USB_VENDOR_SET_WORD          0x20
10 #define USB_VENDOR_GET_SET_MEMORY    0x30
11 #define USB_VENDOR_ERASE_MEMORY      0x40 // erase memory for 1 Byte
12 #define USB_VENDOR_ERASE_1KB_MEMORY  0x48 // erase memory for 1 KB
13 #define USB_VENDOR_MASS_ERASE        0x50 // erase all device memory
14 #define USB_VENDOR_GOTO              0x60
15 #define USB_VENDOR_CALL              0x70
16 #define USB_VENDOR_GET_STATUS        0xF0
17 #define USB_VENDOR_MASK              0xF8 // mask for vendor commands
18
19 #define USB_VENDOR_MEMORY_BY_BULK    0x80
20
21 /* COMMON */
22 #define USB_VENDOR_TARGET_RAM        0x01
23 #define USB_VENDOR_TARGET_FLASH      0x02
24 /* MSP430 */
25 #define USB_VENDOR_TARGET_ADAPTER    0x01
26 #define USB_VENDOR_TARGET_MSP430     0x02
27 /* MSC1210 */
28 #define USB_VENDOR_TARGET_DATA       0x01
29 #define USB_VENDOR_TARGET_XDATA      0x02
30
31 #define USB_VENDOR_TARGET_MASK       0x07
32
33 /* bRequest - type of request */
34 /* wValue - lower address word */
35 /* wIndex - higher address word */
36 /* wLength - data or length of data */
37
38 #endif /*_USB_LOADER_H*/