summaryrefslogtreecommitdiff
path: root/layouts/community/ortho_5x12
diff options
context:
space:
mode:
authorOlivier Poitrey <rs@rhapsodyk.net>2019-05-07 10:43:08 -0700
committerDrashna Jaelre <drashna@live.com>2019-05-07 10:43:08 -0700
commit2d5c16dfd4ef193c4f692722157aa2b526a4c877 (patch)
tree527c5e5f51cf75c4476616a3c6ed91e385f1e1b2 /layouts/community/ortho_5x12
parent3b132599427a648b1f14aaf30312f05f855625ea (diff)
[Keymap] crkbd/keymaps/rs: add rs keymap to corne keyboard and adapt others (#5181)
Update all my keymaps to work with 40 keys. Refactor code using Userspace.
Diffstat (limited to 'layouts/community/ortho_5x12')
-rw-r--r--layouts/community/ortho_5x12/rs/config.h34
-rw-r--r--layouts/community/ortho_5x12/rs/karabiner.json154
-rw-r--r--layouts/community/ortho_5x12/rs/keymap.c48
-rw-r--r--layouts/community/ortho_5x12/rs/readme.md18
4 files changed, 24 insertions, 230 deletions
diff --git a/layouts/community/ortho_5x12/rs/config.h b/layouts/community/ortho_5x12/rs/config.h
index 02076e8728..6f70f09bee 100644
--- a/layouts/community/ortho_5x12/rs/config.h
+++ b/layouts/community/ortho_5x12/rs/config.h
@@ -1,35 +1 @@
#pragma once
-
-#ifdef AUDIO_ENABLE
-//#define STARTUP_SONG SONG(PREONIC_SOUND)
-#define STARTUP_SONG SONG(NO_SOUND)
-
-#define DEFAULT_LAYER_SONGS \
- { SONG(QWERTY_SOUND), SONG(COLEMAK_SOUND), SONG(DVORAK_SOUND) }
-#endif
-
-#define MUSIC_MASK (keycode != KC_NO)
-
-/*
- * MIDI options
- */
-
-/* Prevent use of disabled MIDI features in the keymap */
-//#define MIDI_ENABLE_STRICT 1
-
-/* enable basic MIDI features:
- - MIDI notes can be sent when in Music mode is on
-*/
-
-#define MIDI_BASIC
-
-/* enable advanced MIDI features:
- - MIDI notes can be added to the keymap
- - Octave shift and transpose
- - Virtual sustain, portamento, and modulation wheel
- - etc.
-*/
-//#define MIDI_ADVANCED
-
-/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
-//#define MIDI_TONE_KEYCODE_OCTAVES 2
diff --git a/layouts/community/ortho_5x12/rs/karabiner.json b/layouts/community/ortho_5x12/rs/karabiner.json
deleted file mode 100644
index f5214650ad..0000000000
--- a/layouts/community/ortho_5x12/rs/karabiner.json
+++ /dev/null
@@ -1,154 +0,0 @@
-{
- "title": "RS",
- "rules": [{
- "description": "CapsLock to Escape / Control Mod-Tap",
- "manipulators": [{
- "type": "basic",
- "from": {
- "key_code": "caps_lock",
- "modifiers": {
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "left_control"}],
- "to_if_alone": [{"key_code": "escape"}]
- }]
- },
- {
- "description": "Right-Shift / Enter Mod-Tap",
- "manipulators": [{
- "type": "basic",
- "from": {
- "key_code": "right_shift",
- "modifiers": {
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "right_shift"}],
- "to_if_alone": [{"key_code": "return_or_enter"}]
- }]
- },
- {
- "description": "Right-Command / Backspace Mod-Tap",
- "manipulators": [{
- "type": "basic",
- "from": {
- "key_code": "right_command",
- "modifiers": {
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "right_command"}],
- "to_if_alone": [{"key_code": "delete_or_backspace"}]
- }]
- },
- {
- "description": "Right-Command Accents",
- "manipulators": [
- {
- "type": "basic",
- "from": {
- "key_code": "a",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["left_shift", "right_shift"]
- }
- },
- "to": [
- {"key_code": "grave_accent_and_tilde", "modifiers": ["left_option"]},
- {"key_code": "a"}
- ]
- }]
- },
- {
- "description": "Right Command Navigation",
- "manipulators": [{
- "type": "basic",
- "from": {
- "key_code": "j",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "left_arrow"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "k",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "down_arrow"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "i",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "up_arrow"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "l",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "right_arrow"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "e",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "page_up"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "d",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "page_down"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "s",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "home"}]
- },
- {
- "type": "basic",
- "from": {
- "key_code": "f",
- "modifiers": {
- "mandatory": ["right_command"],
- "optional": ["any"]
- }
- },
- "to": [{"key_code": "end"}]
- }]
- }]
-}
diff --git a/layouts/community/ortho_5x12/rs/keymap.c b/layouts/community/ortho_5x12/rs/keymap.c
index e4e590669f..15cbabaac1 100644
--- a/layouts/community/ortho_5x12/rs/keymap.c
+++ b/layouts/community/ortho_5x12/rs/keymap.c
@@ -1,19 +1,5 @@
#include QMK_KEYBOARD_H
-
-enum layers {
- _QWERTY,
- _HYPER,
-};
-
-#define KC_ KC_TRNS
-
-#define KC_ESCC MT(MOD_LCTL, KC_ESC)
-#define KC_RST RESET
-#define KC_BSPH LT(_HYPER, KC_BSPC)
-#define KC_ENTS MT(MOD_LSFT, KC_ENT)
-// Brightness
-#define KC_BRUP KC_PAUS
-#define KC_BRDN KC_SLCK
+#include "rs.h"
// Used to create a keymap using only KC_ prefixed keys
#ifndef LAYOUT_kc
@@ -34,7 +20,6 @@ enum layers {
#endif
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-
[_QWERTY] = LAYOUT_kc( \
// ,-----------------------------------------------------------------------------------.
GRV , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 0 , MINS ,
@@ -45,21 +30,34 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// |------+------+------+------+------+------+------+------+------+------+------+------|
LSFT , Z , X , C , V , B , N , M , COMM , DOT , SLSH , ENTS ,
// |------+------+------+------+------+------+------+------+------+------+------+------|
- , LCTL , LALT , LGUI , SPC , SPC , BSPC , BSPH , LEFT , DOWN , UP , RGHT
+ , , LCTL , LALT , LGUI , SPC , SPC , BCOD , FN , , LEFT , RGHT
// `---------------------------------------------------+-------------------------------'
- ), // |
- // |
- [_HYPER] = LAYOUT_kc( /* V */ \
+ ),
+ [_CODE] = LAYOUT_kc(
+ // ,-----------------------------------------------------------------------------------.
+ , , , , , , , , , , , ,
+ // |------+------+------+------+------+------+------+------+------+------+------+------|
+ GRV , EXLM , AT , HASH , DLR , PERC , CIRC , LPLT , ASTR , RPGT , NEQL , ,
+ // |------+------+------+------+------+------+------+------+------+------+------+------|
+ , 1 , 2 , 3 , 4 , 5 , MINS , LBRC , UP , RBRC , , BSLS ,
+ // |------+------+------+------+------+------+------+------+------+------+------+------|
+ , 6 , 7 , 8 , 9 , 0 , AMPR , LEFT , DOWN , RGHT , , PIPE ,
+ // |------+------+------+------+------+------+------+------+------+------+------+------|
+ , , , , , DOT , , , , , ,
+ // `-----------------------------------------------------------------------------------'
+ ),
+ [_FN] = LAYOUT_kc(
// ,-----------------------------------------------------------------------------------.
- RST , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , LBRC , RBRC , ,
+ , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 , F10 , F11 ,
// |------+------+------+------+------+------+------+------+------+------+------+------|
- , , , PGUP , , , , , UP , LCBR , RCBR , BSLS ,
+ , , , , , , , , , , , ,
// |------+------+------+------+------+------+------+------+------+------+------+------|
- , , HOME , PGDN , END , , MINS , LEFT , DOWN , RGHT , , PIPE ,
+ BLTG , BLUP , , , , BRMU , VOLU , , PGUP , , , ,
// |------+------+------+------+------+------+------+------+------+------+------+------|
- , , , , , , , , , BRDN , BRUP , ,
+ BLTG , BLDN , , , RST , BRMD , VOLD , CTRA , PGDN , CTRE , , ,
// |------+------+------+------+------+------+------+------+------+------+------+------|
- , , , , , , , , MUTE , VOLD , VOLU , MPLY
+ , , , , , , MUTE , , , , ,
// `-----------------------------------------------------------------------------------'
),
};
+
diff --git a/layouts/community/ortho_5x12/rs/readme.md b/layouts/community/ortho_5x12/rs/readme.md
index d75eefd5b9..d23ab66877 100644
--- a/layouts/community/ortho_5x12/rs/readme.md
+++ b/layouts/community/ortho_5x12/rs/readme.md
@@ -1,17 +1 @@
-# Code friendly 60% keymap
-
-I developped this keymap to make a better use of 60% ortho keyboards I use like the preonic of the iris. Instead of trying to mimic the Planck layout like the default preonic keymap, this keymap removes the raise and lower layers and offers a simpler hyper layer concept for a few missing sign keys and cursors / media keys.
-
-The important part for coders is that most important signs needed to code are available at their usual position on a full keyboard, without complex layer gymnastic. Access to [] and {} are available on the hyper layer at their usual emplacement.
-
-The right thumb is used for both backspace and hyper layer switching. On the hyper layer, in addition to some coding signs, you get the cursor keys arranged in cross, just under your right fingers, so you don't have to move your hand when navigating in code or command line. Other hand gets the home/end page up/down in a similar layout.
-
-Because you sometime have to use your internal keyboard when you use a macbook, a karabiner configuration is also provided to get most of the features of this keyboard, including the hyper layer / backspace on right command key etc.
-
-This keymap has been tested with those keyboards:
-- [Preonic](../../../../keyboards/preonic/)
-- [My preonic clone](../../../rs60/)
-
-Checkout an adaptation of this keymap for other keyboards:
-- [Iris/rs](../../../../keyboards/iris/keymaps/rs/keymap.c)
-- [ErgoTravel/rs](../../../../keyboards/ergotravel/keymaps/rs/keymap.c) \ No newline at end of file
+See [rs readme](../../../../users/rs/readme.md). \ No newline at end of file