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.

Filter by
Sorted by
Tagged with
-2
votes
0answers
23 views

Using i2c for the first time [closed]

So is my frist time when i work with this. Here is my code: https://imgur.com/a/dLIAUx1 I need to edit, to make him to write: PROGRAM -> first row and DEMO -> second row. Is for my class, so don't ...
0
votes
0answers
41 views

Problem with I2C

I trying to make a project to write and i2c display from a renault megane vehicle. There is many people showing it but there is no code that i can use. So i buy a cheap analyzer and i can clearly see ...
0
votes
0answers
45 views

Unable to find/connect I2C devices (SHT31 & SGP30)

I have recently purchased an Arduino Nano 33 IOT together with two sensors: Adafruit SHT31-D (https://learn.adafruit.com/adafruit-sht31-d-temperature-and-humidity-sensor-breakout) Adafruit SGP30 (...
0
votes
1answer
29 views

Problem to Setting up i2c OLED wemos D1 mini shiled (64*24)

Hi I used this shield before well. But it didn't work when I wanted to work with him last night! this is my wireing : Now I want to know how to test that it is healthy? Is i2c address missing or ...
0
votes
1answer
12 views

Pca9685 & WS2818B, 1 Nano

Arduino n00b here. I currently have an Arduino Nano set up to run 6 servos from a PCA9685 board. I'm looking to add 6 switches and 6 LED indicators to switch servo positions. What I'm curious about is ...
0
votes
1answer
23 views

How can I declare custom pins when using with ESP8266 in MPU9250 library

I want to declare SCL and SCK pins like Wire.begin(sda_pin, scl_pin); to use with ESP8266 to integrate a MPU 9250/6500 sensor. I can't figure out a way to declare that in this code exaample provided ...
0
votes
0answers
17 views

Wire.requestFrom() from master triggers requestEvent() in slave, but data written by slave is not received by master

I have a Mega 2560 Master connected via I2C to a Teensy 3.2 slave. The master calls Wire.requestFrom(slaveAddr, (size_t)32) to get data from the slave. Master & slave code snippets shown below: ...
0
votes
0answers
49 views

I2C and softwareserial

Attempting to make gps unit with screen. GPS unit communicates over serial (Adafruit Ultimate GPS Breakout) and I can get GPS data through USB to my pc with Adafruit GPS library softwareserial ...
0
votes
0answers
13 views

BMP280 pressure as a DC motor switch - issues

I'm attempting to control a DC vacuum pump to turn off when it hits a BMP-280 reads a set pressure lower than when it spins up (guesstimate pressure, I've got it hooked up to tweak in person). ...
0
votes
0answers
71 views

I2C and SPI using sensor and Oled display

Im currently working on a project which displays vital signs such as pulse and oxygen on my display. Now, my sensor is connected through I2C while my OLED runs through SPI. Im trying to display the ...
1
vote
0answers
83 views

ESP8266 NodeMCU CP2102 ESP-12E I2C with MPU 6050 Error

So the previous two questions could be found here: ESP8266 computtion error and ESP8266 not working with MPU 6050 over wire library and I2C However, it was not resolved, and with updates and debugs,...
0
votes
1answer
46 views

Is it permissible to connect 3.3V powered devices to the 5V I2C bus?

I have several devices on the I2C bus: RTC DS3231SN TMP100 temperature sensor EEPROM 24LC256 All devices are powered by 3.3V. The voltage on the I2C bus is 5V. Question: Is the voltage difference ...
0
votes
0answers
19 views

Connecting Arduino Uno to Arduino Leonardo

I have an RFID shield connected to my Arduino Uno, but I want it to be able to send keystrokes to the computer when I scan the correct card. I have the Uno set up correctly so that when the card is ...
0
votes
0answers
64 views

ESP8266 not working with MPU 6050 over wire library and I2C

I'm trying to use this version of ESP8266 to access MPU 6050. However, it's not working. https://www.amazon.com/gp/product/B07HF44GBT/ref=ppx_yo_dt_b_asin_title_o07_s00?ie=UTF8&psc=1 i.e. ...
1
vote
1answer
20 views

i am having Strange issues when trying to read form gps serial connection

I have an Adafruit Ultimate GPS connected to a MEGA2560. I am trying to get the data from the buffer and do other data processing at the same time, however. when i allow other processing to be done ...
0
votes
0answers
48 views

How fast exactly can MPU 6050 bus go?

I'm using nano to access MPU 6050 chip. However, it took 5ms to update the loop and was costing me lots of time. So I wanted to find out if there's a way to accelerate the I2C bus speed. Eventually, ...
1
vote
1answer
108 views

