Skip to content

Use explicit PWM timers first#11444

Closed
sensei-hacker wants to merge 11 commits intoiNavFlight:maintenance-9.xfrom
sensei-hacker:pwm_use_explicit_timers_first
Closed

Use explicit PWM timers first#11444
sensei-hacker wants to merge 11 commits intoiNavFlight:maintenance-9.xfrom
sensei-hacker:pwm_use_explicit_timers_first

Conversation

@sensei-hacker
Copy link
Member

@sensei-hacker sensei-hacker commented Mar 19, 2026

Before, even if the user specifically set MOTOR and SERVO timers (output), it would instead use the AUTO ones, disregarding the user's explicit instructions:

Now, it follows instructions - if the user sets a timer as servos, use that for servos first:

image

Goes with Configurator PR:
iNavFlight/inav-configurator#2596

@github-actions
Copy link

Branch Targeting Suggestion

You've targeted the master branch with this PR. Please consider if a version branch might be more appropriate:

  • maintenance-9.x - If your change is backward-compatible and won't create compatibility issues between INAV firmware and Configurator 9.x versions. This will allow your PR to be included in the next 9.x release.

  • maintenance-10.x - If your change introduces compatibility requirements between firmware and configurator that would break 9.x compatibility. This is for PRs which will be included in INAV 10.x

If master is the correct target for this change, no action is needed.


This is an automated suggestion to help route contributions to the appropriate branch.

@sensei-hacker sensei-hacker changed the base branch from master to maintenance-9.x March 19, 2026 20:28
@sensei-hacker sensei-hacker force-pushed the pwm_use_explicit_timers_first branch 10 times, most recently from 77cb935 to dda0932 Compare March 19, 2026 20:36
sensei-hacker and others added 11 commits March 19, 2026 15:36
Create per-pin AF lookup tables (bus_spi_stm32h7xx.h and
bus_spi_stm32f7xx.h) and use them in bus_spi_hal_ll.c to
automatically resolve the correct GPIO AF for each SPI pin.

Previously, SPI3 on STM32H743 applied AF6 to all pins. On H743,
AF6 on PB5 is SPI3_MISO - the MOSI function requires AF7. Targets
routing SPI3_MOSI to PB5 (e.g. HAKRCH743 MAX7456 OSD) received no
MOSI signal. Targets may still define SPI*_SCK/MISO/MOSI_AF in
target.h to override the table.
Both bus_spi_stm32h7xx.h and bus_spi_stm32f7xx.h use CONCAT4 but relied
on transitive includes from the including translation unit to provide it.
Add an explicit include to make the dependency self-contained.
Co-authored-by: qodo-code-review[bot] <151058649+qodo-code-review[bot]@users.noreply.github.com>
Deprecate the following MSP commands with replacement info:
- MSP_ANALOG (110) -> MSP2_INAV_ANALOG
- MSP_MISC (114) / MSP_SET_MISC (207) -> MSP2_INAV_MISC / MSP2_INAV_SET_MISC
- MSP_PIDNAMES (117) -> no replacement needed
- MSP_FILTER_CONFIG (92) / MSP_SET_FILTER_CONFIG (93) -> MSP2_COMMON_SETTING
- MSP_PID_ADVANCED (94) / MSP_SET_PID_ADVANCED (95) -> MSP_INAV_PID
- MSP_OSD_CONFIG (84) / MSP_SET_OSD_CONFIG (85) -> MSP2_INAV_OSD_*
- MSP_POSITION_ESTIMATION_CONFIG (16) / MSP_SET_POSITION_ESTIMATION_CONFIG (17) -> MSP2_COMMON_SETTING
- MSP_SERVO_MIX_RULES (241) / MSP_SET_SERVO_MIX_RULE (242) -> MSP2_INAV_SERVO_MIXER

Commands remain fully functional. This gives third-party developers
a full major release cycle of notice before removal.

Also adds "replaced_by" field to the MSP message JSON schema
(docs/development/msp/format.md) and populates it for all 14 entries.
Co-authored-by: qodo-code-review[bot] <151058649+qodo-code-review[bot]@users.noreply.github.com>
Add replaced_by fields to msp_messages.json and deprecation comments
to msp_protocol.h for MSP_BLACKBOX_CONFIG, MSP_SET_BLACKBOX_CONFIG,
MSP_STATUS, and MSP_DEBUG. MSP_STATUS_EX not marked deprecated because
its accCalibAxisFlags field is absent from MSP2_INAV_STATUS.
…N_DATA

MSP2_INAV_STATUS supersedes MSP_STATUS_EX for all status fields.
The accCalibAxisFlags field absent from MSP2_INAV_STATUS is available
via MSP_CALIBRATION_DATA.
@sensei-hacker sensei-hacker force-pushed the pwm_use_explicit_timers_first branch from dda0932 to e09cbc3 Compare March 19, 2026 20:36
@github-actions
Copy link

github-actions bot commented Mar 19, 2026

Test firmware build ready — commit e09cbc3

Download firmware for PR #11444

227 targets built. Find your board's .hex file by name on that page (e.g. MATEKF405SE.hex). Files are individually downloadable — no GitHub login required.

Development build for testing only. Use Full Chip Erase when flashing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants