วันอาทิตย์ที่ 4 กุมภาพันธ์ พ.ศ. 2561

Raspberry pi connect RFID Reader ( SL500 USB )


Raspberry pi connect RFID Reader ( SL500 USB )

We 'd like to use RFID card with Raspberry pi board for eMoney or RFID cash card  Application in canteen of school.

RFID Reader


We want to use USB RFID Reader. we choose RFID reader model SL500 USB.
For Thailand Shop http://arduinoandroid.lnwshop.com/product/4/rfid-nfc-reader-writer 

RFID Card


Famous RFID tag is NXP Mifare MF-1.


Overview


NXP® has developed the MIFARE® MF1ICS50 to be used in a contactless smart card according to ISO/IEC 14443 Type A.
The MIFARE MF1ICS50 IC is used in applications like public transport ticketing where major cities have adopted MIFARE as their e-ticketing solution of choice.
1.1 Key applications
  • Public transportation
  • Access control
  • Event ticketing
  • Gaming & identity
1.2 Anticollision
An intelligent anticollision function allows to operate more than one card in the field simultaneously. The anticollision algorithm selects each card individually and ensures that the execution of a transaction with a selected card is performed correctly without data corruption resulting from other cards in the field.
1.3 Simple integration and user convenience
The MF1ICS50 is designed for simple integration and user convenience. Which could allow complete ticketing transactions to be handled in less than 100 ms. Thus, the MF1ICS50 card user is not forced to stop at the reader leading to a high throughput at gates and reduced boarding times onto busses. The MIFARE card may also remain in the wallet during the transaction, even if there are coins in it.
1.4 Security
  • Mutual three pass authentication (ISO/IEC DIS 9798-2)
  • Individual set of two keys per sector (per application) to support multi-application with key hierarchy
  • Unique serial number for each device

  • 1 Kbyte, organized in 16 sectors with 4 blocks of 16 bytes each (one block consists of 16 byte)
  • User definable access conditions for each memory block
  • Data retention of 10 years.

Library and Demo

Read Block 0 ( Manufacturer Block )


         b0 88 3f 7b 7c                  88 04                          44 85 00 b4 2e f0 bb 6a a8

Source code on Github

https://github.com/amphancm/RaspberryPi_rfid_sl500

CODE
SL500 Python Library - rfid_sl500.py
Example Code
Read Block0 16 Bytes data - read_block0.py
Read loop - loop.py

Reference

SL500 C language

python

1 ความคิดเห็น: