Merge branch '1.0-local' into 1.0
This commit is contained in:
commit
bc457ef31f
|
@ -20,7 +20,14 @@ MIFAREReader = MFRC522.MFRC522()
|
||||||
|
|
||||||
|
|
||||||
# If we have the UID, continue
|
# If we have the UID, continue
|
||||||
if status == MIFAREReader.MI_OK:
|
while status != MIFAREReader.MI_OK:
|
||||||
|
|
||||||
|
# Scan for cards
|
||||||
|
(status,TagType) = MIFAREReader.MFRC522_Request(MIFAREReader.PICC_REQIDL)
|
||||||
|
|
||||||
|
# Get the UID of the card
|
||||||
|
(status,uid) = MIFAREReader.MFRC522_Anticoll()
|
||||||
|
|
||||||
|
|
||||||
# Print UID
|
# Print UID
|
||||||
suid = str(hex(uid[0]))[2:];
|
suid = str(hex(uid[0]))[2:];
|
||||||
|
@ -31,9 +38,3 @@ if status == MIFAREReader.MI_OK:
|
||||||
print suid;
|
print suid;
|
||||||
|
|
||||||
exit(0);
|
exit(0);
|
||||||
|
|
||||||
else:
|
|
||||||
|
|
||||||
print 127;
|
|
||||||
exit(127);
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue