Introduction: Lego Car/tank, Arduino Meets Android

Picture of Lego Car/tank, Arduino Meets Android

What is it?

A lego-car controlled by the acceleremoter sensor on an android-device through bluetooth.

Whats needed?

1. A lego-car with two engines, one driving the two wheels or track on the left side and the other motor driving the two wheels or track on the right. It will turn like a tank.

2. An arduino uno with a motorshield.

3. A bluetooth module, I used the HC-06 RS232 found on ebay.

4. A 12 volt battery pack used both for arduino and the motor shield. I used a 900 mah 3s lipo which is about 12v.

5. An android phone.

Step 1: Build the Lego-car

Picture of Build the Lego-car

I have no specific instructions for the lego tank. But I have used I used "12V 300RPM 24mm Diameter Matel Speed Geared Box DC Motor ZGA25R-370" found on ebay and used two screws to connect it to the lego part as showed on the picture.

Hot glued some lego parts to the arduino uno and the battery

Step 2: Software

1. Upload the arduino sketch to your board found here:

https://codebender.cc/sketch:285565

Use codebenders site and plugin to upload this sketch to your arduin.

2. Install either the Amarino_2.apk and the AmarinoPluginBundle.apk from

https://code.google.com/archive/p/amarino/download...

or use attached MIT app inventor 2 app also found here:

http://ai2.appinventor.mit.edu/#5066448020176896

Click gallery on the app inventor site and search for "bt_4wd_car"

Step 3: Connect All the Devices

Install the motorshield on the arduino Uno and connect the two motors and the battery.

Connect the bluetooth to the arduino:

tx > rx

rx > tx

ground > ground

vcc > 3,3 volt on the arduino (note that you have unplug the bluetooth module when you want to upload a new sketch to your arduino)

Done!

Comments

About This Instructable

448views

4favorites

License:

More by Joel H:Lego car/tank, arduino meets androidMud flap for bike fender
Add instructable to: