diff options
Diffstat (limited to 'tmk_core/common/avr/xprintf.h')
-rw-r--r-- | tmk_core/common/avr/xprintf.h | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/tmk_core/common/avr/xprintf.h b/tmk_core/common/avr/xprintf.h index 08d9f93a0c..70e0f8e48a 100644 --- a/tmk_core/common/avr/xprintf.h +++ b/tmk_core/common/avr/xprintf.h @@ -13,7 +13,7 @@ extern "C" { #endif extern void (*xfunc_out)(uint8_t); -#define xdev_out(func) xfunc_out = (void(*)(uint8_t))(func) +#define xdev_out(func) xfunc_out = (void (*)(uint8_t))(func) /* This is a pointer to user defined output function. It must be initialized before using this modle. @@ -25,13 +25,11 @@ void xputc(char chr); All outputs from this module are output via this function. */ - /*-----------------------------------------------------------------------------*/ void xputs(const char *string_p); /* The string placed in the ROM is forwarded to xputc() directly. -*/ - + */ /*-----------------------------------------------------------------------------*/ void xitoa(long value, char radix, char width); @@ -49,13 +47,12 @@ void xitoa(long value, char radix, char width); 0x55 2 -8 "01010101" */ - /*-----------------------------------------------------------------------------*/ -#define xprintf(format, ...) __xprintf(PSTR(format), ##__VA_ARGS__) -#define xsprintf(str, format, ...) __xsprintf(str, PSTR(format), ##__VA_ARGS__) -#define xfprintf(func, format, ...) __xfprintf(func, PSTR(format), ##__VA_ARGS__) +#define xprintf(format, ...) __xprintf(PSTR(format), ##__VA_ARGS__) +#define xsprintf(str, format, ...) __xsprintf(str, PSTR(format), ##__VA_ARGS__) +#define xfprintf(func, format, ...) __xfprintf(func, PSTR(format), ##__VA_ARGS__) -void __xprintf(const char *format_p, ...); /* Send formatted string to the registered device */ +void __xprintf(const char *format_p, ...); /* Send formatted string to the registered device */ // void __xsprintf(char*, const char *format_p, ...); /* Put formatted string to the memory */ // void __xfprintf(void(*func)(uint8_t), const char *format_p, ...); /* Send formatted string to the specified device */ @@ -84,7 +81,6 @@ void __xprintf(const char *format_p, ...); /* Send formatted string to the regis */ - /*-----------------------------------------------------------------------------*/ char xatoi(char **str, long *ret); @@ -108,4 +104,3 @@ char xatoi(char **str, long *ret); #endif #endif - |