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.

Filter by
Sorted by
Tagged with
1
vote
1answer
34 views

Is there an easy way to share the power and I2C GPIO pins between multiple sensors without soldering?

I'm trying to connect multiple sensors to the Power and I2C pins of the GPIO header of a Pi 3B, but I can't find an easy way to do it using the standard plug-in jumper cables that are often used for ...
-4
votes
0answers
23 views

How to use dlp2000 evm

I want to interface DLP2000 EVM with RPI, How to do this? RPI is running android os.Its working fine for ubuntu by editing config file.Likewise how to do with android.
0
votes
0answers
30 views

Connect two PCF8575 to I2C bus

I have two PCF8575 breakout boards that I would like to connect to my Raspberry Pi 3B+ running Debian Buster kernel version 4.19.75-v7. Since both have the same address (0x20), I need to create a new ...
0
votes
1answer
19 views

Choosing the pull-up resistor value for i2c that can cater up to n-number of modular devices

Hello i have designed a modular shield like value that uses the i2c buss of the raspberry but i do not know what resistor value for the pull ups to use. most guides tells us to use a safe 4.7k ...
0
votes
0answers
18 views

Customize i2c driver - Change i2c line speed

For the BCM2835, what I would like to do is the following: I want from the user space to be able to change the I2C bus line speed, not just by modifying the CDIV field of the DIV register (Reference), ...
1
vote
1answer
30 views

How can you use pigpio's set_servo_pulsewidth with an i2c address?

I've tried to use hexadecimal for the GPIO address to see if it would work with GPA0 on the MCP23017 import pigpio import time pi = pigpio.pi() gpio_num = 0x21 while True: pi....
3
votes
3answers
92 views

GPIO vs I2C SMBUS2

This example scans for any I2C slave address current on the I2C bus. (I am using a RPi 3B+ with raspbian buster from september release) Script trial_smbus.py: from smbus2 import SMBus channel = 1 ...
2
votes
1answer
44 views

I2C works but gives wrong value

I have an RPi3b (Master) wired up to an MCU (Slave) communicating via I2C. I did have an RPi1b wired up and upon which I did my first development (cheaper to accidentally fry). Suddenly I'm getting a ...
0
votes
0answers
45 views

How do I read all registers of an INA219 sensor via SMBus in Python at once?

I'm trying to Connect my Raspberry Pi 3B+ with a Raspbian 10 to an INA219 current sensor (that also returns voltage and a premultiplied power) via SMBus in Python 3.7. After destroying one Raspberry ...
1
vote
0answers
47 views

Raspberry pi with 1.3" oled i2c screen

I'm currently trying to use this 1.3" i2c oled screen with the Adafruit oled i2c library, but I'm currently getting this issue: I have made sure to run the setup.py and all of the code is the same. ...
1
vote
1answer
61 views

i2cdetect shows all blanks or UU

I am facing a difficulty using MCP23017 with raspberry pi (stratodesk OS). I would like to know if I missed any configuration to get MCP23017 working my config.txt file: dtparam=i2c1=on, dtparam=...
0
votes
2answers
40 views

I2C Usage difference in Arduino and WiringPi

I'm using a device through I2C interface and I'm having some issues when the I2C bus fails, I don't know if it fails because an interferance in the cable or just timing issues in the Raspberry over ...
0
votes
1answer
48 views

Pi Zero W: Second i2c Bus

I did a really stupid mistake - I set up a second i²C bus months ago, so I have two gyro sensors connected - but din't document it. I can see the connected devices with i2cdetect -y 1 and ...
0
votes
2answers
107 views

I2C MPU9250 Gyro/Accelero/Magneto 9-DOF Sensor MicroPython Programming Problem

so I've recently set up my raspberry pi. Am following a tutorial for the MPU9250, from https://github.com/tuupola/micropython-mpu9250. I have did a install of the micropython-mpu9250, and tried the ...
0
votes
1answer
34 views

how can I know the current i2c speed?

I could not find this information anywhere. Where can I find the current i2c speed? It's not in dmesg, and in /sys/module/i2c_bcm2835/parameters/ I only have a file called "debug".
1
vote
1answer
98 views

WiringPi and ADS1115 C/C++ sample programs

I am trying to create c++/c program to AnalogRead using and ADS1115. I have seen that wiringPi has support for ADS1115 but i could not find any sample program to start with. Can anybody link guide me ...
0
votes
0answers
30 views

ADS1115 change i2c address and speed in python

Hello i am using a custom raspberry pi shield on my raspberry pi 4. Currently Im testing only 1 shield with 4 ads1115. In python im using adafruits library to read the data and it can only sample 50x ...
0
votes
0answers
42 views

