Inter-Integrated Circuit (I²C) is a bus for low speed peripherals. Use this tag for questions regarding how to use I²C with an Arduino, or for problems with I²C and your Arduino.

learn more… | top users | synonyms

0
votes
0answers
14 views

Basic communication between Cotek and Arduino UNO

so I am trying to get a reading from my Cotek through my arduino and have it display on an LCD screen. When I run the code, though, nothing shows up. I am EXTREMELY new to using pretty much all this ...
0
votes
0answers
43 views

Protocol options for data exchange between Arduino and ESP8266

I have a device built with an Arduino uno: Arduino software installed on an Arduino uno can be controlled via serial commands can be controlled via physical buttons and sensors on any button/sensor ...
0
votes
1answer
41 views

ESP8266 as i2c client

I've got an ESP8266 that takes instructions from a web page and sets a series of NeoPixels to flash in different sequences. I noticed that when the WiFi got data and parsed it, my LEDs would "stutter" ...
0
votes
0answers
21 views

Use AS3935 with I2C?

Has someone experience with interfacing the AS3935 lightning sensor using I2C? I found a library but it only works with SPI as far as I can tell. I really don't want to give up 4 pins for SPI as I ...
0
votes
1answer
24 views

How to wirelessly communicate with I2C infrared thermometer

I've been getting involved with arduino recently as a means of improving a heating device which is quite small, a box about 15x10x5cm which I would like to rig with an MLX90614 infrared sensor. The ...
0
votes
1answer
23 views

Arduino messing up as slave over i2c

So I have an Arduino Mega2560 and a Raspberry Pi hooked up through i2c. The pi is acting as the master while the Arduino is the slave. While sending data over I2C the int message gets messed up and ...
0
votes
1answer
31 views

unresolved overloaded function type for Wire.onReceive

I am attempting to make an I2C slave out of my Arduino and I can't get past the Wire.onReceive function. Here is my code. The documentation says to just add a function that has the style of void ...
0
votes
1answer
53 views

MCP23017: 16x2 LCD showing black boxes

I've researched a lot but I couldn't find a solution to my problem, which is that after properly following all steps from this Website: ...
0
votes
1answer
26 views

Use TSL2561 and DS1307 RTC together

I want to use a TSL2561 light sensor and a DS1307 RTC and a couple of other sensors like DS18B20, AS3935, ML8511, MQ135, 433 mhz sender together with an Arduino. However on Adafruit I read this today ...
1
vote
1answer
73 views

Arduino Due and BNO055 address in i2c mode

I have a project where I need to have several IMUs, the BNO055 shuttle board (I explained my project here), I manage to get the Euler angles from one BNO055 sensor, which have the address 0x29, ...
1
vote
1answer
41 views

Using union to return a range of bits from a data frame: wrong approach?

I'm working on an adaptation of Jason Leyrer's Guitar Hero Library for Arduino. My version is for a DJ Hero controller, and I've also borrowed some code from this Arduino forum thread: topic=120527 ...
1
vote
1answer
72 views

Software I2C - Atmega8

I am using Atmega8 with 12MHz crystal, on my breadbord. I can use SDA and SCL pins with default arduino library wire.h, and it works. But I want another pins to use I2C protocol. I tried library, ...
0
votes
0answers
224 views

How to Connect new OV7670 FIFO to Arduino?

I bought a new OV7670 FIFO camera to connect to my Arduino UNO a few days ago. The picture of the cam board: I found this forum, it is nice try but it look chaotic and confusing with about 50 ...
0
votes
2answers
60 views

How do you send data via I2C without the wire library?

I have the following digital potentiometer: DS1803-100 which, according to the datasheet, can be controlled using a two-wire serial interface. I have managed to get it working using Wire, however I ...
0
votes
2answers
128 views

Disabling i2c internal pull up resistors

How do you do this? I've been digging around and I can see that I should do this and supply my own external pull up resistors but I don't know exactly how to disable them. The pages I've been reading ...
1
vote
2answers
43 views

Array values won't tokenize

char *p = I2CinBuffer; // array contains "string" "," "string" but char *p = I2CinBuffer; // The data to be parsed e.g. 6,100 char *str; // Temp store for each data chunk int count = 0; ...
-1
votes
2answers
63 views

coding problems

I'm working on a Arduino controlled solenoid motor project that I found on Instructables. I have been able to piece together what I think is most of the code but I'm getting some syntax errors and was ...
-2
votes
3answers
58 views

