Browse Source

[stm32][RTduino] limit pin max number check

Meco Man 1 year ago
parent
commit
a87b399848

+ 2 - 0
bsp/stm32/stm32f401-st-nucleo/applications/arduino_pinout/pins_arduino.h

@@ -38,6 +38,8 @@
 #define A6        (23)
 #define A7        (24)
 
+#define RTDUINO_PIN_MAX_LIMIT A7 /* pin number max limit check */
+
 #define F_CPU          84000000L  /* CPU:84MHz */
 
 #define LED_BUILTIN     D13  /* Default Built-in LED */

+ 2 - 0
bsp/stm32/stm32f411-st-nucleo/applications/arduino_pinout/pins_arduino.h

@@ -38,6 +38,8 @@
 #define A6        (23)
 #define A7        (24)
 
+#define RTDUINO_PIN_MAX_LIMIT A7 /* pin number max limit check */
+
 #define F_CPU          84000000L  /* CPU:84MHz */
 
 #define LED_BUILTIN     D13  /* Default Built-in LED */

+ 2 - 0
bsp/stm32/stm32l475-atk-pandora/applications/arduino_pinout/pins_arduino.h

@@ -59,6 +59,8 @@
 #define A3        (43)
 #define DAC0      (44)
 
+#define RTDUINO_PIN_MAX_LIMIT DAC0 /* pin number max limit check */
+
 #define F_CPU          80000000L  /* CPU:80MHz */
 
 #define LED_BUILTIN     D22  /* Default Built-in LED */

+ 2 - 0
bsp/stm32/stm32l476-st-nucleo/applications/arduino_pinout/pins_arduino.h

@@ -38,6 +38,8 @@
 #define A6        (23)
 #define A7        (24)
 
+#define RTDUINO_PIN_MAX_LIMIT A7 /* pin number max limit check */
+
 #define F_CPU          80000000L  /* CPU:80MHz */
 
 /* i2c1 : PB9-SDA PB8-SCL */