mirror of
https://github.com/tldr-pages/tldr
synced 2026-08-26 14:13:36 +01:00
i2c-tools: add page (#17152)
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
# i2cdetect
|
||||
|
||||
> Scan I2C buses.
|
||||
> See also: `i2cdump`, `i2cget`, `i2cset`.
|
||||
> More information: <https://manned.org/i2cdetect>.
|
||||
|
||||
- List active I2C buses:
|
||||
|
||||
`i2cdetect -l`
|
||||
|
||||
- Scan devices on an I2C bus:
|
||||
|
||||
`i2cdetect {{i2c_bus}}`
|
||||
|
||||
- Scan devices on an I2C bus without asking for confirmation:
|
||||
|
||||
`i2cdetect -y {{i2c_bus}}`
|
||||
@@ -0,0 +1,22 @@
|
||||
# i2cdump
|
||||
|
||||
> Dump I2C device registers.
|
||||
> See also: `i2cdetect`, `i2cget`, `i2cset`.
|
||||
> Note: All addresses should be specified in hexadecimal.
|
||||
> More information: <https://manned.org/i2cdump>.
|
||||
|
||||
- Dump all registers of an I2C device:
|
||||
|
||||
`i2cdump {{i2cbus}} {{device_address}}`
|
||||
|
||||
- Dump all registers of an I2C device without asking for confirmation:
|
||||
|
||||
`i2cdump -y {{i2cbus}} {{device_address}}`
|
||||
|
||||
- Dump all registers of an I2C device using a specific mode:
|
||||
|
||||
`i2cdump {{i2cbus}} {{device_address}} {{b|w|c|s|i}}`
|
||||
|
||||
- Dump registers from `start` to `end` of an I2C device:
|
||||
|
||||
`i2cdump -r {{start}}-{{end}} {{i2cbus}} {{device_address}}`
|
||||
@@ -0,0 +1,18 @@
|
||||
# i2cget
|
||||
|
||||
> Read from an register of an I2C device.
|
||||
> See also: `i2cdetect`, `i2cdump`, `i2cset`.
|
||||
> Note: All addresses should be specified in hexadecimal.
|
||||
> More information: <https://manned.org/i2cget>.
|
||||
|
||||
- Read from a register of an I2C device:
|
||||
|
||||
`i2cget {{i2cbus}} {{device_address}} {{register_address}}`
|
||||
|
||||
- Read from a register of an I2C device without asking for confirmation:
|
||||
|
||||
`i2cget -y {{i2cbus}} {{device_address}} {{register_address}}`
|
||||
|
||||
- Read from a register of an I2C device using a specific mode:
|
||||
|
||||
`i2cget {{i2cbus}} {{device_address}} {{register_address}} {{b|w|c|s|i}}`
|
||||
@@ -0,0 +1,18 @@
|
||||
# i2cset
|
||||
|
||||
> Set the value of a register of an I2C device.
|
||||
> See also: `i2cdetect`, `i2cdump`, `i2cget`.
|
||||
> Note: All addresses should be specified in hexadecimal.
|
||||
> More information: <https://manned.org/i2cset>.
|
||||
|
||||
- Write to a register of an I2C device:
|
||||
|
||||
`i2cset {{i2cbus}} {{device_address}} {{register_address}} {{value}}`
|
||||
|
||||
- Write to a register of an I2C device without asking for confirmation:
|
||||
|
||||
`i2cset -y {{i2cbus}} {{device_address}} {{register_address}} {{value}}`
|
||||
|
||||
- Write to a register of an I2C device using a specific mode:
|
||||
|
||||
`i2cset {{i2cbus}} {{device_address}} {{register_address}} {{value}} {{b|w|c|s|i}}`
|
||||
Reference in New Issue
Block a user