1
0
mirror of https://github.com/arduino/Arduino.git synced 2024-12-02 13:24:12 +01:00
Commit Graph

4 Commits

Author SHA1 Message Date
Martino Facchin
e1a0350062 allow HID submodules to create runtime descriptors
with this PR you can add

\#include Keyboard.h
\#include Mouse.h
\#include HID.h

in the top of the sketch and you will expose a Mouse+Keyboard

From the library pow, simply add

static HID_Descriptor cb = {
	.length = sizeof(_hidReportDescriptor),
	.descriptor = _hidReportDescriptor,
};
static HIDDescriptorListNode node(&cb);
HID.AppendDescriptor(&node);

in the class' constructor and you are done!
2015-07-16 13:13:52 +02:00
Martino Facchin
5defaeaa97 rework HID class functions scopes 2015-07-16 13:13:52 +02:00
Martino Facchin
071323196d enforce single use of HID submodule 2015-07-16 13:13:45 +02:00
Martino Facchin
c2a083b57b standalone Mouse library 2015-07-16 13:12:14 +02:00