Ardusub and AM32 3D Dshot ESC weird movements

Hello.
Running 4.7 locally compiled version of ardusub on a Kakute FC I was trying to use Dshoot to control some modified FPV drone ESC with AM32 firmware and the beaviour of the motors doesn’t match what is represented on the servo output on the MP.
When the servo values apear as 1500 everything is stopped and when moving to 1900 they ramp up nicely but as soon as then go under 1500 the motors go into full power and reducing until reaching 1100.
I have set the SERVO_BLH_3DMASK, the SERVOx_FUNCTION and the MOT_PWM_TYPE parameter but is there anything else I have to change?

Thanks

Hi @papaxiclas,

I’ve just read through the ArduPilot DShot documentation and don’t see anything obvious you’ve missed. It could be worth adjusting the DShot update rate for some extra reliability, and depending on your firmware’s DShot functionalities it may be worth trying different DShot type options.

Glancing through a search of the active issues, DShot is apparently expected to use the 1000-2000 range of values, so it might be worth adjusting your SERVOx_MIN/MAX values to get the full range of your outputs, but that also doesn’t seem relevant to the problem you’ve described. It’s also possible the masking parameters do not map to channels as you’re expecting, but if that’s the case then I’m not sure how they should be mapped, and given 1500 is counting as stopped it does seem like those outputs are already being handled as reversible :man_shrugging:

From the symptoms you’re describing I’d expect that there’s either something wrong with ArduPilot’s DShot driver’s reversible motor type functionality, or there could be a problem with how your ESC firmware tries to handle the relevant commands, but both of those seem like problems others would likely have run into and raised before.

That said, I have no actual experience with DShot, and imagine that’s likely true for much of the community here, so you may get more insightful responses from the broader ArduPilot forum, and/or the AM32 Discord server :slight_smile:

Hello Eliot.
I think I found the culprit. For some reason the SERVO_BLH_3DMASK wasn’t passed to the dshot module in the source code so it was sending the value as a regular PWM servo. I hard coded the mask in there and everything seems to be working as it should now. Don’t really know if it is a bug or if there was some kind of reason that lead to this.
Thanks for your help.

Hello, I am suffering from the same problem, do you have a chance to pass me your solution?

hello! I don’t really remember what the exact solution was but I changed the source in order for the dshoot to work. I think it was because on dshot the reversing of the motors is diferent. From 1500 to 2000 you have forward from 0 to 100% but for reverse you have 1000 to 1500 as 0 to 100% while with PWM it is the other way arround.

Thanks I’m trying to configure (blheli and am32) the esc I have with serial connect, do you remember exactly which lines the source code is in, or did they fix it in beta?

Sorry, I don’t really remember but I used some AI to help find the file to change…

Thanks, I noticed these things:

Dual-channel (3D) settings are not applied without selecting the ESC type(Like am32 or other bheli names), and similarly, applying them only to the aux channels requires a lot of trial and error. I also tried the main pins, but they are not allowed as IO outputs. When I tried to modify this part, the bootloader froze.

So,I’ll briefly focus on the configuration(esc’s) , but esc communication isn’t possible via Pixhawk (im tested b-cube,organgecube,sitl) and an additional MCU. Once I’m done, I might release a markdown and a few useful patches. Thanks again, the thread you started was inspiring.

I was using a kakute fc for the ardusub if that info is of any help!