Electronics

RFID 125Khz EM4100 Card Reader Module RDM630

AED 24.50

Low stock
1

Description

The RFID 125Khz EM4100 Card Reader Module RDM630 is a device that allows you to read EM4100-compatible RFID cards. It operates at a frequency of 125Khz and has a reading distance of up to 10 cm. It is a compact and easy-to-use module that is widely used for access control, identification, and other applications.

 

Package Includes:

  • 1 x RDM630 RFID 125Khz EM4100 Card Reader Module

 

Features:

  1. Frequency: The module operates at a frequency of 125Khz, which is the standard frequency used for low-frequency RFID communication.
  2. Compatibility: The module is compatible with EM4100-compatible RFID cards, which are widely used for access control, identification, and other applications.
  3. Reading distance: The module has a reading distance of up to 10 cm, which makes it suitable for applications where the reader needs to be in close proximity to the card.
  4. External antenna: The module has an external coil antenna that can be connected to the board using two wires. The antenna can be adjusted to optimize the reading distance and signal strength.
  5. Serial interface: The module can be connected to a microcontroller or other device using a simple serial interface, which makes it easy to integrate into a wide range of applications.
  6. LED indicators: The module comes with two LED indicators that provide feedback on the status of the module, such as when a card is detected or when the module is in standby mode.
  7. Low power consumption: The module has low power consumption, which makes it suitable for battery-powered applications.
  8. Compact size: The module is compact in size, which makes it easy to integrate into projects and applications where space is limited.
  9. Cost-effective: The module is cost-effective and provides a low-cost solution for reading EM4100 compatible RFID cards.

 

Description:

The RFID 125Khz EM4100 Card Reader Module RDM630 is a compact and easy-to-use module for reading EM4100-compatible RFID cards. It operates at a frequency of 125Khz, which is the standard frequency used for low-frequency RFID communication. The module has a reading distance of up to 10 cm, which makes it suitable for applications where the reader needs to be in close proximity to the card. The module is compatible with EM4100-compatible RFID cards, which are widely used for access control, identification, and other applications. These cards are often used for security purposes, such as granting access to a building or a room, or for tracking inventory or assets. The RFID 125Khz EM4100 Card Reader Module RDM630 is easy to use and requires minimal setup. It comes with an external coil antenna and can be connected to a microcontroller or other device using a simple serial interface. Once connected, the module can be configured to read and transmit data from the RFID card, making it easy to integrate into a wide range of applications.

 

Principle of Work:

The RFID 125Khz EM4100 Card Reader Module RDM630 works based on the principle of electromagnetic induction. When an EM4100-compatible RFID card is brought into the electromagnetic field created by the external antenna, it generates a small current in the card's coil. This current is then used to power the chip on the card, which in turn sends a signal back to the reader containing the card's unique ID number. The RDM630 module receives this signal through its external antenna and converts it into a digital signal that can be read by a microcontroller or other device through its serial interface. The module also provides feedback to the user through its LED indicators, which can be used to indicate when a card is detected or when the module is in standby mode.

 

Pinout of the Module:

  1. VCC: This pin is used to provide power to the module. It should be connected to a 5V power source.
  2. GND: This pin is the ground connection for the module. It should be connected to the ground of the power source.
  3. TX: This pin is used to transmit data from the module to an external device, such as a microcontroller or computer. It can be connected to the RX pin of the external device.
  4. LED1: This pin is connected to an LED that indicates when the module is in standby mode. When the LED is off, the module is in standby mode.
  5. LED2: This pin is connected to an LED that indicates when a card is detected by the module. When the LED is on, a card has been detected.
  6. ANT1-ANT2: This pin is used to connect the external coil antenna to the module. The antenna should be connected to this pin and the ground pin.

 

Applications: 

  1. Access Control Systems: The RDM630 module can be used in access control systems to grant or deny access to buildings, rooms, or areas based on the identification of a person carrying an RFID card.
  2. Time and Attendance Systems: The module can be used in time and attendance systems to track the attendance of employees or students by identifying them through their RFID cards.
  3. Inventory Management: The module can be used in inventory management systems to track the movement of goods and products by attaching RFID tags to them.
  4. Animal Tracking: The module can be used in animal tracking systems to monitor the movement of livestock or wildlife by attaching RFID tags to them.
  5. Library Management: The module can be used in libraries to automate the borrowing and return of books by attaching RFID tags to the books and RFID cards to the library members.

 

