0

November 14, 2014 AT 4:00 am

How to Connect Arduinos to a Raspberry Pi with I2C #piday #raspberrypi @Raspberry_Pi


NewImage

From LegoMindstormsRobots.com:

I’m intending to use several Arduino Boards as a cheap means of controlling a number of RFID Readers which will be used to detect the position of Locomotive Engines on my LEGO Train Layout. That said I need a way of connecting these Arduinos to the Raspberry Pi which is the Master Controller for the layout.

The easiest way of Connecting an Arduino to a Raspberry PI is using USB, however the PI’s USB ports are need for WiFi Keyboard, Mouse, etc. So in many cases USB is out, especially if you are using a Raspberry Pi Model ‘A’.

Then there is RS232 which both support, however the PI runs on 3v3 whilst most of the Arduinos (UNO & Mega) use 5v, so one needs to add a ‘Level Converter’ between the two devices. It also limits you to just one Arduino and if you need to use more than one, another solution is needed.

Enter I2C
Both the PI and Arduino support two additional types of communication for talking to peripheral devices. First there is SPI which is a high speed serial protocol, and I2C. Like RS232, SPI needs level shifters, but this is not exactly the case for I2C.

Read more. Don’t forget to read read the warning!

NewImage

NewImage


998Each Friday is PiDay here at Adafruit! Be sure to check out our posts, tutorials and new Raspberry Pi related products. Adafruit has the largest and best selection of Raspberry Pi accessories and all the code & tutorials to get you up and running in no time!

Check out all the Circuit Playground Episodes! Our new kid’s show and subscribe!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Learn resistor values with Mho’s Resistance or get the best electronics calculator for engineers “Circuit Playground”Adafruit’s Apps!


Maker Business — Lessons Learned Scaling Airbnb 100X

Wearables — ABS ABC

Electronics — When do I use X10?

Biohacking — VICE Reviews The Internet’s Top Five Nootropics

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !



No Comments

No comments yet.

Sorry, the comment form is closed at this time.