From bc070558b1c628bc3cbeff12dd97b769fccba814 Mon Sep 17 00:00:00 2001 From: jflyper Date: Sun, 28 Jan 2018 22:21:41 +0900 Subject: [PATCH] DEBUG pad (PB3) is the only pin capable of half-duplex soft serial --- src/main/target/BLUEJAYF4/target.c | 3 ++- src/main/target/BLUEJAYF4/target.h | 8 ++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/main/target/BLUEJAYF4/target.c b/src/main/target/BLUEJAYF4/target.c index 1efc549785..0e5d71aec8 100644 --- a/src/main/target/BLUEJAYF4/target.c +++ b/src/main/target/BLUEJAYF4/target.c @@ -26,7 +26,8 @@ /* * - Support HEXA-Dshot - * - S5_OUT, S6_OUT and DEBUG can be assigned to any combination of LED, software serial and servos + * - S5_OUT, S6_OUT are N-channels, which are only capable of outputs. (E.g., motors, servos, LED strip, PWM outputs.) + * - Input is only available on DEBUG pad. See comment on SOFTSERIAL1 in target.h for details. */ const timerHardware_t timerHardware[USABLE_TIMER_CHANNEL_COUNT] = { DEF_TIM(TIM3, CH2, PC7, TIM_USE_PPM, 0, 0 ), // PPM IN diff --git a/src/main/target/BLUEJAYF4/target.h b/src/main/target/BLUEJAYF4/target.h index b49458cf8b..d38366a7d2 100644 --- a/src/main/target/BLUEJAYF4/target.h +++ b/src/main/target/BLUEJAYF4/target.h @@ -119,8 +119,12 @@ #define UART4_TX_PIN NONE // PA0 #define USE_SOFTSERIAL1 -#define SOFTSERIAL1_RX_PIN PB0 // PWM5 -#define SOFTSERIAL1_TX_PIN PB1 // PWM6 +// Since PB0 (motor 5) and PB1 (motor 6) are assigned with N-channels, these pin can not handle input. +// Therefore, receiving function of SOFTSERIAL1 can only be assigned to PB3 (DEBUG). +// Default defined here is to use DEBUG for half-duplex serial, suitable for VTX (SmartAudio or Tramp) controls. +// For non-half-duplex requirement (full-duplex or simplex in either direction), assign PB3 to RX and PB0 or PB1 to TX. +#define SOFTSERIAL1_RX_PIN NONE +#define SOFTSERIAL1_TX_PIN PB3 // DEBUG #define USE_SOFTSERIAL2