SPI receive buffer doesn't equal send buffer when connecting SIN with SOUT. Help!

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

SPI receive buffer doesn't equal send buffer when connecting SIN with SOUT. Help!

1,315 次查看
samerbastawy
Contributor I

I have initialized an SPI instance, configured both slave and master configurations (same phase, polarity and everything), than connected SIN (PTB3) with SOUT (PTB1).

 

I am expecting to receive what I send when calling LPSPI_DRV_MasterTransfer() but for some reason that doesn't happen. Project is attached below. Please help.

Original Attachment has been moved to: lpspi_transfer_example.zip

标签 (2)
标记 (2)
0 项奖励
回复
1 回复

1,147 次查看
jiri_kral
NXP Employee
NXP Employee

Hi Samer, 

in your project you setup once SPI_0 as a master device and as a next step you setup the very same peripheral as a slave device. In attachment is fixed project - it is working with direct connection between pins PTB3 and PTB1 (J2 pin 9 and J4 pin 7 on EVB).  For more details you can look at this tutorial related to SPI basic usage/architecture.

Jiri 

0 项奖励
回复