OLED (I2C) and Micro SD card module not working together in Arduino

I am trying to write some data to SD card and read it back to serial monitor as well as display it to the OLED. Both the sd card and oled work separately but they seem to be interfering with each ...
0
votes
1answer
32 views

How do i send data from a Master to another Master?

I am using an ESP32 to receive data from web. However in an I2C communication, the EPS32 does not work as a Slave and i already have an Atmega as the Master. i have seen sites saying Master-Master ...
0
votes
1answer
97 views

It is any DS2482 I2C to 1-Wire bridge functional library?

Please let me know if you know any good library for DS2482 I2C to 1-Wire bridge. I tried to use https://github.com/cybergibbons/DS2482_OneWire library but I got errors when I'm trying to run the ...
0
votes
2answers
186 views

Best way to send I2C commands between Arduino and ESP32

I made a board with an Arduino nano and a ESP32 Dev kit. I connected them via I2C with voltage adaptation. I'm using arduino IDE and the related library Wire.h. I send messages as ascii chars or ...
0
votes
2answers
32 views

Cannot call function in call back for onRequest()

I am a NOOB! Trying to use the ZS-042 RTC module to retrieve the current time and send it back to the RPi over I2C. I can call the function and spool it to Serial but when I try to call the function ...
0
votes
0answers
20 views

I2C Communication Matlab - FDC1004

