diff --git a/keyboards/blockey_ble/blockey_ble.c b/keyboards/blockey_ble/blockey_ble.c new file mode 100644 index 000000000000..d75ee79e93fd --- /dev/null +++ b/keyboards/blockey_ble/blockey_ble.c @@ -0,0 +1,17 @@ +/* + * blockey_ble.c + * + * Created on: 2019/02/18 + * Author: Gachiham + */ + + + +#include "matrix.h" +#include "quantum.h" +#include "nrf.h" +#include "app_ble_func.h" + +void matrix_init_user() { + set_usb_enabled(true); +} diff --git a/keyboards/blockey_ble/blockey_ble.h b/keyboards/blockey_ble/blockey_ble.h new file mode 100644 index 000000000000..84e59f0cf407 --- /dev/null +++ b/keyboards/blockey_ble/blockey_ble.h @@ -0,0 +1,30 @@ +#ifndef BLOCKEY_BLE_H_ +#define BLOCKEY_BLE_H_ + +#include "quantum.h" + +// This a shortcut to help you visually see your layout. +// The following is an example using the Planck MIT layout +// The first section contains all of the arguments +// The second converts the arguments into a two-dimensional array +#define LAYOUT( \ + 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, k47, k48, k49, k50, k51, k52, k53, k54, \ + k55, k56, k57, k58, k59, k60, k61, k62 \ +) \ +{ \ + { k01, k02, k03, k04, k05, k06, k07 }, \ + { k15, k16, k17, k18, k19, k20, k21 }, \ + { k29, k30, k31, k32, k33, k34, k35 }, \ + { k42, k43, k44, k45, k46, k47, k48 }, \ + { k55, k56, k57, k58, KC_NO, KC_NO, k59 }, \ + { k08, k09, k10, k11, k12, k13, k14 }, \ + { k22, k23, k24, k25, k26, k27, k28 }, \ + { k36, k37, k38, k39, k40, k41, KC_NO }, \ + { k49, k50, k51, k52, k53, k54, KC_NO }, \ + { KC_NO, KC_NO, KC_NO, k60, k61, k62, KC_NO}, \ +} + +#endif /* BLOCKEY_BLE_H_ */ diff --git a/keyboards/blockey_ble/board/custom_board.h b/keyboards/blockey_ble/board/custom_board.h new file mode 100644 index 000000000000..c9df36d8f8e1 --- /dev/null +++ b/keyboards/blockey_ble/board/custom_board.h @@ -0,0 +1,90 @@ +/** + * Copyright (c) 2014 - 2017, Nordic Semiconductor ASA + * Copyright (c) 2018, Sekigon + * Copyright (c) 2019, Gachiham + * + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, + * are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form, except as embedded into a Nordic + * Semiconductor ASA integrated circuit in a product or a software update for + * such product, must reproduce the above copyright notice, this list of + * conditions and the following disclaimer in the documentation and/or other + * materials provided with the distribution. + * + * 3. Neither the name of Nordic Semiconductor ASA nor the names of its + * contributors may be used to endorse or promote products derived from this + * software without specific prior written permission. + * + * 4. This software, with or without modification, must only be used with a + * Nordic Semiconductor ASA integrated circuit. + * + * 5. Any software provided in binary form under this license must not be reverse + * engineered, decompiled, modified and/or disassembled. + * + * THIS SOFTWARE IS PROVIDED BY NORDIC SEMICONDUCTOR ASA "AS IS" AND ANY EXPRESS + * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY, NONINFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL NORDIC SEMICONDUCTOR ASA OR CONTRIBUTORS BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE + * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + */ +#ifndef CUSTOM_BOARD_H +#define CUSTOM_BOARD_H + +#ifdef __cplusplus +extern "C" { +#endif + +//#include "nrf_gpio.h" + +#define GPIO(port, pin) ((port << 5) | pin) +#define PIN1 GPIO(0,8) +#define PIN2 GPIO(0,11) +#define PIN5 GPIO(0,18) +#define PIN6 GPIO(0,16) +#define PIN7 GPIO(0,19) +#define PIN8 GPIO(0,20) +#define PIN9 GPIO(0,22) +#define PIN10 GPIO(0,23) +#define PIN11 GPIO(1,0) +#define PIN12 GPIO(1,3) + +#define PIN13 GPIO(0,9) +#define PIN14 GPIO(0,10) +#define PIN15 GPIO(1,15) +#define PIN16 GPIO(1,14) +#define PIN17 GPIO(0,3) +#define PIN18 GPIO(0,30) +#define PIN19 GPIO(0,0) +#define PIN20 GPIO(0,5) +//#define NRF_LOG_ENABLED 0 +//#define NRF_LOG_BACKEND_SERIAL_USES_UART 0 +//#define NRF_LOG_BACKEND_SERIAL_UART_TX_PIN 5 +#define NRF_LOG_BACKEND_UART_TX_PIN 8 +//#define DEBUG +// Low frequency clock source to be used by the SoftDevice +#ifdef S210 +// #define NRF_CLOCK_LFCLKSRC NRF_CLOCK_LFCLKSRC_XTAL_20_PPM +#else +#define NRF_CLOCK_LFCLKSRC {.source = NRF_CLOCK_LF_SRC_RC, \ + .rc_ctiv = 16, \ + .rc_temp_ctiv = 2, \ + .xtal_accuracy = 0} +#endif + +#ifdef __cplusplus +} +#endif + +#endif // CUSTOM_BOARD_H diff --git a/keyboards/blockey_ble/config.h b/keyboards/blockey_ble/config.h new file mode 100644 index 000000000000..9dda4a84c093 --- /dev/null +++ b/keyboards/blockey_ble/config.h @@ -0,0 +1,73 @@ +/* +Copyright 2018 Eucalyn +Copyright 2018 Sekigon +Copyright 2019 Gachiham + +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 . +*/ + +#ifndef CONFIG_H +#define CONFIG_H + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0xFEED +#define PRODUCT_ID 0x0000 +#define DEVICE_VER 0x0001 +/* in python2: list(u"whatever".encode('utf-16-le')) */ +/* at most 32 characters or the ugly hack in usb_main.c borks */ +#define MANUFACTURER Eucalyn +#define PRODUCT Blockey_BLE +#define DESCRIPTION QMK based keyboard + +/* key matrix size */ +#define MATRIX_ROWS 10 +#define MATRIX_COLS 7 + +#define DIODE_DIRECTION COL2ROW + +/* define if matrix has ghost */ +//#define MATRIX_HAS_GHOST + +/* Set 0 if debouncing isn't needed */ +#define DEBOUNCE 1 + +/* 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 + +/* key combination for command */ +#define IS_COMMAND() ( \ + keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \ +) + +/* + * 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 + +#endif diff --git a/keyboards/blockey_ble/keymaps/default/keymap.c b/keyboards/blockey_ble/keymaps/default/keymap.c new file mode 100644 index 000000000000..636867a5386a --- /dev/null +++ b/keyboards/blockey_ble/keymaps/default/keymap.c @@ -0,0 +1,202 @@ +/* Copyright 2018 Eucalyn + * Copyright 2018 Sekigon + * Copyright 2019 Gachiham + * + * 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 . + */ +#include QMK_KEYBOARD_H + +#include "app_ble_func.h" + +#ifdef RGBLIGHT_ENABLE +#include "rgblight.h" + +//Following line allows macro to read current RGB settings +extern rgblight_config_t rgblight_config; +int RGB_current_mode; +#endif + +enum custom_keycodes { + AD_WO_L = SAFE_RANGE, /* Start advertising without whitelist */ + BLE_DIS, /* Disable BLE HID sending */ + BLE_EN, /* Enable BLE HID sending */ + USB_DIS, /* Disable USB HID sending */ + USB_EN, /* Enable USB HID sending */ + DELBNDS, /* Delete all bonding */ + ADV_ID0, /* Start advertising to PeerID 0 */ + ADV_ID1, /* Start advertising to PeerID 1 */ + ADV_ID2, /* Start advertising to PeerID 2 */ + ADV_ID3, /* Start advertising to PeerID 3 */ + ADV_ID4, /* Start advertising to PeerID 4 */ + BATT_LV, /* Display battery level in milli volts */ + DEL_ID0, /* Delete bonding of PeerID 0 */ + DEL_ID1, /* Delete bonding of PeerID 1 */ + DEL_ID2, /* Delete bonding of PeerID 2 */ + DEL_ID3, /* Delete bonding of PeerID 3 */ + DEL_ID4, /* Delete bonding of PeerID 4 */ + ENT_DFU, /* Start bootloader */ + ENT_SLP, /* Deep sleep mode */ + RGBRST, +}; + +extern keymap_config_t keymap_config; + +enum { + BASE=0, + META, + SYMB, + CTRL, + ABS_MOUSE, + GAME +}; + +// Fillers to make layering more clear +#define _______ KC_TRNS +#define XXXXXXX KC_NO + + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,KC_EQL, KC_BSPC, \ + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC,KC_RBRC,KC_BSLS, \ + KC_LCTL,KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT,KC_ENT, \ + KC_LSFT,KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, KC_SLSH,KC_UP, MO(1), \ + KC_ESC, KC_CAPS,KC_LALT,KC_LGUI,KC_SPC, KC_LEFT,KC_DOWN,KC_RGHT \ + ), + [1] = LAYOUT( + _______,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, \ + _______,RGB_TOG,RGB_HUI,RGB_SAI,RGB_VAI,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX, \ + _______,RGB_MOD,RGB_HUD,RGB_SAD,RGB_VAD,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,_______, \ + _______,AD_WO_L, USB_EN, BLE_EN,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,KC_PGUP,_______, \ + _______,_______,_______,_______,_______, KC_HOME,KC_PGDN,KC_END \ + ), + +}; + +const uint16_t PROGMEM fn_actions[] = { + +}; + +bool process_record_user(uint16_t keycode, keyrecord_t *record) { + char str[16]; + + bool result = true; + +#ifdef RGBLIGHT_ENABLE + switch (keycode) { + //led operations - RGB mode change now updates the RGB_current_mode to allow the right RGB mode to be set after reactive keys are released + case RGB_MOD: + if (record->event.pressed) { + rgblight_mode(RGB_current_mode); + rgblight_step(); + RGB_current_mode = rgblight_config.mode; + } + result = false; + break; + case RGBRST: + if (record->event.pressed) { + eeconfig_update_rgblight_default(); + rgblight_enable(); + RGB_current_mode = rgblight_config.mode; + } + result = false; + break; + } +#endif + + if (record->event.pressed) { + switch (keycode) { + case DELBNDS: + delete_bonds(); + result = false; + break; + case AD_WO_L: + restart_advertising_wo_whitelist(); + result = false; + break; + case USB_EN: + set_usb_enabled(true); + result = false; + break; + case USB_DIS: + set_usb_enabled(false); + result = false; + break; + case BLE_EN: + set_ble_enabled(true); + result = false; + break; + case BLE_DIS: + set_ble_enabled(false); + result = false; + break; + case ADV_ID0: + restart_advertising_id(0); + result = false; + break; + case ADV_ID1: + restart_advertising_id(1); + result = false; + break; + case ADV_ID2: + restart_advertising_id(2); + result = false; + break; + case ADV_ID3: + restart_advertising_id(3); + result = false; + break; + case ADV_ID4: + restart_advertising_id(4); + result = false; + break; + case DEL_ID0: + delete_bond_id(0); + result = false; + break; + case DEL_ID1: + delete_bond_id(1); + result = false; + break; + case DEL_ID2: + delete_bond_id(2); + result = false; + break; + case DEL_ID3: + delete_bond_id(3); + result = false; + break; + case BATT_LV: + sprintf(str, "%4dmV", get_vcc()); + send_string(str); + result = false; + break; + case ENT_DFU: + bootloader_jump(); + result = false; + break; + } + } + else if (!record->event.pressed) { + switch (keycode) { + case ENT_SLP: + sleep_mode_enter(); + result = false; + break; + } + } + + return result; +} + diff --git a/keyboards/blockey_ble/ld/nrf52832_master.ld b/keyboards/blockey_ble/ld/nrf52832_master.ld new file mode 100644 index 000000000000..7f249f652826 --- /dev/null +++ b/keyboards/blockey_ble/ld/nrf52832_master.ld @@ -0,0 +1,28 @@ +/* Linker script to configure memory regions. */ + +SEARCH_DIR(.) +GROUP(-lgcc -lc -lnosys) + +MEMORY +{ + FLASH (rx) : ORIGIN = 0x1f000, LENGTH = 0x61000 + RAM (rwx) : ORIGIN = 0x20002798, LENGTH = 0xd868 +} + +SECTIONS +{ + .fs_data : + { + PROVIDE(__start_fs_data = .); + KEEP(*(.fs_data)) + PROVIDE(__stop_fs_data = .); + } > RAM + .pwr_mgmt_data : + { + PROVIDE(__start_pwr_mgmt_data = .); + KEEP(*(.pwr_mgmt_data)) + PROVIDE(__stop_pwr_mgmt_data = .); + } > RAM +} INSERT AFTER .data; + +INCLUDE "nrf5x_common.ld" \ No newline at end of file diff --git a/keyboards/blockey_ble/ld/nrf52832_slave.ld b/keyboards/blockey_ble/ld/nrf52832_slave.ld new file mode 100644 index 000000000000..176ca93d9157 --- /dev/null +++ b/keyboards/blockey_ble/ld/nrf52832_slave.ld @@ -0,0 +1,28 @@ +/* Linker script to configure memory regions. */ + +SEARCH_DIR(.) +GROUP(-lgcc -lc -lnosys) + +MEMORY +{ + FLASH (rx) : ORIGIN = 0x1f000, LENGTH = 0x61000 + RAM (rwx) : ORIGIN = 0x20002128, LENGTH = 0xded8 +} + +SECTIONS +{ + .fs_data : + { + PROVIDE(__start_fs_data = .); + KEEP(*(.fs_data)) + PROVIDE(__stop_fs_data = .); + } > RAM + .pwr_mgmt_data : + { + PROVIDE(__start_pwr_mgmt_data = .); + KEEP(*(.pwr_mgmt_data)) + PROVIDE(__stop_pwr_mgmt_data = .); + } > RAM +} INSERT AFTER .data; + +INCLUDE "nrf5x_common.ld" \ No newline at end of file diff --git a/keyboards/blockey_ble/ld/nrf52840.ld b/keyboards/blockey_ble/ld/nrf52840.ld new file mode 100644 index 000000000000..f778e79be9c3 --- /dev/null +++ b/keyboards/blockey_ble/ld/nrf52840.ld @@ -0,0 +1,117 @@ +/* Linker script to configure memory regions. */ + +SEARCH_DIR(.) +GROUP(-lgcc -lc -lnosys) + +MEMORY +{ + FLASH (rx) : ORIGIN = 0x26000, LENGTH = 0xda000 + RAM (rwx) : ORIGIN = 0x2000BC70, LENGTH = 0x34390 +} + +SECTIONS +{ +} + +SECTIONS +{ + . = ALIGN(4); + .mem_section_dummy_ram : + { + } + .log_dynamic_data : + { + PROVIDE(__start_log_dynamic_data = .); + KEEP(*(SORT(.log_dynamic_data*))) + PROVIDE(__stop_log_dynamic_data = .); + } > RAM + .fs_data : + { + PROVIDE(__start_fs_data = .); + KEEP(*(.fs_data)) + PROVIDE(__stop_fs_data = .); + } > RAM + .cli_sorted_cmd_ptrs : + { + PROVIDE(__start_cli_sorted_cmd_ptrs = .); + KEEP(*(.cli_sorted_cmd_ptrs)) + PROVIDE(__stop_cli_sorted_cmd_ptrs = .); + } > RAM + +} INSERT AFTER .data; + +SECTIONS +{ + .mem_section_dummy_rom : + { + } + .sdh_soc_observers : + { + PROVIDE(__start_sdh_soc_observers = .); + KEEP(*(SORT(.sdh_soc_observers*))) + PROVIDE(__stop_sdh_soc_observers = .); + } > FLASH + .sdh_ble_observers : + { + PROVIDE(__start_sdh_ble_observers = .); + KEEP(*(SORT(.sdh_ble_observers*))) + PROVIDE(__stop_sdh_ble_observers = .); + } > FLASH + .pwr_mgmt_data : + { + PROVIDE(__start_pwr_mgmt_data = .); + KEEP(*(SORT(.pwr_mgmt_data*))) + PROVIDE(__stop_pwr_mgmt_data = .); + } > FLASH + .log_const_data : + { + PROVIDE(__start_log_const_data = .); + KEEP(*(SORT(.log_const_data*))) + PROVIDE(__stop_log_const_data = .); + } > FLASH + .nrf_balloc : + { + PROVIDE(__start_nrf_balloc = .); + KEEP(*(.nrf_balloc)) + PROVIDE(__stop_nrf_balloc = .); + } > FLASH + .sdh_state_observers : + { + PROVIDE(__start_sdh_state_observers = .); + KEEP(*(SORT(.sdh_state_observers*))) + PROVIDE(__stop_sdh_state_observers = .); + } > FLASH + .sdh_stack_observers : + { + PROVIDE(__start_sdh_stack_observers = .); + KEEP(*(SORT(.sdh_stack_observers*))) + PROVIDE(__stop_sdh_stack_observers = .); + } > FLASH + .sdh_req_observers : + { + PROVIDE(__start_sdh_req_observers = .); + KEEP(*(SORT(.sdh_req_observers*))) + PROVIDE(__stop_sdh_req_observers = .); + } > FLASH + .nrf_queue : + { + PROVIDE(__start_nrf_queue = .); + KEEP(*(.nrf_queue)) + PROVIDE(__stop_nrf_queue = .); + } > FLASH + .cli_command : + { + PROVIDE(__start_cli_command = .); + KEEP(*(.cli_command)) + PROVIDE(__stop_cli_command = .); + } > FLASH + .crypto_data : + { + PROVIDE(__start_crypto_data = .); + KEEP(*(SORT(.crypto_data*))) + PROVIDE(__stop_crypto_data = .); + } > FLASH + +} INSERT AFTER .text + +INCLUDE "nrf_common.ld" \ No newline at end of file diff --git a/keyboards/blockey_ble/ld/nrf52840_master.ld b/keyboards/blockey_ble/ld/nrf52840_master.ld new file mode 100644 index 000000000000..7f249f652826 --- /dev/null +++ b/keyboards/blockey_ble/ld/nrf52840_master.ld @@ -0,0 +1,28 @@ +/* Linker script to configure memory regions. */ + +SEARCH_DIR(.) +GROUP(-lgcc -lc -lnosys) + +MEMORY +{ + FLASH (rx) : ORIGIN = 0x1f000, LENGTH = 0x61000 + RAM (rwx) : ORIGIN = 0x20002798, LENGTH = 0xd868 +} + +SECTIONS +{ + .fs_data : + { + PROVIDE(__start_fs_data = .); + KEEP(*(.fs_data)) + PROVIDE(__stop_fs_data = .); + } > RAM + .pwr_mgmt_data : + { + PROVIDE(__start_pwr_mgmt_data = .); + KEEP(*(.pwr_mgmt_data)) + PROVIDE(__stop_pwr_mgmt_data = .); + } > RAM +} INSERT AFTER .data; + +INCLUDE "nrf5x_common.ld" \ No newline at end of file diff --git a/keyboards/blockey_ble/pro_v1/config.h b/keyboards/blockey_ble/pro_v1/config.h new file mode 100644 index 000000000000..415ed3d64468 --- /dev/null +++ b/keyboards/blockey_ble/pro_v1/config.h @@ -0,0 +1,21 @@ +#ifndef MASTER_CONFIG_H_ +#define MASTER_CONFIG_H_ + +#include "custom_board.h" + +#define THIS_DEVICE_ROWS 10 +#define THIS_DEVICE_COLS 7 + +#define MATRIX_ROW_PINS { PIN1, PIN5, PIN7, PIN10, PIN12, PIN2, PIN18, PIN15, PIN14, PIN13 } +#define MATRIX_COL_PINS { PIN6, PIN11, PIN8, PIN9, PIN20, PIN19, PIN17 } +#define IS_LEFT_HAND true + +#define RGB_DI_PIN PIN16 // The pin the LED strip is connected to + +#define RGBLED_NUM 4 // Number of LEDs in your strip +#define RGBLIGHT_HUE_STEP 10 +#define RGBLIGHT_SAT_STEP 17 + +#define RGBLIGHT_ANIMATIONS + +#endif /* MASTER_CONFIG_H_ */ diff --git a/keyboards/blockey_ble/pro_v1/rules.mk b/keyboards/blockey_ble/pro_v1/rules.mk new file mode 100644 index 000000000000..b595dcfadd48 --- /dev/null +++ b/keyboards/blockey_ble/pro_v1/rules.mk @@ -0,0 +1,13 @@ + +RGBLIGHT_ENABLE = no + +# it should exist either in /ld/ +MCU_LDSCRIPT = nrf52840 +MCU_SERIES = NRF52840 +NRFSDK_ROOT := $(NRFSDK15_ROOT) #Path to nRF SDK v15.0.0 + +# project specific files +#SRC = matrix.c + +# NRF_SEPARATE = master +#CFLAGS += -DNRF_XTAL_32MHZ diff --git a/keyboards/blockey_ble/rules.mk b/keyboards/blockey_ble/rules.mk new file mode 100644 index 000000000000..5e86bd6f83c6 --- /dev/null +++ b/keyboards/blockey_ble/rules.mk @@ -0,0 +1,35 @@ + +DEFAULT_FOLDER = blockey_ble/pro_v1 + +NRF_DEBUG = no + +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = yes # Console for debug +COMMAND_ENABLE = yes # Commands for debug and configuration +SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend +NKRO_ENABLE = no # USB Nkey Rollover +CUSTOM_MATRIX = yes # This flag should be on for nrf52 + +## chip/board settings +MCU_FAMILY = NRF52 +# linker script to use +# Cortex version +# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4 +MCU = cortex-m4 +# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7 +ARMV = 7 +# If you want to be able to jump to bootloader from firmware on STM32 MCUs, +# set the correct BOOTLOADER_ADDRESS. Either set it here, or define it in +# ./bootloader_defs.h or in ./boards//bootloader_defs.h (if you have +# a custom board definition that you plan to reuse). +# If you're not setting it here, leave it commented out. +# It is chip dependent, the correct number can be looked up here (page 175): +# http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf +# This also requires a patch to chibios: +# /tmk_core/tool/chibios/ch-bootloader-jump.patch +#STM32_BOOTLOADER_ADDRESS = 0x1FFFC800 + +# Build Options +# comment out to disable the options. +#