Questions tagged [i2c]

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.

103 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
1answer
102 views

I2C - Confusion

It's not often I ask a question. This one has me a little stumped though. Scenario: I have an 328PB (internal 8mhz), it speaks to a multiplexer on Wire1 (the PB's second IC2 - Minicore lib). The ...
2
votes
0answers
25 views

qMenuSystem using DigoleSerial library doesn’t work on my I2C Monochrome OLED

Just like the title says I’m trying to make qMenuSystem to work with my oled display. Here is what I know so far about my display : - It's a Monochrome OLED 128x64 (Blue) Display - It's connecting ...
2
votes
0answers
305 views

How to use SPI to set/ read registers for a sensor (Avoiding need for Github Lib)

Ok so as some readers might have seen, my current project involves using MPU's. The idea is sending data via CAN bus to a controlling MCU to then send to a raspberry pi to perform the calculations ...
2
votes
1answer
4k views

I2C libraries for ATTiny85?

I want to transmit I2C data, using a Digispark ATTiny85 board: http://digistump.com/products/1 http://digistump.com/wiki/digispark/tutorials/connecting I've found the following I2C libraries. Which ...
2
votes
0answers
3k views

Why is Wire.onReceive() called during requests?

I'm building a complex I2C-based networking protocol and have noticed that the Wire.onReceive() handler is called both for I2C read and write operations. When the master writes to the slave, it is ...
2
votes
1answer
121 views

Accelerometer (I2C) and Fona Shield (software serial) won't work together

I am using a Fona 808 shield with an Arduino Uno and the LSM303 accelerometer. The accelerometer is connected via I2C and the Fona uses software serial. My project requires the accelerometer to be ...
2
votes
0answers
431 views

Connecting arduino and EV3 using I2C

I'm trying to connect arduino uno and ev3 by using this guide (http://www.dexterindustries.com/howto/connecting-ev3-arduino/), everything works perfectly but when i tried to use analogRead block to ...
2
votes
0answers
640 views

Raspberry Pi, Teensy and Arduino's on i2c

I just got into an interesting mess. I have 3 Arduino's (Pro Mini's) and 2x Teensy's (3.1's) connected via I2C to a Raspberry Pi Master. The 2x Teensy's I2C data lines are connected via OctoBoards ...
2
votes
0answers
119 views

How can I send a number from a master and make the slave read it?

I am building a fan controller using an Arduino and a Raspberry Pi (the Pi is the master and the Arduino is the slave). The Raspberry Pi generates random numbers and I want the slave (Arduino) to be ...
1
vote
0answers
30 views

Can't get MMC3416xPJ to work

I needed a magnetometer with a high Output Data Rate (ODR). This is because I wanted to measure AC magnetic fields of around 20-80 Hz. So I decided to go with the MMC3416xPJ prototyping board which ...
1
vote
1answer
79 views

conflict with different i2c devices

I am trying to communicate with two i2c components using an arduino nano - some ADS1115s and some i2c flow sensors each connected to a different i2c multiplexer, but they seem to be conflicting. ...
1
vote
0answers
129 views

Is it possible to use I2C and SPI ons the same Clock line?

I'm trying to connect an I2C OLED display and an n RF24L01 WiFi module to an ATTiny85. But I only need 1 extra pin. Is it possible to use the same clock wire/pin for the I2C and SPI device? Maybe with ...
1
vote
0answers
46 views

STM32F103C8 - Arduino Mega FAST MODE(400000L) I2C communcation not working

I'm trying to connect a stm32F103C8 board (master) to an Arduino Mega (slave) over I2C. I have a master and slave program which runs perfectly fine when the clock frequency for I2C communication is ...
1
vote
1answer
395 views

Looking for light-weight Arduino OLED library that supports text and bitmaps

I'm trying to incorporate a screen into my Arduino code which is quite large already. The Adafruit SSD1306 library is overly large and has a lot of unnecessary things in it. I've found the ...
1
vote
0answers
318 views

How to read the busy flag on LCD?

I have a standard 16x2 LCD screen and I have it hooked up to my Arduino UNO via a I2C backpack (4-bit mode). Since I want to learn about the lcd at a lower level I’ve decided not to use the LCD ...
1
vote
0answers
401 views

