Its a rolling robot which you can control via Bluetooth. The inspiration for this project comes from (very very awesome) Sphero robots that are available on the market. I decided to make something of my own that rolls around.

Step 1: Design

Make a design

Guide Lines for the design:

The main Idea is to have a hamster in a wheel all around it.

Try to make a design such that the center of gravity of the main body is below the horizontal, so that it always comes to rest with the main body in the same orientation. That way no gyroscope needs to be incorporated in the design.

Make space for all the components that will be needed to make it work.

For my design, I chose a main body with pockets for the two motors, and space for the wires to go through to the arduino and the battery. I also made the main body to have space for bearings and then split the body in half to make it easy to print. I made the bearing supports detachable in case I needed to change them later. I tried to keep the design as modular as possible.

I used bearings for their weight and also because they would at as good passive wheels. You can choose to shift that around and have just one set of bearings on each side. You can even use wheels instead of bearings if you wish.

The idea is to have a robot with 4 wheels, two connected to the motor and two passive to support the robot.

Step 2: Gathering the Materials Needed

For my design, I required the following materials to build:

Gather the materials.

For this project I used,

1x Arduino Uno

1x L298N motor shield

1x HC 05 Bluetooth chip

2x Pololu geared motors (I used: https://www.amazon.com/gp/product/B00QC2J6TQ/ref=oh_aui_detailpage_o03_s00?ie=UTF8&psc=1 )

4x 28x8x7 mm skateboard bearings

1x portable phone charger for power (I used:

2x foam wheels (31mm Dia) (I used: https://www.amazon.com/gp/product/B000PE69MO/ref=o... )

1x 140 mm diameter Christmas ornament (Or you can 3D print your own Shells)

Some 5 mm thick wood to laser cut

Velcro (I used: https://www.amazon.com/gp/product/B000TGSPV6/ref=oh_aui_detailpage_o02_s00?ie=UTF8&psc=1 )

E6000 Epoxy glue


Clear tape

Plastidip (if you plan to 3D print the wheels or the outer Shell)

Jumper Wires (IDK how many, I didn't count. Just have a lot)

Access to soldering and drilling tools.

Software: Solidworks or any other CAD software

Arduino C++

Tera Term for Bluetooth communication

I used Fritzing as well, to make the circuits.

Step 3: Make Your Circuit

In my cicuit, I did not choose to do an RGB LED or the gyroscope (MPU 6050 chip) for simplicity. The robot worked just fine without those.

My circuit looked like the image below. If you want, you can include a gyroscope or an RGB led to make this design even cooler. The new circuit could look like the ones in the other images.

First I connected the motors to the motor shield.

Then I connected the motor shield to the power (the portable phone charger where it said 5-35 V) and the negative to the negative terminal. I stripped a male type A USB chord of its plastic and metal covering to conserve space. And then I soldered wires on it to connect it to the battery.

Then I connected 2 wires to the 5V output. One went to power the Arduino 5V pin. The other to the Bluetooth module. both their grounds connected to the ground on the motor shield.

Then I connect pins 3, 5, 6 and 9 to IN1, IN2, IN3, and IN4 to the motor shield. I chose those pins as they are PWM and they work with the L298N motor shield.

After that, I connected the Tx pin to the Rx pin on the Bluetooth module and vice versa.

The connection to the RGB leds or the gyroscope are shown in the other diagrams. I used 670 ohm resistors for the LEDs.

After making the circuit, I tested the circuit after connecting the Bluetooth with my computer. I used Tera Term software for serial communication between my Bluetooth and Arduino

Step 4: Start Building!

3d print the two halves of the main body and the bearing supports and the two half of the shell if you want to use 3D printed shells.

Glue the 2 body halves together and the bearing supports on the main body as depicted in the diagram. Let the epoxy cure.

While you wait, laser cut the wood (or machine it if you are a master!) and then glue it to the top of the main frame.

Set the main frame aside for now.

Next, very very carefully, drill 3 mm holes into the Dubro tires (if using them), as the Pololu motors have a 3 mm axle and the tires have a 1.2 mm hole. If you want to 3D print wheels, then I recommend using wheels with a big radius of curvature. Since 3D printed wheels have very little traction, you will have to spray those wheels with Plastidip or something else of the same nature. Repeat with the inner surface of the spherical shells for increased friction. I found this helpful.

Glue the wheels on the motor axle using superglue and test the circuit on the breadboard again.

Set aside.

Next, cut up the hooks of the Velcro into small (approximately) 1 in x 1 in squares and the stick them to the bottom of each of the 3 electronic chips.

Then we come back to the main body. Glue like sized Velcro loops on the wooden platform of the main body, such that the Bluetooth chip, the motor shield and the arduino can all fit together.

Next slide the motors into their slots. I personally wedged them in there using a folded piece of paper, but you can glue them there if you like it better.

Next I slid the battery in its slot and used a small strip of velcro to hold it there.

(Almost there)

Slide the bearings onto the bearing support.

The main robot assembly is now complete!

Now put the robot in the shell and see if it balances perfectly. If not, play with the position of the battery so that robot balances in the middle.

After that, put on the other half of the spherical shell, (and then tape it there if using Christmas ornaments).

Show off to your friends.

Step 5: Write Your Code

The code I wrote is available in the file above. I used Bluetooth communication on my computer. No additional libraries were needed. Although, you will need them if you decide o incorporate the gyroscope.

To set up the Bluetooth, upload the set up code to the arduino, then wait for the built in led (pin 13) to come on. You will now have 10 seconds to hook up the Rx wires to Tx and vice versa for the Bluetooth chip. After that, wait till the led starts blinking and the set up should be done. You can now connect you computer to the Bluetooth using the user name of ROBOT and password of 1234.

Now you can use the Bluetooth chip (HC 05) for Serial Communication between the arduino and the HC 05.

PS: Remove the Bluetooth connections on the Arduino pins 0 and 1 to upload any sketch to the Arduino. Reconnect after uploading.

Step 6: Possible Improvements

There is a lot to be improved in this design which I wish I had time to do.

You can improve the code to make the device turn while it is moving. Right now it only turns after stopping.

You can include the MPU 6050 gyroscope chip to get your acceleration values, and then integrate them to get displacement values of the robot, so that it keeps a track of its location. Then include a homing section of the code on the bot.

You can use a more powerful Lipo battery and make the bot go faster. It is limited by 5V right now, but the motors can take up to 12 V each. They have a top speed of 200 RPM. That would improve their speed. Right now, they move at about 1 rev/s. Which brings it to a top speed of around 3 cm/s or 0.11 kmph. This could be improved upon a lot.

great, you can build a BB8 now
<p>This is so cool! Thanks for sharing and welcome to the community! </p>

About This Instructable



More by Suvidhy:The Roll-Bot 
Add instructable to: