From b5308b2c28923eeb85acec7ff760cd8f62e4f7f0 Mon Sep 17 00:00:00 2001 From: samyalik <112065346+samyalik@users.noreply.github.com> Date: Mon, 29 Aug 2022 23:56:22 -0400 Subject: [PATCH] Add correct STATUS_LEDS definitions for RADIO_TPRO I just wanted blue LEDs on my Jumper T-Pro. Instead I found a headache. PCBX7 STATUS_LED definitions were being used for RADIO_TPRO, resulting in incorrect GPIO pin assignments for GREEN and BLUE LED colors. LED_GREEN_GPIO_PIN would activate the blue LED, and vice versa for LED_BLUE_GPIO_PIN. To rectify this, a new definition for RADIO_TPRO has been created with proper GPIO pin assignments for LED_GREEN and LED_BLUE --- radio/src/targets/taranis/hal.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/radio/src/targets/taranis/hal.h b/radio/src/targets/taranis/hal.h index 349153696..0e789c30f 100644 --- a/radio/src/targets/taranis/hal.h +++ b/radio/src/targets/taranis/hal.h @@ -1461,6 +1461,16 @@ #define LED_RED_GPIO_PIN GPIO_Pin_13 // PE.13 #define LED_BLUE_GPIO GPIOE #define LED_BLUE_GPIO_PIN GPIO_Pin_2 // PE.02 +#elif defined(RADIO_TPRO) + #define STATUS_LEDS + #define GPIO_LED_GPIO_ON GPIO_SetBits + #define GPIO_LED_GPIO_OFF GPIO_ResetBits + #define LED_GREEN_GPIO GPIOB + #define LED_GREEN_GPIO_PIN GPIO_Pin_1 // PB.01 + #define LED_RED_GPIO GPIOC + #define LED_RED_GPIO_PIN GPIO_Pin_5 // PC.05 + #define LED_BLUE_GPIO GPIOC + #define LED_BLUE_GPIO_PIN GPIO_Pin_4 // PC.04 #elif defined(RADIO_TX12MK2) #define STATUS_LEDS #define GPIO_LED_GPIO_ON GPIO_SetBits