mavlink / MAVSDK-Python

MAVSDK client for Python.
https://mavsdk.mavlink.io
BSD 3-Clause "New" or "Revised" License
323 stars 220 forks source link

Parameter Error with `set_maximum_speed` and `get_maximum_speed` #733

Open Ziaad03 opened 2 weeks ago

Ziaad03 commented 2 weeks ago

I encountered an issue when using the set_maximum_speed and get_maximum_speed functions in MAVSDK. Whenever I attempt to use these methods, I receive a parameter error, and the command fails. I also want to mention that I am using Arduopilot. Also, when using the set_current_speed method the speed of the drone stays the same at 10 m/s even though ArduoPilot acknowledges the command.

julianoes commented 2 weeks ago

You're right. Looks like it's not supported for ArduPilot in the current state. It's using a PX4 only param.

https://github.com/mavlink/MAVSDK/blob/963f05a4b443e4751d98f8c7555395b1505d3245/src/mavsdk/plugins/action/action_impl.cpp#L725-L731

https://github.com/mavlink/MAVSDK/blob/963f05a4b443e4751d98f8c7555395b1505d3245/src/mavsdk/plugins/action/action_impl.h#L130

Ziaad03 commented 2 weeks ago

Ok, do you have any idea how the speed can be changed other than using these methods?

julianoes commented 2 weeks ago

Check the ArduPilot docs and parameters.

Ziaad03 commented 2 weeks ago

There is a parameter called WPNAV_SPEED that controls the drone speed in auto mode only but it only change the speed to a value under 10 m/s . If I try to give it a value above 10 , the speed will not change and stay at 10 m/s. Also, I want to say that I really appreciate your help, and I want to thank you for your efforts.

julianoes commented 2 weeks ago

Thank you for your kind words.

I have to say I'm somewhat tempted to remove this MAVSDK API because: