M keyboards/handwired/kbod/config.h => keyboards/handwired/kbod/config.h +1 -41
@@ 23,61 23,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define MATRIX_ROWS 8
#define MATRIX_COLS 8
-/*
- * Keyboard Matrix Assignments
- *
- * Change this to how you wired your keyboard
- * COLS: AVR pins used for columns, left to right
- * ROWS: AVR pins used for rows, top to bottom
- * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
- * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
- *
-*/
#define MATRIX_ROW_PINS { C6, D7, E6, B4, B5, B6, B7, D6 }
#define MATRIX_COL_PINS { D0, D1, F0, F1, F4, F5, F6, F7 }
-/* COL2ROW, ROW2COL*/
#define DIODE_DIRECTION COL2ROW
-// #define BACKLIGHT_PIN B7
-// #define BACKLIGHT_BREATHING
-// #define BACKLIGHT_LEVELS 3
+#define LED_CAPS_LOCK_PIN B0
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCE 5
-/* define if matrix has ghost (lacks anti-ghosting diodes) */
-//#define MATRIX_HAS_GHOST
-
-/* number of backlight levels */
-
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
/*
- * Force NKRO
- *
- * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
- * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
- * makefile for this to work.)
- *
- * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
- * until the next keyboard reset.
- *
- * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
- * fully operational during normal computer usage.
- *
- * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
- * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
- * bootmagic, NKRO mode will always be enabled until it is toggled again during a
- * power-up.
- *
- */
-//#define FORCE_NKRO
-
-/*
* Feature disable options
* These options are also useful to firmware size reduction.
*/
@@ 93,5 54,4 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
//#define NO_ACTION_TAPPING
//#define NO_ACTION_ONESHOT
-#undef TAPPING_TOGGLE
#define TAPPING_TOGGLE 2
M keyboards/handwired/kbod/keymaps/default/keymap.c => keyboards/handwired/kbod/keymaps/default/keymap.c +8 -16
@@ 61,7 61,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case SFT_ESC:
- SET_WHETHER(MODS_PRESSED(SHIFT), KC_ESC, KC_GRAVE);
+ SET_WHETHER(MODS_PRESSED(SFT), KC_ESC, KC_GRAVE);
return false;
@@ 75,24 75,16 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
}
-void led_set_user(uint8_t usb_led) {
- if (usb_led & _BV(USB_LED_CAPS_LOCK)) {
- PORTB |= _BV(PB0);
- } else {
- PORTB &= ~_BV(PB0);
- }
-}
-
void matrix_init_user(void) {
- DDRB |= _BV(PB0);
- DDRC |= _BV(PC7);
+ setPinOutput(C7);
+ writePinLow(C7);
}
-void matrix_scan_user(void) {
- uint8_t layer = get_highest_layer(layer_state);
- if (layer) {
- PORTC |= _BV(PC7);
+layer_state_t layer_state_set_user(layer_state_t state) {
+ if (get_highest_layer(state)) {
+ writePinHigh(C7);
} else {
- PORTC &= ~_BV(PC7);
+ writePinLow(C7);
}
+ return state;
}
D keyboards/handwired/kbod/keymaps/default/readme.md => keyboards/handwired/kbod/keymaps/default/readme.md +0 -5
@@ 1,5 0,0 @@
-# The default keymap for kbod
-
-This is the default keymap for kbod,
-
-it consists of a base layer with QWERTY layout, a momentary cursor-layer, and mouse-keys and multimedia layers.>
\ No newline at end of file
D keyboards/handwired/kbod/keymaps/default/rules.mk => keyboards/handwired/kbod/keymaps/default/rules.mk +0 -9
@@ 1,9 0,0 @@
-BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite
-MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
-CONSOLE_ENABLE = no # Console for debug(+400)
-COMMAND_ENABLE = no # Commands for debug and configuration
-NKRO_ENABLE = yes
-BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
-AUDIO_ENABLE = no # Audio output
-RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.