ST意法半导体
直播中

赵鑫

7年用户 189经验值
私信 关注
[问答]

请问怎么才能将4线SPI与接口LSM9DS0连接?

我正在使用LSM9DS0进行设计。

我的目标是将4线SPI连接到MEMs设备。

这是我的界面设计。


我将接口2 SDO引脚的3:1多路复用器添加到MISO中。
我想知道我的方法适合与simgle 4线SPI连接。
如果存在其他想法,请告诉我。

我找不到任何LSM9DS0的参考设计。所以我不能参考任何设计。
ST是否有任何参考设计?
#4-wired-spi #interface-confliction#lsm9ds0 #interface

以上来自于谷歌翻译


以下为原文




I'm designing with LSM9DS0.

And my goal is interface a 4-wired SPI with the MEMs device.

This is my interface design.


I add a 3:1 mux for interface 2 SDO pins into a MISO.
I want to know that my approach is suitable for interfacing with a simgle 4-wired SPI.
If the other idea exist, please let me know.

I can't find any reference design for LSM9DS0. So I can't refer any design.
Is there any reference design ST proposed?  
#4-wired-spi #interface-confliction #lsm9ds0 #interface

回帖(4)

孙婧

2019-6-13 09:32:46
SDO根据数据表(SPI的标准)排列三态,因此您只需将它们连接在一起即可。使用CS从相应的SDO引脚获取数据。确保它们是独占的,所以没有冲突。这就是我解释数据的方式,以及我将如何使用该部分。

以上来自于谷歌翻译


以下为原文





The SDO lines tri-state according to the data sheets (standard for SPI), so you just connect them together. Use CS to get data from the appropriate SDO pin. Make sure they are exclusive so there is no conflict. That is how I interpret the data, and how I will use the part.
举报

赵鑫

2019-6-13 09:50:15
谢谢ricky,还有一个问题。
 
 
 如果我使用一个器件作为SPI,那么另一个器件应该是I2C。
 
 由于SCL和SDA信号与SPI和I2C共用,我担心I2C器件有可能被激活。
 (LSM9DS0具有I2C从器件功能,从器件的事务通过START信号启动.I2C的START条件定义为SDA从高电平到低电平的转换,而SCL保持高电平.START信号从主器件发送到从器件。)
 
 如果SPI和I2C同时处于活动状态,哪个接口占主导地位?
 而且,如何解决这个问题?
 我应该通过控制SCLK和SDI的阶段来避免冲突吗?

以上来自于谷歌翻译


以下为原文





Thanks ricky and there is one more question.


If I use one device as SPI, then the other device should be I2C.

Because the SCL and SDA signal share with the SPI and I2C, I concern about that the I2C device has a possibility of activation.
(LSM9DS0 has I2C slave functionality and the transaction of slave is started through a START signal. The START condition of I2C is defined as a HIGH to LOW transition on SDA while the SCL is held HIGH. The START signal transmitted from master to slave.)

If the SPI and I2C are active on the same time, Which Interface is dominant?
And, How to solve this problem?
Should I avoid the confliction by controlling the SCLK and SDI's phase?
举报

孙婧

2019-6-13 10:09:28
数据手册第6节说如果CS接高电平,则部分为I2C,如果CS为低电平,则为SPI,而CS为低电平时发生的数据事务将为SPI,因此不存在冲突。沟通标准。由于您正在编程主机处理器,因此您可以控制CS和正在使用的prootcol。

以上来自于谷歌翻译


以下为原文





Data sheet section 6 says that if CS is tied high, then part is I2C, if CS is taken low, then it is SPI, and the data transactions that take place while CS is low will be SPI, so there is no conflict between the communication standards. Since you are programming the host processor, you have control of the CS and the prootcol in use.
举报

林邵嫔

2019-6-13 10:24:03
但这里有两个CS。我假设CS_G和CS_XM在内部用于选择SPI / I2C(如果CS_G为1且CS_XM为0,则是SPI或I2C模式下的SDA / SDI引脚)?
 
 
 在同一个SPI总线上,有没有比单个LSM9DS0更多SPI设备的解决方案?

以上来自于谷歌翻译


以下为原文





But here are two CS. I assume CS_G and CS_XM are or'ed internally to select SPI/I2C (If CS_G is 1 and CS_XM is 0, is the SDA/SDI-pin in SPI or I2C mode)?


And is there any solution for more SPI-devices than a single LSM9DS0 on the same SPI-bus?
举报

更多回帖

发帖
×
20
完善资料,
赚取积分