Browse Source

AP_HAL_ChibiOS: allow undef of SPI devices

apm_2208
Andy Piper 3 years ago committed by Andrew Tridgell
parent
commit
1ff3ee7a12
  1. 3
      libraries/AP_HAL_ChibiOS/hwdef/scripts/chibios_hwdef.py

3
libraries/AP_HAL_ChibiOS/hwdef/scripts/chibios_hwdef.py

@ -2671,6 +2671,9 @@ def process_line(line): @@ -2671,6 +2671,9 @@ def process_line(line):
bylabel.pop(u, '')
alttype.pop(u, '')
altlabel.pop(u, '')
for dev in spidev:
if u == dev[0]:
spidev.remove(dev)
# also remove all occurences of defines in previous lines if any
for line in alllines[:]:
if line.startswith('define') and u == line.split()[1]:

Loading…
Cancel
Save