Radar depth sensor for surface

Is there any sensor than can capture surface at one time (so that I could get matrix of distances to the points on some surface)? I think that moving one sensor across surface like in this is bad idea ...
0
votes
4answers
84 views

Can't detect I2C displays with arduino nano

SCL - A5 SDA - A4 VCC - 5v GND - GND All cables tested and work .. Im using an arduino nano board and an I2C display - Ive tried everything to get it to work and im now convinced its a hardware ...
0
votes
1answer
27 views

Trouble making TMP102 work with any ADD0 other than ground

I'm trying to get an Arduino Uno to run four sensors (all I2C). The first two are TMP102 temperature sensors. The address is controlled by tying the ADD0 pin to GND, VCC, SDA, or SCL (four possible ...
1
vote
2answers
63 views

How do I use two I2C LCDs with 4 pins?

I have two I2C LCD screens: one with 2 lines one with 4 lines. Both have 4 pins each: GND, VCC, SDA, SDL. I connect SDA and SDL to A4 and A5 respectively, and I display text on each one of them ...
0
votes
2answers
87 views

arduino I2C maximum number of writes per Transmisson

Is there any limit on the number of Wire.write() commands consecutively in between the Wire.beginTransmission() command and the Wire.endTransmission() command for the Arduino Wire library?
0
votes
1answer
74 views

How to use an PCF8574P with the simplest code possible

i'm having few PCF8574P which i want to use with my arduino and multiplex them however i have no idea how to use the I2C BUS and the IC in general. There are few libraries but they're fairly complex. ...
0
votes
0answers
31 views

I2C with an arduino, a PI and an IO expander

im working on a project which requires alo i/o pins. For that reason i bought a pcf8574P 8bit I/O expander which uses the I2C protocol. The problem is how to combine the Rasp PI and the arduino. For ...
0
votes
1answer
111 views

Reading data from airspeed v3 eagle tree

I am trying to get values from this sensor Airspeed v3 from eagle tree but it seems my I2C is not working properly. I bought a module in third party mode and followed these instructions from the ...
1
vote
2answers
139 views

Conflict between OneWire and I2C?

I have two Arduino boards and I want to make them communicate via I2C. The first board (slave) should read a temperature value from a DS18B20 sensor (OneWire) and send it to the second board (master) ...
0
votes
1answer
176 views

Alternatives to Wire library for I2C

I am looking for (reasonably easy to use and well tested) alternatives to the Wire library. Wire works very well, but: I only need the Arduino to act as I2C master and the Wire library seems to be a ...
0
votes
0answers
30 views

Receiving multiple bytes from an RPi using the i2c protocol

Trying to send bytes from an RPi as a master to an arduino as a slave. The send uses the write_byte(addr, value) function and seems to be working perfectly. The arduino however has issues with ...
0
votes
2answers
53 views

#ifdef / #include CPP issue

I'm developing a sketch which I need to run on an Uno (for debug) and a Gemma (as the target). Adafruit has their own Wire library (TinyWireM) which I was planning on using on the Gemma. Thus, I was ...
0
votes
0answers
146 views

Arduino LCD 2x16 and PCF8574AP works well for limited time

I have got a problem with operating my typical 2x16 LCD with PCF8574AP. I have read the entire internet about that, other topics etc. but none of them can relate to my problem. The thing is that my ...
0
votes
1answer
72 views

LCD Display hangs the computer

I'm trying to connect 16x2 LCD screen to clone Arduino UNO via PF8574T backpack. 4 cables are connected to +5V, GND, SDA and SDL pins. When I tried this I2C scanner code from arduino.cc. It returned ...
0
votes
1answer
341 views

Do I need Kalman Filter after I read DMP data on MPU6050?

In my project I need to use as noiseless as possible data from a MPU6050, I do have some nice DMP data, what will happen if I apply Kalman filter above it? Will I get more noiseless data? Or will it ...
0
votes
0answers
40 views

Getting inverse values of acceleration and tilt for the MPU 6050

I'm using the I2C library to connect to a GY-521 board and, when executing the getAcceleration() methods I get gyro values and viceversa.. This is my setup (I'm using a proto shield but that ...
0
votes
0answers
91 views

Unexpected Timer Conflicts (Uno)

I've been working on a project (Arduino Uno: Atmega328) that implements a gyroscope (which is used with the LSM9DS0 spark-fun library) that is communicated with through I2C and uses a Servo library. ...
0
votes
2answers
90 views

