F405-VTOL PWM group confusion

Being as late as usual to the party, I’m trying to set up a Matek F405-VTOL for use in a Heewing Ranger T1 VTOL. Seems like I’m running into PWM group issues. There doesn’t seem to be a wiki entry specificly for this variation of FC, so I’m trying my luck here.

According to Matek, PWM groups are:

S1,S2 / S3,S4 / S5-8 / S9 / S10 / S11 / S12
https://www.mateksys.com/?portfolio=f405-vtol#tab-id-7

So I have it set up like this:

S1, S2, S3 = Motors 1-3 (DSHOT600 on CH 1,2,3)
S5, S6, S7 = Aileron L / Aileron R / Elevator - PWM
S9, S10 = Tilt L / Tilt R - PWM

Error message in MP:

03/07/2024 23:15:48 : Chan 3 to 9, PWM: failed, no DMA
*03/07/2024 23:15:48 : RCOut: DS600:1-2 PWM:3 *
DS600:4 PWM:5-12

According to the message, the actual PWM grouping might be different?

To add to the confusion, Matek also writes (on the wiring diagram):

S2, S3, S4, S9, S10, S11 = servos
https://www.mateksys.com/?portfolio=f405-vtol#tab-id-4

If this is their recommendation, motors should be on S1, S5, S7, S8 and/or S12? This wouldn’t seem to fit with the groups either?

This is also the first time I ever saw some kind of DMA error in connection with motor/servo outputs.

In short, I’m perfectly confused. :sunglasses:

Thanks for any hints!

It uses the F405-TE firmware right?
F405-TE hwdef

Yes, using F405-TE BDshot. Interesting page, so that’s where Matek copy the PWM groups from. They have to be correct then.

I don’t get the PWM group-related errors, Chan 3 is not set to PWM for example. Maybe I should just try another AP build? Using 4.5.2, just noticed it’s still an older version from May when I started the build which then got interrupted (as usual).

That’s the problem. Different configuration in the BDShot firmware: ardupilot/libraries/AP_HAL_ChibiOS/hwdef/MatekF405-TE-bdshot/hwdef.dat at master · ArduPilot/ardupilot · GitHub

1 Like

That’s it, thanks! Is there any documentation I could have read about this difference before? Matek apparently didn’t think of mentioning it. Well, from now on I’ll always check hwdefs directly. Thanks again!

EDIT: New problem, with that grouping I’m struggling to put all 3 motors on BIDIR channels while keeping the 5 servos on channels/groups set to PWM. I’ve never been good at that kind of puzzles, does anyone have a solution?

Don’t think so, no.

PWM9…12 are still defined from the non-BDShot firmware, so you could do:
BDShot: 4, 6, 7
Servos: 1, 2, 3, 9, 10

2 Likes

Ah, “undef”, but only some of them, now I get it (not a developer here). Thanks again! Never ran into this before in years of AP, but then again I never had project use that many outputs.

1 Like