From 9974327d333c3db443a7627b476f02c91a1ace0e Mon Sep 17 00:00:00 2001 From: ellensp <530024+ellensp@users.noreply.github.com> Date: Sun, 11 Feb 2024 03:28:37 +1300 Subject: [PATCH] extend uart checks --- Marlin/src/HAL/STM32/inc/SanityCheck.h | 5 +++-- .../src/pins/stm32f1/pins_BTT_SKR_MINI_E3_V2_0.h | 15 +++++++++++++++ .../src/pins/stm32g0/pins_BTT_SKR_MINI_E3_V3_0.h | 11 +++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/Marlin/src/HAL/STM32/inc/SanityCheck.h b/Marlin/src/HAL/STM32/inc/SanityCheck.h index 8bff51874e..e35b4e59cf 100644 --- a/Marlin/src/HAL/STM32/inc/SanityCheck.h +++ b/Marlin/src/HAL/STM32/inc/SanityCheck.h @@ -58,8 +58,9 @@ * Check for common serial pin conflicts */ #define _CHECK_SERIAL_PIN(N) (( \ - BTN_EN1 == N || DOGLCD_CS == N || HEATER_BED_PIN == N || FAN0_PIN == N || \ - SDIO_D2_PIN == N || SDIO_D3_PIN == N || SDIO_CK_PIN == N || SDIO_CMD_PIN == N \ + BTN_EN1 == N || BTN_EN2 == N ||DOGLCD_CS == N || HEATER_BED_PIN == N || FAN0_PIN == N || \ + SDIO_D2_PIN == N || SDIO_D3_PIN == N || SDIO_CK_PIN == N || SDIO_CMD_PIN == N || \ + Y_STEP_PIN == N || Y_ENABLE_PIN == N || E0_ENABLE_PIN == N || POWER_LOSS_PIN == N \ )) #define CHECK_SERIAL_PIN(T,N) defined(UART##N##_##T##_PIN) && _CHECK_SERIAL_PIN(UART##N##_##T##_PIN) #if SERIAL_IN_USE(1) diff --git a/Marlin/src/pins/stm32f1/pins_BTT_SKR_MINI_E3_V2_0.h b/Marlin/src/pins/stm32f1/pins_BTT_SKR_MINI_E3_V2_0.h index b950d8d1ac..c182f2febe 100644 --- a/Marlin/src/pins/stm32f1/pins_BTT_SKR_MINI_E3_V2_0.h +++ b/Marlin/src/pins/stm32f1/pins_BTT_SKR_MINI_E3_V2_0.h @@ -107,3 +107,18 @@ #define E0_SLAVE_ADDRESS 3 #endif #endif + +// Pins for documentation and sanity checks only. +// Changing these will not change the pin they are on. + +// Hardware UART pins +#define UART1_TX_PIN PA9 // default usage LCD connector +#define UART1_RX_PIN PA10 // default usage LCD connector +#define UART2_TX_PIN PA2 // default usage TFT connector +#define UART2_RX_PIN PA3 // default usage TFT connector +#define UART3_TX_PIN PB10 // default usage Y_STEP_PIN +#define UART3_RX_PIN PB11 // default usage Y_ENABLE_PIN +#define UART4_TX_PIN PC10 // default usage TMC UART +#define UART4_RX_PIN PC11 // default usage TMC UART +#define UART5_TX_PIN PC12 // default usage POWER_LOSS_PIN +#define UART5_RX_PIN PD2 // default usage E0_ENABLE_PIN diff --git a/Marlin/src/pins/stm32g0/pins_BTT_SKR_MINI_E3_V3_0.h b/Marlin/src/pins/stm32g0/pins_BTT_SKR_MINI_E3_V3_0.h index ba1d06f689..df91933d71 100644 --- a/Marlin/src/pins/stm32g0/pins_BTT_SKR_MINI_E3_V3_0.h +++ b/Marlin/src/pins/stm32g0/pins_BTT_SKR_MINI_E3_V3_0.h @@ -461,3 +461,14 @@ #ifndef BOARD_NEOPIXEL_PIN #define BOARD_NEOPIXEL_PIN PA8 // LED driving pin #endif + +// Pins for documentation and sanity checks only. +// Changing these will not change the pin they are on. + +// Hardware UART pins +#define UART1_TX_PIN PA9 // default usage LCD connector +#define UART1_RX_PIN PA10 // default usage LCD connector +#define UART2_TX_PIN PA2 // default usage TFT connector +#define UART2_RX_PIN PA3 // default usage TFT connector +#define UART4_TX_PIN PC10 // default usage TMC UART +#define UART4_RX_PIN PC11 // default usage TMC UART