Dave's custom keymap

This moves the keys closer to a traditional layout with some redundancy
around the middle to compensate for fast non-traditional typists like
myself who tend to wander from the home row a fair bit. Navigation keys
are provided in layer 2 (accessed by left thumb button), programming
symbols and classic numeric keypad in layer 1 (accessed by right thumb
button). Permanent layer switching is provided with a smaller thumb
button. Ctrl provided in place of caps lock (because no-one needs
caps/num lock), space, backspace, enter, shift all in traditional
positions with layer 1 providing things like equals, tilde and
apostrophe (an attempt to re-use existing muscle memory).

LEDs are pimped to the point of being silly (fading in/out on layer
switch, rolling on reboot ... because I can). Power and reset keys
provided on left thumb pad in layer 2.

No meh or hyper as I haven't found a burning need for them yet.
This commit is contained in:
Dave Jones 2015-12-19 22:18:58 +00:00
parent 9c5f30ed83
commit 7ba06c9e0d
4 changed files with 217 additions and 11 deletions

View file

@ -34,7 +34,7 @@ void ergodox_blink_all_leds(void);
uint8_t init_mcp23018(void);
uint8_t ergodox_left_leds_update(void);
#define LED_BRIGHTNESS_LO 31
#define LED_BRIGHTNESS_LO 15
#define LED_BRIGHTNESS_HI 255
@ -42,11 +42,13 @@ inline void ergodox_board_led_on(void) { DDRD |= (1<<6); PORTD |= (1<<6);
inline void ergodox_right_led_1_on(void) { DDRB |= (1<<5); PORTB |= (1<<5); }
inline void ergodox_right_led_2_on(void) { DDRB |= (1<<6); PORTB |= (1<<6); }
inline void ergodox_right_led_3_on(void) { DDRB |= (1<<7); PORTB |= (1<<7); }
inline void ergodox_right_led_on(uint8_t led) { DDRB |= (1<<(led+4)); PORTB |= (1<<(led+4)); }
inline void ergodox_board_led_off(void) { DDRD &= ~(1<<6); PORTD &= ~(1<<6); }
inline void ergodox_right_led_1_off(void) { DDRB &= ~(1<<5); PORTB &= ~(1<<5); }
inline void ergodox_right_led_2_off(void) { DDRB &= ~(1<<6); PORTB &= ~(1<<6); }
inline void ergodox_right_led_3_off(void) { DDRB &= ~(1<<7); PORTB &= ~(1<<7); }
inline void ergodox_right_led_off(uint8_t led) { DDRB &= ~(1<<(led+4)); PORTB &= ~(1<<(led+4)); }
inline void ergodox_led_all_on(void)
{
@ -67,6 +69,11 @@ inline void ergodox_led_all_off(void)
inline void ergodox_right_led_1_set(uint8_t n) { OCR1A = n; }
inline void ergodox_right_led_2_set(uint8_t n) { OCR1B = n; }
inline void ergodox_right_led_3_set(uint8_t n) { OCR1C = n; }
inline void ergodox_right_led_set(uint8_t led, uint8_t n) {
(led == 1) ? (OCR1A = n) :
(led == 2) ? (OCR1B = n) :
(OCR1C = n);
}
inline void ergodox_led_all_set(uint8_t n)
{