rpi_i2c_get | R Documentation |
Return a byte from an i2c device
rpi_i2c_get(chip_address, data_address, data_size = "b")
chip_address |
an integer between 0x03 and 0x77. Use i2cdetect -y 1 to identify the address |
data_address |
an integer between 0x00 and 0xFF. This will come from the chip documentation |
data_size |
read a byte (b) or a word (w) from data_address |
data from the i2c device located at chip_address and data_address
#' # get a byte from an i2c device located at 0x77
rpi_i2c_get(chip_address = 0x77, data_address = 0xfa, data_size = 'b')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.