diff --git a/pages/linux/i2cdetect.md b/pages/linux/i2cdetect.md new file mode 100644 index 0000000000..7cc9e039f5 --- /dev/null +++ b/pages/linux/i2cdetect.md @@ -0,0 +1,17 @@ +# i2cdetect + +> Scan I2C buses. +> See also: `i2cdump`, `i2cget`, `i2cset`. +> More information: . + +- 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}}` diff --git a/pages/linux/i2cdump.md b/pages/linux/i2cdump.md new file mode 100644 index 0000000000..58b404b01e --- /dev/null +++ b/pages/linux/i2cdump.md @@ -0,0 +1,22 @@ +# i2cdump + +> Dump I2C device registers. +> See also: `i2cdetect`, `i2cget`, `i2cset`. +> Note: All addresses should be specified in hexadecimal. +> More information: . + +- 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}}` diff --git a/pages/linux/i2cget.md b/pages/linux/i2cget.md new file mode 100644 index 0000000000..6ab253e04a --- /dev/null +++ b/pages/linux/i2cget.md @@ -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: . + +- 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}}` diff --git a/pages/linux/i2cset.md b/pages/linux/i2cset.md new file mode 100644 index 0000000000..d37295924d --- /dev/null +++ b/pages/linux/i2cset.md @@ -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: . + +- 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}}`