X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=keyboard.h;h=988dac36ed8b3b71c6b39acc56e2e108ec72a243;hb=225de7a847a511d004bf909b1334e19497cf2f9d;hp=2c2d43aca5ddb10a6b322df2eeb5d9f8f6a058ae;hpb=acc974c64b1e17e6807133fdc50de5bb34aedda5;p=qmk_firmware.git diff --git a/keyboard.h b/keyboard.h index 2c2d43aca..988dac36e 100644 --- a/keyboard.h +++ b/keyboard.h @@ -1,43 +1,28 @@ +/* +Copyright 2011 Jun Wako + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 2 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . +*/ + #ifndef KEYBOARD_H #define KEYBOARD_H #include -#include -#include "host.h" - - -/* keyboard Modifiers in boot protocol report */ -#define BIT_LCTRL (1<<0) -#define BIT_LSHIFT (1<<1) -#define BIT_LALT (1<<2) -#define BIT_LGUI (1<<3) -#define BIT_RCTRL (1<<4) -#define BIT_RSHIFT (1<<5) -#define BIT_RALT (1<<6) -#define BIT_RGUI (1<<7) -#define BIT_LCTL BIT_LCTRL -#define BIT_RCTL BIT_RCTRL -#define BIT_LSFT BIT_LSHIFT -#define BIT_RSFT BIT_RSHIFT - - -extern report_keyboard_t *keyboard_report; -extern report_keyboard_t *keyboard_report_prev; - -void keyboard_set_led(uint8_t led); -void keyboard_send(void); - -void keyboard_add_key(uint8_t key); -void keyboard_add_mod_bit(uint8_t mod); -void keyboard_set_mods(uint8_t mods); -void keyboard_add_code(uint8_t code); -void keyboard_swap_report(void); -void keyboard_clear_report(void); - -uint8_t keyboard_has_anykey(void); -uint8_t *keyboard_get_keys(void); -uint8_t keyboard_get_mods(void); -#endif +void keyboard_init(void); +void keyboard_proc(void); +void keyboard_set_leds(uint8_t leds); +#endif