summaryrefslogtreecommitdiffstats
path: root/keyboards/ploopyco/trackball_mini
diff options
context:
space:
mode:
authorlokher <lokher@gmail.com>2022-09-13 11:13:00 +0800
committerlokher <lokher@gmail.com>2022-09-13 11:13:00 +0800
commitfe13cedf8c09fa34d5cec4e4c624738095176625 (patch)
tree818436626d49c7f22f325632b2053edba10d4358 /keyboards/ploopyco/trackball_mini
parentfa207545a9759c50b9f230eb608d86a9085801d4 (diff)
parentf46379f308783994b8178f95adc686f4b4c3ebd8 (diff)
merge upstream master
Diffstat (limited to 'keyboards/ploopyco/trackball_mini')
-rw-r--r--keyboards/ploopyco/trackball_mini/config.h6
-rw-r--r--keyboards/ploopyco/trackball_mini/info.json9
-rw-r--r--keyboards/ploopyco/trackball_mini/rev1_001/config.h2
-rw-r--r--keyboards/ploopyco/trackball_mini/rev1_002/config.h2
-rw-r--r--keyboards/ploopyco/trackball_mini/trackball_mini.c8
5 files changed, 13 insertions, 14 deletions
diff --git a/keyboards/ploopyco/trackball_mini/config.h b/keyboards/ploopyco/trackball_mini/config.h
index 9c53f1f501..bf7570f364 100644
--- a/keyboards/ploopyco/trackball_mini/config.h
+++ b/keyboards/ploopyco/trackball_mini/config.h
@@ -21,12 +21,6 @@
#include "config_common.h"
-/* USB Device descriptor parameter */
-#define VENDOR_ID 0x5043
-#define PRODUCT_ID 0x1EAB
-#define DEVICE_VER 0x0001
-#define PRODUCT Trackball Mini
-
/* key matrix size */
#define MATRIX_ROWS 1
#define MATRIX_COLS 5
diff --git a/keyboards/ploopyco/trackball_mini/info.json b/keyboards/ploopyco/trackball_mini/info.json
index 67d62cc2b9..f465a7a21e 100644
--- a/keyboards/ploopyco/trackball_mini/info.json
+++ b/keyboards/ploopyco/trackball_mini/info.json
@@ -1,8 +1,13 @@
{
- "keyboard_name": "Ploopy Trackball Mini",
+ "keyboard_name": "Trackball Mini",
+ "manufacturer": "PloopyCo",
"url": "www.ploopy.co",
"maintainer": "ploopyco",
- "manufacturer": "Ploopy Corporation",
+ "usb": {
+ "vid": "0x5043",
+ "pid": "0x1EAB",
+ "device_version": "0.0.1"
+ },
"layouts": {
"LAYOUT": {
"layout": [
diff --git a/keyboards/ploopyco/trackball_mini/rev1_001/config.h b/keyboards/ploopyco/trackball_mini/rev1_001/config.h
index 06720b8fdf..d4c9d23bec 100644
--- a/keyboards/ploopyco/trackball_mini/rev1_001/config.h
+++ b/keyboards/ploopyco/trackball_mini/rev1_001/config.h
@@ -36,5 +36,5 @@
// These pins are not broken out, and cannot be used normally.
// They are set as output and pulled high, by default
-#define UNUSED_PINS \
+#define UNUSABLE_PINS \
{ B5, C7, D0, D1, D3, D5, D6, F1, F3, F5, F6, F7 }
diff --git a/keyboards/ploopyco/trackball_mini/rev1_002/config.h b/keyboards/ploopyco/trackball_mini/rev1_002/config.h
index 06720b8fdf..d4c9d23bec 100644
--- a/keyboards/ploopyco/trackball_mini/rev1_002/config.h
+++ b/keyboards/ploopyco/trackball_mini/rev1_002/config.h
@@ -36,5 +36,5 @@
// These pins are not broken out, and cannot be used normally.
// They are set as output and pulled high, by default
-#define UNUSED_PINS \
+#define UNUSABLE_PINS \
{ B5, C7, D0, D1, D3, D5, D6, F1, F3, F5, F6, F7 }
diff --git a/keyboards/ploopyco/trackball_mini/trackball_mini.c b/keyboards/ploopyco/trackball_mini/trackball_mini.c
index e4b4a47c2b..df13912af4 100644
--- a/keyboards/ploopyco/trackball_mini/trackball_mini.c
+++ b/keyboards/ploopyco/trackball_mini/trackball_mini.c
@@ -111,10 +111,10 @@ void process_wheel(void) {
if (debug_encoder) dprintf("OPT1: %d, OPT2: %d\n", p1, p2);
- uint8_t dir = opt_encoder_handler(p1, p2);
+ int8_t dir = opt_encoder_handler(p1, p2);
if (dir == 0) return;
- encoder_update_kb(0, dir == 1);
+ encoder_update_kb(0, dir > 0);
}
void pointing_device_init_kb(void) {
@@ -200,8 +200,8 @@ void keyboard_pre_init_kb(void) {
* pathways to ground. If you're messing with this, know this: driving ANY
* of these pins high will cause a short. On the MCU. Ka-blooey.
*/
-#ifdef UNUSED_PINS
- const pin_t unused_pins[] = UNUSED_PINS;
+#ifdef UNUSABLE_PINS
+ const pin_t unused_pins[] = UNUSABLE_PINS;
for (uint8_t i = 0; i < (sizeof(unused_pins) / sizeof(pin_t)); i++) {
setPinOutput(unused_pins[i]);