diff options
author | tmk <nobody@nowhere> | 2013-05-14 16:18:22 +0900 |
---|---|---|
committer | tmk <nobody@nowhere> | 2013-05-14 16:19:40 +0900 |
commit | ff2d276b193632136c785d92ed01df48aea8461f (patch) | |
tree | bd8e7c789fbb7f191b4de31498160f05d2f80229 /common/host.c | |
parent | d9c06db60006e2191d8b86e34f651644a54426b4 (diff) |
Use dprint and dprintf for debug
Diffstat (limited to 'common/host.c')
-rw-r--r-- | common/host.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/common/host.c b/common/host.c index 6ed3d780f6..2c2279aa4e 100644 --- a/common/host.c +++ b/common/host.c @@ -63,11 +63,11 @@ void host_keyboard_send(report_keyboard_t *report) (*driver->send_keyboard)(report); if (debug_keyboard) { - print("keys: "); + dprint("keys: "); for (int i = 0; i < REPORT_KEYS; i++) { - phex(keyboard_report->keys[i]); print(" "); + dprintf("%02X ", keyboard_report->keys[i]); } - print(" mods: "); phex(keyboard_report->mods); print("\n"); + dprintf(" mods: %02X\n", keyboard_report->mods); } } @@ -235,7 +235,7 @@ static inline void add_key_bit(uint8_t code) if ((code>>3) < REPORT_KEYS) { keyboard_report->keys[code>>3] |= 1<<(code&7); } else { - debug("add_key_bit: can't add: "); phex(code); debug("\n"); + dprintf("add_key_bit: can't add: %02X\n", code); } } @@ -244,6 +244,6 @@ static inline void del_key_bit(uint8_t code) if ((code>>3) < REPORT_KEYS) { keyboard_report->keys[code>>3] &= ~(1<<(code&7)); } else { - debug("del_key_bit: can't del: "); phex(code); debug("\n"); + dprintf("del_key_bit: can't del: %02X\n", code); } } |