I2C

I²C or I2C (Inter-IC) is a synchronous, multi-controller/multi-target (controller/target), packet switched, single-ended, serial communication bus invented in 1982 by Philips Semiconductors.

It is used by many hardware boards to communicate with general purpose I/O (GPIO) devices.

A similar extension of I2C is SMBus which is more specifically used for hardware monitoring purposes.

Installation

I2C kernel modules already exist in most default kernel packages.

Userspace tools can be installed from i2c-tools. Bleeding edge is on i2c-tools-gitAUR.

SMBus-specific tools can be installed from lm_sensors.

Module loading

In some cases it might be required to load the module at boot:

/etc/modules-load.d/i2c-dev.conf
i2c-dev

Depending on your system and usage, other hardware-specific modules such as i2c_i801 or i2c_smbus might have to be loaded as well.

If the modules are properly loaded, you should see the /dev/i2c-* devices.

Permission for using the /dev/i2c-* devices can be granted by adding the user to the the i2c user group.

Usage

can detect all the active I2C devices:

When an I2C device is connected to a known bus, can probe it for active addresses:

gollark: Also, yes, apparently the global trend is not for those to be increasing. Unless you're being totally US-centric.
gollark: You've jumped immediately to "pretty high suicide rates → everyone is unhappy" and I think you've failed to consider other things.
gollark: Mortality due to other stuff is very low for young people, so I'm not sure what you'd expect.
gollark: Discounting hundreds of years of massive progress in many areas due to a somewhat bad statistic is uncool.
gollark: You are, again, missing the point.

See also

This article is issued from Archlinux. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.