Been playing around with a quadplane in SITL, doing guided missions with a companion computer. When my plane reaches the end of its mission with Q_GUIDED_MODE set to 1, the plane transitions with a very violent spike in motor output before coming back to normal levels.
My theory is that is has something to do with “Reset alt target to 59.6” but i am not sure.
Try reducing THR_MAX. Also, when the plane is moving forward fast and you transition to QLOITER mode, it can cause this action as it tries to hold position. Try a transition to QHOVER mode first and then change to QLOITER to hold position.
Thanks you for your suggestion. This simulated plane is using a combustion engine for forward thrust, whereas this spike is the lift motors. Would you still recommend the same course of action?
Yes, try reducing THR_MAX first. If that isn’t satisfactory, change your mission plan to transition to QHOVER mode and then add a step to change the mode to QLOITER if that is what you want.