Usb read
Dependencies: FATFileSystem
Fork of F401RE-USBHost by
USBHostHID/USBHostMouse.h@3:a3872f7593e2, 2014-01-25 (annotated)
- Committer:
- va009039
- Date:
- Sat Jan 25 12:51:44 2014 +0000
- Revision:
- 3:a3872f7593e2
- Parent:
- USBHostMouse.h@0:5160ee0c522d
- Child:
- 8:6463cd1964c0
fix max packet size
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
va009039 | 0:5160ee0c522d | 1 | // Simple USBHost Mouse for FRDM-KL46Z |
va009039 | 0:5160ee0c522d | 2 | #include "USBHost.h" |
va009039 | 0:5160ee0c522d | 3 | |
va009039 | 0:5160ee0c522d | 4 | class USBHostMouse { |
va009039 | 0:5160ee0c522d | 5 | public: |
va009039 | 0:5160ee0c522d | 6 | USBHostMouse() { |
va009039 | 0:5160ee0c522d | 7 | host = USBHost::getHostInst(); |
va009039 | 0:5160ee0c522d | 8 | } |
va009039 | 0:5160ee0c522d | 9 | int readReport(uint8_t* data) { |
va009039 | 0:5160ee0c522d | 10 | return host->InterruptRead(data, 4); |
va009039 | 0:5160ee0c522d | 11 | } |
va009039 | 0:5160ee0c522d | 12 | |
va009039 | 0:5160ee0c522d | 13 | private: |
va009039 | 0:5160ee0c522d | 14 | USBHost * host; |
va009039 | 0:5160ee0c522d | 15 | }; |
va009039 | 0:5160ee0c522d | 16 |