Hi everyone,
I need a compass steering mode for rover / boat. I have gone through this forum and found a few posts where people have had a similar need but no solution. Could anyone please suggest what would be the right way to get the mode done? Would it be possible to find help here at this forum or should I go to some freelancers hiring site to find someone capable of writing Arduino code?
Here is the mode I need in a nutshell
- automatic navigation is done according to compass reading (not by GPS)
- automatic navigation can be overrun by manual steering at any time, but the moment the steering stick is returned to the centre position the heading by compass at that moment is fixed and automatic navigation will hold that heading
- speed control is manual
I would be grateful for any help / suggestion.
Fred
Replies
Fred,
This sounds exactly like STEERING MODE in ROVER 2.50. Unless I'm not understanding the question right? It's my favorite mode that I use with my boat.
Regards,
David R. Boulanger
Thank you for the comment. Yes, it sounds like STEERING mode except STEERING mode uses GPS to hold the heading but I would like to use only a compass.
In STEERING mode my boat does not hold the heading very well, it starts floating off in 20 seconds or so. Even in totally calm weather. I have adjusted all the parameters I know connected to GPS and compass. Still floats off. To my knowledge, there is no way to eliminate the GPS and rely on compass only. Or is there?
Thanks
Fred
Fred,
I don't think STEERING MODE uses the GPS. Only the compass. I will test this in about 3 hrs. If it drifts off in the same direction all the time you may want to check your radio calibration and dead zone around the sticks. Also the trims on your radio. The more I think of this, it is only compass, based on bench testing I've done. Post a parameter list and a log to look at.
Regards,
David R. Boulanger
David,
Thank you so much for the quick reply. I attach hereby the parameter list. I think that set worked the best for me. I do not have the logs though. I cleared all them off in the autumn. It is mid-winter here in Estonia now and it takes another 2-3 month when ice melts and I can do the real testing again.
Your notion about the radio is very interesting indeed. It never occurred to me that the radio may drift. I will check that.
And the other issue with STEERING MODE is that it does not fix the heading when I change it. Let's say I change the heading of the moving boat by 15 degrees to the left and return the steering stick into the centre position. Then the boat turns back towards the old heading and the new heading is maybe only 3 degrees to the left. So it takes 3-4 attempts to get the boat actually following the new desired 15 degrees to the left heading. Quite a fiddling.
As far as I remember the speed control was weird also in STEERING MODE. Definitely not, like in MANUAL MODE.
I am actually very new to the APM thing and there might be some parameters that need to be tuned and all my problems will be gone. I searched the forums of Diydrones and Ardupilot though.
Thank you
Fred
parameters.param
Fred, I will look at your parameters in a little bit. The speed in STEERING is governed by the THR_MAX parameter or CRUISE SPEED I believe ( not totally sure). If it is set to 50% then your max throttle in STEERING would be one half of that as it would be in MANUAL. Your probably seeing the boat speed is less in STEERING than MANUAL I would guess. I Don't know at the moment what the problem is changing your heading. It could be parameters, radio, or even compass interference I suppose.
I'll let you know if there is anything in the parameter list that jumps out at me and looks wrong.
Regards,
David R. Boulanger
Fred,
In the future you probably should post questions on the Arduboat forum. I few things I noticed are.
COMPASS_ORIENT 8. So your compass is not facing forward and right side up ?
NAVL1_PERIOD 1. This should probably in the high single digits if not even in the teens.
All of your STEER2SRV Parameters are way off where they should be in my opinion. This could be part of the problem.
Attached are my parameters. All boats would be different but not as crazy as your Steering Parameters I would think.
Regards,
David R. Boulanger
2.5 boat july 22.param
David,
Thank you very much for the ultra quick and honest comments. I really appreciate you found time to go through the parameters.
.... not as crazy as your Steering Parameters :-))) I must admit I experimented a lot with NAVL1_ and STEER2SRV Parameters to get my boat going steady at low speeds about 2 km/h and deliberately put some crazy values to them to see what happens. With these, it worked actually pretty well. Thank you for your parameters. I think they are a good starting point to start experimenting again.
As for COMPASS_ORIENT 8 - I do not remember I changed that. Maybe it game through the calibration process. Compass is installed by book - facing forward and the right side up. I will change COMPASS_ORIENT to 0. Maybe that is the core reason of my problems.
David, how about the example of changing the heading by 15 degrees I wrote about earlier. Will your boat stick to the new heading right away when you release the steering stick?
Thank you,
Fred
Fred,
My boat sticks to the new heading right away. No sense speculating on your problem without you testing with the COMPASS ORIENT right. I don't know what 8 even means without looking in the manual. My boat runs about 4km/h in auto I think. 2 Knots plus a little. You do the math. Somebody would really need to see the logs of your boat use to better get an idea of the problem. I no expert, but have used the Rover code on a boat for a year now. A picture of the boat and underbody would be useful to better understand its steering characteristics. Does it work O.K. in AUTO mode going from waypoint to waypoint?
Regards,
David R. Boulanger
David,
Fantastic, thank you David. That is very good news indeed that your boat sticks to the new heading right away. That means it most likely is a problem with my parameters but that is easily fixable, no extra programming needed. And I have your working parameters to start with.
Your comments have been really helpful. In a couple of month the weather conditions will allow me to get my boat on the lake again. Cannot really wait.
Once again - big thank you.
Fred
@David,
You beat me to that suggestion and I believe that you are right when using the STEERING Mode.
Regards,
Tom C AVD