forked from mirrors/qmk_userspace
Add USB HID(host) protocol.(not finished)
This commit is contained in:
parent
7350b7c6aa
commit
895cd4dfa2
7 changed files with 300 additions and 0 deletions
22
protocol/usb_hid/USBAPI.h
Normal file
22
protocol/usb_hid/USBAPI.h
Normal file
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
* Override original arduino USBAPI.h.
|
||||
*/
|
||||
#include <stdint.h>
|
||||
#include "Stream.h"
|
||||
|
||||
|
||||
class NullSerial : public Stream
|
||||
{
|
||||
public:
|
||||
void begin(uint16_t baud_count);
|
||||
void end(void);
|
||||
|
||||
virtual int available(void);
|
||||
virtual void accept(void);
|
||||
virtual int peek(void);
|
||||
virtual int read(void);
|
||||
virtual void flush(void);
|
||||
virtual size_t write(uint8_t);
|
||||
operator bool();
|
||||
};
|
||||
extern NullSerial Serial;
|
Loading…
Add table
Add a link
Reference in a new issue