summaryrefslogtreecommitdiff
path: root/keyboards/binepad/bnr1/v2
diff options
context:
space:
mode:
authorVino Rodrigues <366673+vinorodrigues@users.noreply.github.com>2023-02-10 08:01:21 +1100
committerGitHub <noreply@github.com>2023-02-09 13:01:21 -0800
commit989f2476b6053fbb970a1560094b04b88d337891 (patch)
tree2a8a73b13748a2211312ea340dbbb44d80172f7f /keyboards/binepad/bnr1/v2
parent9c6b8fae404f4e31a898b01e47e9d53d9c0c8a45 (diff)
[Keyboard] Add Binepad BNR1 v2 rotary encoder (#19770)
Diffstat (limited to 'keyboards/binepad/bnr1/v2')
-rw-r--r--keyboards/binepad/bnr1/v2/config.h9
-rwxr-xr-xkeyboards/binepad/bnr1/v2/info.json22
-rwxr-xr-xkeyboards/binepad/bnr1/v2/rules.mk7
3 files changed, 38 insertions, 0 deletions
diff --git a/keyboards/binepad/bnr1/v2/config.h b/keyboards/binepad/bnr1/v2/config.h
new file mode 100644
index 0000000000..7fbf1cfab1
--- /dev/null
+++ b/keyboards/binepad/bnr1/v2/config.h
@@ -0,0 +1,9 @@
+// Copyright 2022 BINEPAD (@binepad)
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+#pragma once
+
+#include "config_common.h"
+
+#define WEAR_LEVELING_LOGICAL_SIZE 1024
+#define WEAR_LEVELING_BACKING_SIZE (WEAR_LEVELING_LOGICAL_SIZE * 2)
diff --git a/keyboards/binepad/bnr1/v2/info.json b/keyboards/binepad/bnr1/v2/info.json
new file mode 100755
index 0000000000..03cee81b99
--- /dev/null
+++ b/keyboards/binepad/bnr1/v2/info.json
@@ -0,0 +1,22 @@
+{
+ "bootloader": "stm32duino",
+ "processor": "STM32F103",
+ "diode_direction": "COL2ROW",
+ "usb": {
+ "pid": "0x4241",
+ "device_version": "2.0.0"
+ },
+ "matrix_pins": {
+ "cols": ["A15"],
+ "rows": ["A8"]
+ },
+ "encoder": {
+ "enabled": true,
+ "rotary": [
+ {
+ "pin_a": "B3",
+ "pin_b": "B4"
+ }
+ ]
+ }
+}
diff --git a/keyboards/binepad/bnr1/v2/rules.mk b/keyboards/binepad/bnr1/v2/rules.mk
new file mode 100755
index 0000000000..a9a826d49f
--- /dev/null
+++ b/keyboards/binepad/bnr1/v2/rules.mk
@@ -0,0 +1,7 @@
+# This file only contains EFL/WL settings and enables F103 low-power mode
+
+EEPROM_DRIVER = wear_leveling
+WEAR_LEVELING_DRIVER = embedded_flash
+
+# Enter lower-power sleep mode when on the ChibiOS idle thread
+OPT_DEFS += -DCORTEX_ENABLE_WFI_IDLE=TRUE