Code Monkey home page Code Monkey logo

pn532-hsu's People

Contributors

mfdogalindo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

pn532-hsu's Issues

Failed to authenticate

I'm using this library with PN532 and Raspberry Pi B+ but having trouble reading my cards. Here's the output I'm seeing when trying to scan.

Port:/dev/ttyAMA0
Found PN532 with firmware version: 1.6
Waiting for MiFare card...
Found card with UID: 0x23051749
Failed to authenticate block 0

The card is the one that came with the PN532 but I'm seeing the same with these cards as well.

Error: TypeError: must be str, not bytes

I am using Python 3.6, when I trying to run the code, error below appear, please help. TQ

Traceback (most recent call last):

File "", line 1, in
runfile('E:/PN532-HSU-master/readmifare.py', wdir='E:/PN532-HSU-master')

File "C:\Users\Lam\Anaconda3\envs\tfgpu36v2\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 668, in runfile
execfile(filename, namespace)

File "C:\Users\Lam\Anaconda3\envs\tfgpu36v2\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 108, in execfile
exec(compile(f.read(), filename, 'exec'), namespace)

File "E:/PN532-HSU-master/readmifare.py", line 41, in
pn532.SAM_configuration()

File "E:\PN532-HSU-master\PN532.py", line 333, in SAM_configuration
self.call_function(PN532_COMMAND_SAMCONFIGURATION, params=[0x01, 0x14, 0x01])

File "E:\PN532-HSU-master\PN532.py", line 297, in call_function
if not self._write_frame(data):

File "E:\PN532-HSU-master\PN532.py", line 204, in _write_frame
ack = self._ack_wait(1000)

File "E:\PN532-HSU-master\PN532.py", line 216, in _ack_wait
rx_info += self.ser.read(self.ser.inWaiting())

TypeError: must be str, not bytes

GPIO configuration

Does this depend upon a particular pin configuration?

According to a diagram I found for the RasberryPi 3 I am using, it seems like the following would be right

GPIO 8 > Tx (SDA)
GPIO 10 > Rx (SCL)

Thanks!!!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.