I have a ProtoCentral FDC1004 board (datasheet: http://www.ti.com/lit/ds/symlink/fdc1004.pdf) connected to an Arduino. I am then trying to connect to the system via matlab. I have found the address (...
-1
votes
1answer
93 views

Parallel communication between multiple Arduino

Here's a post which explained the communication standard. I need to establish communication between multiple Arduino nano board. I have used SPI bus on one of the Arduino board for wireless ...
0
votes
1answer
114 views

SSD1306 recognized in I2C scaner, can't get it to display

The gist of my issue is in the title. I have a cheap ebay SSD1306 128x64 display which I hooked up to my arduino, and checked the wiring at least 50 times and the address is correct, the display has ...
1
vote
1answer
104 views

I2C OLED conflicts with Interrupt

I'm using Nmradcc.h in combination with a OLED I2C. The nrmadcc.h is using a interrupt 0 on Pin 2, the OLED uses A4 and A5. After initialisation of the OLED and the Function The problem is, I can ...
0
votes
1answer
31 views

How many I2C lines does the Arduino Due have?

According to the Arduino pin Mapping 20 PB12 SDA 3 6 21 PB13 SCL 3 6 70 PA17 SDA1 3 6 71 PA18 SCL2 15 9 The first one seems pretty obvious, the second one though is ...
0
votes
0answers
37 views

I2C sensor hogs the bus with empty write commands

I am trying to read data from a pair of TLE493-W2B6 magnetic position sensors [1, 2] with Arduino over I2C. I can read from each sensor individually, using the Arduino library from the manufacturer [3,...
0
votes
2answers
78 views

USING HX711 ( WITH LOADCELL) WITH PCF8574 IN NODEMCU

I have used hx711 and loadcell with nodemcu (esp8266) in its D1 and D2 pins ( here I have used Logic level shifter and a 5v supply to power hx711).It worked perfectly fine. Due to the lack of enough ...
0
votes
0answers
35 views

MPU6050 - Why is my gyro integration incorrect?

My situation: I am able to communicate over i2c with my MPU6050 IMU I can get accelerometer and gyro data I can compute the sensor's orientation using my accelerometer Issue: when trying to compute ...
0
votes
0answers
41 views

Problem with printing keypad input to the LCD in a while loop

this is my first post here, though I have been following this forum for a while (pun intended). I am trying to write a program for a machine that will drill holes in a metal rail, and cut the rail to ...
0
votes
0answers
48 views

I2C Hangs (sometimes) when Wire->endTransmission() is called

Architecture MKRZero BME280 Atmospheric Sensor SSD1306 128x64 OLED Screen SparkFun GPS: device: https://www.sparkfun.com/products/14414 arduino library: https://github.com/sparkfun/...
1
vote
1answer
146 views

How to get text to flash on ssd1306 i2c screen

I am trying to alternate a string back and forth on the SSD1306 oled screen. So I want the display to show "test1" for 0.5 seconds, then "test2" for 0.5 seconds, repeating. the code below is just ...
0
votes
2answers
103 views

How to send data to multiple slave at a time

I have one master and three slave devices and i need to send data to all the slaves at a time.is that possible if so how to check which slave has recieved the data first
0
votes
0answers
27 views

MPU6050 with Arduino I2C Unreliable with Motor Noise

I have an autonomous wall-tracking robot that uses relative angle changes from a I2C-connected MPU6050 module along with ultrasonic 'ping' sensors for motor speed control to acquire and then track a ...
0
votes
0answers
10 views

STM32F103C Connection to MPU6050 Only works less than half the time

I am programming the STM32 Blue Pill board via the Arduino IDE. I have been stuck with this problem for a very long time and it is becoming immensly infuriating. The MPU6050 connects and gets ...
1
vote
2answers
50 views

How to check if two device has the same address on I2C?

I start a new project with Arduino UNO and MCP23017 expander. Using this, I can connect 8 chips on Arduino, by selecting different addresses ( from 0x20 to 0x27 ). My question is, if I connect two ...
0
votes
1answer
40 views

Compass heading not varying linearly

I am using an HMC-5983 magnetometer compass on my arduino uno to find the heading of a car I'm building.But my compass readings aren't varying linearly.For example when I physically turn my compass by ...
0
votes
1answer
30 views

FIXING BUG when Using Wire library to obtain compass heading

I am using the HMC-5983 magnetometer module to obtain the compass heading of a autonomous car I am building using the arduino platform.I'musing the Z axis and X axis to obtain the heading. However ...
0
votes
0answers
139 views

Arduino nano with 128x64px OLED freezing

I have an arduino nano, MCP3424 i2C ADC and a 128x64px i2C OLED display. The function is quite basic; the arduino receives information from the ADC and prints it to the screen as described in the code ...
1
vote
0answers
104 views

Reading I2C data from SW6106 register

I am using the SW6106 powerbank IC as an I2C but no matter what I have tried I couldn't read something other than "FF". Datasheet for the IC. Timing diagram for reading data: Timing diagram for ...
0
votes
2answers
46 views

What is the best data type to be used through i2C

i'm trying to send multiple commands to multiple slaves controlling motors. Slave Controller(Arduino Nano) will receive the command, and returns the current position of the motors to the Master(...
0
votes
0answers
58 views

i2c man in the middle

I'm developing a bridge, or man in the middle for touch controller and a system board connected with I2C. The connection is: Touch Controller(slave)---I2C---(master)STM32(slave)---I2C---(master)ARM ...
0
votes
1answer
132 views

I2C code working on Mega 2560 but not on Uno and nano

I have recently purchased this Heart rate sensor and was trying to make it work. I used this MAX30100 library I found on Github. For some reason when I use any of the given examples, they seem to work ...
0
votes
0answers
20 views

nodemcu nack error bh1750

I am trying to run a simple example of bh1750 on my nodemcu, code is #include <Wire.h> #include <BH1750.h> */ BH1750 lightMeter(0x23); void setup(){ Serial.begin(9600); Wire.begin(...
0
votes
0answers
109 views

Completing an action on button release help with delaying to give other modules time to repond

I'm currently having problems with my code it has several modules within the main one is my current keypad one working of a mcp23017. what I needed it to do is count how long a key is pressed and upon ...
0
votes
0answers
50 views

Byte not written to the memory

In the following code I'm computing crc and setting it as last (11th) byte in the array. The problem is it's sent on I2C just when I print it on the serial terminal. static constexpr uint8_t ...
0
votes
1answer
119 views

MCP4725 I2C address

I want to use four of MCP4725 DAC module at the same time but it only has two I2C addresses which can be set via jumpers: In page 10 of the datasheet it says: Device Address Selection pin. This ...
0
votes
1answer
107 views

Sending more than BUFFER_LENGTH(32) bytes in slave answer I2C

I need to send 259 bytes as answer to I2C master read request. AFAIK there is a buffer limit of 32 bytes in Wire.h and in HW (Arduino Nano). Is there a way sending 259 byte answer, or I have to choose ...
0
votes
1answer
224 views

Connect arduino nano and ESP32 with I2C on the GPIO7 and GPIO8?

I made a mistake connecting SD0 (GPIO7) and SD1 (GPIO8) with the SDA and SCL on my arduino nano. I got confused with GPIO21 and pin21 and GPIO22 and pin 22! Since I made a PCB prototype, I would ...
0
votes
0answers
31 views

Communication between arduino nano and MCP3424 over I2c pt. 2

I'm am completing a project of mine that uses an MCP3424 i2c 18bit ADC and an arduino nano to measure temperature with an NTC thermistor but am having trouble with the arduino wire library. This is my ...

1
2 3 4 5
12