Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [i2c]

I²C stands for Inter-Integrated circuit, and is a data transferation system that allows connections between computers or microcontrollers and low-level peripherals (e.g. sensors or EEPROMS). It is a multi-master, multi-slave, single-ended, serial computer bus.

0
votes
1answer
22 views

OSError: [Errno 121] Remote I/O error or pigpio.error: 'I2C read failed' on MPU6050

So I use MPU6050 to get acceleration from stepper motor linear rail movement(steper motor working in thread, I use pigpio for the motor) by make the MPU6050 can work on threading and it can show data ...
0
votes
2answers
57 views

i2cdetect doesn't catch ANY address (no device detection)

I have ti046b1 chip (Serial I2C F-RAM) to read. I tried to read it with my raspberry Pi 3, so I connected SDA SCL VDD GND as shown in pictures, but when I run the command "i2cdetect -y 1" on my ...
1
vote
1answer
32 views

Trouble accessing Sensirion sht21 though multiplexer tca9548a using i2c and python

I can't reach my sht21 sensor throughout the Multiplexer tca9548a (adafruit). When I run it with python3 in the raspberry pi's terminal, I get this error report: Traceback (most recent call last): ...
1
vote
2answers
48 views

RPi to Arduino I2C block_data read fails with “Errno 121, Remote I/O error” (Python3)

Folks, I cringe to bring this up as it has been discussed frequently, but I am at a loss. Background: I have a Raspberry project with about 3000 lines of Python3 code and want to add a wireless ...
0
votes
1answer
53 views

I2C device (DS3231 RTC) not detected

