完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
电子发烧友论坛|
你好
我按如下方式配置了LSM303DLHC加速度计。 CTRL_REG1_A,带有0x77 // 400hz数据 CTRL_REG4_A与0x00 //小端 并开始从OUT___A寄存器读取数据。 但我可以找到一些东西,发现下部的半字节一直都是零 OUT___A,OUT___A,OUT___A寄存器。 那么LSM303 12bit中的数据左对齐还是我遗漏了什么? 注意:在数据表中我发现它是16位,但在某些驱动程序样本中,数据寄存器的值被组合并右移4位(我假设这是为了补偿左对齐数据) 问候 HPC #lsm303dlhc-data-format#lsm303dlhc 以上来自于谷歌翻译 以下为原文 Hi I configured the LSM303DLHC accelerometer as follows. CTRL_REG1_A with 0x77 //400hz data CTRL_REG4_A with 0x00 //Little endian And started reading the data from the OUT___A registers. But I could find something that the lower nibble was found to be zero all the time in the OUT___A, OUT___A, OUT___A registers. So is the data in LSM303 12bit left justified or am I missing something? Note: In datasheet i found it is 16bit but in some driver samples the values of the data registers are combined and right shifted by 4 bits (I assume this is to compensate the left justified data) Regards HpC #lsm303dlhc-data-format #lsm303dlhc |
|
相关推荐
3个回答
|
|
|
也许LSM303DLH的规格在这个问题上更具信息性。
以上来自于谷歌翻译 以下为原文 maybe spec of LSM303DLH is more informative regarding that issue. |
|
|
|
|
|
谢谢
但我已经完成了规范,但没有提到这个问题...... 以上来自于谷歌翻译 以下为原文 Thanks But I have gone through the spec, but nothing is mentioned threre regarding this... |
|
|
|
|
|
是的,他们左对齐16位宽。您还可以通过查看输出并使用重力作为参考来验证这一点。例如,如果您设置范围为+ -2G(默认值),您将看到当您使加速度计水平时,您将在Z轴上读取大约16k(+ - 取决于哪一端向上)并关闭在另外2个轴上为0。 + - 32k将是满量程,如果左对齐,1G是半满量程。
以上来自于谷歌翻译 以下为原文 Yes, they are left justified 16 bits wide. You can also verify this by looking at your output and using gravity as a reference. For example, if you set the range for +-2G (the default) you will see that when you have the accelerometer horizontal you will have a reading of about 16k (+- depending on which end is up) on the Z axis and close to 0 on the other 2 axes. +- 32k would be Full Scale if left justified and 1G is half full scale. |
|
|
|
|
只有小组成员才能发言,加入小组>>
stm32mp157的异核通信的rpmsg_sdb的m4固件和a7驱动该如何编写?
1453 浏览 0 评论
stm32f103用freertos对一个采样率为1kHz的传感器,进行采样,数据出差
1502 浏览 0 评论
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
3649 浏览 1 评论
3842 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
2461 浏览 1 评论
STM32H7打开DCache后,出现了串口接收信息为空的现象,是哪里出了问题?
727浏览 5评论
用NANO STM32F103RBT6的开发板烧录不了是哪里出了问题?
661浏览 5评论
710浏览 5评论
外部中断触发类型为双边沿触发,进入中断回调后有什么办法判断该边沿是上升沿还是下降沿?
941浏览 5评论
STM32L071CBT6低温环境下无法正常工作是什么原因引起的?
745浏览 5评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-2 05:25 , Processed in 0.800414 second(s), Total 76, Slave 59 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
3853