嗨,
我正在研究LIS2DH12,配置它时遇到问题。我想使用Stream-to-FIFO模式,我希望INT1在其中一个加速轴高于阈值时触发。我已配置LIS2DH12寄存器来执行此操作。
然后我这样做:
我初始化所有registerI触发interrup
ti读取FIF中的所有数据FIFO是空的(FIFO_SRC_REG中的0x20)我读取INT1_SRC以清除IA位,并且我读取0x15。此后FIFO仍为空并且LIS2DH12不填充他,你知道为什么FIFO不以流模式返回吗?
ps:INT_1被锁存,但读取INT1_SRC必须清除它。
#interrupts#lis2dh12#stream-to-fifo
以上来自于谷歌翻译
以下为原文
Hi,
I'm working on the LIS2DH12 and I have issues when I configure it. I want to use the Stream-to-FIFO mode, and I want INT1 to trigger when one of the acceleration axis is above the threshold. I have configured the LIS2DH12 registers to perform this.
Then i do this:
- I initialialize all the register
- I trigger the interrupt
- I read all the data in the FIFO
- When the FIFO is empty (0x20 in FIFO_SRC_REG ) I read the INT1_SRC in order to clear the IA bit, and I read 0x15.
After this the FIFO still empty and the LIS2DH12 doesn't fill him, do you have an idea why the FIFO doesn't return in stream mode?
ps: INT_1 is latched, but reading INT1_SRC must clear it.
#interrupts #lis2dh12 #stream-to-fifo