X-Git-Url: https://git.friedersdorff.com/?a=blobdiff_plain;f=util.h;h=2b607ad284423bbf98e40c83db9c392a1c268b96;hb=239bdbf41936566c0ae5b0cbd8c6bf7dd824f7fb;hp=256bda020ce7da15cc1f45df908e13d51a6d646b;hpb=461e0d3d8c82cc78d29d3115af3c417bb51bb50f;p=max%2Ftmk_keyboard.git diff --git a/util.h b/util.h index 256bda02..2b607ad2 100644 --- a/util.h +++ b/util.h @@ -1,7 +1,17 @@ #ifndef UTIL_H #define UTIL_H 1 -#define XSTR(s) STR(s) -#define STR(s) #s +#include + +// convert to L string +#define LSTR(s) XLSTR(s) +#define XLSTR(s) L ## #s +// convert to string +#define STR(s) XSTR(s) +#define XSTR(s) #s + + +int bitpop(uint8_t bits); +int biton(uint8_t bits); #endif