You are reading a single comment by @billsalt and its replies. Click here to read the full conversation.
  • Hi All,
    I'm wanting to use the LIS3DH analog inputs along with accelerometer. I'm getting totally lost on addressing, it would appear. When I set it up using the LIS3DH module using the default address and read the accelerometer, everything is fine. When I try the following setup, returns a timeout error.

    Gotta be something very simple that I'm doing wrong; help?


    I2C1.setup({sda:B7, scl:B6});
    var addr = 0x18; //chip addr
    read = function(reg, len) {
      I2C1.writeTo(addr, reg);
      return I2C1.readFrom(addr, len);
    write = function(reg, data) {
      I2C1.writeTo(addr, [reg, data]);

Avatar for billsalt @billsalt started