I have a small DS3231 RTC module, like the following, that I am trying to get to work with my PI 3 Model B. However it is not correctly being detected by the Pi. Connected like so (ignore cables, ...
0
votes
2answers
40 views

Protect raspberry i2c pins with general ground connection with Arduino

I have connection like on the screen I have 12 arduinos. Each of them has one general 12V power supply. The problem is when i connect one of the Arduino supply (while all scheme works) Raspberry pi ...
0
votes
0answers
98 views

MLX90640 & I2C on Raspberry Pi 3

I'm using a thermal camera MLX90640 with the RPi3 to measure temperatures. I want to get data from it using I2C which I'm doing using the python smbus library. The problem I'm running in to is that ...
0
votes
1answer
35 views

Is SPI in Raspberry Pi Reliable..?

I'am trying to initiate a two way communication between Raspberry pi and Arduino. I worked with spidev library and directly using the SPDR register in the Arduino micro-controller without being able ...
0
votes
1answer
43 views

I don't know whether I have fried the I2C port on the Raspberry Pi 3 B

I am using a Raspberry Pi to send data to an Arduino Nano using I2C and it was working fine by just connecting the SDA, SCL and GND pins together from the Pi and the arduino. I then tried to get ...
0
votes
1answer
48 views

Raspberry Pi not detecting MPU6050 with i2cdetect

I am trying to connect my GY-521 MPU6050 to my Raspberry Pi Zero W using I2C detect but I'm unable to find the MPU6050 on the table. The results using i2cdetect: pi@raspberrypi:~ $ sudo i2cdetect -...
0
votes
1answer
33 views

RPi I2C Master vs. slave with Arduino

I have an Moteino board (similar to Arduino with a radio module). The Moteino uses the radio module to collect weather data from my Davis weather station. I want to use I2C to send this data to an ...
1
vote
0answers
72 views

Multiple Devices with I2C

I'm attempting to read data from the VL53L1X-SATEL and the TSL2561 Luminosity Sensor at the same time using I2C on the Raspberry Pi 3 B+. When just the vl53l1x is connected I get the following from ...
1
vote
1answer
38 views

Really strange but with RTIMULib2, why does it not work in a class?

I'm doing a project with an accelerometer/gyrometer combo and I'm using the great RTIMULib2 library. I know installing it and getting it to even work at all is a common challenge, but I've gotten it ...
0
votes
1answer
38 views

Wiring Omron D6T Thermal Sensor to Raspberry Pi Zero W with Adafruit T-Cobbler Plus

I have a Raspberry Pi Zero W connected to a Adafruit T-Cobbler Plus and breadboard. My question is regarding wiring. I have followed tutorials to create simple circuits, however, I am struggling to ...
0
votes
1answer
41 views

How can I get /dev/i2c-* devices to appear on Alpine Linux?

I have loaded the appropriate kernel modules and set them to load upon boot (i2c-dev and i2c_bcm2835). A call to lsmod confirms that they do indeed load on boot. But alas, I don't see any i2c devices ...
4
votes
0answers
60 views

Raspberry as I2C Slave, how to slow down transfer rate?

I have had minor success using the PIGPIO library and interfacing the Pi as an I2C Slave (Using GPIO Pins 18 and 19 as SDA and SCL) with a Campbell CR1000X Datalogger I am encountering a problem ...
0
votes
1answer
73 views

Periodically update DS3231 RTC with NTP

I am working on a pi hat that will cut the Pi's power in the evening when the pi isn't being used in my application. Anyways, I have a couple questions about using the DS3231 RTC. There is a uC in ...
0
votes
0answers
28 views

Read SI7021 I2C values using node-rpio

I'm trying to read temperature and himidity values from my SI7021 (page 18) via I2C using rpio . But there are a few thing, which I do not understand: Which baud rate should I set? I do not find ...
0
votes
1answer
38 views

How to Read I2C Address

I ran i2cdetect -y 1 and got the following chart back: 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- ...
1
vote
1answer
62 views

keep reading the same value from air pressure sensor (MS5611)

I have bought a GY-86 sensor. it is comprised of an accelerometer/gyroscope (Mpu6050) a magnetometer(HMC5883L) and a barometer(MS5611-01BA01). all these sensors have I2C interface. I am reading the ...
1
vote
1answer
483 views

How to fix Remote I/O Error Whilst Using i2c OLED

I was using my i2c OLED perfectly well when seemingly for no reason I started getting the Remote I/O Error when I ran my Python program. For some reason this was fixed by installing i2c tools again. ...
0
votes
0answers
128 views

How many arduinos can I control with one raspberry pi 3 B+

I have been reading about using a Raspberry Pi to control an Arduino. My goal is to control several Arduinos using a single Raspberry Pi, in order to automate several tasks, it is important to note ...
0
votes
1answer
132 views

Using the HMC5883L on the GY87

This was touched on in this question, but I was unable to get the solution to work: (Not all devices that are connection via I2C are showing) I have a GY-87 multi-sensor module and can get the IMU (...
2
votes
1answer
100 views

I2C device address changing of MCP23017 I/O extender

When I connect all A0, A1 and A2 to ground, then my device address of the MCP23017 is 0x20 (constant). But when I disconnect the A0 from ground, then the device address is switching between 20 and ...
1
vote
1answer
124 views

luma.core.error.DeviceNotFoundError: SPI device not found

I'm trying to setting up my new Dot Matrix MCU LED Display Module 8x32 with MAX7219 on my Raspberry Pi 3. I followed all the steps here https://max7219.readthedocs.io/en/0.2.3/ and of course using ...
1
vote
0answers
48 views

DRV2605 + TCA9548A I2C Multiplexer gets sporadic “Remote I/O Error”

The setup is a raspberryPi driving two AdaFruit DRV2605s through an AdaFruit TCA i2c multiplexer and it all works correctly the bulk of the time. I adapted the sample Arduino code and by and large we'...
-2
votes
1answer
127 views

How can I setup i2c on Alpine Linux? [closed]

There are tutorials all over the internet about how to enable i2c on Rasbian using raspi-config, but I'd like to work with Alpine Linux. How do the i2c devices/drivers/kernel modules work and how can ...
0
votes
0answers
54 views

Rpi not reading data from Sense HAT due to missing frame buffer

I'm having trouble getting my RPi 3 to listen to a Sense HAT. The Sense Hat is getting power and the RPI is aware of the Hat. pi@BBLPi1:~ $ ls /dev/i2c* /dev/i2c-1 pi@BBLPi1:~ $ i2cdetect -y 1 ...
0
votes
1answer
41 views

Distinguishing data-addresses of I2C chips [case ADS1015]

I'm trying to learn reading out I2C chips, but somehow I can't figure out how to find the right data addresses. I bought a water level sensor and a ADS1015 ADC[foto below]. They are connected via ...
0
votes
0answers
181 views

Problem using RTC using ds3231

Trying to get an RTC to load at boot. I've enabled i2c, that works fine for other components. /etc/modules contains: snd-bcm2835 i2c-bcm2835 i2c-dev rtc-ds3231 /etc/rc.local contains: echo ...
0
votes
1answer
361 views

Reading Multiple bytes in Raspberry Pi over I2C using Wiring Pi library [closed]

0 down vote favorite I am trying to build one sensor interface using Raspberry Pi over I2C. I have installed WiringPi. I am seeing limitations of wiringPi library, that supports only 1 or 2 bytes I2C ...
0
votes
1answer
163 views

How to write a single bit on a I2C/smbus register

I have a MCP23017 GPIO expansion chip connected to a Pi via the I2C bus. I want to be able to treat the pins of the chip like the GPIO pins of the PI – turning them on and off individually. ...
0
votes
1answer
33 views

How to I check and confirm if one's Pi 3's “Raspbian kernel” supports I2C on additional GPIO pins?

The June 4, 2018 Instructables article Raspberry Pi Multiple I2C Devices by Jacco Slabbert says The latest raspbian kernel support the creation of multiple I2C busses using GPIO pins. See also in ...
0
votes
0answers
31 views

Raspberry Pi3 connection I2C

I am looking to connect an external battery to my Raspberry and know its level of charge. For that, I have to use a SMBus connection, so I can use the I2C ports of my Raspberry. But I can not recover ...
0
votes
1answer
79 views

How to connect more I2C sensors on top of a RPI shield

I'm struggling with a problem, how to connect more sensors on top of this raspberry shield => https://sixfab.com/product/raspberry-pi-nb-iot-shield/ The shields schematic can be found here and it ...
1
vote
2answers
306 views

Cannot Detect LIDAR Lite v3 Raspberry Pi 3B+

I am trying to connect my Garmin LIDAR Lite v3 sensor to my Raspberry Pi 3B+ via i2c interface. However i2cdetect on the command line returns dashes for every address. I'll try my best to clearly ...
0
votes
0answers
24 views

Is it possible to call a subroutine asychronously when certain data arrive at the I²C bus?

Scenario: I'm replacing a bunch of GPIO pins with an MCP23017-based I²C port expander. In the GPIO era, i used to use the pigpio function gpioSetAlertFunc () to keep an eye on my GPIO input pins, so ...
1
vote
1answer
154 views

Can the i2c baudrate be changed on the fly without a reboot?

With the new device tree on my Raspberry Pi 3B+, the i2c baudrate gets set in the /boot/config.txt. Is it possible to set this on the fly instead? I have a device (DAC8574) that needs some initial ...
0
votes
2answers
67 views

I2C Primitive Sunfction for Python & Pi

Well-versed in C/C++, but new to Python. I have done a lot of research here and maybe I am missing something, but it seems that Pi/Python does not have primitive functions for I2C, which is sad to ...
0
votes
1answer
62 views

Serial connection with raspberry pi to arduino, works only once and needs a hard reset every time

so I am working on a project where I have to connect an arduino to the raspberry pi through serial and then transfer the input from the raspi to another I2C device. So, just to test things out and ...
0
votes
0answers
66 views

AMS Franklin AS3935 Lightning Sensor can't detect linghtning

I'm using Embedded Adventures MOD-1016 with AMS Franklin AS3935 connected by I2C. The code is from pcfens/RaspberryPi-AS3935 as in given there example. Everything looks OK. No bugs, noises and ...
0
votes
1answer
50 views

Connecting raspberry pi with ev3 using i2c

Recently, I have been trying to build a project where I need to connect an ev3 to a raspberry pi. I have decided doing it by i2c after reading (and successfully replicating) an article about ...
0
votes
0answers
111 views

Cheap 128x64 OLED

I purchased two cheap OLED modules, one is 0.96" 128x32 I2C at the following link: https://www.amazon.it/gp/product/B06XRBTBTB/ and the other is a 2.4" 128x64 at the following link: https://www....
0
votes
2answers
263 views

WiringPi Library and PCA9685 throwing errows

I am using this example code PCA9685 in C and whenever I run the code I get this as my output: PCA9685 servo example Connect a servo to any pin. It will rotate to random angles pwmWrite: You have ...
0
votes
0answers
47 views

Parallax MS5607 and Raspberry Pi 3?

I am trying to connect the MS5607 to the Raspberry Pi via I2C. I can confirm that it connected when I run sudo i2cdetect -y 1. I then went ahead and tried to use rsolomon's python code. First error I ...
0
votes
0answers
38 views

Raspberry pi analog joystick using Arduino i2c for kodi

so I'm working on a project and among others I want to integrate an analog joystick, like those cheap ones that send analog values between 0 and 1023 for x and y movements. The end game is that I ...
0
votes
0answers
88 views

How to read data from PIR sensor which is controlled by relay i2c?

There are my first steps with RPi and i2c. I use expander pcf8574 and I would like to drive a relay to control LED and PIR sensor. When the state on sensor is HIGH, LED should be turn on. I wrote a ...
0
votes
0answers
84 views

unable to set i2c speed for raspberry pi 3

I found several tutorials online on how to change the I2C speed on RPi3. They all boil down to this one. The script does work and I do read a 400000 value. However when I look at the scope my ...
1
vote
1answer
200 views

What does Pin Base mean in WiringPI Library?

I cant seem to find a clear answer what "pinBase" does. Does anyone have an idea what it does? Thanks! Code node = wiringPiNewNode (pinBase, 8) ; Function struct wiringPiNodeStruct *...
1
vote
1answer
94 views

Can I enable I2C before first boot?

I want to enable the I2C interface, but without having to boot, login, and the whole sudo raspi-config. I tried editing /boot/config.txt right after sudo dd the image to the disk, still in my main ...