cancel
Showing results for 
Search instead for 
Did you mean: 

LPS33WTR Interrupt control

SGano.1
Associate II

Hi,

In the LPS33WTR pressure sensor,

I want to program the LPS33WTR FIFO to a certain pressure and configure the interrupt as Threshold-based interrupt.

No Where have I found the duration of the Interrupt logic change.

I want to use it as a HW trigger once a threshold is crossed (pressure decreases).

For how long will the Interrupt stay in 'high' state ( assuming it is configured as Active high AND Push - Pull).

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Eleon BORLINI
ST Employee

Hi @SGano.1​ ,

please note that the threshold that can be set for the FIFO is not related to a "pressure" threshold, i.e. a physical, but is referred to the number of samples stored in the FIFO memory. As reported in the datasheet p.18: "a FIFO threshold interrupt can be enabled (F_OVR bit in CTRL_REG3 (12h) in order to be raised when the FIFO is filled to the level specified by the WTM4:0 bits of FIFO_CTRL (14h)".

You can however of course set a threshold for a certain pressure in the THS_P_H (0Dh) and THS_P_L (0Ch). In this case, to generate an interrupt event based on a user-defined threshold, the DIFF_EN bit must be set to '1' and the threshold values stored the previous registers. When DIFF_EN = '1', the PHE bit or PLE bit (or both bits) has to be enabled. The PHE and PLE bits enable the interrupt generation on the positive or negative event respectively.

>> For how long will the Interrupt stay in 'high' state

If the interrupt is not latched, it will stay 1/ODR seconds, while if latched (LIR bit of the INTERRUPT_CFG (0Bh) register) it will stay high till the event has occurred.

You can however find more details in the datasheet, p.35 and 36.

-Eleon

View solution in original post

4 REPLIES 4
Eleon BORLINI
ST Employee

Hi @SGano.1​ ,

please note that the threshold that can be set for the FIFO is not related to a "pressure" threshold, i.e. a physical, but is referred to the number of samples stored in the FIFO memory. As reported in the datasheet p.18: "a FIFO threshold interrupt can be enabled (F_OVR bit in CTRL_REG3 (12h) in order to be raised when the FIFO is filled to the level specified by the WTM4:0 bits of FIFO_CTRL (14h)".

You can however of course set a threshold for a certain pressure in the THS_P_H (0Dh) and THS_P_L (0Ch). In this case, to generate an interrupt event based on a user-defined threshold, the DIFF_EN bit must be set to '1' and the threshold values stored the previous registers. When DIFF_EN = '1', the PHE bit or PLE bit (or both bits) has to be enabled. The PHE and PLE bits enable the interrupt generation on the positive or negative event respectively.

>> For how long will the Interrupt stay in 'high' state

If the interrupt is not latched, it will stay 1/ODR seconds, while if latched (LIR bit of the INTERRUPT_CFG (0Bh) register) it will stay high till the event has occurred.

You can however find more details in the datasheet, p.35 and 36.

-Eleon

SGano.1
Associate II

Thanks Eleon!

>> it will stay high till the event has occurred.

Do you mean after the Event had ended and the pressure has returned to above the threshold?

Hi @SGano.1​ ,

right, the interrupt should stay high until the pressure goes back down (or up) of the threshold.

-Eleon

ABlum.1
Associate

Hello Eleon,

I have two more questions.

  1. When using the interrupt for data ready indication if latched mode is used, when is the interrupt cleared?
  2. This is not related directly to the interrupt but - when working in one-shot mode what would be the response time of the device?

Thanks!