Multiple interrupt lines connection

in my project need to connect more then 10 I2C sensors(MPU 6050) to Arduino Mega and each sensor an interrupt line is essential. Since in Arduino it only got several interrupt slot(digital 2, 3, ...
1
vote
1answer
138 views

16 bit register addressing through i2c

Note: I'm using just the atmega chip and atmel studio. Not exactly a full arduino. I have been using the atmega168 with a MAX17040 fuel gauge in a project. The I2C interface between the atmel and the ...
0
votes
0answers
84 views

How do I use I2C from an Arduino Uno when I have a GSM shield mounted?

This may be an extremely obvious question but I don't seem able to find a definitive answer. I have an Arduino Uno and a Sim900 GPRS/GSM shield fitted on top of it. I had I2C working on the Arduino ...
0
votes
1answer
166 views

pcDuino 3B Wire library errors

I recently purchased a pcDuino 3B and I am very pleased with the Board so far. I can use the preinstalled arduino IDE to program the board from the board and run programs. However, when I came to use ...
2
votes
1answer
131 views

I2C or SPI to control 6 motors?

I am a hobbyist & know little about electronics. I am making a robot arm, like this one. For which I will need 2 stepper motors (for elbow & shoulder joint) & 4 simple DC motors. Which ...
1
vote
2answers
183 views

Arduino Uno (master) and ATTiny85 (slave) I2C connection not working

I am trying to send and receive data using I2C between an Arduino Uno and an ATTiny85. The Arduino Uno is using the Wire library. The ATTiny85 is using the TinyWire library and is programmed (and ...
0
votes
2answers
212 views

Using I2C: Master Reader and Writer

I'm using I2C and the Arduino Library (Wire) to communicate between two Ardunios, and my code isn't working. It's supposed read in an int from the slave, write a value to the slave, then read back ...
2
votes
2answers
74 views

If I have a group of Arduinos connected via I2C, can one Arduino cause the rest to freeze?

I have a group of four Arduino boards connected via I2C. One is the master, which sends and receives values from all of the others. I noticed that the Master will stop executing its loop if power is ...
1
vote
2answers
133 views

I2C TinyWireS SEND: How to convert unsigned long to uint8_t array?

How do you convert an unsigned long to a uint8_t array? I am interested in sending an unsigned long integer from an ATTiny85 to an Arduino Uno via I2C. The issue is with TinyWireS.Send() which can ...
0
votes
2answers
543 views

Reading I2C sensors with a timer interrupt

I would like to read a sensor connected via I2C using Timer3 and Arduino Mega. Values are read from the sensor in the interrupt service routine and timer3 is set to trigger an interrupt at 200Hz. ...
1
vote
1answer
110 views

Bizarre compilation problem — only compiles with the addition of a single Serial.println() line?

I have a SwitchDoc Labs DS3231 Real Time Clock Module that I am using with an Arduino Mega. It's connected to 3.3V and the SDA(20)/SDL(21) pins. I'm also using SwitchDoc's RTC_SDL_DS3231_ARDUINO ...
2
votes
1answer
388 views

I²C between ATTiny85 (8MHz) and Arduino Uno

I keep receiving the following error in myATTiny85-Slave code below: sketch_mar12a.ino: In function 'void setup()': sketch_mar12a:19: error: 'class USI_TWI_S' has no member named 'onRequest' ...
0
votes
1answer
394 views

How to change i2c address for mpu9250?

I'd like to connect 12 mpu9250 sensors to one arduino board. I can't find documentation on how to change the addresses of mpu9250 boards. (i read through the reference ). Some tutorials talk about ...
1
vote
1answer
185 views

How does the Arduino send more than 6 bytes via I2C

I have been working with the wire library (I2C) to send data from one Arduino to another. I read that the Arduino can only send 6 bytes per cycle, but I have been able to transfer much larger ...
1
vote
1answer
1k views

How do I send a string to master using i2c

I want to write an Arduino program that simply recieves a string (via the I2C wire library) from a master Arduino, then waits for a request, and sends that string back. Here is my code: #include ...
1
vote
0answers
41 views

Interfacing accelerometer LSM303DLH with Arduino UNO using I2C

I am trying to connet a tri axis accelerometer LSM303DLH to arduino UNO using the libraries taken from the following links (https://github.com/adafruit/Adafruit_LSM303DLHC and/or ...