From 66be9318b51e3c27ed6a097b54ca8bd147002ef8 Mon Sep 17 00:00:00 2001 From: JoanVC Date: Tue, 11 Nov 2025 15:04:42 +0000 Subject: [PATCH] unoq: fix: reversed A4 and A5 ADC channels and clarify pin assignments Correct the io-channels ordering so that A4 maps to PC1 (ADC1 Channel 2) and A5 maps to PC0 (ADC1 Channel 1). The corresponding channels can be found in the STM datasheet on page 111. Also, add some comments to clarify which pins are being used. --- .../arduino_uno_q_stm32u585xx.overlay | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.overlay b/variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.overlay index f8d59cd9..bc296fea 100644 --- a/variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.overlay +++ b/variants/arduino_uno_q_stm32u585xx/arduino_uno_q_stm32u585xx.overlay @@ -313,12 +313,12 @@ control-gpios = <&gpiog 13 GPIO_ACTIVE_HIGH>; /* Internal SPI RDY */ analog-switch-gpios = <&gpioa 2 GPIO_ACTIVE_HIGH>; /* Analog switch for VREF */ - io-channels = <&adc1 9>, - <&adc1 10>, - <&adc1 11>, - <&adc1 12>, - <&adc1 1>, - <&adc1 2>; + io-channels = <&adc1 9>, /* A0 - PA4 */ + <&adc1 10>, /* A1 - PA5 */ + <&adc1 11>, /* A2 - PA6 */ + <&adc1 12>, /* A3 - PA7 */ + <&adc1 2>, /* A4 - PC1 */ + <&adc1 1>; /* A5 - PC0 */ dac = <&dac1>; dac-channels = <1>, <2>;