File Transfer using beam.py between Android phone and Raspberry Pi?
Hi all,
I have been trying to transfer files such as docs, pdfs, jpegs, etc between an Android phone (galaxy s6) and a Raspberry Pi by using a PN532 and the beam.py example. I have come across a few problems problems:
Upon completion of sending the file from the host (phone) , the client device (rpi) will save the file stated in the terminal. When it is opened, it contains the address to the application used to display the file on the other device such as:
muplay.
This is what is shown on the terminal for receiving (doesn't look like anything is wrong from my pov):
root@raspberryp
--device ttyAMA0:pn532 recv save test1rc.doc
[nfc.clf] searching for reader on path ttyAMA0:pn532
[nfc.clf] using PN532v1.6 at /dev/ttyAMA0
[nfc.snep.server] snep server bound to port 4 (MIU=1984, RW=15), will
accept up to 1048576 byte NDEF messages
[nfc.dep] running as NFC-DEP Target 424F passive mode MIU=251 RWT=0.077329
[nfc.llcp.llc] LLCP Link established as NFC-DEP Target
Local LLCP Settings
LLCP Version: 1.1
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Service List: 0000000000010011
Remote LLCP Settings
LLCP Version: 1.2
Link Timeout: 1000 ms
Max Inf Unit: 2175 octet
Service List: 0000000000010011
[nfc.llcp.tco] accepting CONNECT from SAP 32
[nfc.snep.server] serving snep client on remote sap 32
[main] default snep server got put request
[main] save ndef message 'urn:nfc:wkt:U'
[nfc.dep] stop NFC-DEP Target 424F passive mode MIU=251 RWT=0.077329,
packets sent/rcvd INF 134/134 ATN 0/0 ACK 0/0 NAK 0/0
I believe this is typical of another phone which doesn't have this application which causes the client to download it before continuing with the transfer. So I believe this is a problem with the AAR (Android Application Record) on androids part as the link shows below:
http://
So I presume I have to disable this to solve this problem?
A similar thing happens the other way round (rpi sends a file to the phone) where the phone shows a "New tag collected" and the contents being "application/
From the terminal for sending:
root@raspberryp
--device ttyAMA0:pn532 send file Test1.doc
[nfc.clf] searching for reader on path ttyAMA0:pn532
[nfc.clf] using PN532v1.6 at /dev/ttyAMA0
[nfc.snep.server] snep server bound to port 4 (MIU=1984, RW=15), will
accept up to 1048576 byte NDEF messages
[nfc.dep] running as NFC-DEP Target 424F active mode MIU=251 RWT=0.077329
[nfc.llcp.llc] LLCP Link established as NFC-DEP Target
Local LLCP Settings
LLCP Version: 1.1
Link Timeout: 500 ms
Max Inf Unit: 2175 octet
Service List: 0000000000010011
Remote LLCP Settings
LLCP Version: 1.1
Link Timeout: 1000 ms
Max Inf Unit: 2175 octet
Service List: 0000000000010011
[nfc.llcp.llc] BrokenLinkError
while operating as Target',)
[nfc.dep] stop NFC-DEP Target 424F active mode MIU=251 RWT=0.077329,
packets sent/rcvd INF 160/128 ATN 0/0 ACK 0/33 NAK 0/0
Broken link error caused by the me removing the phone since it wont
progress any further.
In some cases the phone won't send a file (even 5kb in size) to the raspberry pi stating that the receiver isn't capable of receiving large files via beam.
If anyone can help or point me in a certain direction it will be greatly appreciated. Note that I may need some things dumbed down because I'm not the most capable person with these things.
Thanks,
Lewis
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- nfcpy Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Lewis Molyneux for more information if necessary.