snep server-client application

Asked by Daniel

Hi all,

I am tryting to use snep test client and server. When I run the client using the test 2. I get the following message

dany@ubuntu:~/nfcpy/examples$ sudo ./snep-test-client.py --test 2
searching for a usable reader
searching for a usb bus reader
using SCM Micro SCL3711-NFC&RW at usb:002:004
activated a p2p target in 424 kbps active mode
LLCP Link established, I'm the DEP Initiator
Local LLCP Settings
  LLCP Version: 1.1
  Link Timeout: 1000 ms
  Max Inf Unit: 1024 octet
  Service List: 0000000000000011
Remote LLCP Settings
  LLCP Version: 1.1
  Link Timeout: 1000 ms
  Max Inf Unit: 1024 octet
  Service List: 0000000000010011
Test 2: unfragmented message exchange
'('application/octet-stream', '1', '\x00\x01\x02\x03\x04\x05\x06\x07\x08\t\n\x0b\x0c\r\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f !"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\')' is not an acceptable record type
shutdown on local request
I was the Initiator
Traceback (most recent call last):
  File "./snep-test-client.py", line 393, in <module>
    main()
  File "./snep-test-client.py", line 304, in main
    test_suite[test-1]()
  File "./snep-test-client.py", line 73, in test_02
    record = nfc.ndef.Record(("application/octet-stream", "1", payload))
  File "/home/dany/nfcpy/nfc/ndef/record.py", line 78, in __init__
    self.type = record_type if record_type is not None else 'unknown'
  File "/home/dany/nfcpy/nfc/ndef/record.py", line 214, in type
    raise ValueError("invalid record type")
ValueError: invalid record type

Could you explain me what is going on?

Thanky so much!

Question information

Language:
English Edit question
Status:
Answered
For:
nfcpy Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Stephen Tiedemann (stephen-tiedemann) said :
#1

Please re-try with revision 140. The snep test code was not yet adapted to the recent ndef changes for instantiating records. Many thanks for pointing this out.

Can you help with this problem?

Provide an answer of your own, or ask Daniel for more information if necessary.

To post a message you must log in.