The goal of this tutorial is to help you begin programming with Python to control your Arduino robots with a Raspberry PI. We will go over the basics like installation and some simple examples to control your robot from a Python GUI from Raspberry PI.


Step 1: Parts List

In this tutorial we are going to use the following items :

1.   Raspberry PI ( with monitor, USB hub, keyboard, mouse,and WIFI Dongle)

2.   Arduino UNO or compatiable (USB cable)

3.   Wifi Router

Now when it comes to robot bases there are many kits available in size and complexity. In this tutorial I have decided on using this setup with a 12v battery that will give us long run times and high load capacity. And a power distribution board with regulated 12v and 5v power outputs that makes it easy to deliver power to our robot.

4.   Robot Base 

5. Motor Driver

6. Power Distribution Board

7. 12volt  7amp hr Battery
Cool will finish it soon but using ROS :)
<p>do you need an arduino uno R3 board module?</p>
<p>Second, are you using any type of fuse? </p>
<p>Hey. This is fantastic! I've always wanted to build a robot. Thank you. I'm sooo close. Just have a couple of questions that I'd love if you could help with. First What's the small piece connected to the switch section of the board in this picture? </p>
<p>Nice work! I'm trying to wrap my mind around how the R-Pi communicates to the Arduino though</p>
<p>In this case, the writer has the Arduino and RPI connected via USB. The pyserial library is used for the communication on the RPI side and the Serial library (hardware in this case) is used on the Arduino side.</p>
<p>Thank you for sharing. I did a search for raspberry pi robot tutorial and your instructable was at the top 3 links. I have a more genera unrelated question and I apologize for it: how do you guys come up with the funds for all these fun projects?</p><p>I'm looking forward to building a raspberry pi robot. Thanks.</p>
<p>Do u have the circuit diagram of this robot? If you have please share.</p>
<p>Very very nice! I like your style!</p>
<p>What kind of wire do I need to hook this all up? </p>
<p>We normally just use jumper wires similar to these:</p><p><a href="http://www.zagrosrobotics.com/shop/item.aspx?itemid=834" rel="nofollow">http://www.zagrosrobotics.com/shop/item.aspx?itemi...</a></p><p>You will probalby want some male-male and male-female</p>
<p>Nice work! I'm trying to wrap my mind around how the R-Pi communicates to the Arduino though. From the one image it's got a 5V connection to the Arduino, but there aren't any data connections from Pi to Arduino?</p>
<p>Hi Fells, there was a problem with the sketch provided. To make it work you will need to change <br><br>int r_motor_pwm = 10;</p><p>to </p><p>int r_motor_pwm = 3;</p>
<p>This depends on the version of the motor driver listed above or if a different motor drive is used. Always double check the data sheets or specs on your components/devices against your code to avoid any confusion during setup/operation.</p>
Thanks ZRob, That is very good advice. I had bought the exact parts linked to from you and it just is a little thing that tripped me up as a beginner. I wanted to make sure any other inexperienced people would be able to find the problem easily.
This works sweet! Have you tried to run it with NetIO on an Android or Iphone device?
Zrob thanks for helping a 50 year old realize his bot dreams!! I have been hitting a brickwall with this project for 6 months!! Unfortunatley my wife is screaming at me for yelling ITS ALIVE!!! at 1:00 am!!LOL II now realize why the villagers actually destroyed Dr. Frankenstein's lab. Any way to program the button control to an android tablet or phone? <br>
Great instructable! I think I'm gonna try this as I have all the parts on hand. Do you know how one would go about adding live video streaming to something like this? I have a camera module on the way and also a compatible webcam. Though I wasn't impressed with the usb webcam performance.
Thank you for your post, I was blocked with the python part of my project and you give me some robust base to begin my learn :-)
Wow this is so awesome! I just got a Raspberry Pi and I have been wanting to use it for robotics. Thank you for taking the time to put this together I know it will be a big help to me!

About This Instructable




More by ZRob314:Piano Pi - Play a Duet With Your Pi! Raspberry Pi Touchscreen Setup Times Square in your living room!   Turn your Sense Hat LED into a news ticker. 
Add instructable to: