Topic: about to go crazy, raspberry and pn532 breakout

I spent the whole day, checked and rechecked cables, connection soldering, everything is perfect...
I just can't make it working
raspberry + pn532 breakout board

of course I followed the instructions, connected directly uart port to the board... after spending hours in testing I noted that randomly I get:

pi@raspberrypi ~/src/libnfc/libnfc-1.7.0-rc7/examples $ ./nfc-poll
/home/pi/src/libnfc/libnfc-1.7.0-rc7/examples/.libs/lt-nfc-poll uses libnfc 1.7.0-rc7
pn53x_check_communication: Timeout
lt-nfc-poll: ERROR: Unable to open NFC device.
pi@raspberrypi ~/src/libnfc/libnfc-1.7.0-rc7/examples $ ./nfc-poll
/home/pi/src/libnfc/libnfc-1.7.0-rc7/examples/.libs/lt-nfc-poll uses libnfc 1.7.0-rc7
pn53x_check_communication: Timeout
lt-nfc-poll: ERROR: Unable to open NFC device.
pi@raspberrypi ~/src/libnfc/libnfc-1.7.0-rc7/examples $ ./nfc-poll
/home/pi/src/libnfc/libnfc-1.7.0-rc7/examples/.libs/lt-nfc-poll uses libnfc 1.7.0-rc7
NFC reader: pn532_uart:/dev/ttyAMA0 opened
NFC device will poll during 30000 ms (20 pollings of 300 ms for 5 modulations)
ISO/IEC 14443A (106 kbps) target:
    ATQA (SENS_RES): 00  04 
       UID (NFCID1): ad  e3  c9  23 
      SAK (SEL_RES): 08 
pi@raspberrypi ~/src/libnfc/libnfc-1.7.0-rc7/examples $ ./nfc-poll
/home/pi/src/libnfc/libnfc-1.7.0-rc7/examples/.libs/lt-nfc-poll uses libnfc 1.7.0-rc7
pn53x_check_communication: Timeout
lt-nfc-poll: ERROR: Unable to open NFC device.
pi@raspberrypi ~/src/libnfc/libnfc-1.7.0-rc7/examples $ ./nfc-poll
/home/pi/src/libnfc/libnfc-1.7.0-rc7/examples/.libs/lt-nfc-poll uses libnfc 1.7.0-rc7
pn53x_check_communication: Timeout
lt-nfc-poll: ERROR: Unable to open NFC device.


so .. it worked once... It must work again.
Thought to a timeout problem, incresed the timeout in the driver from 1 to 3 seconds, but .. didn't help

I really don't know what to try more....

thanks for any kind of help,

v

Re: about to go crazy, raspberry and pn532 breakout

3 (edited by vito.rallo 2013-08-06 22:55:50)

Re: about to go crazy, raspberry and pn532 breakout

Re: about to go crazy, raspberry and pn532 breakout

trying with older libnfc 1.5.1 ... there is no really an explanation, same story... working randomly yes and no...

pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
Connected to NFC reader: PN532 (/dev/ttyAMA0) - PN532 v1.6 (0x07)
NFC device will poll during 30000 ms (20 pollings of 300 ms for 5 modulations)
ISO/IEC 14443A (106 kbps) target:
    ATQA (SENS_RES): 00  04 
       UID (NFCID1): ad  e3  c9  23 
      SAK (SEL_RES): 08 
pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
pn53x_check_communication: Operation timed-out
No NFC device found.
pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
Connected to NFC reader: PN532 (/dev/ttyAMA0) - PN532 v1.6 (0x07)
NFC device will poll during 30000 ms (20 pollings of 300 ms for 5 modulations)
ISO/IEC 14443A (106 kbps) target:
    ATQA (SENS_RES): 00  04 
       UID (NFCID1): ad  e3  c9  23 
      SAK (SEL_RES): 08 
pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
pn53x_check_communication: Operation timed-out
No NFC device found.
pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
Connected to NFC reader: PN532 (/dev/ttyAMA0) - PN532 v1.6 (0x07)
NFC device will poll during 30000 ms (20 pollings of 300 ms for 5 modulations)
ISO/IEC 14443A (106 kbps) target:
    ATQA (SENS_RES): 00  04 
       UID (NFCID1): ad  e3  c9  23 
      SAK (SEL_RES): 08 
pi@raspberrypi ~/src/libnfc/libnfc-1.5.1/examples $ sudo ./nfc-poll
/home/pi/src/libnfc/libnfc-1.5.1/examples/.libs/lt-nfc-poll uses libnfc 1.5.1 (r)
pn53x_check_communication: Operation timed-out
No NFC device found.

Re: about to go crazy, raspberry and pn532 breakout

I am having exact same problem.
I have wired the pn532 as a uart device to the RPi and connected the power pin to the 5v pin on the Pi.  Looking at the app note, it seems to say it should never have more than 3.6v on that pin in a uart application.

Secondly, I have put the nfc-poll in an endless bash script loop and after a cold boot start start of this script, it reads the first MiFare card and keeps timing out after that.
In that state, I can pretty reliably get it to work again by breaking (hitting ctrl-c) out of a running nfc-poll command.
I believe this supports the idea that there is some state it gets stuck in (the idea that it may be missing an ACK or something during a deselect command???).

Anyway, has anybody got this working on thr Pi?
The frustrating part is that the python nfc libraries that I tried don't support MiFare tags that come standard eith the breakout board from Adafruit and guess what the tags are that they seem to push with this card?   
Let's think this through Adafruit...it's a Raspberry Pi so most people want python.  C'mon guys!

Re: about to go crazy, raspberry and pn532 breakout

understand man, thanks for getting back here... I am happy, don't feel alone with this issue anymore.
Yes, I tried the python way, of course but no support for the board. did you find a solution?

Re: about to go crazy, raspberry and pn532 breakout

Hi!

I am having the same problem that it can only poll if i use LIBNFC_LOG_LEVEL=3 and i checked my logs and i get "allow_intrusive_scan is set to false" but in the .conf file i put it to true. Dont know if this is connected but..... please help!