完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
嗨支持,
我们想知道是否有任何寄存器配置允许我们将运动检测路由到INT1引脚并将自由落体检测路由到INT2引脚并且两者同时工作?两个引脚都布线/连接到我们的uP,我们需要启用这两个功能并同时工作。 提前致谢 以上来自于谷歌翻译 以下为原文 Hi support, We wonder if there is any register configuration that allow us to route the motion detection to the INT1 pin and the free-fall detection to the INT2 pin and both working at the same time? Both pins are routed/connected to our uP and we need to have these two features enabled and working at the same time. Thanks in advance |
|
相关推荐
1个回答
|
|
是的,这种配置是可行的。
您应该在中断引脚INT1(CTRL_REG3 0x22h)上启用中断发生器(AOI1),并在中断坑INT2(CTRL_REG6 0x25h)上启用中断发生器(AOI2)。 然后根据需要配置中断发生器。数据表中描述了INT1的配置,检查寄存器INT1_CFG,INT1_SRC,INT1_THS,INT1_DURATION。以下是INT2的寄存器列表,这些寄存器不在当前版本的数据表中,但很快就会发布。 另请查看应用说明 http://www.st.com/resource/en/application_note/cd00290365.pdf 有关自由落体和唤醒中断配置的详细信息。 INT2_CFG(34h) AOI - >和/或中断事件的组合。默认值:0 6D - >启用6方向检测功能。默认值:0。 ZHIE - >在Z高事件上启用中断生成。默认值:0 ZLIE - >在Z低事件上启用中断生成。默认值:0 YHIE - >在Y高事件上启用中断生成。默认值:0 YLIE - >在Y low事件上启用中断生成。默认值:0 XHIE - >在X高事件上启用中断生成。默认值:0 XLIE - >在X低事件上启用中断生成。默认值:0 INT2_SRC(35h) 0→不要换 IA->中断激活。 ZH-> Z高。默认值:0 ZL-> Z低。默认值:0 YH-> Y高。默认值:0 YL-> Y低。默认值:0 XH-> X高。默认值:0 XL-> X低。默认值:0 INT2_THS(36h) THS [6:0] - > 1 LSb = 16 mg @ FS = 2 g 1 LSb = 32 mg @ FS = 4 g 1 LSb = 62 mg @ FS = 8 g 1 LSb = 186 mg @ FS = 16 g INT2_DURATION(37h) D [6:0] 1 LSb = 1 / ODR(持续时间以N / ODR测量,其中N是持续时间寄存器的内容。) 以上来自于谷歌翻译 以下为原文 Yes, this configuration is possible. You should enable interrupt generator (AOI1) on interrupt pin INT1 (CTRL_REG3 0x22h) and interrupt generator (AOI2) on interrupt pit INT2 (CTRL_REG6 0x25h). Then configure interrupt generator according to you needs. Configuration of INT1 is described in the datasheet, check registers INT1_CFG, INT1_SRC, INT1_THS, INT1_DURATION. Below is the list of registers for INT2 which are not in the current version of the datasheet but will be published soon. Please also check application note http://www.st.com/resource/en/application_note/cd00290365.pdf for details about free fall and wake-up interrupt configuration. INT2_CFG (34h) AOI -> AND/OR combination of interrupt events. Default value: 0 6D -> 6-direction detection function enabled. Default value: 0. ZHIE ->Enable interrupt generation on Z high event. Default value: 0 ZLIE ->Enable interrupt generation on Z low event. Default value: 0 YHIE ->Enable interrupt generation on Y high event. Default value: 0 YLIE ->Enable interrupt generation on Y low event. Default value: 0 XHIE ->Enable interrupt generation on X high event. Default value: 0 XLIE ->Enable interrupt generation on X low event. Default value: 0 INT2_SRC (35h) 0-> do not change IA->Interrupt active. ZH->Z high. Default value: 0 ZL->Z low. Default value: 0 YH->Y high. Default value: 0 YL->Y low. Default value: 0 XH->X high. Default value: 0 XL->X low. Default value: 0 INT2_THS (36h) THS[6:0] -> 1 LSb = 16 mg @ FS = 2 g 1 LSb = 32 mg @ FS = 4 g 1 LSb = 62 mg @ FS = 8 g 1 LSb = 186 mg @ FS = 16 g INT2_DURATION (37h) D[6:0] 1 LSb = 1/ODR (Duration time is measured in N/ODR, where N is the content of the duration register.) |
|
|
|
只有小组成员才能发言,加入小组>>
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
2642 浏览 1 评论
3208 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
1783 浏览 1 评论
3611 浏览 6 评论
5988 浏览 21 评论
939浏览 4评论
1316浏览 4评论
在Linux上安装Atollic TRUEStudio的步骤有哪些呢?
584浏览 3评论
使用DMA激活某些外设会以导致外设无法工作的方式生成代码是怎么回事
1303浏览 3评论
1360浏览 3评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-24 07:19 , Processed in 1.077590 second(s), Total 76, Slave 59 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号