Arduino Boat

Hey guys I'm making an autonomous boat powered by arduino, GPS & Compass readings and thought id see if anyone reads this stuff at all, Hoping to also get a bit more info about a gps Im using and also the TinyGPS & TinyGPS++ library data and the calculation I would use to adjust for currents when changing heading, Ie How do I go north when i need to power nne to adjust for a cross current if i cross a fast flowing river.

Cheers for any tips, Im sure a flight guy would know the answer from adapting to the wind.

Cheers

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • David, noone's arguing against that.  I think we all, including the OP, understand that Ardurover can do boats.  Dat0 prefers to work from scratch, maybe for learning, maybe for other reasons.  It's a perfectly reasonable decision.  Sometimes having a working model isn't the only goal.

    At school, I'm building a multirotor flight controller from scratch, even though I understand (from personal experience) that ArduCopter exists and works very well.  The amount of knowledge you soak up when implementing your own PID controllers, filters, inertial navigation, communications, etc. is incredible, and totally worth the effort put into it.

    The original question was about algorithms for compensating for windage.  If we were to draw from the Ardorover project, I think the best way would be to discuss how it handles the windage problem, so that we can learn from it and emulate it.


  •  This will be the last I say.  I have a boat and you don't need to hack the rover code.  It handles windage and current just fine.

    Regards,

    David R. Boulanger

  • I prefer not to learn by hacking apart the programming of an ardurover. To get it to interface the compass differently and steering differently. I mean id rather learn and program a mega myself at this stage.

    Cheers buy please no more ardurover stuff I'm going DIY

    And thanks for the cross track correction tip. I'm looking at what might be the best way forward with it.

  •  Ardurover does an outstanding job doing this.  2.5 is the last release I think that works on the old processors.

    Regards,

    David R. Boulanger

  • Sure, what you're talking (at least in part) about is called crosstrack correction.  (APM actually replaced this with an entirely different navigation algorithm, but it still works...).  

    The basic idea is that with simple movement, you constantly adjust your heading to point directly towards the current waypoint.  If you get swept off course, you'll just stay off course because you'll keep heading directly from your new position to the current waypoint.  What you should do is calculate how far off course you are (distance between your position and the closest point on the original course line), and then use that number to adjust your heading so that the "corrected heading" is not directly towards the waypoint, but is biased towards getting you back on course.

  • Sounds like I'd be spending a lot of time and effort trying to adapt code already written to work how I would want it to and on the equipment I want to use.
    I think I might be better off learing the math and experimenting with the heading to adapt for wind.
    At the moment my thoughts are to continue as planed and avoid trying to adapt pre written mostly finished code.

    So that in mind does anyone have any reading that would help ?

    Thanks

  •  

    The Ardurover code works just fine on a boat.  You wil need to use a older release if not using a Pixhawk.

    Regards,

    David R. Boulanger


  •  Yeah, you could run it on Ardumega, as that is the base chip on the ardupilot. The code requires a bit of modification for a standard board, but it will work. In fact, there might already might be a script that is on github that does exactly that. 


    Dat0 said:

    Hey

    I think you have taken your original post and run with it a little far, Im not using ardupilot at all unless its code that loads onto an Arduino mega. Really I'm after the following - 

    a bit more info about a gps Im using and also the TinyGPS & TinyGPS++ library data and the calculation I would use to adjust for currents when changing heading, Ie How do I go north when i need to power nne to adjust for a cross current if i cross a fast flowing river.
    Cheers for any tips, Im sure a flight guy would know the answer from adapting to the wind.

    So yeah, If anyone has any info on how i would start to tackle this code let me know.

    Cheers

  • Hey

    I think you have taken your original post and run with it a little far, Im not using ardupilot at all unless its code that loads onto an Arduino mega. Really I'm after the following - 

    a bit more info about a gps Im using and also the TinyGPS & TinyGPS++ library data and the calculation I would use to adjust for currents when changing heading, Ie How do I go north when i need to power nne to adjust for a cross current if i cross a fast flowing river.
    Cheers for any tips, Im sure a flight guy would know the answer from adapting to the wind.

    So yeah, If anyone has any info on how i would start to tackle this code let me know.

    Cheers

  • Hi Dat0

    You don't need to worry, your "flight Plan" defines a required track and the boat follows the course as best as possible to achieve the desired track and not heading. And it will also adjust speed (within limits) to maintain a desired constant speed over the earth, in other words less throttle down stream and much more into the current. The autopilot derives a heading from the track (a gps position now compared to a gps position a few seconds back) so into current conditions when the position has not changed significantly cause errors in the derived heading and cause a bit of oscillation in track (weaving).  

This reply was deleted.

Activity

DIY Robocars via Twitter
RT @chr1sa: You can see this in person in two weeks for our next live event with real cars. It's great fun for adults and kids alike, and…
Sunday
DIY Robocars via Twitter
RT @chr1sa: The final race (1:24) at yesterday's @DIYRobcars virtual event was our best. It's only two minutes long but it has everything,…
Sunday
DIY Robocars via Twitter
RT @chr1sa: The monthly @diyrobocars virtual race is starting now! https://www.twitch.tv/roboticists2
Saturday
Mike Whitney liked Mike Whitney's profile
Jul 19
DIY Robocars via Twitter
Jul 2
DIY Robocars via Twitter
Jun 26
Abdulatif Tlaib liked Ryan's profile
Jun 24
DIY Robocars via Twitter
RT @SmallpixelCar: First time at @wsraceways. After tuning @HokuyoUsa lidar signal and camera sensor on @NVIDIAEmbedded, my car was able to…
Jun 20
DIY Robocars via Twitter
RT @breadcentric: The handy bit about racing with self-driving cars is that one can type while the car is racing. Report from #AWSDeepRacer…
Jun 18
DIY Robocars via Twitter
RT @chr1sa: Our Bay Area @DIYRobocars meetup is now at 2,700 members. Next in-person events (in Oakland) are training day on July 17 and…
Jun 18
DIY Robocars via Twitter
Videos from the ICRA autonomous racing workshop are now available: https://linklab-uva.github.io/icra-autonomous-racing/
Jun 10
DIY Robocars via Twitter
RT @SmallpixelCar: Prepared race track for Warm Spring Raceways @wsraceways and looking forward to test my new car at RAMS RC @ramsaicar fa…
Jun 6
DIY Robocars via Twitter
RT @f1tenth: Trying out some nasty blocking maneuvers 🏎️🤖 #f1tenth #autonomousracing https://t.co/nMTstsaogM
Jun 5
DIY Robocars via Twitter
May 27
DIY Robocars via Twitter
RT @araffin2: I will talk this Saturday from 18:00 to 19:00 Paris time for the @diyrobocars community about learning to race in hours using…
May 27
DIY Robocars via Twitter
RT @a1k0n: Luckily the infeasible hairpin problem was easily reproducible in simulation and I could test the fix before bringing the car ba…
May 26
More…