AnsweredAssumed Answered

LIS2DH not driving INT2 pin

Question asked by Giorgio Malaguti on Dec 5, 2017
Latest reply on Dec 11, 2017 by Giorgio Malaguti

hi,

I'm trying to program a LIS2DH via I2C, with a stm32l151rb. I'm interested in the activity mode, in order to wake up the stm32l1 using the INT2 pin connected to one micro's wake-up pin.

 

my configuration is:

/*CTRL_REG1*/ 0x29, //0b0010 1001 ODR@10Hz, LowPower mode enabled, Z disabled, Y disabled, X enabled, should drain 3uA
/*CTRL_REG2*/ 0x00, 
/*CTRL_REG3*/ 0x00, //disable all INT1 interrupts
/*CTRL_REG4*/ 0x10, //0b0001 0000 FS = +/- 4G, self test disabled
/*CTRL_REG5*/ 0x00, //do not latch
/*CTRL_REG6*/ 0x08, //0b0000 1000 enable activity interrupt on INT2
/*REFERENCE*/ 0x00, //was 0x1e
/*INT2_CFG*/ 0x02, //0b0000 0010 enable INT2 interrupt generation on X high events
/*INT2_THS*/ 0x20,
/*INT2_DUR*/ 0x10,
/*ACT_THS*/ 0x21, //0x1e = 1000mG (9.81 m/s^2)@4G FS refer to table 84 (pg.48) of datasheet
/*ACT_DUR*/ 0x14}; //0x01 = ~1 sec (900msec) refer to table 86 (pg.48) of datasheet

INT2_THS and INT2_DUR are set as ACT regs just for debug.

 

I'm reading (for debug) the OUT_X/Y/Z_H regs and they behave meaningfully, just as INT2_SRC as I get a 0x16 whenever the X-axis exceeds the threshold. However, the IA, as the INT2 pin, is always low.

 

what configuration am I missing?

Outcomes