i2cdetect detects the device but also shows a full row of addresses

I have successfully setup a RTC clock ( DS3231 ) on a RPi zero. The whole process was explained here. It works as expected but with only a minor difference: Row 5 is filled with numbers from 0x50 to ...
2
votes
1answer
33 views

How to securely share linux devices from client to another linux server

I have 3 I2C devices connected to my raspberry pi 3 i2c bus 1. I want to share this whole I2C bus 1 (/dev/i2c-1) to another linux server, which is running in the cloud, through a secure TLS, username ...
1
vote
3answers
94 views

How to interface more than 10x ADS1115 a raspberry pi?

Hello i am creating a shield for raspberry Pi 3/4 and in need of a lot of analog pins to read 30 sensors. and since the shield can only fit 5 sockets of the connector i am using i need to use 2 ...
0
votes
1answer
45 views

Slaves on i²c bus aren't detected

I'm currently trying to get multiple i²c slaves with the same address working without the use of a multiplexer on a PI Model 3b. I followed this instrutable for the creation of a second i²c bus: cd /...
2
votes
1answer
79 views

Need advice for connecting multiple arduinos to raspberry pi

I have a project in hand where I need to connect 5 arduinos as slaves to Raspberry Pi. Load Cells, Reed Switch, Solenoid lock will be connected to each of the arduino. The arduinos need to send the ...
0
votes
0answers
49 views

Issue with I2C communication with raspberry pi and arduino

I am new to I2C communication and python coding so please bear with me if my question is naive or my code looks very bad. I am able to achieve I2C communication between raspberry pi and arduino and ...
0
votes
2answers
130 views

How to physically wire two I2C sensors' SCL/SDA signals to a single I2C bus?

I need to connect two sensors like this https://encrypted-tbn0.gstatic.com/images?q=tbn%3AANd9GcRDDlL2AK_eYo9BKbImJcekMZ0PgIYC2GL0OLIMVGzkWAtq54zG to rpi 3 b. I found that it is not a problem and ...
2
votes
2answers
135 views

Adding I2C Bus with dtoverlay Does Not Show Up in i2cdetect

I am trying to set up multiple I2C interfaces on my pi. I have added the following lines to my /boot/config.txt and rebooted: dtoverlay=i2c-gpio,bus=4,i2c_gpio_delay_us=1,i2c_gpio_sda=29,...
0
votes
1answer
59 views

How to access BCM i2c registers? i2c speed halves on raspbian buster (Zero W, Pi 3 B, Pi 4 B), fine on raspbian stretch

I have a problem with I2C clock in Raspbian Buster (using either SMbus or i2c-dev). It defaults to 50 kHz on RPi 4B and to 62.5 kHz on RPi 3B and Zero W. However, if I set the speed i2c_arm_baudrate=...
0
votes
1answer
21 views

Stacking together two I²C hats with different voltage

I plan to make a domotic system based on a raspberry pi. I choose a grove hat to connect sensors and relays, but I need a digital potentiometer and grove system does not have that. So I plan to buy ...
1
vote
1answer
249 views

How to connect two BME280 sensors via I2C to a Raspberry Pi 3B+

I have a Raspberry Pi 3B+ and I bought two BME280 sensors (specifically these) and I would like to connect them via I2C. I read that you can do software multiplexing but all the information I am ...
0
votes
1answer
72 views

Problem with i2c communication between arduino and raspberrypi

