Interfacing with two different SPI components?

I'm trying to use both an SD card and an LCD screen (link) that need pins 9 - 12 to talk to the Arduino. Is there any way to do this, or is it not possible..?

Thanks

That display doesn't have an SPI interface: it's I2C, which uses analog pins 4 and 5. If you check the seller's website:

there are two different versions of the display. I'm pretty sure I've seen an Arduino driver mentioned for the Philips chip, but I don't remember whether there's one for the Epson chip. Make sure there's an Epson driver, or that you can specify that you're getting a supported one.

There are similar LCDs being sold without the convenient carrier PCB for less than half the price, but they also require you to solder to a tiny SMD connector. It's a tough call, even for a cheapskate like me :slight_smile:

Ran

Well my reading says it is SPI, the question at the end "Is it SPI or I2C" answer "It's SPI" seems to be the clincher.

So to answer the question yes you can use more than one device on the SPI bus. You simply have to wire the ~CE (Not Chip enable) of each device to another Arduino pin and put the one low that you want to talk to. The clock and data can go to both devices.

Oh, very cool. Sorry, I'm new to SPI, will any digital input work? Then I simply set it as an input to use that one? And since it's an LCD screen, it seems like it would need to be constantly activated, or is that only necessary to update the screen?

SPI can be kinda hairy, as I've found more and more trying to integrate an arduino as a gateway between an SPI enabled blackfin based acoustics processing system and a small pc. What I've learned you can find here, the information itself might not be all that immediately relevant but I think I give a decent description of the SPI related registers you have to edit as well as my thought process in setting things up. Hope this helps!

http://thecodebender.com/journal/2009/2/18/making-the-arduino-speak-spi-and-talk-to-a-blackfin.html

or is that only necessary to update the screen?

It only needs enabling when you want to talk to it.

Then I simply set it as an input to use that one?

No you set the Arduino pin to an output, wire it to the chip enable line and put that output to a zero, do the SPI transfer then put it to a one.
Do this for each SPI device you have, each device a different output pin.

Have the SPI data and SPI clock common to all chips.

Ok. Is chip enable the same as chip select? Thanks for all your help!

Is chip enable the same as chip select

Yes.