Skip to main content

Questions tagged [i2c]

A two-wire bi-directional master/slave data-bus

Filter by
Sorted by
Tagged with
4 votes
2 answers
1k views

Low-cost servo with digital control interfaces? [closed]

Some years ago, there where some projects that provided hardware and software to perform modifications on standard hobby servos to convert them to digital servos, with all the advantages that come ...
Jakob's user avatar
  • 3,054
4 votes
2 answers
1k views

How can i connect two adafruit 16-channel 12-bit PWM/Servo Driver I2C interface (pac9685) to Raspberry or Arduino

I need to control 24 servos but I do not know how to do with I2C. I saw some componentes that do it with USB, but I need to do it with I2c. I am working in a robot with 8 legs and 3 degree of freedom ...
Julio Tentor's user avatar
3 votes
1 answer
9k views

How to read data from i2c using i2cget?

I'm new to embedded devices and am trying to understand how to use i2cget (or the entire I2C protocol really). I'm using an accelerometer MMA8452, and the datasheet says the Slave Address is 0x1D (if ...
pedalpete's user avatar
  • 131
3 votes
1 answer
786 views

MPU6050 inconsistent Gyro data

I'm using an MPU6050 for a custom flight controller and I am facing an issue when reading the values from the IMU. The data shown below represents the angular velocity in the y-axis. When the angular ...
MrMuffins's user avatar
3 votes
1 answer
103 views

Does anyone know what might be giving me this error coming from an i2c device

Here is the background. I am trying to write a service for the HiTechnic prototype board. Using the Appendix 2 from the blue tooth developers kit from Lego's site I am able to understand what is ...
Kenn's user avatar
  • 193
2 votes
3 answers
935 views

Connecting two microcontrollers using I2C [closed]

I Have an ATmega16 mc which is master on the i2c and a ATMega8 mc which is slave on the i2c. I have connected the two mcs' sda and scl ports to each other alongside a pullup resistor. Now I want to ...
Miro Markaravanes's user avatar
2 votes
2 answers
2k views

How to interrupt on a data ready trigger when communications to the sensor are interrupt driven?

Background: I'm using the L3GD20H MEMS gyroscope with an Arduino through a library (Pololu L3G) that in turn relies on interrupt-driven I2C (Wire.h); I'd like to be able to handle each new reading ...
chrstphrchvz's user avatar
2 votes
1 answer
397 views

How do I interpret this data, received by the I2C controller on an NXT 2 brick?

I have been trying to write code to connect a HiTechnic prototype board to my lego brick. Although I am using MSRDS studio, that isn't the issue; reading and writing to the serial port that the device ...
Kenn's user avatar
  • 193
1 vote
1 answer
355 views

Using i2c's SCL and GPIO pins as SDA

The beaglebone black which I work on has only 2 i2c busses. Say for some crazy reason, i need to use 8 i2c busses. I dont want to chain any of the devices. The idea is to have every device's SDA line ...
user2967920's user avatar
1 vote
0 answers
445 views

BeagleBone uart/spi/i2c latency

There seems to be consensus here that the BeagleBone Black has 1ms+ latency while toggling gpio pins due to the fact that gpio is handled outside of the cpu. Are the uart/i2c/spi lines equaly slow, or ...
David's user avatar
  • 420
0 votes
4 answers
389 views

Why must I loop 127 times for a "7-bit" address in this example?

I am learning about I2C on the Arduino. I was looking at a sample program to scan for I2C devices and saw this: ...
Kenn's user avatar
  • 193
0 votes
1 answer
27 views

RPi 4B + PCA9685

I am working on project that requires lots of PWM channels and decided to use PCA9685 and Raspberry Pi 4B as my controller, which I've never used. I installed Ubuntu 22.04LTS in order to use ROS-...
msalaz03's user avatar
0 votes
2 answers
4k views

How to convert this arduino code snippet to AVR GCC?

I recently engaged with a university robotics project (based on ROS) and my main processing controller is Raspberry Pi and the system stability controller is Atmega 32 microcontroller (It is ...
Kaviranga's user avatar
  • 123
0 votes
2 answers
181 views

I2C Arduino Connection

I am working on a wheel mobile robot with multiple sensors which are IMU, two encoders, four ultrasonic sensors, and using two Arduino: Uno and Mega. The IMU, encoders, and ultrasonic sensors are ...
oluwayinka esan's user avatar
0 votes
0 answers
23 views

Im using a BNO055 In the IMU operation mode, but i can only get it to display 0's

Ive read the data sheet but cant find much info there, but when I try to get IMU to give me euler data (yaw,pitch,roll). It gives me not accurate numbers for euler data and i cant use the adafruit ...
Waffle's user avatar
  • 1
0 votes
1 answer
25 views

Catkin _make failed when I altered an existing GitHub repository of an 2 wheel bot package for a four wheel bot

50%] Linking CXX executable /home/happy/guna_ws/devel/lib/autonomous/i2c_ros /usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu/Scrt1.o: in function ...
Dhaarani's user avatar
0 votes
0 answers
140 views

Interface multiple I2C slaves to microcontroller

I want to communicate the Tiva C ARM Cortex M4 to sensorhub from TI which has multiple sensors with different I2C addresses such as MPU9150, BMP180, Temperature Sensors... With a single I2C slave, i ...
Earthgod's user avatar
  • 237
-1 votes
1 answer
682 views

I²C read multiple registers with DMA

I am using an STM32-L432KC microcontroller to read data from an I²C Device (Bno-055) via DMA. On a microcontroller without DMA i would try to minimize the IO-Wait by only reading the necessary ...
aul12's user avatar
  • 37