[Jack], a mechanical engineer, loom builder, and avid sailor wanted an autopilot system for his 1983 Robert Perry Nordic 40 sailboat with more modern capabilities than the one it came with. He knew a PC-based solution would work, but it was a bit out of reach. Once his son showed him an Arduino, though, he was on his way. He sallied forth and built this Arduino-based autopilot system for his sloop, the Wile E. Coyote.
He’s using two Arduino Megas. One is solely for the GPS, and the other controls everything else. [Jack]’s autopilot has three modes. In the one he calls knob steering, a potentiometer drives the existing hydraulic pump, which he controls with a Polulu Qik serial DC motor controller. In compass steering mode, a Pololu IMU locks in the heading to steer (HTS). GPS mode uses a predetermined waypoint, and sets the course to steer (CTS) to the same bearing as the waypoint.
[Jack]’s system also uses cross track error (XTE) correction to calculate a new HTS when necessary. He has fantastic documentation and several Fritzing and Arduino files available on Dropbox.
Autopilot sailboat rigs must be all the rage right now. We just saw a different one back in November.
22 thoughts on “Ride, Captain, Ride Aboard Your Arduino-Controlled Autopiloted Sailboat”
why would a mechanical engineer seemingly use a cardboard box as an enclosure?
I had a lead programmer once tell me after a week of beating my head against GUI issues I was having with Drupal, “make it work, make it work better, THEN make it pretty.”
I love the “Although functioning, parts of it are still packaged in a prototypical way. ”
way to go!
Exactly what I envision a terrorist’s one-time-use device would look like. :)
This is great for drug smugglers ;)
I like the title, but now the song will be haunting the rest of the day… B^)
Why would a PC based solution be ‘out of reach’? I don’t think it’s a monetary problem, old PCs are so common someone might actually pay you to take it! Maybe the interface? Get one with a parallel port and it can’t be that much different than the GPIOs of an Arduino. The language? Arduino is basically C++, PCs use any language you prefer, including C++.
I think the Arduino is a better choice but I am curious why a PC solution was “out of reach”.
Raspberry pi uses less power than the Mega board.
not sure about using TWO megas but good job.
I built a similar system for controlling a trolling motor (very similar to Minnkota auto pilot). I had to use two arduinos because the serial interrupt while reading GPS data disruptive to the entire system.
Chris is right about the two Megas. The GPS cycle time is 1 Hz whereas the IMU is operating at 50Hz. Once a second the Main mega recieves the GPS update in a few milli seconds. I am working to add a third Mega to provide a remote control over a single cable with serial data transfer.
In the spirit of open software which is at the heart hacking is the idea of using and crediting the source. I would like to see that Bill Bishop whose blog The Marine Installers Rant, http://themarineinstallersrant.blogspot.com/ be credited as the original author for the material in this Hack A Day blog.
Such a waste of hardware
Want to expand on that a little? In what way is it a waste?
If you can afford a Nordic 40, you can afford a proper Raymarine autopilot IMHO. This would be great for those of us with smaller boats that don’t have 100G to blow through on a 40 footer though.
Just because you could afford something once doesn’t mean you can continue to. Perhaps circumstances changed, perhaps he could barely afford it, or perhaps he has other financial obligations. I wouldn’t leap to conclusions
or he just wanted to…
The boat is 31 years old. Pretty sure it never cost 100G.
Never owned a pit you throw money down (boat), eh?
Here is the same model one year newer for $109,500 http://m.yachtworld.com/mobile/boats/1984/Nordic-40-2396149/Georgetown/ME/United-States
Some people will mortgage a larger boat to “live aboard” if their respective marina will allow it.
Someone needs to filk Sloop John B. into Sloop Wile E., and throw in some stuff about arduino, GPS and autopilot. http://songmeanings.com/songs/view/4885/
Jack has done a great job. I am not sure whether I would have the inclination to embark on such a project. However, I am currently re-writing the AutoPilot code to obviate the mega which handles the GPS..
I have a finite finite state machine handling the incoming GPS, and the GPS code no longer blocks the auto pilot code. In addition, the overhead to do the data transfer is now gone.
The have re-used the majority of the current GPS code,
In addition I am implementing alternative IMU components & optionsto work with the 9 DOF IMU that I have, so I have some work to do there still. I will attempt to keep the Polulu code.
Please be kind and respectful to help make the comments section excellent. (Comment Policy)