Rover/Boat QuikTune alpha testers wanted!

@rmackay9

I was able to get out and do some testing of the quicktune on a skidsteer boat today, this log has two different quicktune tried see below. I first did a 10m circle then I did some driving around tired guided mode which didn’t seem to do well after the 10m quicktune, there was a lot of oscillation @20:40:44. So I decided to do another quicktune with larger circles this time being 30m afterwards guided mode seemed to work much better.
the second log just has some guided and rtl nothing much to really see. I have the exact same motors, esc are also set to same value which was verified in blheli and they are both set to 1000-2000 pwm value in the servo tab as well as all trims center on the rc transmitter but there is a little bias on which side has more power is there a auto trim function or should I manually adjust it in the servo tab. the second log probably at the very end shows this bias best.

2 Likes

It has been a long couple of months building the new boats for our new FishTec franchises in Europe but I was able to get on the water for the first time with one of the new AIMy430’s yesterday.
It wasn’t too bad but there is definitely too much throttle in the right and obtuse angle turns, where the acute angle turns are a little better.
How can I restrict the throttle in the turns?
Also noted Rover4.4 doesn’t like the waypoints too close as seen in wpt20-21.
Here is the log - 00000063.BIN - Google Drive

2 Likes

How do you get the aux function screen on mission planner?

@geofrancis,

To make MP’s aux function screen visible, hover over any of the existing tabs (on the Data screen) and then right-mouse-button-click and select “Customize” and then check the “tabAuxFunctions” checkbox.

image

1 Like

Hi @John_Easton,

Sorry for not responding earlier. I saw your note about getting a CUAV V6X binary so I will produce that shortly. I delayed slightly because we’re planning a Rover-4.4.0-beta4 release soon but I’ll go ahead and create a separate binary in any case.

1 Like

@John_Easton,

We’ve included the Rover QuikTune in Rover-4.4.0-beta4 which should appear in the ground stations within the next few hours and then it can be installed using MP’s beta firmwares link.

I plan to have a look at your logs tomorrow. Again, sorry for the delay.

2 Likes

That is awesome, thank you Randy. I plan on testing again next week Monday.

1 Like

Hi @John_Easton,

I had a look at yours logs and it appears that the CRUISE_SPEED and CRUISE_THROTTLE values haven’t been set. The QuikTune will set these for you though when you run it so let’s see how that goes.

The steering rate controller is under achieving fairly badly. So for example the upper navigation controls are asking the vehicle to turn at 40deg / sec but the vehicle is only turning at about 10deg/sec.

This next graph shows the FF, P and I contributions to the output. The balance of the three is not bad so I think they’re all basically too low. At least ATC_STR_RAT_FF should probably be doubed from 0.15 to 0.30. Again the QuikTune could figure this out.

By the way, it would be good to tell the controllers the limits of the frame by reducing these parameters:

  • reduce ATC_STR_RAT_MAX from 120 to perhaps 40 or even less
  • reduce ATC_TURN_MAX_G from 0.6 to perhaps 0.2 or even less

By the way, one thing regarding the frame, it would be good if the vehicle could turn more quickly. I think 10deg/sec max turn rate means that the controller has very little power to correct deviations from the path.

1 Like

Thank you very much for taking the time to review my log Randy, and I agree, a good tuning will make a big difference.

I tried the QuikTune yesterday but I got a strange error - “Tune needs to be armed and moving”, but the craft was armed and moving - here is the log for that test:-

With regard to the frame, the motor has been set to its maximum turn angles possible.
Another interesting fact is that on Rover4.2 this same craft used to go dead straight on the straights and make fairly accurate turns using the old L1 controller.

Hi @John_Easton,

The message, “Tune needs to be armed and moving” is displayed when the RC switch is in the middle and the throttle is zero. So one unintuitive thing about the script is the RC switch positions (RC6 on your transmitter I think):

Low: Disabled
Mid: Enabled (e.g. starts tuning)
High: Save tuned parameters

So I think while the vehicle was in circle mode the switch was in the high position. Then later on while the vehicle was in Manual mode the switch was moved to the middle and the message appears.

1 Like

So should this be the procedure?:-
a - RC6 low / disabled
b - change to circle mode
c - change back to manual mode
d - RC6 mid / enabled
and when complete - e - RC6 high / save

@John_Easton,

The procedure should be:

a - rc6 low / disabled
b - change to circle mode
c - rc6 mid / enable
d - wait for the tune to complete. It should save parameters but if not rc6 high
e - rc6 low / disable
f - Acro or Auto to test tune

… so the key thing is that the QuikTune should be run while the vehicle is in Circle mode. I will change the script to enforce that in the near-ish future.

3 Likes

Oh ok, roger that. Makes sense now.

If I upgrade my firmware to 4.4, will I loose all my existing parameters?
I really don’t want to redo all those after spending months to where I am now.
I am keen to try the script with maybe some help to install it.

Hi @Fossil,

Thanks for getting involved in the testing of this new feature!

No, parameters should remain intact even after a firmware upgrade. Upgrading the firmware does not erase the eeprom which is where parameters are stored unless firmware for a different vehicle (e.g. Copter, Plane, Sub, etc) is loaded onto the autopilot.

By the way, saving all parameters to a file is quite easy using MP’s Full Parameter List (see “Save to file”) button but it is rarely needed.

Parameters are also stored in the onboard log files (aka dataflash log files, aka .bin files) which are stored on the autopilot’s SD card and can be extracted using MP’s Data screen’s Dataflash Log’s tab’s “Create KML + gps” button.

… so even if parameters were erased (which they probably won’t be) they can nearly always be retrieved.

Perfect. Many thanks @rmackay9. I will re-read the whole thread and attempt to follow the instructions.
I still have to overcome my lack of servo output first! Very frustrating,
Cheers, Martin

1 Like

I managed to get out on the water this morning but I must be doing something wrong …
Here is the log - 00000009.BIN - Google Drive

Hi @John_Easton,

Thanks for giving it a try.

It looks like it partially tuned the vehicle but it could not complete the steering “feed forward” tuning because the vehicle was not turning aggressively enough. You might have seen the message, “RTun: increase steering (6% < 10%)”.

The solution is to make the circle tighter by reducing CIRC_RADIUS from 20m to perhaps 15m or 12m.

By the way, I noticed that the vehicle is setup to use EKF2. My guess is that when the vehicle was setup you perhaps just blanket copied all parameters from an older vehicle. It’s probably OK but in general we don’t recommend doing this. Instead we recommend more targeted copying of parameters. For example attitude control parameters all start with ATC* so you might only copy those. Could you switch to EKF3 by setting these parameters?

  • AHRS_EKF_TYPE = 3
  • EK2_ENABLE = 0
  • EK3_ENABLE = 1

For what we’re doing here, there’s no real significant difference between EKF2 and EKF3 but it’s good to be using the latest “estimator”.

1 Like

Thank you for the feedback Randy, I will try that today.

thanks for the script. I tested it today on CubeOrangePlus + Rover 4.4.0-beta4 .
SRC_ENABLE=1
CIRC_DIR=0
CIRC_RADIUS=20
CIRC_SPEED=6

but in my boat for some reason the counter-clockwise direction was mixed. and the script gave an error so I couldn’t configure anything.

Critical: RTun: Internal Error: /APM/scripts/rover-quicktune.lua:633: attempt to call a nil value (method 'get_steering_and_throttle')