0
\$\begingroup\$

I have four SPI-controlled chips which I want to control from Zynq-7020 via an FMC LPC connector. Each chip/device requires an SCLK, MISO, MOSI and CS line.

I'd like to give each device their own separate SPI bus, but for my given application, I don't have enough clock capable (CC) pins on the FMC LPC connector to give each device their own SPI SCLK. I do have enough pins to give each device separate MISO, MOSI and CS lines. There are a few options on what I could do, and I am wondering what the advantages/disadvantages of each would be:

1) Every device shares a single SPI bus (Separate CS lines, but shared SCLK, MISO, MOSI)

2) Shared SCLK, but separate MISO, MOSI, and CS lines for each device

3) Separate SPI buses, driving SCLKs through LA pins instead of CC pins on the FMC LPC interface. (I am not sure if my FPGA would like that I am driving a clock from a non-CC pin)

My target device is a PCB, what implications would each of the three options have on my design, and what would be the best option?

\$\endgroup\$
  • 1
    \$\begingroup\$ Give the FMC spec a careful reading -- your SPI clocks are probably going to be well within the speed that the LPC data pins can handle. I suspect -- but don't know -- that "clock capable" means clocks at FPGA-ish speeds, not SPI-ish speeds. \$\endgroup\$ – TimWescott Apr 3 at 0:13
  • \$\begingroup\$ @TimWescott Do you have a link to the spec? I am unable to find one that defines the pin speeds and capabilities \$\endgroup\$ – Rishub Nagpal Apr 3 at 0:33
  • \$\begingroup\$ I don't, but my gut feel is that if you're going to be clocking at 1MHz or less you can just use single-ended data lines and don't worry. If you're going to be clocking up to 20MHz or so, you can probably get away with it, but if it were me I'd want to look at the signals on a scope. \$\endgroup\$ – TimWescott Apr 3 at 0:53
  • \$\begingroup\$ you are probably right - I will try to get 1mhz off the pin on my scope and see. I want to be thorough as this is my first pcb! \$\endgroup\$ – Rishub Nagpal Apr 3 at 1:39
0
\$\begingroup\$

1 - If your SPI clock is slow, less than 10 MHz, you can use a GPIO to generate the clock. At this speed, you have enough timing margin, you don't need a dedicated clock output. The SPI "Clock" can be generated using a counter.

2 - Having a dedicated SPI clock is usually better for EMC. I have a seen a few cases where a slow-ish free-running clock would cause noise and EMC problems.

3 - Having seperate SPI links mean you can communicate in parallel with these devices. It can be helpful in some applications...

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.