Circuit:

Connect the RFID module's TX pin to the Arduino's RX pin (pin 6), and connect the module's RX pin to the Arduino's TX pin (pin 8). The module's VCC and GND pins should also be connected to the Arduino's 5V and GND pins, respectively.

 

 

Library:

 

No need to install any external library  

Code:  

The code is for interfacing an RFID reader module, specifically the RDM630/RDM6300, with an Arduino board. The module communicates with the Arduino through a software serial connection using pins 6 (RX) and 8 (TX).

#include "SoftwareSerial.h"

const int BUFFER_SIZE = 14; // RFID DATA FRAME FORMAT: 1byte head (value: 2), 10byte data (2byte version + 8byte tag), 2byte checksum, 1byte tail (value: 3)
const int DATA_SIZE = 10; // 10byte data (2byte version + 8byte tag)
const int DATA_VERSION_SIZE = 2; // 2byte version (actual meaning of these two bytes may vary)
const int DATA_TAG_SIZE = 8; // 8byte tag
const int CHECKSUM_SIZE = 2; // 2byte checksum

SoftwareSerial ssrfid = SoftwareSerial(6,8); 

uint8_t buffer[BUFFER_SIZE]; // used to store an incoming data frame 
int buffer_index = 0;

void setup() {
 Serial.begin(9600); 
 
 ssrfid.begin(9600);
 ssrfid.listen(); 
 
 Serial.println(" INIT DONE");
}

void loop() {
  if (ssrfid.available() > 0){
    bool call_extract_tag = false;
    
    int ssvalue = ssrfid.read(); // read 
    if (ssvalue == -1) { // no data was read
      return;
    }

    if (ssvalue == 2) { // RDM630/RDM6300 found a tag => tag incoming 
      buffer_index = 0;
    } else if (ssvalue == 3) { // tag has been fully transmitted       
      call_extract_tag = true; // extract tag at the end of the function call
    }

    if (buffer_index >= BUFFER_SIZE) { // checking for a buffer overflow (It's very unlikely that an buffer overflow comes up!)
      Serial.println("Error: Buffer overflow detected! ");
      return;
    }
    
    buffer[buffer_index++] = ssvalue; // everything is alright => copy current value to buffer

    if (call_extract_tag == true) {
      if (buffer_index == BUFFER_SIZE) {
        unsigned tag = extract_tag();
      } else { // something is wrong... start again looking for preamble (value: 2)
        buffer_index = 0;
        return;
      }
    }    
  }    
}

unsigned extract_tag() {
    uint8_t msg_head = buffer[0];
    uint8_t *msg_data = buffer + 1; // 10 byte => data contains 2byte version + 8byte tag
    uint8_t *msg_data_version = msg_data;
    uint8_t *msg_data_tag = msg_data + 2;
    uint8_t *msg_checksum = buffer + 11; // 2 byte
    uint8_t msg_tail = buffer[13];

    // print message that was sent from RDM630/RDM6300
    Serial.println("--------");

    Serial.print("Message-Head: ");
    Serial.println(msg_head);

    Serial.println("Message-Data (HEX): ");
    for (int i = 0; i < DATA_VERSION_SIZE; ++i) {
      Serial.print(char(msg_data_version[i]));
    }
    Serial.println(" (version)");
    for (int i = 0; i < DATA_TAG_SIZE; ++i) {
      Serial.print(char(msg_data_tag[i]));
    }
    Serial.println(" (tag)");

    Serial.print("Message-Checksum (HEX): ");
    for (int i = 0; i < CHECKSUM_SIZE; ++i) {
      Serial.print(char(msg_checksum[i]));
    }
    Serial.println("");

    Serial.print("Message-Tail: ");
    Serial.println(msg_tail);

    Serial.println("--");

    long tag = hexstr_to_value(msg_data_tag, DATA_TAG_SIZE);
    Serial.print("Extracted Tag: ");
    Serial.println(tag);

    long checksum = 0;
    for (int i = 0; i < DATA_SIZE; i+= CHECKSUM_SIZE) {
      long val = hexstr_to_value(msg_data + i, CHECKSUM_SIZE);
      checksum ^= val;
    }
    Serial.print("Extracted Checksum (HEX): ");
    Serial.print(checksum, HEX);
    if (checksum == hexstr_to_value(msg_checksum, CHECKSUM_SIZE)) { // compare calculated checksum to retrieved checksum
      Serial.print(" (OK)"); // calculated checksum corresponds to transmitted checksum!
    } else {
      Serial.print(" (NOT OK)"); // checksums do not match
    }

    Serial.println("");
    Serial.println("--------");

    return tag;

}
long hexstr_to_value(char *str, unsigned int length) { // converts a hexadecimal value (encoded as ASCII string) to a numeric value
  char* copy = malloc((sizeof(char) * length) + 1); 
  memcpy(copy, str, sizeof(char) * length);
  copy[length] = '\0'; 
  // the variable "copy" is a copy of the parameter "str". "copy" has an additional '\0' element to make sure that "str" is null-terminated.
  long value = strtol(copy, NULL, 16);  // strtol converts a null-terminated string to a long value
  free(copy); // clean up 
  return value;
}

