Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError #83

Open
niwla23 opened this issue Sep 28, 2019 · 6 comments
Open

TypeError #83

niwla23 opened this issue Sep 28, 2019 · 6 comments

Comments

@niwla23
Copy link

niwla23 commented Sep 28, 2019

pi@raspberrypi:~/MFRC522-python $ python3 Write.py 
/home/pi/MFRC522-python/MFRC522.py:133: RuntimeWarning: This channel is already in use, continuing anyway.  Use GPIO.setwarnings(False) to disable warnings.
  GPIO.setup(self.NRSTPD, GPIO.OUT)
Traceback (most recent call last):
  File "Write.py", line 41, in <module>
    MIFAREReader = MFRC522.MFRC522()
  File "/home/pi/MFRC522-python/MFRC522.py", line 135, in __init__
    self.MFRC522_Init()
  File "/home/pi/MFRC522-python/MFRC522.py", line 406, in MFRC522_Init
    self.MFRC522_Reset();
  File "/home/pi/MFRC522-python/MFRC522.py", line 138, in MFRC522_Reset
    self.Write_MFRC522(self.CommandReg, self.PCD_RESETPHASE)
  File "/home/pi/MFRC522-python/MFRC522.py", line 141, in Write_MFRC522
    spi.transfer(((addr<<1)&0x7E,val))
TypeError: function takes exactly 2 arguments (1 given)

I fixed the brackets but getting this error in Read.py
please help me

@JoeLutz11
Copy link

i Have the same Problem!

@gunalp
Copy link

gunalp commented Oct 28, 2019

i have too

@Daniel2193
Copy link

52507f1

It fixes the errors but i cant get any readings -> card aren't detected but maybe someone can tell me why

@Daniel2193
Copy link

I'll try it again tomorrow

@Daniel2193
Copy link

I know a bit late but after you apply these patches everything works fine (27-11-19)

52507f1

@wahajmurtaza
Copy link

Just found the solution that worked for me

git clone https://github.com/lthiery/SPI-Py.git
cd SPI-Py
git checkout -b 8cce26b9ee6e69eb041e9d5665944b88688fca68
sudo python setup.py install

After that Enable Remote-GPIO for raspberry pi interface.

worked with python3 and 2 on Pi 4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants