The division by zero bug occurs in different flight stage according to the vehicle type.
–> ArduCopter: division by zero bug occurs when AP lands on the ground after finish a mission.
–> ArduPlane & Rover: after immediately assign 0 to the parameter, division by zero bug occurs
We cant protect users against every combination of bad params, there are loads that will cause the code or vehicle to crash, if you keep to the range given in the documentation you should be OK.
@iampete
I understand that ArduPilot does not need to prevent all bad params.
It will be great if documentation will be updated.
This is because it says the valid range of SCALING_SPEED is from 0 to 50.
But, assigning 0 leads to the division by zero
Thanks!
I think the code will still work fine with that division by zero, it is constrained. In any case we could update the documentation, its is here if you fancy making a PR: