Created
May 24, 2016 06:16
-
-
Save syaro/1896d9ca3c9d8b95e0e63739718631cd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import nfc | |
import time | |
servcode = 0x110B | |
def connected(tag): | |
service_code = [nfc.tag.tt3.ServiceCode(servcode >> 6, servcode & 0x3f)] | |
students_id = [nfc.tag.tt3.BlockCode(i) for i in range(1, 2)] | |
print tag.read_without_encryption(service_code, students_id) | |
time.sleep(3) | |
clf.connect(rdwr={'on-connect': connected}) | |
clf = nfc.ContactlessFrontend('usb') | |
clf.connect(rdwr={'on-connect': connected}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment