How to fix the 'Time out, the Target has not answered' error?
Hello,
I am trying to setup llcp-based connection-oriented data transfer between two identical PN533 USB devices.
Client-side: Raspberry Pi, DL533N USB adapter, python 2.7 with libusb1 and pyserial, libusb-1.0-0, nfcpy trunk
Server-side: Win7, DL533N USB adapter, python 2.7.11 with libusb1 and pyserial, nfcpy trunk, libusb1.dll
Both PN533 devices successfully run the tagtool.py example but I do not manage to set up a stable llcp connection. The following error shows up [nfc.llcp.llc] ProtocolError(
May I ask for a pointer or two to get the llcp connection working reliably?
The server is started with: python llcp-test-server.py -d nfc.clf -f server.log
The client is started with: python llcp-test-client.py --test 01 -d nfc.clf -f client.log
Please note that the two devices are placed next to each other so that I do not have to physically move them to establish a connection.
The server logfile contains:
2016-03-22 17:21:46,312 [main] enable debug output for 'nfc.clf'
2016-03-22 17:21:46,312 [nfc.clf] searching for reader on path usb
2016-03-22 17:21:46,312 [nfc.clf.transport] using libusb-1.0.20
2016-03-22 17:21:46,312 [nfc.clf.transport] path matches '^(usb|)$'
2016-03-22 17:21:47,000 [nfc.clf.device] loading pn533 driver for usb:04cc:2533
2016-03-22 17:21:47,140 [nfc.clf.pn533] chipset is a PN533v2.7
2016-03-22 17:21:47,171 [nfc.clf.pn533] no eeprom attached
2016-03-22 17:21:47,171 [nfc.clf.pn533] no eeprom attached
2016-03-22 17:21:47,171 [nfc.clf.pn533] write analog settings for Type A
2016-03-22 17:21:47,171 [nfc.clf] using SensorID StickID PN533v2.7 at usb:003:003
2016-03-22 17:21:47,171 [nfc.clf] connect('llcp',)
2016-03-22 17:21:47,171 [main] bound connection-less echo server to port 16
2016-03-22 17:21:47,171 [main] bound connection-mode echo server to port 17
2016-03-22 17:21:47,171 [main] bound connection-mode dump server to port 18
2016-03-22 17:21:47,171 [nfc.clf] connect options after startup: llcp
2016-03-22 17:21:47,187 [nfc.clf] listen 1.000 seconds for DEP
2016-03-22 17:21:47,187 [nfc.clf.pn533] nfca_params 010183419440
2016-03-22 17:21:47,187 [nfc.clf.pn533] nfcf_params 01fe0e62d6c735b
2016-03-22 17:21:48,217 [nfc.clf] sense 106A atr_req=
2016-03-22 17:21:48,247 [nfc.clf.pn533] running DEP in 106 kbps active mode
2016-03-22 17:21:48,247 [nfc.clf] found 106A atr_req=
2016-03-22 17:21:48,247 [nfc.clf] >>> f006d404001203 timeout=0.1
2016-03-22 17:21:48,279 [nfc.clf] <<< f004d50500 0.031s
2016-03-22 17:21:48,279 [nfc.dep] running as NFC-DEP Initiator 424F active mode MIU=251 RWT=0.077329
2016-03-22 17:21:48,279 [nfc.llcp.llc] LLCP Link established as NFC-DEP Initiator
Local LLCP Settings
LLCP Version: 1.3
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Link Service: connection-less and connection-oriented
Data Protect: secure data transfer mode not supported
Service List: 0000000000000011 (SDP, LLC)
Remote LLCP Settings
LLCP Version: 1.3
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Link Service: connection-less and connection-oriented
Data Protect: secure data transfer mode is supported
Service List: 0000000000000011 (SDP, LLC)
2016-03-22 17:21:48,279 [nfc.clf] connected LLC: Local(MIU=2175, LTO=500ms) Remote(MIU=2175, LTO=500ms)
2016-03-22 17:21:48,295 [nfc.clf] >>> 06d406000000 timeout=
2016-03-22 17:21:48,418 [nfc.clf.pn533] Error 0x01: Time out, the Target has not answered
2016-03-22 17:21:48,418 [nfc.clf] >>> 04d40680 timeout=
2016-03-22 17:21:48,543 [nfc.clf.pn533] Error 0x01: Time out, the Target has not answered
2016-03-22 17:21:48,543 [nfc.clf] >>> 04d40680 timeout=
2016-03-22 17:21:48,653 [nfc.clf.pn533] Error 0x01: Time out, the Target has not answered
2016-03-22 17:21:48,653 [nfc.llcp.llc] ProtocolError(
2016-03-22 17:21:48,653 [nfc.clf] >>> 03d408 timeout=0.1
2016-03-22 17:21:48,778 [nfc.clf.pn533] Error 0x01: Time out, the Target has not answered
2016-03-22 17:21:48,778 [main] close connection-mode dump server socket
2016-03-22 17:21:48,778 [main] close connection-mode echo server socket
2016-03-22 17:21:48,778 [main] close connection-less echo server socket
the client logfile contains:
2016-03-22 17:21:46,855 [main] enable debug output for 'nfc.clf'
2016-03-22 17:21:46,856 [nfc.clf] searching for reader on path usb
2016-03-22 17:21:46,857 [nfc.clf.transport] using libusb-1.0.11
2016-03-22 17:21:46,863 [nfc.clf.transport] path matches '^(usb|)$'
2016-03-22 17:21:46,868 [nfc.clf.device] loading pn533 driver for usb:04cc:2533
2016-03-22 17:21:46,939 [nfc.clf.pn533] chipset is a PN533v2.7
2016-03-22 17:21:46,976 [nfc.clf.pn533] no eeprom attached
2016-03-22 17:21:46,977 [nfc.clf.pn533] no eeprom attached
2016-03-22 17:21:46,977 [nfc.clf.pn533] write analog settings for Type A
2016-03-22 17:21:46,983 [nfc.clf] using SensorID StickID PN533v2.7 at usb:001:004
2016-03-22 17:21:46,984 [nfc.clf] connect('llcp',)
2016-03-22 17:21:46,985 [nfc.clf] connect options after startup: llcp
2016-03-22 17:21:46,995 [nfc.clf] listen 1.000 seconds for DEP
2016-03-22 17:21:46,996 [nfc.clf.pn533] nfca_params 0101988f9240
2016-03-22 17:21:46,996 [nfc.clf.pn533] nfcf_params 01fee105892da02
2016-03-22 17:21:47,194 [nfc.clf.pn533] activated in 106A active communication mode
2016-03-22 17:21:47,195 [nfc.clf.pn533] 106A send ATR_RES d50101fee105892
2016-03-22 17:21:47,223 [nfc.clf.pn533] 106A rcvd PSL_REQ d404001203
2016-03-22 17:21:47,224 [nfc.clf.pn533] 106A send PSL_RES d50500
2016-03-22 17:21:47,229 [nfc.clf.pn533] set CIU_RxMode to 10100001
2016-03-22 17:21:47,234 [nfc.clf.pn533] send PSL_RES d50500
2016-03-22 17:21:47,243 [nfc.clf.pn533] set CIU_TxMode to 10100001
2016-03-22 17:21:47,262 [nfc.dep] running as NFC-DEP Target 424F active mode MIU=61 RWT=0.077329
2016-03-22 17:21:47,265 [nfc.llcp.llc] LLCP Link established as NFC-DEP Target
Local LLCP Settings
LLCP Version: 1.3
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Link Service: connection-less and connection-oriented
Data Protect: secure data transfer mode is supported
Service List: 0000000000000011 (SDP, LLC)
Remote LLCP Settings
LLCP Version: 1.3
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Link Service: connection-less and connection-oriented
Data Protect: secure data transfer mode not supported
Service List: 0000000000000011 (SDP, LLC)
2016-03-22 17:21:47,266 [nfc.clf] connected LLC: Local(MIU=2175, LTO=500ms) Remote(MIU=2175, LTO=500ms)
2016-03-22 17:21:47,271 [nfc.clf] >>> 06d507000000 timeout=
2016-03-22 17:21:47,391 [nfc.clf] <<< 04d40680 0.119s
2016-03-22 17:21:47,392 [nfc.clf] >>> 04d50780 timeout=
2016-03-22 17:21:47,511 [nfc.clf] <<< 04d40680 0.119s
2016-03-22 17:21:47,513 [nfc.clf] >>> 04d50780 timeout=
2016-03-22 17:21:47,633 [nfc.clf] <<< 03d408 0.120s
2016-03-22 17:21:47,634 [nfc.clf] >>> 03d509 timeout=0
2016-03-22 17:21:47,641 [nfc.clf] <<< None 0.007s
2016-03-22 17:21:47,642 [nfc.clf] >>> None timeout=
2016-03-22 17:21:47,747 [nfc.clf] <<< 0.105s
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- nfcpy Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Stephen Tiedemann
- Solved:
- Last query:
- Last reply: