writeBytesReg method

void writeBytesReg(
  1. int address,
  2. int register,
  3. List<int> byteData
)

Writes byteData to the register of the I2C device with the address.

Implementation

void writeBytesReg(int address, int register, List<int> byteData) {
  var data = <I2Cmsg>[];
  var bData = <int>[];
  bData.add(register);
  bData.addAll(byteData);
  data.add(I2Cmsg.buffer(address, [], bData));
  var result = transfer(data);
  result.dispose();
}