Sep 13, 2007

Serenity, a robotic LEGO boat

I actually started wondering about LEGO robotic boats a while back, when some threads on the NXTasy forums brought them up (as well as submarines). There were two main problems I could see for a "pure LEGO" water-craft: (1) Flotation (which could perhaps be solved by LEGO boat hulls, which re-entered the LEGO scene in a number of recent City sets, such as the Fireboat (#7906), City Harbor (#7994), and the Speedboat (#7244)), and (2) Propulsion. I did not want to deal with the risk of rotating seals for propeller shafts etc., so I figured on having all the electronics (including motors) above the waterline, with the propeller drive shafts either entering the water at an angle, or being driven by pure mechanical linkages to a completely submerged prop. But upon getting two of the Fireboat sets for the hulls, I decided to try using the stock LEGO underwater motors that come with these sets.

The result was Serenity (posted on NXTlog), a pure-LEGO robotic (not remote controlled!) boat.

Two hulls are tied together with bow and stern beams, made from studded beams locked together with studless elements, resulting in beams that can not pull apart under tension or flexing (the connection to the boat hulls is unfortunately studs-only). The NXT and two NXT motors sit along the midline, not powering the vehicle but in this case only steering the stock underwater motors attached below. To make the vehicle float level in the water, the NXT is on two long axles and can be slide fore and aft to trim the vessel (no port-starboard trim was needed in this case). Mounting the underwater motors firmly to a mounting frame was one problem, but was solved with some half-stud offsets.

The program uses a Hitechnic compass, trimming the rear motor like a rudder to keep the nose pointed along the initial heading. After a specified time (configured at the start of the program), Serenity makes a 180° turn "in place" by steering both the bow and stern motors, and then again tries to maintain a new heading opposite the initial heading, returning to the shore.

The scary part was testing this. I tested first in a small tub of water on my back deck, but then it was time for a more realistic "sea trial", and lacking a swimming pool my only option was a small local pond, with weeds, swampy shores, and an active fountain in the center. I didn't want to use a tether, as that would really be unfair (not to mention the drag of the tether would likely cause problems with the autonomous navigation routine), so the first "live" test (yes, as seen in the video) was more than a bit nerve wracking - if it didn't turn around, I'd just have to hope it would hold it's heading long enough to get to the far side before wandering under the fountain. And if there was any more serious programming or mechanical issue, there was a good chance I'd get to watch a LEGO-version of the Titanic disaster. Hitting the button and letting go was... tense. But careful pre-testing held - it worked almost flawlessly, through four trials until the underwater motors completely fouled on weeds near the end of the last trial (thankfully, close enough to drift in towards the shore). Even when bumped off course, the NXT faithfully corrected the heading, and it always executed a beautiful 180° turnaround at the midpoint.



Not too bad for a proof on concept (I'd not known of JP's amazing craft at the time, nor thought to use the dirigibles like that... not that I had any handy). It clearly needs a more reliable (non-fouling) propulsion (sidewheels splash a lot, I've tried, but I've got other ideas), and for larger lakes and rivers it probably needs to be bigger (if you are smaller than the local waves, there's going to be problems). But I'm curious how far I can take this... that is, how far I can take this project before turning it into an unplanned submarine.

--
Brian Davis

7 comments:

Rick Rhodes said...

WOW,

Maybe it's the camera angle, but your electronics appear to be VERY close to the water. Not for the faint-of-heart.

Great job.

Rick

Brian Davis said...

The motors under the NXT are well clear of the water... almost 3 cm :-). As it stands, this is not going to work with significant waves. But if I make the base bigger (wider outriggers, longer fore-to-aft), then I could raise the (very heavy!) electronics further above the waterline. Move them too high, and they'll be very safe from splashes... but the boat is then far less stable to being flipped.

But I'd have to agree with you, not for the faint of heart. It's a realy leap of faith in your construction and programming skills when you hit "run" for the first time on open water...

--
Brian Davis

Robert said...

Very nice, and moves at a decent speed as well. I can't deal with slow things - speed, speed, speed.

Have you thought about a water jet system? don't know if there are parts to make one in ogel (don't like the restrictions on the use of L).

I remember a long while back somebody making a sub with RIS - not all ogel of course - now that is faith! I think you are taking too many risks by being pure ogel - maybe some protective plastic bags are in order.

Still, very nice.

Rob

Kirk Backstrom said...

Brian,

I like the turning mechanism.

Just a humble suggestion: to help protect the unit from sinking in an unfortunate event, you may want to add foam blocks in the outriggers.

Kirk

Brian Davis said...

It's even better than that: because the "deck" and "hull" snap together by a couple of "pillars" inside, the foam has to be really complexly cut... but if you fit holes in the foam for the pillars to run through, then the foam will float the boat even if the hull pieces detached completely. I agree, it's something I've got to add before I take it on to bigger lakes :-)

Good suggestion!

--
Brian Davis

BlueToothKiwi said...

Man - those City Fireboat propellers are really powerful.

A well designed boat - really well thought out. Well done Brian.

Kirk's idea is a good one. That what I did with SPIT during the trials. It makes it look less elegant - but you know what Murphy's law is like.

I am working on a new blog entry on 'How to rescue your NXT after water damage'! We would need it for this weekend for all the readers who want to try desgning somethig like what you have done!

P.S. I had a really good submarine that nearly worked (based on the old Chinese Diving Bell). I gave up when the winter started - but if you want to take it further, please get in touch and work together on it.

Tim

Michael said...

Hello Tim, you mentioned you were working on a blog "How to rescue your NXT after water damage". My son's LEGO RCX 1.o got modestly wet, and now does not respond, turn on etc. Help! My 6 year old son is as upset as me, do you have any repair advice.

Much appreciated.

Mike Sanio/Renzo Sanio Reston VA USA

Related Posts Plugin for WordPress, Blogger...