LIS3DSH no output data
Hi all,
I'm trying to work with the LIS3DSH but i'm not getting any output data.
I have verified the SPI is working, I can write to and read back numbers from the registers so I know they are getting set correctly. I'm using the initialisation code below. To get the angles I read from the output registers but they are always the same (all 0 apart from the Z MSB at 33). The temperature register also doesn't change (always 0) at anytime of day.
Any advice would be great, thanks.
// Configure LIS3DSH
LIS3DSH_WriteReg(LIS3DSH_CTRL_REG4, 0x57); // 50SPS, all axes, continuous update
LIS3DSH_WriteReg(LIS3DSH_CTRL_REG5, 0xC0); // 50Hz bandwidth, +/-2g, no self test, 4 wire SPI
LIS3DSH_WriteReg(LIS3DSH_CTRL_REG6, 0x10); // No FIFO, auto increment, no interrupt outputs
LIS3DSH_WriteReg(LIS3DSH_FIFO_CTRL_REG, 0x00); // No FIFO, don't care (watermark)