我在带有串行闪存芯片的公共SPI总线上遇到LIS3DH器件问题。我想知道我是否可以做一些我不应该做的事情。
这两个器件共用一个公共SPI总线(SPC,SDI和SDO)。 LIS3DH和存储器各自具有单独的CS线。
一切正常,直到我尝试访问串行闪存中的特定内存位置。似乎LSI3DH虽然它的CS很高,但是它会监听SPC和SDI线,并将它们视为I2C SCL和SDA线。然后在非常特殊的模式条件下,当我希望LIS3DH保持“静音”时,它会检测到I2C启动条件。因此,在一些时钟周期之后,我看到SDI(SDA)线被拉低(与微控制器作斗争,而微控制器试图在此时保持高电平。)
我在想,因为LIS3DH上的“CS”线实际上是一个接口模式选择器(I2C / SPI),所以在公共SPI总线上使用LIS3DH器件是不安全的(使用任何其他器件)
对此情况的任何评论/意见将不胜感激。
以上来自于谷歌翻译
以下为原文
I am having a problem with an LIS3DH device on a common SPI bus with a serial flash memory chip. I am wondering if I may be doing something that I should not.
The two devices share a common SPI bus (SPC, SDI and SDO). The LIS3DH and the memory each have individual CS lines.
All works fine un
til I try to access particular memory locations in the serial flash. It seems as if the LSI3DH is, while it's CS is high, listening to the SPC and SDI lines and treating them like I2C SCL and SDA lines. Then under very particular pattern conditions, when I would have liked the LIS3DH to remain "silent", it detects an I2C Start condition. And so, some number of clock cycles later, I see the SDI (SDA) line being pulled down (fighting against the microcontroller, which was trying to keep it high at that point.)
I am thinking that, because the "CS" line on the LIS3DH is really an interface mode selector (I2C/SPI), it is unsafe to use LIS3DH devices on a common SPI bus (with ANY other device)
Any comments/observations on this situation would be much appreciated.