Combination of rfıd reader and sd card reader

For my Arduino project, I need to use sd card reader and rfıd reader components together, but they both use the same ports. What should I do.

An SD Card reader generally uses hardware SPI. e.g. 11-13 on Uno
An LCD backpack generally uses hardware I2C. e.g. A4-A5 on Uno

If you are not using a Uno, hardware SPI is on the 3x2 SPI header.
Hardware I2C is on the SDA, SCL pins.

Life is much easier if you post a link to the actual LCD and actual SD module that you have bought. e.g. Ebay sale page(s)

David.

Sorry, there was also an rfid reader (mfrc522) as an extra, rfid reader and sd reader ports are the same

Both interfaces are designed to be used by multiple devices on the same bus. Just like you have a single driver with multiple passengers on an automobile bus.

SPI devices have different /CS (chip-select) pins.
I2C devices have different Slave addresses.

If you want specific advice, please post links to the actual items that you have bought.

David.

use different CS lines for the sd card (i.e. pin 10) and rfid reader (i.e. pin 5).
sck, mosi, miso lines can be shared when both devices are SPI devices.
This is what a SPI bus is planned to be used for.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.