I have connected Rpi with Arduino using i2c communication. Pin Configuration: Rpi ---- Arduino Mega SDA SDA SCL SCL GND GND I also have an encoder attached to Rpi. Encoder `------ Rpi 5V 5V Gnd Gnd ...
3
votes
1answer
59 views

Pi locking up trying to use rising/falling edge detection

I have a B+ v1.2, with a motor controller and 2 quadrature encoders setup. It's running Arch: 4.19.69-2-ARCH armv6l. It's completely locking up, requiring a plug-pull when either of the encoders ...
0
votes
1answer
42 views

PIGPIO not detecting I2C device but i2cdetect -y 1 detects it and I can even run my codes well in SMBUS

I have a Raspberry Pi 3 Model B+. My I2C device which is this (exact breakout board) isn't getting detected through PIGPIO Library. The sensor works very well with the example codes which uses SMBUS ...
1
vote
1answer
38 views

I2C communication between two arduino masters sending events and one raspberry pi slave

I have two arduinos intercepting events. They have to deliver these events to a raspberry pi. According to my understanding of the I2C protocol, the RPi must be configured as slave, and the two ...
0
votes
1answer
197 views

Can't use my Raspberry Pi 3 B+ for I2C in high speed mode

I've been trying to use a Raspberry Pi 3 B+ to get data from an accelerometer, namely an ADXL 357, via I2C but the problem is that the data rate is about 200 Hz or even less. I tried to set the ...
0
votes
1answer
30 views

Why i2cdetect slave can not detect polling way but interrupt can?

I had tried to use rpi as master to detect slave. The slave is MCU, using polling to answer rpi's request. However, when I tried to use rip to check the slave address, using command : i2cdetect -y 1 ...
1
vote
0answers
38 views

Why does writing to I2C is too slow in Python comparing to C? [closed]

I am trying to find out why the same code in Python works 25 times slower than C even if I use CDLL, when I try to write into I2C. Below I will describe all the details what I am doing step by step. ...
1
vote
1answer
35 views

intermittence in Adresses on a I2C bus when using more than 5

Hello im doing and experiment trying to Expand my raspberry to use 7 I2C devices (MCP23017 E/SP) its my first time using more than 1 MCP Im using SparkFun Solderable Breadboard to conect Pi 5v / GD ...
0
votes
1answer
144 views

Using Normal GPIO Pins as I2C (required)

We are attempting to use the Raspberry Pi as an embedded software platform. We are writing this in python, but currently we have it wired up to use 3 separate I2C busses. We have two of them wired to ...
0
votes
0answers
31 views

Oled Display doesn't work properly

Im using my Raspberry Pi zero W For an project with an Oled display and i can't get it to work properly I Installed Adafruit and tried the examples. It didn't work and i tried an other example but ...
1
vote
0answers
51 views

Creating a Device Tree Overlay for i2c device

I'm trying to create a Device Tree overlay for a i2c touch screen. Things are a bit strange as the screen is a 16bit DPI so all usual i2c pins are consumed. I'm using a i2c-tiny-usb adapter to get an ...
0
votes
0answers
59 views

How to get and set the byte in EEPROM - Waveshare AT24/FM24 using i2cget and i2cset command?

My raspberry pi is 3 Model B v 1.2. I have changed the i2c baud rate to The configuration in my raspberry pi are # cat /boot/config.txt # For more options and information see # http://www....
0
votes
1answer
40 views

How rpi3 as slave use i2c with wiringPi

I tried to let my rpi3 with wiringPi as slave to receive data from master and data +1 send to master . mater send 1 to slave (rpi3) My rpi3 SDA is GPIO 18 ,SLC is GPIO 19 the code on my rpi3 : #...
1
vote
1answer
88 views

i2cdetect shows two device address

I have interfaces Atmel 24C04 EEPROM to raspberry PI 3b+ and used i2cdetect to verify if the interfacing is done properly. I am new to this area and trying to learn by doing some hands on. After ...
1
vote
1answer
66 views

Does the Pi4 have pullups on SDA/SCL?

I can't find a full Pi4 schematic but I gather some previous Pis have had pullups on these two lines whilst others haven't, along with much discussion on whether hats should have a pullup or not. ...
0
votes
0answers
75 views

Simple Sound Card with I2S - how do I switch frequencies?

I asked this a month ago, but didn't get an answer and so the thread was auto-deleted. It is becoming critical that this be solved, so I am reposting. I have the simple sound card working with a ...
2
votes
1answer
53 views

Reading more than 8 bits from an SI7021 sensor

I am using the Si7021-A20 sensor on a Raspberry Pi Zero WH (headless, controlled via ssh and VNC). I want to get readings using Python (version 3). However, I have a very hard time to actually get ...
1
vote
1answer
49 views

Peculiar features of I2C communication between RPi and Arduino

I am currently trying to establish two-way communications between an Arduino Leonardo and a Pi model B using the I2C bus, as slave and master respectively. Spookily, the Pi can successfully send ...
2
votes
1answer
78 views

I2C Communication between Arduino and RPi failing when Arduino is sending data

I'm trying to read some data from the Arduino slave and when I receive the data it shows some numbers but not the correct ones. I'm using node and i2c-bus module, also tried with wiringPi but got the ...
0
votes
1answer
50 views

DS3231 doesn't update its internal time?

UPD: with another chip of the same model RTC works just fine, presumably that the chip was broken/damaged. I installed DS3231 RTC clock ( which is detected as DS1307 for some reason). My config.txt ...
1
vote
0answers
100 views

Using the MCP7940N RTC with the Pi 3B+

I have a breakout board with the MCP7940N RTC on the Pi 3B+. How do I get this to work. I've been following this guide but don't seem to be getting anywhere. In my /boot/config.txt I have added ...
0
votes
1answer
183 views

Multiples i2c devices with the same address

I am trying to find the simplest way to connect multiple 15 IMU sensors (ICM-20948) to a wearable suit.The thing is that they all have fixed addresses. The solutions I found so far are: Using a ...