PIC 184520 SPI connections

Thread Starter

camerart

Joined Feb 25, 2013
3,730
Hi,

I am making a circuit using an 18F4520 PIC and want to make sure that I am connecting the SPI connections correctly.
I think MOSI=SDO PIN24 MISO=SDI PIN23 and guess that CS can be connected anywhere? Does the SCK PIN output the Crystal frequency? If so which PIN and how do I set it up please?
Camerart.
 

jpanhalt

Joined Jan 18, 2008
11,087
That is not necessarily correct in all cases, particularly when the device can be either a master or slave.

From Wikipedia:
The MOSI/MISO convention requires that, on devices using the alternate names, SDI on the master be connected to SDO on the slave, and vice versa.
Is the PIC master or slave?

John
 
Top