cancel
Showing results for 
Search instead for 
Did you mean: 

Configure interrupt for LIS2DH12

P M
Associate II
Posted on April 24, 2018 at 17:11

I am trying to configure an interrupt on a LIS2DH12 in order to detect when the device is being hit.

I tried just configuring one axes to generate the interrupt. But Interrupt is never being fired (Or it is fired constantly). This is my current configuration:

20---- 67

21---- 0

22---- 40

23---- 0

24---- 8

25---- 0

26---- 0

27---- ff

28---- 40

29---- 0

2a---- c0

2b---- ff

2c---- 80

2d---- 44

2e---- 0

2f---- 20

30---- 10

31---- 55

32---- 40

33---- 0

34---- 0

35---- 0

36---- 0

37---- 0

38---- 0

39---- 0

3a---- 0

3b---- 0

3c---- 0

3d---- 0

3e---- 0

Leaving the device over the table where I work, gives a constant measurement of:

x:     0    y:    0    z:   63

And int1Source register gives 0x25 which seems to be 0010 0101. I have just configured ZLow to trigger the interrupt but I get that XL, YL and ZH but not IA so interrupt is not generated by register. INT1 pin is always on in this case. 

What should I do in order to configure a movement in any of the 3 axis? I want that my device stays in a position and detect any movement in any of the axes configured over the threshold set(For example, any movement higher than 1G). But I think I cannot detect at the same time ZH or ZL, XL or XH or YL or YH. I mean, if the device reads 64, trigger an interrupt over 0 or 128 in that axes. Is this possible?

#lis2dh12
0 REPLIES 0