A Titantic Undertaking

First off, there’s going to be a lot of puns on these pages, and I won’t apologise for them, so here goes…

The project is called roboboat, and it’s essentially a robotic sailboat. Yes, sailboat. I know, cool. I thought so too. I’m the software guy, I think. I’ll be working with a postgrad computer scientist and some engineers. (I know, but I can’t hold it against them, since, like Somali pirates, they have the yacht and aren’t likely to give it to me.)

The project as I see it, is as follows:

There will be some sensors to determine variables like wind velocity and the velocity and pitch of the yacht, which is a one meter model of a large sailing yacht.

There will be some motors to keep the mainsheet taut and a servo to control the rudder. Depending on the model yacht, another may be required for the centre/dagger board. To keep the boat balanced, either a weight attached to a servo or a liquid pumped from side to side can be used as the equivelent to a sailor hanging off the side. I’ll need to speak to the engineers working with the physical boat to see what’s needed there.

The motors and servos will be controlled by an Arduino microcontroller with a fitted motor shield. It can easily handle the required number of motors and servos and has accurate timers and lots of pinouts. You programme for it in C, with lots of nice libraries available. It’s own supplied compiler then converts it to machine code. I have had the misfortune of working with gumstix and robostix before, and while they have significantly more processing power, they are not very user friendly. Sure they can do the maths fast, but trying to talk to them is painful. Arduinos are eager kids. They do what you want, when you want it, as long as it’s simple enough to be explained in crayon. In that respect, they’re similar to the copywriters of the News of the World.

For an added challenge, try to read the original:

J ibwf ibe uif njtgpsuvof pg xpsljoh xjui hvntujy boe spcptujy cfgpsf, boe xijmf uifz ibwf tjhojgjdboumz npsf qspdfttjoh qpxfs, uifz bsf bvujtujd qspejhjft. Tvsf uifz dbo ep uif nbuit gbtu, cvu uszjoh up ubml up uifn jt qbjogvm. Bsevjopt bsf fbhfs ljet. Uifz ep xibu zpv xbou, xifo zpv xbou ju, bt mpoh bt ju’t tjnqmf fopvhi up cf fyqmbjofe jo dsbzpo. Jo uibu sftqfdu, uifz’sf tjnjmbs up uif dpqzxsjufst pg uif Ofxt pg uif Xpsme.

I’m not sure yet if there will be a need for a gumstix on the boat, or if I can unload the maths to a landlubbin’ computer. Actually, I’m not 100% sure of anything in this project yet, except that I need to obtain an eighteenth century Royal Navy Admiral’s hat, and fast. I’m not sure appropriate headdress will count when grading, but it can’t hurt to show commitment.

Now, down to the knitty-gritty that every computer scientist purports to revel in but secretly can’t stand. The maths. The environmental forces acting on a sailing vessel are quite complex. The idea for this yacht is to have it sailing around UCD’s lake autonomously, which has very flat water and no currents. That’s nice because currents and waves and bad weather requires a human sailor, that beast I’m trying to obsolete, to have a good feel for the boat. How a boat “feels” is going to be hard to ascertain with limited sensors, so sailing on flat water will is a real advantage. That’s an assumption though, and anyone who’s met assumption’s children knows how dangerous getting in bed with her is.

Even if I do hop in with her, there’s still a lot going on, though. The basic problem is:

  1. Find yacht velocity.
  2. Find wind velocity.
  3. Adjust rudder to correct yacht velocity’s direction component.
  4. Adjust sail to obtain maximum force from wind engaging the sail.
  5. Goto line 1.

There’s other things to take into account, like controlling the speed of the yacht by loosing and tautening the mainsheet, the effect of the jib, the use of the centre board, actually working out the yacht’s position and how to beat, or sail upwind.

This is not to mention the physics of the sail, which is actually an airfoil, which generates lift, not dissimilarly to a wing.

I’m thinking that I will have to:

  1. Write control systems for the boat (and possibly build them) (codename: Engine Room)
  2. Write a control loop for the microcontroller to:
    - Read in sensor data (codename: Crow’s Nest)
    - Process data or send it to shore for processing (codename: Captain On Deck)
    - Set the pinouts (codename: Helmsman)
  3. Write a shore based interface (codename: Haulbowline)
  4. Work out how to wirelessly talk the yacht (codename: Semaphore)
  5. Test (codename: Sea Worthy)
  6. Goto line 5.

How it actually shapes up remains to be seen, I’ll sea you later (pun intentional). - D.N.T. (01/10/08)

Wednesday, October 1st, 2008 Roboboat

No comments yet.

Leave a comment