summaryrefslogtreecommitdiffstats
path: root/keyboards/handwired/splittest/bluepill/post_config.h
diff options
context:
space:
mode:
authordvermd <315743+dvermd@users.noreply.github.com>2022-08-03 10:31:37 +0200
committerGitHub <noreply@github.com>2022-08-03 09:31:37 +0100
commit0206bd9df31521fcfd764c3dd4cff383e4957151 (patch)
tree38873d759919be585d3d3db74daa1cd756322621 /keyboards/handwired/splittest/bluepill/post_config.h
parentb6757d2380d32b5f60f61ffc42d27c40eb219208 (diff)
add bluepill mcu to splittest (#16959)
* add bluepill mcu to splittest * fix typo * refactoring * mcu config goes to mcuconf.h of keyboard * keymap specific config goes to keymap config.h * keyboard specific depending of keymap goes to post_config.h * Apply suggested change Co-authored-by: Ryan <fauxpark@gmail.com> * Apply suggested change Co-authored-by: Ryan <fauxpark@gmail.com> * Apply suggested change Co-authored-by: Ryan <fauxpark@gmail.com> * Apply suggested change Co-authored-by: Ryan <fauxpark@gmail.com> * Apply suggested change Co-authored-by: Ryan <fauxpark@gmail.com> * splittest/bluepill: improve documentation Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'keyboards/handwired/splittest/bluepill/post_config.h')
-rw-r--r--keyboards/handwired/splittest/bluepill/post_config.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/keyboards/handwired/splittest/bluepill/post_config.h b/keyboards/handwired/splittest/bluepill/post_config.h
new file mode 100644
index 0000000000..b866805a64
--- /dev/null
+++ b/keyboards/handwired/splittest/bluepill/post_config.h
@@ -0,0 +1,38 @@
+
+#if defined(SPLIT_BITBANG)
+
+ #define SOFT_SERIAL_PIN B8
+
+#elif defined(SPLIT_SERIAL_HALFDUPLEX)
+
+ #if defined(USE_SDI1_ON_STANDARD_ROLE_PINS)
+ #define SOFT_SERIAL_PIN A9
+ #elif defined(USE_SDI1_ON_ALTERNATE_ROLE_PINS)
+ #define SOFT_SERIAL_PIN B6
+ #define USART1_REMAP // Remap USART TX and RX pins on STM32F103 MCUs
+ #elif defined(USE_SDI2)
+ #define SOFT_SERIAL_PIN A2
+ #define SERIAL_USART_DRIVER SD2 // USART driver of TX and RX pin. default: SD1
+ #else
+ #error "splittest serial_halfduplex keymap is missing a configuration (USE_SDI1_ON_STANDARD_ROLE_PINS, USE_SDI1_ON_ALTERNATE_ROLE_PINS, USE_SDI2)"
+ #endif
+
+#elif defined(SPLIT_SERIAL_FULLDUPLEX)
+
+ #define SERIAL_USART_FULL_DUPLEX // Enable full duplex operation mode.
+
+ #if defined(USE_SDI1_ON_STANDARD_ROLE_PINS)
+ #define SOFT_SERIAL_PIN A9
+ #define SERIAL_USART_RX_PIN A10 // USART RX pin
+ #elif defined(USE_SDI1_ON_ALTERNATE_ROLE_PINS)
+ #define SOFT_SERIAL_PIN B6
+ #define SERIAL_USART_RX_PIN B7 // USART RX pin
+ #define USART1_REMAP // Remap USART TX and RX pins on STM32F103 MCUs
+ #elif defined(USE_SDI2)
+ #define SOFT_SERIAL_PIN A2
+ #define SERIAL_USART_RX_PIN A3 // USART RX pin
+ #define SERIAL_USART_DRIVER SD2 // USART driver of TX and RX pin. default: SD1
+ #else
+ #error "splittest serial_fullduplex keymap is missing a configuration (USE_SDI1_ON_STANDARD_ROLE_PINS, USE_SDI1_ON_ALTERNATE_ROLE_PINS, USE_SDI2)"
+ #endif
+#endif