Rc522 Proteus Library Jun 2026
Below I cover:
#include #include #define SS_PIN 10 #define RST_PIN 9 #define GREEN_LED 2 #define RED_LED 3 MFRC522 rfid(SS_PIN, RST_PIN); // Define the Master Card UID that unlocks the system byte masterCard[] = 0x10, 0x23, 0x45, 0x67; void setup() Serial.begin(9600); SPI.begin(); rfid.PCD_Init(); pinMode(GREEN_LED, OUTPUT); pinMode(RED_LED, OUTPUT); Serial.println("System Ready: Scan your RFID Card..."); void loop() // Look for new cards if ( ! rfid.PICC_IsNewCardPresent()) return; // Select one of the cards if ( ! rfid.PICC_ReadCardSerial()) return; Serial.print("Card UID detected: "); bool accessGranted = true; for (byte i = 0; i < rfid.uid.size; i++) Serial.print(rfid.uid.uidByte[i] < 0x10 ? " 0" : " "); Serial.print(rfid.uid.uidByte[i], HEX); if (rfid.uid.uidByte[i] != masterCard[i]) accessGranted = false; Serial.println(); if (accessGranted) Serial.println("ACCESS GRANTED."); digitalWrite(GREEN_LED, HIGH); delay(2000); digitalWrite(GREEN_LED, LOW); else Serial.println("ACCESS DENIED."); digitalWrite(RED_LED, HIGH); delay(2000); digitalWrite(RED_LED, LOW); rfid.PICC_HaltA(); Use code with caution. Exporting the HEX File: In the Arduino IDE, go to .
C:\ProgramData\Labcenter Electronics\Proteus 8 Professional\Data\LIBRARY rc522 proteus library
If you only need to , simulate using a generic SPI EEPROM (e.g., 25AA1024 ) or a virtual terminal + custom code.
Place a Virtual Terminal, connecting TX to RX and RX to TX of the Arduino, or connect the serial output of the RFID module to the terminal to see tag IDs. Below I cover: #include #include #define SS_PIN 10
The MFRC522 is a highly integrated reader/writer IC for contactless communication at 13.56 MHz. It supports SPI, I²C, and UART protocols and is widely used with microcontrollers like Arduino, STM32, and Raspberry Pi. 3.3V Operating Frequency: 13.56 MHz Read Range: Up to 30mm (physically) 2. Finding and Installing the RC522 Proteus Library
Serial.println(); Serial.print("Message : "); content.toUpperCase(); Place a Virtual Terminal, connecting TX to RX
When you develop a system with an RC522 module, it typically requires: an external antenna coil, a few passive matching components, a 3.3V regulated power supply, and a host microcontroller to drive it via SPI. The goal of using a Proteus library is to faithfully replicate all these aspects inside a virtual environment.
Note: The "ProgramData" folder is hidden by default in Windows. Enable "Hidden items" in the File Explorer View tab to locate it. Step 3: Restart Proteus