replace number with variable

i googled for changing the pin 22, i only found a hint to line 10 so i changed line 113 to use the variable from line 10 instead of the number
This commit is contained in:
Marek2k17 2018-03-20 10:55:12 +01:00 committed by GitHub
parent 8ddc994007
commit 68963702c1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -110,7 +110,7 @@ class MFRC522:
def __init__(self, dev='/dev/spidev0.0', spd=1000000):
spi.openSPI(device=dev,speed=spd)
GPIO.setmode(GPIO.BOARD)
GPIO.setup(22, GPIO.OUT)
GPIO.setup(NRSTPD, GPIO.OUT)
GPIO.output(self.NRSTPD, 1)
self.MFRC522_Init()