The output-group parser reads timer_config.cpp as text. A board that
guards timer or channel entries with #if defined(CONFIG_...) now gets
those guards evaluated against the board's Kconfig output, passed as
--board-config by the parameter and actuator metadata generators, so
the PWM_MAIN parameters and the actuator metadata match the channels
the firmware actually has.
Co-authored-by: Andre Heinemans <andre.heinemans@nxp.com>
Add the PX4 arch layer for the i.MX9 family: ADC, HRT on LPTMR with
LPIT deadlines, TPM io timers, pin interrupts, LPSPI with chip selects
for all eight instances, critmon on the DWT cycle counter, a tone alarm
on a TPM channel, version reporting with the 128-bit ECID read from the
Fuse Status Block as the UUID, the board reset entry point, plus the
i.MX95 chip include set, the chip mapping in px4_impl_os.cmake and the
PX4_SOC_ARCH_ID_IMX95 id. DShot uses the shared NXP FlexIO driver with
the i.MX9 FlexIO base, offsets, IRQ, clock root and pad hooks.
Not implemented yet: reset of the M7 through the System Manager, LED
PWM and PWM input capture.
i.MX9 timer configs name their timers Timer::TPMn and mark DShot
capable ones with initIOTimerDshot(), so teach
output_groups_from_timer_config.py both forms.
Co-authored-by: Andre Heinemans <andre.heinemans@nxp.com>
The implementation assumed timers are defined in the same order as used
in the channels. This could lead to a mismatch between TIMx param and
actual timer config.
Now we use the actual array index, same as in the code.