Search code examples
pythonwindowsusbnfcrfid

Windows: Is there a python library for accessing RC522(RFID reader) with USB to TTL?


I am trying to read an rfid card on windows 10 using python. But I don't know how to go about. I have connected my RC522 to a USB-TTL device and my windows 10 picked it up once connected but now I would like to create a python application to interact with it. Any ideas on how I can achieve this?

Currently the connections are set as follows:

--------------------------
|  RC522      |  USB-TTL |
--------------------------
|RX/SDA/SS    |   TX     |
|TX/MISO/SCL  |   RX     |
|  GND        |   GND    |
|  3.3V       |   3.3V   |
--------------------------

In the end I would like to know if there is a python library that does this and if not maybe another language but the key focus here is the ability to access it via windows 10 to create custom applications without needing the Arduino IDE.


Solution

  • Pyserial provides a nice library for this type of communication. See example code here --> https://pyserial.readthedocs.io/en/latest/shortintro.html