How to Use and Arduino Shield With the Raspberry Pi
by dexter_industries in Circuits > Raspberry Pi
37713 Views, 101 Favorites, 0 Comments
How to Use and Arduino Shield With the Raspberry Pi
![front.gif](/proxy/?url=https://content.instructables.com/F6A/Z0TD/HY7TBV3O/F6AZ0TDHY7TBV3O.gif&filename=front.gif)
Adding Arduino shields to the Raspberry Pi can be a very big pain. You end up having a mess of wires running around and setting up the software is a challenge in it's own right.
Here is a simple solution to start using your own Arduino Shields with the Raspberry Pi in under 10 minutes.
Parts Needed
![parts.JPG](/proxy/?url=https://content.instructables.com/F43/S9B7/HY7TBVSF/F43S9B7HY7TBVSF.jpg&filename=parts.JPG)
- Raspberry Pi
- Arduberry
- Any Arduino shield (we are using a Dexter Industries GPS shield for example)
- An SD card with Dexter Industries Raspbian Image
Connecting the Arduino Shield to the Raspberry Pi
![assembly1.JPG](/proxy/?url=https://content.instructables.com/FHW/X3OD/HY7TBVJD/FHWX3ODHY7TBVJD.jpg&filename=assembly1.JPG)
![assembly2.jpg](/proxy/?url=https://content.instructables.com/FJQ/P739/HY7TBVMB/FJQP739HY7TBVMB.jpg&filename=assembly2.jpg)
Place the Arduino GPS shield over the Arduberry and mount the Arduberry on the Raspberry Pi GPIO headers. Now turn on the Raspberry Pi.
Add the Library
![lib.JPG](/proxy/?url=https://content.instructables.com/F7C/1JVT/HY7TBRCW/F7C1JVTHY7TBRCW.jpg&filename=lib.JPG)
![add_lib.JPG](/proxy/?url=https://content.instructables.com/F6O/WCQN/HY9Y0SF7/F6OWCQNHY9Y0SF7.jpg&filename=add_lib.JPG)
Now download the Arduino GPS library from here:
sudo wget http://dexterindustries.com/files/dGPS_Example_3.... -O /usr/share/arduino/libraries/dGPS_Example_3.zip
Now unzip the library at /usr/share/Arduino/libraries:
sudo unzip /usr/share/arduino/libraries/dGPS_Example_3.zip
Upload the Code to the Arduberry
![open_arduino.JPG](/proxy/?url=https://content.instructables.com/F27/L27S/HY7TBRD3/F27L27SHY7TBRD3.jpg&filename=open_arduino.JPG)
![upload.JPG](/proxy/?url=https://content.instructables.com/FWW/IMGQ/HY7TBRFP/FWWIMGQHY7TBRFP.jpg&filename=upload.JPG)
Open Arduino IDE from Start -> Electronics -> Arduino IDE, and open the example from File -> Examples ->dGPS_Example_3. Change the programmer, Tools->Programmer->Raspberry Pi GPIO and upload the sketch to the Arduberry(use Ctrl+Shift+U to upload).
Print the Data From the Arduino Shield to the Serial Monitor
![serial_out.JPG](/proxy/?url=https://content.instructables.com/FIH/JM3K/HY7TBRFZ/FIHJM3KHY7TBRFZ.jpg&filename=serial_out.JPG)
Select the Serial Port, Tools->Serial Port->/dev/ttyS0 and click on the Serial Monitor button to start receiving the data.
Check out the Arduberry Page for more information and interesting projects.