完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
我有一块带陀螺仪(L3GD20H)和Accel / Mag(LSM303D)的电路板。我正在使用I2C与传感器连接。我可以毫无问题地与Accel / Mag沟通。然而,陀螺仪出现在(7位)地址0x68处,它应该是0x6A(因为SA0为低)。我能够转储寄存器,其中一些是正确的(WHO_AM_I),但数据不正确。我已划定了线条,它们看起来很好,它只是在错误的地址回应。我附上了示波器读数和原理图。
有没有人见过这个?我已经探测过所有引脚,看起来是正确的。 谢谢。 以上来自于谷歌翻译 以下为原文 I've got a board with a Gyro (L3GD20H) and Accel/Mag (LSM303D). I'm interfacing with the sensors using I2C. I can communicate with the Accel/Mag without issues. However, the Gyro is showing up at (7bit) address 0x68 and it should be 0x6A (since SA0 is low). I'm able to dump the registers and some of them are correct (WHO_AM_I), however, the data isn't correct. I've scoped the lines and they look OK, it's just responding at the wrong address. I've attached the scope readings and the schematic. Has anyone seen this before? I've probed all the pins and they look correct. Thanks. |
|
相关推荐
2个回答
|
|
你好安德鲁,
如果SA0为高电平,则L3GD20H的7位地址为0x6B而不是0x68。但是,如果您能够读取一些具有正确值的寄存器,则问题将不在I2C地址中。您是否只将这两个传感器连接到I2C或同一个I2C上是否有另一个传感器?如果有两个传感器具有相同的I2C地址连接到同一总线,则可以观察到某些值正确且某些值不正确的行为。 最好的祝福, 玛丽安 以上来自于谷歌翻译 以下为原文 Hello Andrew, the 7bit address for L3GD20H if SA0 is high is 0x6B and not 0x68. But if you are able to read some registers with correct values the problem will not be in I2C address. Do you have only those two sensors connected to I2C or is there another sensor on the same I2C? The behavior that some values are correct and some not can be observed if there are two sensors with the same I2C address connected to the same bus. Best Regards, Marian |
|
|
|
你好安德鲁,
您附加的图片上的I2C通信是错误的。我通过正确的沟通附上图片。我的配置几乎与你的配置相同,只是我的SA0连接到1.8 V.我担心你的程序中有一些错误。 最好的祝福, 玛丽安 以上来自于谷歌翻译 以下为原文 Hello Andrew, the I2C communication on picture you attached is wrong. I attached picture with correct communication. My configuration is almost the same as yours, just my SA0 is connected to 1.8 V. I am afraid that you have some mistake in your program. Best Regards, Marian |
|
|
|
只有小组成员才能发言,加入小组>>
请教:在使用UDE STK时,单片机使用SPC560D30L1,在配置文件怎么设置或选择?里面只有SPC560D40的选项
2725 浏览 1 评论
3237 浏览 1 评论
请问是否有通过UART连接的两个微处理器之间实现双向值交换的方法?
1807 浏览 1 评论
3646 浏览 6 评论
6034 浏览 21 评论
1337浏览 4评论
197浏览 3评论
对H747I-DISCO写程序时将CN2的st-link复用为usart1,再次烧录时无法检测到stlink怎么解决?
350浏览 2评论
STM32G474RE芯片只是串口发个数据就发烫严重是怎么回事?
442浏览 2评论
STM32处理增量式编码器Z信号如何判断中断是正转的还是反向转的?
273浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-12-22 21:54 , Processed in 1.126316 second(s), Total 79, Slave 62 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号