s32k146 lpspi communication

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

s32k146 lpspi communication

828 次查看
carolineliu_wiw
Contributor II

Hi everyone!

I' m using s32k146, trying to use lpspi communicaton. My s32k146 acts as Master Device to send data, and imu device act as slave device. But now I can not receive data from slave device.

Here is my lpspi configuration.

pastedImage_1.png

Here is my main code.

pastedImage_2.png

pastedImage_3.png

count = 1000;

can anyone help?

0 项奖励
2 回复数

746 次查看
Alexis_A
NXP TechSupport
NXP TechSupport

Hi carolineliu_wiw@163.com‌,

The configuration looks good, could you try using a logic analyzer/oscilloscope to check if the IMU is responding to the transfer? 

Also, check that pin configuration is done correctly. The following shows the pin configuration used in the SDK example.

pastedImage_1.png

Best Regards,

Alexis Andalon

0 项奖励

746 次查看
carolineliu_wiw
Contributor II

Hi Alexis Andalon,

Thanks for your reply.

I have already found the error. I use DMA, but I didn't  initialize it.

Now my spi communication can work.

:smileyhappy:

Liu

0 项奖励