Reading GY-81 BMA180 accelerometer control registers

Hi Everyone,

I develop vibrometer application ( and I have GY-81 board to evaluate. That board has BMA180 accelerometer. So I downloaded the test sketch from the internet.

I put that sketch here:

Before running that sketch I also ran i2c scanner sketch, it has returned 0x38 address for the accelerometer. That address was different to the 0x40 address that was in the downloaded sketch, so I changed it to 0x38.

After that, the said sketch has started to work and report meaningful data.

Then I wanted to read a control register, so I put these lines in to the test sketch:

  readFrom(BMA180_ADDRESS, BMA180_BW,1,temp);
  Serial.print("Read test: bw=");

The result was 0xff - all bits have been read as ones, which is not what I expected.

If you own that board, could you try my sketch and see if you can read back a control register?

Sorry, I just discovered I have BMA020 on that board, by coincidence it was compatible with BMA180 in the data registers, but all other registers are different.