Skip to content

Commit

Permalink
AP_HAL_Chibios hwdef script: cleanup h743 ADC pins
Browse files Browse the repository at this point in the history
  • Loading branch information
magicrub committed Mar 23, 2024
1 parent c6fb4b2 commit a0b302c
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions libraries/AP_HAL_ChibiOS/hwdef/scripts/STM32H743xx.py
Original file line number Diff line number Diff line change
Expand Up @@ -1278,6 +1278,8 @@

ADC1_map = {
# format is PIN : ADC1_CHAN
# "PA0_C": 0, # not supported
# "PA1_C": 1, # not supported
"PF11" : 2,
"PA6" : 3,
"PC4" : 4,
Expand All @@ -1299,6 +1301,9 @@
}

ADC2_map = {
# format is PIN : ADC2_CHAN
# "PA0_C": 0, # not supported
# "PA1_C": 1, # not supported
"PF13" : 2,
"PA6" : 3,
"PC4" : 4,
Expand All @@ -1309,17 +1314,20 @@
"PB0" : 9,
"PC0" : 10,
"PC1" : 11,
"PC2" : 12,
"PC3" : 13,
"PC2" : 12,
"PC3" : 13,
"PA2" : 14,
"PA3" : 15,
"N/A" : 16,
"N/A" : 17,
# ADC2_INP16 not implemented on H743
# ADC2_INP17 not implemented on H743
"PA4" : 18,
"PA5" : 19,
}

ADC3_map = {
# format is PIN : ADC3_CHAN
"PC2" : 0, # labeled PC2_C
"PC3" : 1, # labeled PC3_C
"PF9" : 2,
"PF7" : 3,
"PF5" : 4,
Expand All @@ -1328,6 +1336,9 @@
"PF8" : 7,
"PF6" : 8,
"PF4" : 9,
"PC0" : 10,
"PC1" : 11,
# "PC2" : 12, # not supported, using the name "PC2" for PC2_C ADC3_INP0
"PH2" : 13,
"PH3" : 14,
"PH4" : 15,
Expand Down

0 comments on commit a0b302c

Please sign in to comment.