Servers by jDrones

The Greatest Puzzle of All Time - Path Wobble


(John Easton) #6

The Puzzle … What changed??


(Nathan E) #7

The EKF and environment. The computer did the exact same math, but with a different assumed “zero” from the accelerometers and gyroscopes from boot. The INS parameters are different because of a different physical state during boot. The difference is very slim, but it obviously had a bad effect because of the unstable PID’s.


(John Easton) #8

What can I do to resolve this Nathan?
Did I do something wrong on 000186 compared to 000185?


(Nathan E) #9

Lower your ATC_STR_RAT_P

You didn’t change anything – I get that.


(John Easton) #10

Nathan,

You might have given me a very important clue!

185 was booted on land, and 186 was booted on the water, could this have made a difference?


(John Easton) #11

Some interesting info here - https://www.facebook.com/groups/thecubeautopilot/permalink/1921004044648875/

Do increase a period. :wink: I need to read up on that type of controller - I may need it in my work soon - but from what I understand about it either a period or damping should be increased. Most likely period, my guess would be around 1.5x times.


(Nathan E) #12

John,

I looked back on your other threads, and I think I might have given you some bad advice above here – looking at your STER data shows me that your desired and actual turn rates match very closely in both logs. Don’t change your P and FF values yet.

Seeing the desired lateral acceleration osciallate means that the navigation controller is the one that is causing oscillations now. Your L1 settings -

NAVL1_PERIOD
NAVL1_DAMPING
NAVL1_XTRACK_I

Probably need to be tested and optimized. Try increasing the period and decreasing the damping slightly. If I remember correctly, we had you increase your TURN_MAX_G from previous missions so that you could turn sharply on corners. Unfortunately that probably allowed the navigation controller more authority during straight runs - and now its settings are causing some oscillations.


(John Easton) #13

That is really interesting, I will certainly try that.
Thank you once again for your efforts Nathan.
I think I need to go to a local dam and camp for a few days so I can test as soon as I get the info.
Where in the world are you from? I am in Durban South Africa


(Nathan E) #14

Iowa - Central United States.

I don’t know if you can, but the single best thing that saves me time tuning is a good telemetry radio (RFD900 or something similar). That allows me to make parameter changes in the middle of a mission to see the outcomes. Most of the parameter changes here do not affect hardware, and they do not require a re-boot to see the effects. They are live, so you can try them as you go. It might save you a lot of time.


(John Easton) #15

Ok, so there is an 8 hour difference.

That is good advice, I need to get the RFD900 as I have been looking at it for a while now.

It still boggles my mind that the controller is actually instructing the craft to start the wobble without any change from the ‘environment’.


(Nathan E) #16

The rover isn’t “self-learning,” so it doesn’t surprise me that it can be unstable at times. Sometimes the smallest things can throw it off when it’s very close to being unstable.

It’s difficult for the same parameters to work on all vehicles. Some are tiny RC cars while others are houseboats. It’s crazy what ardupilot can control once the tuning is complete.

For what it’s worth, these are the parameters compared from log to log. All of the INS parameters are changed on boot, so that’s why they change. BRD_SAFETYOPTION and RC4_DZ were probably changed by you, but the rest change every boot.


(David Boulanger) #17

I don’t know if booting up on the water is the way to go.


(Jasper) #18

Could it be that the code is not tilt compensating the compass? A slight roll in the boat will give a compass change of a few degrees which will cause the rudder to try to correct this imaginary course deviation introducing a wobble into an otherwise straight path.

Put the boat on land and introduce roll and see if your yaw changes.


(John Easton) #19

The craft is doing EXACTLY what the controller is telling it to do.

It is at this 3:55:45 to 3:56:00 point that we need to determine what changed in the controller code to tell the craft to start wobbling.

And then again at 3:57:15 what changed back to normal again to tell it to go straight again.

If the craft is heading in the right direction, the only thing that could possibly change when there is no wind, current or chop, is the compass going nuts IMHO.


(Jasper) #20

Do you have the compass readings at that time?
What happens to the compass if you roll the boat on the bench?

If the software allow you change the smoothing of the compass readings, You probably only need to act on compass changes once per second so smoothing over 10 or 20 readings (assuming read rate is once per 100ms) should still give you enough info to not oversteer on gentle turns.

Not sure if ardu pilot uses the gyro and compass for yaw control, if so, adjusting PID only on the yaw control might not be enough but would help.


(Nathan E) #21

You are correct. That is why it appears to be a navigation controller problem, not a position/attitude estimation problem. That kind of oscillation happens to me when my L1 period is too low for my plane.


(John Easton) #22

Nathan I am currently using L1 Period of 8, if I go higher the drift off the path is increased dramatically


(John Easton) #23

I remember reading you can use a recorded log as a simulated file, maybe that will give us some answers, in particular what the heading was doing at that point (3:55:45) when it told the craft to start wobbling

185 has the wobble


(Nathan E) #24

Have you tried raising
NAVL1_DAMPING and NAVL1_XTRACK_I?


(John Easton) #25

Settings:
NAVL1- DAMP = 8
NAVL1- XTRACK-I = 0