1
0
Fork 0
forked from forks/qmk_firmware
qmk_firmware/keyboards/handwired/splittest/teensy_2/teensy_2.c
Joel Challis 0da743d80b [Keyboard] Refactor handwired/splittest to support multiple boards (#6373)
* Refactor splittest to support multiple dev boards

* Refactor splittest to support multiple dev boards - revert change to number of RGB led

* Refactor splittest to support multiple dev boards - update docs

* Refactor splittest to support multiple dev boards - correct docs

* Refactor splittest to support multiple dev boards - update teensy master logic
2019-07-20 13:35:30 -07:00

15 lines
408 B
C

#include QMK_KEYBOARD_H
bool is_keyboard_master(void) {
// TODO: replace this override once USB host detection is implemented
// SPLIT_HAND_PIN Combined with MASTER_LEFT or MASTER_RIGHT, gives a crude
// way to force teensy to run as slave/master
setPinInput(SPLIT_HAND_PIN);
#if defined(MASTER_RIGHT)
return !readPin(SPLIT_HAND_PIN);
#else
return readPin(SPLIT_HAND_PIN);
#endif
}