USB Host Driver with Socket Modem support. Works with revision 323 of mbed-src but broken with any later version.
Dependencies: FATFileSystem
Fork of F401RE-USBHost by
USBHostMouse.h@0:5160ee0c522d, 2014-01-18 (annotated)
- Committer:
- va009039
- Date:
- Sat Jan 18 13:30:22 2014 +0000
- Revision:
- 0:5160ee0c522d
first commit
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 |