supertunaman edited this page Feb 21, 2011 · 5 revisions
Clone this wiki locally

It started with this RC boat (which doubles as a skimmer!) that my parents brought home. It's pretty pricey for something that is essentially a waterborne Air Hogs toy with a butterfly net affixed to it. I might believe $100 if Air Hogs weren't producing helicopters with video cameras on board for half the price. But hey, I'm no marketing mathematician (thank Dobbs), I'm just trying to hack in the functionality that $100 deserves.

Like everything during this project, I kept hardware pretty simple. I used a Boarduino (because that's what was lying around) and an RC remote matching the 27.145 MHz frequency. My mom (who owns the boat, and the pool, and the red velvet cake I just scarfed down) wouldn't let me pull apart the remote it came with (and getting a replacement from the company will set you back $23, the antenna is $5 extra), but fortunately I had another one lying around of the same frequency and sporting the same TX-2B IC found in many RC toys. It belonged to a tiny RC car perfect for annoying my dog. Despite the controller having the physical appearance of a mobile phone, it didn't take her too long to figure out that I was controlling the tiny device buzzing about her paws, so it stopped being fun.

Me, RC car? Certainly not, I'm just -- hang on, I have to take this.Me, RC car? Certainly not, I'm just -- hang on, I have to take this.

First I experimented to see which button caused the boat to do what, breaking nearly every bone in my index finger and thumb in the process (I had to see which way the propeller was spinning somehow!). The mapping was a bit odd, which comes as no surprise, considering this is a chipset designed for RC cars, but adapted to a boat. I worked it out to be like this.

  • Up - Left motor reverse
  • Down - Left motor forward
  • Left - Right motor forward
  • Right - Right motor reverse

and so I soldered wires to each pad and gave them digital pins on the Boarduino that made sense.

  • 8: Left forward
  • 9: Right forward
  • 10: Right reverse
  • 11: Left reverse

Now I have this mess. Mmmm, spaghetti hardware.

After writing a couple of arduino sketches like this and fixing a couple of bugs, it seemed to be working great, so I moved on to software.

I would like to know why pulling the pins LOW activates the motors, and HIGH shuts them off (hence the helper functions power_on and power_off). Any EE experts have a clue?