Compare commits
8 Commits
40df6174a9
...
main
Author | SHA1 | Date | |
---|---|---|---|
5affbb0043 | |||
|
cfb618134e | ||
cfea64d258 | |||
e86a794582 | |||
|
bb9f650edd | ||
|
54eeebdb0f | ||
|
f63cb0f92a | ||
|
165df2de5a |
2
.idea/misc.xml
generated
2
.idea/misc.xml
generated
@@ -3,5 +3,5 @@
|
||||
<component name="Black">
|
||||
<option name="sdkName" value="Python 3.12 (CNSA-276-FP)" />
|
||||
</component>
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.11 (CNSA-276-FP) (2)" project-jdk-type="Python SDK" />
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.12 (CNSA-276-FP)" project-jdk-type="Python SDK" />
|
||||
</project>
|
9
main.py
9
main.py
@@ -33,7 +33,7 @@ On Windows, the native WebAuthn API will be used.
|
||||
"""
|
||||
import time
|
||||
import configparser
|
||||
gpie = False
|
||||
gpie = True
|
||||
if gpie:
|
||||
import RPi.GPIO as GPIO
|
||||
import pickle
|
||||
@@ -47,11 +47,12 @@ import sys
|
||||
import ctypes
|
||||
from fido2.ctap2 import Ctap2
|
||||
from fido2 import cbor
|
||||
# from fido2 import CtapNfcDevice
|
||||
|
||||
config = configparser.ConfigParser()
|
||||
|
||||
config.read('config.ini')
|
||||
|
||||
# test
|
||||
dbusername = config.get('Setup', 'dbusername')
|
||||
dbpassword = config.get('Setup', 'dbpassword')
|
||||
dbname = config.get('Setup', 'dbname')
|
||||
@@ -105,7 +106,7 @@ class CliInteraction(UserInteraction):
|
||||
|
||||
|
||||
while True:
|
||||
isNfc = False
|
||||
# isNfc = False
|
||||
if gpie:
|
||||
GPIO.output(door, GPIO.LOW)
|
||||
|
||||
@@ -326,7 +327,7 @@ while True:
|
||||
|
||||
GPIO.output(greenLed, GPIO.HIGH)
|
||||
GPIO.output(door, GPIO.HIGH)
|
||||
time.sleep(5)
|
||||
time.sleep(3)
|
||||
GPIO.output(greenLed, GPIO.LOW)
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user