rpi_i2c_get: Return a byte from an i2c device

View source: R/rpi_i2c_get.R

rpi_i2c_getR Documentation

Return a byte from an i2c device

Description

Return a byte from an i2c device

Usage

rpi_i2c_get(chip_address, data_address, data_size = "b")

Arguments

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

Value

data from the i2c device located at chip_address and data_address

Examples


#' # get a byte from an i2c device located at 0x77
rpi_i2c_get(chip_address = 0x77, data_address = 0xfa, data_size = 'b')


mnr/rpigpior documentation built on May 3, 2024, 12:14 a.m.