diff options
author | haierwangwei2005 <69899561+haierwangwei2005@users.noreply.github.com> | 2020-12-07 01:37:32 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-06 09:37:32 -0800 |
commit | f1b082320eb5cb5430ce4bcb536a56d9227e2e8a (patch) | |
tree | ca08af3c7d78ddace9df96b2fd71735462bd2266 | |
parent | 8d6ad23b096ed2fc4d8fd0e6781fca30b87b343f (diff) |
[Keyboard] Latin47ble bluetooth keyboard (#11023)
* Create rules.mk
* Create glcdfonr.c
* Create keymap.c
* Create keymap.c
* Create rules.mk
* Add files via upload
* Update readme.md
* Update readme.md
* Update readme.md
* Update config.h
* Update 10bleoledhub.h
* Update 10bleoledhub.c
* Update info.json
* Update keymap.c
* Update keymap.c
* Rename glcdfonr.c to glcdfont.c
* Update config.h
* Update config.h
* Update config.h
* Update rules.mk
* Update 10bleoledhub.c
* Update 10bleoledhub.h
* Update info.json
* Update config.h
* Update rules.mk
* Update keymap.c
* Update keymap.c
* Update glcdfont.c
* Update keyboards/10bleoledhub/rules.mk
* Update keyboards/10bleoledhub/keymaps/via/keymap.c
* Update keyboards/10bleoledhub/keymaps/default/keymap.c
* Update keyboards/10bleoledhub/config.h
* Update keyboards/10bleoledhub/config.h
* Update keyboards/10bleoledhub/10bleoledhub.h
* Create readme.md
* Create rules.mk
* Create latin47ble.h
* Create latin47ble.c
* Create info.json
* Create config.h
* Create keymap.c
* Create rules.mk
* Create keymap.c
* Update keymap.c
* Update keyboards/latin47ble/keymaps/default/keymap.c
* Update keymap.c
* Update keyboards/latin47ble/keymaps/via/keymap.c
* Update keyboards/latin47ble/rules.mk
* Update keyboards/latin47ble/rules.mk
* Update keyboards/latin47ble/rules.mk
* Update latin47ble.h
* Update latin47ble.c
* Update latin47ble.h
* Update latin47ble.c
* Update keymap.c
* Update keymap.c
* Update config.h
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/keymaps/via/keymap.c
* Update keyboards/latin47ble/rules.mk
* Delete info.json
* Update readme.md
* Update keymap.c
* Update keymap.c
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/config.h
* Update keyboards/latin47ble/keymaps/default/keymap.c
* Update keyboards/latin47ble/latin47ble.c
* Update keyboards/latin47ble/latin47ble.h
* Update keyboards/latin47ble/keymaps/via/keymap.c
* Update keymap.c
* Update keymap.c
* Update latin47ble.h
* Update keymap.c
* Update keymap.c
* Update keymap.c
* Update keymap.c
* Update keyboards/latin47ble/keymaps/default/keymap.c
* Update keyboards/latin47ble/keymaps/default/keymap.c
* Update keyboards/latin47ble/latin47ble.h
* Update keyboards/latin47ble/keymaps/default/keymap.c
* Update keyboards/latin47ble/keymaps/via/keymap.c
* Update keyboards/latin47ble/rules.mk
-rw-r--r-- | keyboards/latin47ble/config.h | 123 | ||||
-rw-r--r-- | keyboards/latin47ble/keymaps/default/keymap.c | 47 | ||||
-rw-r--r-- | keyboards/latin47ble/keymaps/via/keymap.c | 54 | ||||
-rw-r--r-- | keyboards/latin47ble/keymaps/via/rules.mk | 2 | ||||
-rw-r--r-- | keyboards/latin47ble/latin47ble.c | 16 | ||||
-rw-r--r-- | keyboards/latin47ble/latin47ble.h | 30 | ||||
-rw-r--r-- | keyboards/latin47ble/readme.md | 14 | ||||
-rw-r--r-- | keyboards/latin47ble/rules.mk | 28 |
8 files changed, 314 insertions, 0 deletions
diff --git a/keyboards/latin47ble/config.h b/keyboards/latin47ble/config.h new file mode 100644 index 0000000000..716ab52f5d --- /dev/null +++ b/keyboards/latin47ble/config.h @@ -0,0 +1,123 @@ + /* Copyright 2020 haierwangwei2005 + * + * 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 0x6C63 // "lc" = latincompass +#define PRODUCT_ID 0x6C62 // "lb" = latin47BLE +#define DEVICE_VER 0x0001 +#define MANUFACTURER latincompass +#define PRODUCT Latin47BLE + +/* key matrix size */ +#define MATRIX_ROWS 4 +#define MATRIX_COLS 12 + +/* + * 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 { D0, D1, D2, D3 } +#define MATRIX_COL_PINS { D6, D7, B5, B6 ,C6, C7, F7, F6, F5, F4, F1, F0 } +#define UNUSED_PINS + +/* COL2ROW or ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +#define RGB_DI_PIN B7 +#ifdef RGB_DI_PIN + #define RGBLED_NUM 3 + #define RGBLIGHT_HUE_STEP 8 + #define RGBLIGHT_SAT_STEP 8 + #define RGBLIGHT_VAL_STEP 8 +// #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */ +// #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */ +// /*== all animations enable ==*/ + #define RGBLIGHT_ANIMATIONS +// /*== or choose animations ==*/ +// #define RGBLIGHT_EFFECT_BREATHING +// #define RGBLIGHT_EFFECT_RAINBOW_MOOD +// #define RGBLIGHT_EFFECT_RAINBOW_SWIRL +// #define RGBLIGHT_EFFECT_SNAKE +// #define RGBLIGHT_EFFECT_KNIGHT +// #define RGBLIGHT_EFFECT_CHRISTMAS +// #define RGBLIGHT_EFFECT_STATIC_GRADIENT +// #define RGBLIGHT_EFFECT_RGB_TEST +// #define RGBLIGHT_EFFECT_ALTERNATING +#endif + +#define TAPPING_TERM 250 + +/* 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 diff --git a/keyboards/latin47ble/keymaps/default/keymap.c b/keyboards/latin47ble/keymaps/default/keymap.c new file mode 100644 index 0000000000..3827c61fd7 --- /dev/null +++ b/keyboards/latin47ble/keymaps/default/keymap.c @@ -0,0 +1,47 @@ + /* Copyright 2020 haierwangwei2005 + * + * 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/>. + */ +#include QMK_KEYBOARD_H + +enum layers { + _QWERTY, + _FN1, + _FN2, +}; +#define KC_X0 LT(_FN2, KC_GRV) +#define KC_X1 MO(_FN1) +#define KC_X2 MO(_FN2) + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT_planck_mit( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_X2, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, KC_1, KC_2, KC_3, KC_4 + ), + [_FN1] = LAYOUT_planck_mit( + OUT_AUTO, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_EQL, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RGB_TOG, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, RGB_TOG, RGB_MOD, KC_MYCM, KC_CALC + ), + [_FN2] = LAYOUT_planck_mit( + KC_NLCK, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_BSPC, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RGB_TOG, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, RGB_TOG, RGB_MOD, KC_MYCM, KC_CALC + ), +}; diff --git a/keyboards/latin47ble/keymaps/via/keymap.c b/keyboards/latin47ble/keymaps/via/keymap.c new file mode 100644 index 0000000000..6dd3a7231c --- /dev/null +++ b/keyboards/latin47ble/keymaps/via/keymap.c @@ -0,0 +1,54 @@ + /* Copyright 2020 haierwangwei2005 + * + * 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/>. + */ +#include QMK_KEYBOARD_H + +enum layers { + _QWERTY, + _FN1, + _FN2, +}; + +#define KC_X0 LT(_FN2, KC_CAPS) +#define KC_X1 MO(_FN1) +#define KC_X2 MO(_FN2) + + + const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [_QWERTY] = LAYOUT_planck_mit( + KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_X2, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, KC_1, KC_2, KC_3, KC_4 + ), + [_FN1] = LAYOUT_planck_mit( + OUT_AUTO, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_EQL, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RGB_TOG, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, RGB_TOG, RGB_MOD, KC_MYCM, KC_CALC + ), + [_FN2] = LAYOUT_planck_mit( + KC_NLCK, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_BSPC, + KC_X0, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RGB_TOG, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_PGUP, KC_PGDN, KC_SPC, KC_X1, RGB_TOG, RGB_MOD, KC_MYCM, KC_CALC + ), + [3] = LAYOUT_planck_mit( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), +}; diff --git a/keyboards/latin47ble/keymaps/via/rules.mk b/keyboards/latin47ble/keymaps/via/rules.mk new file mode 100644 index 0000000000..36b7ba9cbc --- /dev/null +++ b/keyboards/latin47ble/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/latin47ble/latin47ble.c b/keyboards/latin47ble/latin47ble.c new file mode 100644 index 0000000000..c207b42297 --- /dev/null +++ b/keyboards/latin47ble/latin47ble.c @@ -0,0 +1,16 @@ + /* Copyright 2020 haierwangwei2005 + * + * 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/>. + */ +#include "latin47ble.h" diff --git a/keyboards/latin47ble/latin47ble.h b/keyboards/latin47ble/latin47ble.h new file mode 100644 index 0000000000..87ecaad658 --- /dev/null +++ b/keyboards/latin47ble/latin47ble.h @@ -0,0 +1,30 @@ + /* Copyright 2020 haierwangwei2005 + * + * 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 "quantum.h" + +#define LAYOUT_planck_mit( \ + K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K10, K11, \ + K12, K13, K14, K15, K16, K17, K18, K19, K20, K21, K22, K23, \ + K24, K25, K26, K27, K28, K29, K30, K31, K32, K33, K34, K35, \ + K36, K37, K38, K39, K40, K41, K42, K43, K44, K45, K46 \ +) { \ + { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K10, K11}, \ + { K12, K13, K14, K15, K16, K17, K18, K19, K20, K21, K22, K23}, \ + { K24, K25, K26, K27, K28, K29, K30, K31, K32, K33, K34, K35}, \ + { K36, K37, K38, K39, K40, K41, K42, K43, K44, K45, K46 } \ +} diff --git a/keyboards/latin47ble/readme.md b/keyboards/latin47ble/readme.md new file mode 100644 index 0000000000..cc8e9e6a34 --- /dev/null +++ b/keyboards/latin47ble/readme.md @@ -0,0 +1,14 @@ +# Latin47ble + +![Latin47ble](https://github.com/latincompass/latin64BLE-kb) + +macro 47 ble 4.0 RGB keyboard + +* Keyboard Maintainer: [latincompass](https://github.com/latincompass) +* Hardware Availability: https://github.com/haierwangwei2005/latin47blekeyboard-/blob/main/1%20(2).png + +Make example for this keyboard (after setting up your build environment): + + make latin47ble: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/latin47ble/rules.mk b/keyboards/latin47ble/rules.mk new file mode 100644 index 0000000000..c9cdfc9121 --- /dev/null +++ b/keyboards/latin47ble/rules.mk @@ -0,0 +1,28 @@ +# MCU name +MCU = atmega32u4 + +# Processor frequency +F_CPU = 8000000 + +# Bootloader selection +BOOTLOADER = caterina + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = no # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output +BLUETOOTH = AdafruitBLE + +LAYOUTS = planck_mit |