summaryrefslogtreecommitdiff
path: root/keyboards/maple_computing/the_ruler
diff options
context:
space:
mode:
authorpeepeetee <43021794+peepeetee@users.noreply.github.com>2022-01-31 03:28:04 +0800
committerGitHub <noreply@github.com>2022-01-30 11:28:04 -0800
commita1b39e6db231923935055846384eb2e78e538268 (patch)
treeeeaee7335efdff3d9ce960050882acf2cfe570a9 /keyboards/maple_computing/the_ruler
parent07bb65384cf96be88feb2916604cb4a89cd0ad33 (diff)
[Keyboard] move That-Canadian 's boards into /maple_computing (#16050)
Diffstat (limited to 'keyboards/maple_computing/the_ruler')
-rw-r--r--keyboards/maple_computing/the_ruler/config.h107
-rw-r--r--keyboards/maple_computing/the_ruler/info.json10
-rw-r--r--keyboards/maple_computing/the_ruler/keymaps/default/keymap.c63
-rw-r--r--keyboards/maple_computing/the_ruler/keymaps/default/readme.md1
-rw-r--r--keyboards/maple_computing/the_ruler/readme.md13
-rw-r--r--keyboards/maple_computing/the_ruler/rules.mk18
-rw-r--r--keyboards/maple_computing/the_ruler/the_ruler.c1
-rw-r--r--keyboards/maple_computing/the_ruler/the_ruler.h8
8 files changed, 221 insertions, 0 deletions
diff --git a/keyboards/maple_computing/the_ruler/config.h b/keyboards/maple_computing/the_ruler/config.h
new file mode 100644
index 0000000000..bcb7441140
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/config.h
@@ -0,0 +1,107 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+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 <http://www.gnu.org/licenses/>.
+*/
+
+#pragma once
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0x1337
+#define PRODUCT_ID 0x6007
+#define DEVICE_VER 0x0001
+#define MANUFACTURER Maple Computing
+#define PRODUCT The PCB Ruler
+
+/* key matrix size */
+#define MATRIX_ROWS 1
+#define MATRIX_COLS 6
+
+/*
+ * 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 { C7 }
+#define MATRIX_COL_PINS { D6, D7, B4, B5, B6, C6}
+#define UNUSED_PINS
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* 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.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#define RGB_DI_PIN E6 // The pin your RGB strip is wired to
+#define RGBLED_NUM 1 // Number of LEDs
+#define RGBLIGHT_ANIMATIONS
+#define RGBLIGHT_HUE_STEP 10
+#define RGBLIGHT_SAT_STEP 17
+#define RGBLIGHT_VAL_STEP 17
diff --git a/keyboards/maple_computing/the_ruler/info.json b/keyboards/maple_computing/the_ruler/info.json
new file mode 100644
index 0000000000..5f2b9fba8f
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/info.json
@@ -0,0 +1,10 @@
+{
+ "keyboard_name": "The Ruler",
+ "url": "",
+ "maintainer": "qmk",
+ "layouts": {
+ "LAYOUT": {
+ "layout": [{"x":0, "y":0}, {"x":1, "y":0}, {"x":2, "y":0}, {"x":3, "y":0}, {"x":4, "y":0}, {"x":5, "y":0, "w":2}]
+ }
+ }
+}
diff --git a/keyboards/maple_computing/the_ruler/keymaps/default/keymap.c b/keyboards/maple_computing/the_ruler/keymaps/default/keymap.c
new file mode 100644
index 0000000000..898881fc3c
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/keymaps/default/keymap.c
@@ -0,0 +1,63 @@
+#include QMK_KEYBOARD_H
+
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _DEFAULT 0
+#define _FN_1 1
+#define _FN_2 2
+
+enum custom_keycodes {
+ DEFAULT = SAFE_RANGE,
+ FN_1,
+ FN_2
+};
+
+// Defines for task manager and such
+#define CALTDEL LCTL(LALT(KC_DEL))
+#define TSKMGR LCTL(LSFT(KC_ESC))
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Default Layer
+ * ,-----------------------------------------------.
+ * | FN_2 | 2 |TSKMGR |CALTDEL| ESC | FN_1 |
+ * `-----------------------------------------------'
+ */
+[_DEFAULT] = LAYOUT(
+ MO(_FN_2), KC_2, TSKMGR, CALTDEL, KC_ESC, MO(_FN_1)
+),
+
+/* FN 1 Layer
+ * ,-----------------------------------------------.
+ * |RGB_TOG|RGB_HUD|RGB_HUI|RGB_SAD|RGB_SAI| FN_1 |
+ * `-----------------------------------------------'
+ */
+[_FN_1] = LAYOUT(
+ RGB_TOG, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, _______
+),
+
+/* FN 2 Layer
+ * ,-----------------------------------------------.
+ * | FN_2 |RGB_VAD|RGB_VAI|RGB_MOD|TSKMGR | RESET |
+ * `-----------------------------------------------'
+ */
+[_FN_2] = LAYOUT(
+ _______, RGB_VAD, RGB_VAI, RGB_MOD, TSKMGR, RESET
+)
+
+};
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ // NONE
+ }
+ return true;
+}
diff --git a/keyboards/maple_computing/the_ruler/keymaps/default/readme.md b/keyboards/maple_computing/the_ruler/keymaps/default/readme.md
new file mode 100644
index 0000000000..b515c1d48e
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/keymaps/default/readme.md
@@ -0,0 +1 @@
+# The default keymap for the ruler \ No newline at end of file
diff --git a/keyboards/maple_computing/the_ruler/readme.md b/keyboards/maple_computing/the_ruler/readme.md
new file mode 100644
index 0000000000..ff958db029
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/readme.md
@@ -0,0 +1,13 @@
+# The Ruler PCB
+
+A custom keyboard PCB ruler, that can also function as a macro pad.
+
+Keyboard Maintainer: Maple Computing
+Hardware Supported: PCB Ruler V1 by That-Canadian and Bishop Keyboards
+Hardware Availability: [Bishop Keyboards](https://bishopkeyboards.com/product/pcb-ruler-gloss-black-silver/)
+
+Make example for this keyboard (after setting up your build environment):
+
+ make maple_computing/the_ruler:default
+
+See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
diff --git a/keyboards/maple_computing/the_ruler/rules.mk b/keyboards/maple_computing/the_ruler/rules.mk
new file mode 100644
index 0000000000..986f0f277a
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/rules.mk
@@ -0,0 +1,18 @@
+# MCU name
+MCU = atmega32u4
+
+# Bootloader selection
+BOOTLOADER = atmel-dfu
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite
+MOUSEKEY_ENABLE = yes # Mouse keys
+EXTRAKEY_ENABLE = yes # Audio control and System control
+CONSOLE_ENABLE = no # Console for debug
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = no # Enable N-Key Rollover
+BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
+AUDIO_ENABLE = no # Audio output
+RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
diff --git a/keyboards/maple_computing/the_ruler/the_ruler.c b/keyboards/maple_computing/the_ruler/the_ruler.c
new file mode 100644
index 0000000000..29a8248924
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/the_ruler.c
@@ -0,0 +1 @@
+#include "the_ruler.h"
diff --git a/keyboards/maple_computing/the_ruler/the_ruler.h b/keyboards/maple_computing/the_ruler/the_ruler.h
new file mode 100644
index 0000000000..171d21a072
--- /dev/null
+++ b/keyboards/maple_computing/the_ruler/the_ruler.h
@@ -0,0 +1,8 @@
+#pragma once
+
+#include "quantum.h"
+
+#define LAYOUT( \
+ K00, K01, K02, K03, K04, K05 ) { \
+ { K00, K01, K02, K03, K04, K05 } \
+}