X-Git-Url: https://git.friedersdorff.com/?a=blobdiff_plain;f=protocol%2Flufa%2Flufa.h;h=195123c0f974f55a534ce716769e4358c0129554;hb=bfd2d969b48eb2f381137383c6262b60e03cf5b1;hp=bcee060d67df62ce416262eaea9906c182d77c9b;hpb=dc79a8521946a3a2e5b86945b8043b87a8b8d78c;p=max%2Ftmk_keyboard.git diff --git a/protocol/lufa/lufa.h b/protocol/lufa/lufa.h index bcee060d..195123c0 100644 --- a/protocol/lufa/lufa.h +++ b/protocol/lufa/lufa.h @@ -66,4 +66,15 @@ typedef struct { uint16_t usage; } __attribute__ ((packed)) report_extra_t; + +#if LUFA_VERSION_INTEGER < 0x120730 + /* old API 120219 */ + #define ENDPOINT_CONFIG(epnum, eptype, epdir, epsize, epbank) Endpoint_ConfigureEndpoint(epnum, eptype, epdir, epsize, epbank) +#else + /* new API >= 120730 */ + #define ENDPOINT_BANK_SINGLE 1 + #define ENDPOINT_BANK_DOUBLE 2 + #define ENDPOINT_CONFIG(epnum, eptype, epdir, epsize, epbank) Endpoint_ConfigureEndpoint((epdir) | (epnum) , eptype, epsize, epbank) +#endif + #endif