Hi!! since i updated my copter 4.0.7 to 4.2.X i noticed that the drone does not follow the speed set in the mission commands(DO_CHANGE_SPEED). Anyone else with this problem? The same parameters with 4.0.7 work fine. My wpnav_speed is 12 but i can’t fly less than this in auto mode.
In this log i put 10m/s, send the mission some times but after takeoff did not hold the speed.
Thanks for the report. This is a real bug so well done uncovering it! I’ve created an issue here and this is almost undoubtedly caused by a change we made to the takeoff and landing code.
The work around until we have a fix is to add a WAYPOINT command immediately after the TAKEOFF with all zero lat, lon and alt. Then put the DO_CHANGE_SPEED after this all zero WAYPOINT command.
Yes the bug is new for 4.2.0 and is present in all subsequent versions.
I discussed with Leonard and we have a plan to fix it but it will require moving where we hold the latest desired speed from the waypoint controller up into the Auto mode. This is not a huge change but it will require some careful testing.
@rmackay9, I am very close to submitting a PR for a Lua binding that interacts with some of these methods (set_desired_speed for Rover and set_speed_xy for Copter) - effectively giving us DO_CHANGE_SPEED functionality in scripting, as we discussed earlier this year. It is implemented much like the guided mode bindings that already exist.
Is the bug fix impactful enough to warrant waiting for it before I submit the PR?
Ok! I think it’s ready for submission, but I’d like to test an example script for inclusion with the PR, and I didn’t quite finish that today. Thanks to @iampete, of course, for a little guidance earlier as well!
For some reason change speed is bugged since ages. It just works random. What i find sometimes helps is using not round numbers for speed. Try 10.2 or something similar.
This bug is present since at least 3 years ago.
Does anyone know if this bug has been fixed yet? I don’t recall seeing it in the release notes - but I’ll admit I haven’t been looking for it.
Creating a test photo mission today, I noticed a couple of things that may or may not be related.
The mavlink command for do_change_speed has a new parameter compared to the docs in the wiki. The first parameter is now “type” - and the default value is “0” which is “airspeed.”
I have no idea how this may affect copter missions - that do not have airspeed sensors.
The Mission Planner “AUTO WP - SURVEY GRID” feature for polygons, does not automatically add the do_change_speed command per the selections for the survey - as it used to.
Pretty scary when the drone takes off at 15/ms 2Mtrs above a field…totally ignoring it being set to 1/ms… It appears to ignore mission speed randomly. I’ll try the above workaround eg WP set at 0 0 0 0 0 0 0 and keep fingers crossed!!
@norim We don’t set DO_DIGICAM_CONTROLL so doesn’t affect our missions. But it does appear to be a bug, hopefully fixed in next release, fingers crossed
If a waypoint command’s altitude is set to zero then it will use the vehicle’s target altitude at the moment it started the command. So if the vehicle is flying at 30m and it starts a waypoint command with the altitude field set to zero, it will fly at 30m.
Interpreting “0” as “current altitude” is a long standing feature but I also always set the altitude to the specific value that I want the vehicle to fly at.
Re the issue that @norim brings up, the do-digicam-control command is not directly related to the vehicle flying slower than expected. The issue is that we have a slight shortcoming in our waypoint navigation code which means the vehicle will fly slowly if waypoints are placed too close together.