# SPI setup 2 devices, Pi 4

**URL:** <https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903>\
**Category:** Raspberry Pi\
**Created:** [3 December 2020 00:01 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903 "2020-12-03T00:01:08Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Peter105632](https://avatars.discourse-cdn.com/v4/letter/p/7ba0ec/32.png) [@Peter105632](https://forum.core-electronics.com.au/u/Peter105632)\
**Post date:** [3 December 2020 00:01 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903/1 "2020-12-03T00:01:08Z")

</div>

Hi I need to use 3.5 touch screen ( SKU: CE04868) and a RFID reader writer (SKU: CE07140).  
Both are using shared SPI pins. I need to know how to assign the pins to allow the devices to work.  
I can make them work as separate units but not together.

---

<div class="post-metadata">

**Author:** ![Robin57159](https://avatars.discourse-cdn.com/v4/letter/r/cc9497/32.png) [@Robin57159](https://forum.core-electronics.com.au/u/Robin57159)\
**Post date:** [3 December 2020 00:20 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903/2 "2020-12-03T00:20:41Z")

</div>

That’s correct and perfectly OK. It is the chip select pin (CS) pin which determines which device on the SPI bus is be addressed. Make sure the devices are using unique pins for CS when you define them in the code.

Check the Learning Centre for a tutorial on the SPI bus.

---

<div class="post-metadata">

**Author:** ![Peter105632](https://avatars.discourse-cdn.com/v4/letter/p/7ba0ec/32.png) [@Peter105632](https://forum.core-electronics.com.au/u/Peter105632)\
**Post date:** [3 December 2020 01:10 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903/3 "2020-12-03T01:10:25Z")

</div>

Is there a tutorial I can use, as I am new to the Pi world.

---

<div class="post-metadata">

**Author:** ![Robin57159](https://avatars.discourse-cdn.com/v4/letter/r/cc9497/32.png) [@Robin57159](https://forum.core-electronics.com.au/u/Robin57159)\
**Post date:** [3 December 2020 01:14 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903/4 "2020-12-03T01:14:59Z")

</div>

I have linked a couple of references in the following thread:

> [@Raspberry rpi spi bus want t](https://forum.core-electronics.com.au/t/raspberry-rpi-spi-bus-want-t/8867):
>
> does the raspberry pi have an spi bus gpio pins on the board if so can some body pls inform me of the bot the tx rx pins and power range sported i have i think a 16 Mb add on memory board that runs on the spi bus lines… i may be able to provide with help a programmable boot loader that you can text mode select at boot the sd-card or any usb port …also with the correct support nay be able to choose between booting of either the usb-2 port s or the usb 3 ports, this all may be possible …

---

<div class="post-metadata">

**Author:** ![Bryce](https://yyz2.discourse-cdn.com/flex028/user_avatar/forum.core-electronics.com.au/bryce/32/3631_2.png) [@Bryce](https://forum.core-electronics.com.au/u/Bryce)\
**Post date:** [3 December 2020 23:52 UTC](https://forum.core-electronics.com.au/t/spi-setup-2-devices-pi-4/8903/5 "2020-12-03T23:52:56Z")

</div>

> [@Peter105632](#):
>
> I am new to the Pi world

That’s excellent Peter! Glad to hear it. If you’re interested in learning all the basics in a formal sense I’d take a look at the workshop we’ve got totally free and online, I’ve linked it for you below. If there’s anything else that you need please let us know.

[https://core-electronics.com.au/tutorials/raspberry-pi/raspberry-pi-workshop-for-beginners.html](https://core-electronics.com.au/tutorials/raspberry-pi/raspberry-pi-workshop-for-beginners.html)

P.S. Here’s a bunch of tutorials on various Pi, make sure to send us an email if you have suggestions for more and we’ll see what we can do.

> **[Raspberry Pi Tutorials | Raspberry Pi Education Australia](https://core-electronics.com.au/guides/raspberry-pi/)**
>
> Raspberry Pi tutorials served straight up from the creative team at Core Electronics. We cover a range of uses from software through to hardware.
