sent to 32 bit spi transfer problem

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

sent to 32 bit spi transfer problem

964 次查看
osmanuzun
Contributor I

Hi Dear,

I want to send PUSHR 32 bit data Field  for SPI  ,

I use to Continuous selection,

step by step

CONT1=1;

SPI1->PUSHR.B.EOQ=1;//The spi data is the last data transfer

SPI1->PUSHR.B.CONT=1;//KeepPCSN signas asserted beetween transfer  SPI1->MCR.B.CONT_SCKE=1;//continuous sck enable

SPI1->PUSHR.B.PCS_0=Assert;

SPI1->PUSHR.B.PCS_1=Assert;

SPI1->MCR.B.HALT=1;//stop transfer

SPI1->SR.B.EOQF=1;//E0q is set in the executing SPI command

SPI1->MCR.B.FRZ=1;//modified SPI transfer format enable

SPI1->PUSHR.B.TXDATA=0b0101010101010101;//send to data 1

SPI1->PUSHR.B.TXDATA=0b0101010101010101;//send to data 2

//I want to send TXDATA="data1data2 " //totaly 32 bit data;

SPI1->MCR.B.HALT=0;//start transfer

while( SPI1->SR.B.TCF == 0 );

//SPI1->SR.B.EOQF=0;//E0q is set in the executing SPI command

  //SPI1->MCR.B.FRZ=0;//modified SPI transfer format enable

SPI1->PUSHR.B.CONT=0;

SPI1->MCR.B.CONT_SCKE=0;//continuous sck enabl

How is the problem? Can you fixed problem please.Have a  nice workning day.

Best Regards,

Mcu model:K30X256VLK7

Osman UZUN

Kontrol System Engineer

osman.uzun@tumosan.com.tr

0 项奖励
回复
1 回复

783 次查看
jeremyzhou
NXP Employee
NXP Employee

Hi Osman,

I'd like confirm with you about theses queries as following.

1. What's exactly problems with the SPI transmission, please clarify in details.

2. Had you already captured the signal by using the oscilloscope or logic analyzer during SPI transmission?
Have a great day,
Ping

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复