Help on SPI communication

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Not applicable

first of all, I have to say that I'm a total beginner in microcontrollers and that
I've never had any contact with them until I got XE167F Easy Kit.
So this is my starting point in learning about microcontrollers.
Also sorry for my English, I'm not a native English speaker.

I'm trying to connect XE167 to ETH Click Ethernet module using SPI. And I'm stuck at the very beginning.
The problem is, I can't get the SSC_vSendData function to work.

I used DAVE to configure USIC0 module.
Channel U0C0 is configured as ASC, channel U0C1 is configured as SSC.
I'm using port 10 pins as SPI lines.
Checked DAVE generated code and now I'm reading through the Infineon documentation and everything seems fine.
Well at least it all seems fine to me when I don't know exactly what I'm looking for.

I used oscilloscope to check the SPI lines.
When I run SendData function, there was no change SCK an MOSI lines as they stayed low.
But CS line went from 1 to 0 for 4,5 ms (although baud rate was set to 2,000 kbaud).

Also there is a tutorial on SPI communication with EEPROM.
Followed it step by step but it still didn't work.

Is there anything that I need to enable / disable before using SPI.
I tried different channels, changing settings in DAVE but I can't figure out why can't I get the clock on SCK line.

So what should I do?
Any help would be very much appreciated!

Best regards,
1 Reply
Not applicable
Hi Jiminy,

Do you mind list out how you configured the SPI on the DAVE?
It would be easy for us to reproduce your error and we can troubleshoot from there.
Thank you.