Skip to main content
Visitor II
February 6, 2018
Question

LIS2DH self test & interrupt

  • February 6, 2018
  • 2 replies
  • 1018 views
Posted on February 06, 2018 at 09:55

Hi,

I am looking to test if the interrupt 1 and 2 are working correctly on a LIS2DH.

Is it possible to trigger interrupts with the self test functon ?

Thank you for the help

#lis2dh #self-test #interrput
    This topic has been closed for replies.

    2 replies

    ST Employee
    February 6, 2018
    Posted on February 06, 2018 at 21:06

    There is no built-in function to test interrupts.

    But you can for example setup threshold interrupt to some very high value and set the condition to enable interrupt if measured acceleration is below the threshold, so this will artificaly trigger the interrupt without need to do a movement with the sensor.

    Visitor II
    February 8, 2018
    Posted on February 08, 2018 at 23:41

    actually you can self test the interrupts with the built in self test.

    If you read the spec sheet look at sections 7.6 thru 7.9  

    in CRTL_REG3  you need to set the I1_AOI1 and 

    I1_AOI2 bits to 1 to activate the interrupts, by default they are 0.

    Weather in self test mode or using external vibration to test, these will activate the interrupts based on the preset threshold levels.

    You simply have to determine what levels you want to use if using vibration to test, in self test mode the interrupts should fire.

    One of the easiest is of course attach the LIS2DH int pins to interrupts on the micro to see if they fired.