From 4ccbea7f36c8dc562d3607a4218db390e6fbe55b Mon Sep 17 00:00:00 2001 From: Oleg Mazurov Date: Mon, 22 Sep 2014 17:48:40 -0600 Subject: [PATCH] Send Report added to hiduniversal --- hiduniversal.cpp | 6 ++++++ hiduniversal.h | 3 +++ 2 files changed, 9 insertions(+) diff --git a/hiduniversal.cpp b/hiduniversal.cpp index e7a65e39..3cca8cfb 100644 --- a/hiduniversal.cpp +++ b/hiduniversal.cpp @@ -418,3 +418,9 @@ uint8_t HIDUniversal::Poll() { } return rcode; } + + +//Send a report to interrupt out endpoint. This is NOT SetReport() request! +uint8_t HIDUniversal::SndRpt(uint16_t nbytes, uint8_t *dataptr) { + return pUsb->outTransfer(bAddress, epInfo[epInterruptOutIndex].epAddr, nbytes, dataptr); +} \ No newline at end of file diff --git a/hiduniversal.h b/hiduniversal.h index 3e090aa7..5fd7e6b7 100644 --- a/hiduniversal.h +++ b/hiduniversal.h @@ -100,6 +100,9 @@ public: // UsbConfigXtracter implementation virtual void EndpointXtract(uint8_t conf, uint8_t iface, uint8_t alt, uint8_t proto, const USB_ENDPOINT_DESCRIPTOR *ep); + + //Send report - do not mix with SetReport()! + uint8_t SndRpt(uint16_t nbytes, uint8_t *dataptr); }; #endif // __HIDUNIVERSAL_H__