The code is designed to interface with an RFID reader module such as the RDM630 or RDM6300, which can be used to read data from RFID tags. The module communicates with a microcontroller (such as an Arduino) over a serial interface, and the code uses the SoftwareSerial library to create a software serial port on pins 6 and 8. we listen to the software serial port for incoming data from the RFID reader module. When a tag is detected by the RFID reader module, it sends a data frame to the microcontroller in the format of 14 bytes. The data frame contains a preamble (value: 2), 10 bytes of data (2 bytes for version information and 8 bytes for the tag ID), 2 bytes for a checksum, and a postamble (value: 3)then the code reads each byte of the incoming data frame from the software serial port and stores it in a buffer. When the entire data frame has been received (i.e., when the postamble is detected), the code extracts the tag ID from the buffer by parsing the data bytes and converting them from hexadecimal to a long integer value. The code also calculates a checksum from the received data bytes and compares it to the checksum included in the data frame to ensure that the data was received correctly. If the calculated checksum matches the received checksum, the code prints the tag ID and the checksum to the serial monitor for debugging purposes.

 

 

Technical Details:

  • Operating frequency: 125KHz
  • Support external antenna for greater range (recommended antenna: 5-10cm)
  • Maximum effective distance for reading tags: up to 50mm
  • Decoding time: less than 100ms
  • Interface: UART (Serial)
  • Supports EM4100 compatible read-only or read/write tags
  • Module size: 3.8 x 1.8 x 1.2cm
  • Operating voltage: 5V
  • Operating current: less than 50mA
  • Operating temperature: -10°C to +70°C
  • Storage temperature: -20°C to +80°C
  • Relative humidity: 5%-95% non-condensing

 

Resources:

Tutorial

 

Comparisons:

 

  1. Frequency: The RC522 operates at 13.56MHz, while the RDM630 and RDM6300 operate at 125kHz.
  2. Communication Protocol: The RC522 uses SPI communication protocol, whereas the RDM630 and RDM6300 use TTL-level serial communication.
  3. Compatibility: The RC522 is compatible with a wider range of RFID tags, including MIFARE Classic, MIFARE Ultralight, and NTAG213/NTAG215/NTAG216. The RDM630 and RDM6300 are typically used with EM4100-compatible tags.
  4. Range: The RC522 has a maximum effective reading distance of up to 50mm, while the RDM630 and RDM6300 have a shorter range of up to 100mm.
  5. Decoding Time: The RC522 has a decoding time of less than 100ms, while the RDM630 and RDM6300 have a decoding time of around 100-150ms.
  6. Size: The RC522 is larger, with a size of 8.5 x 5.2 x 1.2 cm, compared to the RDM630 and RDM6300, which have a size of 4.5 x 2.5 x 0.2 cm.
  7. Voltage: Both the RC522 and RDM630/RDM6300 operate at 5V.