PCI SPI interface card

Hi All,

I am developing an embedded product, and I need to talk to it using the MPU's SPI interface. I have been looking around for a cheap PCI card that has an SPI interface on it but I am having a hard time finding one that is not a programmer. Does anyone have any recommendations for a card that I could use to send and receive bytes to my MPU (ie. a simple card with a bidirectional DLL driver) ?

Thanks, Phil

Reply to
psd
Loading thread data ...

Phil,

How fast do you want to talk over SPI? I presume you are attempting to talk to it from a PC. What operating system? Any particular reason you want SPI as the interface from the PC to the embedded target, (kind of strange)? It might be easier to bit-bang asynchronous communications.

I've seen PC-SPI before using a line from a serial port, (Circuit Cellar) but you'll still needed an electric voltage conversion, (schematic in article). It was very slow, but that application only needed 32 bits at 7.5Hz. There is Win32 C code in the article. See:

formatting link

If you buy something off the shelve for $295 see:

formatting link

Or if you are proficient with microcontrollers you could buy any off the self board for $25-$49 (TI,Microchip, Atmel...) and program your own converter.

But if you are willing to do this and have the capacity on your embedded product, then I'd just bit-bang the asynchronous comm on your target, (pretty easy to do and lots of example code available).

Reply to
Freelance Embedded Systems Engineer

How fast does this need to go ?

FTDI have SPI modes in their chips, so they would seem a natural solution.

formatting link

Parallel port bit-bang also works, but will be slower.

-jg

Reply to
Jim Granville

Phil

Does it have to be PCI? TotalPhase sell the Aardvark SPI widget but that uses USB.

Andrew

Reply to
Andrew Jackson

Hi Andrew,

I want to go with SPI because "in theory" I will be able to talk @

25 Mbps. At those speeds my MPU will need to pause the transmission when its buffer is full. USB has high bandwidth but high latency, so I was thinking a PCI card would work better for my application. A few months ago I saw a small website that had a simple PCI SPI card, but I lost the link, and I can't find it with google or yahoo, so I was hoping someone here might of it or another one.

Thanks for the reply and I will keep the Aardvark in mind if I can't locate a PCI version, Phil

Reply to
psd

talk to it from a PC. What operating system? =A0Any particular reason you wa= nt SPI as the interface from the PC to the embedded target, (kind of strange= )? =A0It might be easier to bit-bang asynchronous communications.

but you'll still needed an electric voltage conversion, (schematic in articl= e). It was very slow, but that application only needed 32 bits at 7.5Hz. =A0= There is Win32 C code in the article. =A0See:

formatting link
dfs/SynchronousComm.pdf

er.com/spispec.htm

elf board for $25-$49 (TI,Microchip, Atmel...) and program your own converte= r.

roduct, then I'd just bit-bang the asynchronous comm on your target, (pretty= easy to do and lots of example code available).

Hi,

I need a low pin count, full duplex interface. It also has to be incredibly fast because I have to program a 256 MB NAND flash chip. SPI is the best choice for me because my MPU can operate at 25 Mbps in master mode ! I have I2C and UART ports available too, but they are not as fast as SPI.

Thanks for the tip, I am hoping I will not have to make my own boards or write my own low level device driver like you suggested. I did this before for another project, and it worked well, but I would rather buy the card from another company to save the labor.

Reply to
psd

Hi Jim,

I am programming a 256 MB flash chip. So the faster the better :)))

My MPU can pound out 25 Mbps in SPI master mode, so I was hoping to get something that could do at least 10 Mbps. In the worst case I could buy a blank PCI interface card and install a sister version of my MPU in it, BUT my MPU is capped at 4.5 Mbps in slave mode, so I would be doing a lot work to get a slower interface.

Thanks, Phil

Reply to
psd

I saw the other posts and your responses. "In theory" and " talk @ 25 Mbps." over SPI on a cable interface don't go together. SPI is intended for very short distances, i.e., typically on a single board. Noise will become a significant issue on any cable at all. At a minimum be prepared to use twisted pairs, maybe a piece of Cat 5 cable to make this work.

Scott

Reply to
Not Really Me

If you can use USB take a look at the LabJack. We used those for SPI, around $100, has nice screw terminals for the SPI wires and the little box itself can also be bolted down. You can pick any color as long as it is red :-)

--
Regards, Joerg

http://www.analogconsultants.com/
Reply to
Joerg

Might want to check how fast the chip will let you program it. Especially how "slow" it will let you erase it.

I would guess most of the PC-based SPI widgets you can get are going to be SPI masters not slaves.

And while USB has high latency, to move data at the kinds of rates you seem to want to you are going to have to pipeline the process, so learning to program across USB latency may not be a deal breaker - basically, you want to keep shoving data through and get deferred acknowledgement of success sometime later, not keep waiting on acknowledgement.

Reply to
cs_posting

))

Hi cs_post... and Andrew Jackson,

I guess once I try running it at this speed, my SPI cable length will have to be so short, I will end up having to use a USB device after all. I will have to come up with a protocol that only sends a single 2K flash page at a time. The USB host would wait for an acknowledgment before sending the next page ...

I can do this and it is probally a good way to go too, so thanks for the advice. Everybody here really helped me out ...

Take Care, Phil

Reply to
psd

If the SPI hardware side acts up at that speed you might want to add some AC termination so the signals arriving at the NAND chip look somewhat clean. A few ten pF in series with a resistor close to the cable impedance should do.

--
Regards, Joerg

http://www.analogconsultants.com/
Reply to
Joerg

I recently did 20MHz SPI over about 3ft with telephone wire because there was no spare spool of CAT-5 at that client. Worked.

--
Regards, Joerg

http://www.analogconsultants.com/
Reply to
Joerg

ed for

ecome

use

Thanks for the advice,

I will definately use it if I have any noise problems.

Phil

Reply to
psd

Or even ethernet. I program my SPI (or EzPort) device over ethernet.

Petter

--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Reply to
Petter Gustad

Then you could also look at some simple compression ? Is the Flash always full, and what data is going into the Flash ?

- also what is the FLASH write bandwidth ?

If this is one-way, USB will be ok, as the latency issues there mainly mess-up ping-pong type designs.

-jg

Reply to
Jim Granville

If you want to buy pre-built USB hardware that uses an FTDI 2232, try the Olimex JTAG USB OCD ($70 USD) and available from

formatting link

This interface is targeted toward the JTAG interface on ARM microcontrollers. However, JTAG and SPI have a fairly equivalent signal set: TMS/CS, TCK/SPICK, TDI/DI, TDO/DO. Thus, the hardware supports the SPI format also.

While you can talk SPI using the baseline D2XX drivers, FTDI has an SPI driver along with a sample application that talks to a small SPI EEPROM. If you want to transfer lots of data (and you do), then you will want to use the buffered write capability. I did have a problem when trying to use the buffered read capability, where I was getting an error that shouldn't happened.

If you want to plug in the hardware and interface to an SPI DLL, I'd probably spend the $300+ on a dedicated USB/sync serial pod. If your time is money, you'll be ahead of the game with a pre-engineered solution.

urb

Reply to
Paul Urbanus

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.