Loading...
Welcome,
Guest
. Please
login
or
register
.
May 23, 2013, 04:47:32 am
|
Arduino Forum
::
Using Arduino
::
Project Guidance
:: I2C help
« previous topic
next topic »
Pages: [
1
]
Go Down
Print
Author
Topic: I2C help (Read 186 times)
0 Members and 1 Guest are viewing this topic.
No1Daemon
Offline
Jr. Member
Karma: 0
Posts: 84
I2C help
«
on:
January 12, 2013, 04:01:07 pm »
Bigger
Smaller
Reset
Hi there
I am connecting an HMC5883L to I2C and also an MMA7660.
I am a bit confused, I know the Arduino Uno I am using has pull up resistors already but I have read that you need to add them to the bus.
I am using 2 I2C devices so I planned to use the same 2 10K pullup resistors for both devices.
How do I connect this? Diagrams arent my thing and I am slightly confused by the use of VD0 and VCC when I am searching.
I know it is connected
Arduino GND -> HMC5883L GND - MMA7660 GND
Arduino 3.3V -> HMC5883L VCC
Arduino 5V -> MMA7660 VCC
Arduino A4 (SDA) -> HMC5883L SDA - MMA7660 SDA
Arduino A5 (SCL) -> HMC5883L SCL - MMA7660 SCL
And the resistors are added between VCC and SDA and VCC and SCL.
The confusion arrives because I am using one device that connects to 3.3v and 1 that connects to 5v.
Is there a Fritzing diagram somewhere or can someone show me an image of the solution because I have looked at google searches etc and if I do it the way they suggest it seems to me that SDA,SCL,3.3v VCC and 5v VCC will all be connected together. Wont this affect the voltage that goes to each device? ie the HMC5883L may receive 5V instead of the 3.3V in the data sheet
*Edit
So far I am trying just connecting both SDA and SCL lines through pull up resistors to the 3.3v VCC
That seemed to work well
«
Last Edit: January 12, 2013, 11:48:41 pm by No1Daemon
»
Logged
skyjumper
Smithfield, Rhode Island
Offline
God Member
Karma: 2
Posts: 825
Re: I2C help
«
Reply #1 on:
January 13, 2013, 02:55:33 am »
Bigger
Smaller
Reset
Sometimes the devices are tolerant, you can check the datasheets. Typically, though, you need a "level shifter" to bridge the 5V and 3.3V. This app note shows a good way to do it, and there are other ways:
http://ics.nxp.com/support/documents/interface/pdf/an97055.pdf
Logged
No1Daemon
Offline
Jr. Member
Karma: 0
Posts: 84
Re: I2C help
«
Reply #2 on:
January 13, 2013, 03:12:46 am »
Bigger
Smaller
Reset
Thankyou for that.
You learn something every day.
Much appreciated.
Logged
Pages: [
1
]
Go Up
Print
« previous topic
next topic »
|
Arduino Forum
::
Using Arduino
::
Project Guidance
:: I2C help
Jump to:
Please select a destination:
-----------------------------
General Category
-----------------------------
=> General Discussion
-----------------------------
Using Arduino
-----------------------------
=> Installation & Troubleshooting
=> Project Guidance
=> Programming Questions
=> General Electronics
=> LEDs and Multiplexing
=> Displays
=> Audio
=> Motors, Mechanics, and Power
=> Sensors
=> Networking, Protocols, and Devices
=> Interfacing w/ Software on the Computer
-----------------------------
Topics
-----------------------------
=> E-Textiles and Craft
=> Robotics
=> Science and Measurement
=> Home Automation and Networked Objects
=> Device Hacking
=> Education and Teaching
=> Interactive Art
=> Product Design
-----------------------------
Development
-----------------------------
=> Suggestions for the Arduino Project
=> Other Hardware Development
=> Other Software Development
-----------------------------
Community
-----------------------------
=> Website and Forum
=> Products and Services
=> Gigs and Collaborations
=> Workshops and Events
=> Local Groups
=> Exhibition / Gallery
=> Bar Sport
-----------------------------
International
-----------------------------
=> Deutsch
=> Español
=> Français
=> Italiano
=> Portugues
=> Scandinavia
-----------------------------
Forum 2005-2010 (read only)
-----------------------------
===> Uno Punto Zero
===> Bar Sport
===> Frequently-Asked Questions
===> News
===> Exhibition
===> Workshops
===> Interfacing
===> Bugs & Suggestions
===> Development
===> Troubleshooting
===> Portugues
===> Deutsch
===> Español
===> Français
===> Italiano
===> Scandinavia
===> Development
===> Interfacing
===> Syntax & Programs
===> Bugs & Suggestions
===> Troubleshooting
===> Report Spam at Arduino.cc
===> Forum
===> Playground Wiki
=> General
=> Hardware
=> Software
=> International
=> Web/Forum/Email/Spam
-----------------------------
Using Arduino
-----------------------------
=> Storage
=> Microcontrollers
-----------------------------
International
-----------------------------
===> Humor y Debate
===> Talleres, Encuentros, ...
===> Tutoriels et cours
===> Réalisations et Projets Finis
===> Le bar
=> Nederlands
===> Software
===> Hardware
===> Proyectos
===> Documentación
=> India
===> Hardware
===> Software
===> Megatopic
-----------------------------
Products
-----------------------------
=> The Arduino Starter Kit
=> Arduino Due
-----------------------------
International
-----------------------------
===> Generale
-----------------------------
Products
-----------------------------
=> Arduino Esplora
=> Arduino GSM Shield
-----------------------------
Maker Faire Rome - The European Edition
-----------------------------
=> Makers
=> Events and Tour
Loading...