I2C on ATtiny85 and Si4703 radio

I've got an Si4703 breakout from Sparkfun, which communicates via I2C. I have gotten it to work very easily using a regular 3.3V Arduino Pro Mini, but am now trying to move everything over to an ...
1
vote
2answers
700 views

I2C broadcast and reply on Arduino M0+

I am trying to set up several ATSAM-based AVR chips in a master/slave broadcasting arrangement. I want the master to be able to send a broadcast message to I2C address 0, and then for slaves to ...
1
vote
0answers
358 views

Connection between Arduino Mega 2560 , ESP8266-12F , PCF8574

Another start for achieving something new , I want to connect ESP8266-12F , Arduino Mega 2560 Board And the PCF8574 I/O Expander (I can use MCP23017 also) together , Where ESP8266-12F will take ...
1
vote
0answers
921 views

How to prevent Wire.requestFrom from hanging?

I'm trying to read data from an Arduino Uno I2C slave via Wire.requestFrom() on an Arduino Uno master. The slave's onRequest handler is simply: void I2C_Send() { byte myArray[4]; myArray[0] = ...
1
vote
3answers
2k views

Multiple VL6180X distance sensors interactive problem

I am trying to use a VL6180X distance sensor and an Arduino Uno board for individual sensor doing individual distance sensing. This sensor follows the I2C protocol. Since for the same type of sensor, ...
1
vote
0answers
41 views

Why am I only receiving the first address byte? (I2C Protocol)

Expecting the slave to ACKnowledge and return data, but it does not. This is my protocol. This is my Datasheet. Also FYI I'm on an Arduino Fio but I am not inheriting the Arduino library. #include &...
1
vote
0answers
245 views

Adafruit Trinket 3v with LED matrix backpack producing error

I have been wanting to create a Arduino watch. I built the circuit with an Adafruit Trinket 3v and an Adafruit LED matrix backpack (8*8). When I try to upload this example code: /*********************...
1
vote
0answers
135 views

Reprogramming a specific slave from the master ATTiny 85 (connected to IDE)?

Given that every ATTiny connected already has a bootloader (micronucleus) installed, here's my theoretical chain: Computer > Master ATTiny (Connected via USB) > ATTiny Slave A > ATTiny Slave B Is it ...
1
vote
0answers
177 views

Too many Bytes Using Ultrasonic Sensors

I need to send one transmission and record multiple distances with 4 receivers, but everytime I use more than 2 receivers, the serial data does not print. What can I do? P.S. I'm using 5 SRF-02 ...
1
vote
0answers
569 views

ATtiny85 + HC-05 + Oled = smart watch

I am using an ATtiny85 for making a smart watch. Bluetooth module HC-05 with ATtiny85 pins PB3->TX, PB4->RX and it works. Secondly I have connected a 0.96" OLED on PB0 (SDA) and PB2 (SCL) and this is ...
1
vote
0answers
531 views

I2C — set int pin

I am using a blend micro board, where the digital pins 4, 6 and 7 are reserved. I have connected a MPU6050 which uses the I2C protocol, so there is the need for the i2cdev lib to handle that. The ...
1
vote
0answers
100 views

Teensy and MS5803 sensor

I'm trying to use the MS5803 pressure sensor with a Teensy 3.2. Compiling the Sparkfun, or other, libraries, however, results in no output. Can you provide guidance on how to modify the libraries to ...
1
vote
0answers
115 views

Basic communication between Cotek and Arduino UNO

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 ...
1
vote
0answers
138 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 ...
1
vote
0answers
312 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 ...
1
vote
0answers
968 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. ...
1
vote
0answers
953 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 ...
1
vote
0answers
172 views

i2C and lost connections with IO errors

Having issues troubleshooting IO errors using i2C . Running a Python script on a raspberry Pi as master talking to an Arduino slave. The problem is that when making any change in my code that results ...
1
vote
0answers
198 views

GPS - Speed doesn't update as should - EM408 & Arduino Mega & GSM

I'm developing a system that will get the GPS signal and send it though the GSM with information about position, speed and temperature from some digital sensors. Currently I'm using the GPS EM408, ...
1
vote
1answer
579 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 shouldn'...
1
vote
1answer
560 views

Arduino Pro Mini I2C Problem

I am trying to connect a distance sensor VL6180x to Arduino Pro Mini via I2C. Yesterday it was working without any problems, but today it refuses to work, even though I haven't changed anything. The ...
0
votes
0answers
35 views

I2C communication between arduino and raspberry pi breaks under stress for unclear reasons. Why?

I am having a behavior I cannot explain while using arduino mega as a I2C slave for a raspberry pi master. I am showing here an idealised program that shows the issue. I experience pretty much the ...
0
votes
1answer
21 views

Reset I2C connection with arduino as slave

I am currently using I2C serial communications with arduino as slave and raspberry pi as the master. I am sending sensor data from arduino to raspberry pi. I need to reset the I2C connection once the ...
0
votes
0answers
26 views

Emulate I2C BMP180

I want to know if possible to emulate a temp sensor such as BMP180 with Arduino. The reason I am asking this is : BMP 180 is obsolete, so I am trying to replace it with BMP280 I want to read the ...
0
votes
1answer
30 views

Slave to Send Data after Receiving Command using I2C

I want to have my Slave Arduino to send signal to Master after the command was made. But the Slave Arduino does not proceeds to sending the signal after doing the command. What is wrong with my code? ...
0
votes
0answers
152 views

Using ESP32-CAM (with ov2640 camera image sensor) to send image via USB

I was trying to obtain image from ESP32-CAM (with ov2640 camera image sensor). I obtained the image through camera web server by connecting the ESP32-CAM and PC to same wifi network. A USB to TTL ...
0
votes
1answer
29 views

Two arduino boards with sensors i2c

I am new and lost I have been searching the internet about how to transfer data of multiple sensors from one Arduino to another using i2c but no luck. all the codes and tutorials online focus on ...
0
votes
1answer
58 views

Communication with sensor KMX63 in I2C

I trying to use a new sensor the KMX63 with a Arduino Uno board, my sensor is on a evaluation board made by kionix. For the connexion il linked as follows: | Pin Uno | Pin evaluation board | | A5 | ...
0
votes
0answers
35 views

I2C freeze on master

On my first big Arduino-project I made a game using the following Arduino's and the I2C-protocol: 1x Mega as master 4x Mega as slave 2x Uno as slave The Arduino's controll a physical game where the ...
0
votes
1answer
105 views

i2c Connection for MCP4725(Dac) with Esp8266 wemos d1 mini

------------ This question has been edited ------------ note: Dac and Adc is12bits my problem : I use two ESP. Using esp1, I read the Adc amount of the alternating signal (ECG) and send it to esp2 ...
0
votes
0answers
25 views

NFC wont send URL to mobile phone

I'm using nfc 2 click (NT3H2111), I tried via arduino to send data to my mobile phone using this code : #include <Wire.h> int i = 0; int j = 0; uint8_t NDEF_DATA[] = { 0x03, // NDEF Message ...
0
votes
0answers
38 views

Servo PWM Pin seems to be interfering with Wire.onRequest i2C function

A newbie here. I am thinking of interfacing Raspberry Pi with Arduino via I2c to control a few servo motor (as RPi have limited PWM pins). Meaning I would send input from RPi to Arduino to allow to ...
0
votes
1answer
20 views

Wire SlaveReceiver : will the registered function in onRecieve interrupt/conflict with loop block?

I am currently researching on I2C, and I made a configuration that has MasterWriter that transmits data to a SlaveReceiver that will store the data received from Master, into an SD card, and then ...
0
votes
0answers
17 views

Arduino Setup for RF Transmit and Receive, IR Receive, WS2812 LEDs and a Piezo Speaker

I am new to Arduino and microcontroller in general and just finished one Project (TonUINO - a DIY music box for kids). Now I am planing and working on my next project. A IR shooting range. The guns ...
0
votes
0answers
51 views

Calculate pullup resistor, cat5e ftp

let me describe my schema, i got one arduino and one esp32 connected over i2c using 30m cat 5e ftp cable, I'm using 12v to power up both devices, each of them have dc-dc converter that convert to 5V, ...