|SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Tez||9/20/11 8:53 AM|
I have the following scenario
1. Phone A prepares an NDEF message and Phone B registers foreground
2. Phone A pushes the NDEF. Phone B receives this and processes it.
3. Phone A now registers for foreground dispatch and disables NDEF
push.Phone B replies with an NDEF push.
ALL this is to be done in one swipe. How can I do this?
Right now, I have to pull the devices away for the 2nd part to work. I
have seen the sample on p2p exchange, but in that case, both the
message contents are known in advance. Here, the reply depends on the
Secondly, will there be a proper NFC API with the ability to create
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Tez||9/21/11 9:07 AM|
Basically, I need a request-response mechanism in one swipe.
from the logs, I see that the system is "about to close" an LLCP
connection, but does not do so until the 2 devices are out of each
others RF fields.
Due to this, the polling loop does not restart to make the system
available for another NDEF push.
Is there anything that can be done, short of modifying the system
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Alexander Starchenko||9/22/11 6:11 AM|
Check out this:
1. Tutorial to make hidden API visible devmaze.wordpress.com/2011/01/18/using-com-android-internal-part-1-introduction/
2. Use INfcAdapter, ILlcpServiceSocket, ILlcpSocket (will be visible after 1 step) like it's done in the code from com.android.nfc.ndefpush package;
Yes, it's quite 'dirty' way, but the only possible currently on 2.3.4 version.
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Alexander Starchenko||9/22/11 2:20 AM|
Take a look:
2. INfcAdapter, ILlcpServicesocket, ILlcpSocket classes (following 1.
would give You access to these classes);
It's possible to make LLCP P2P communication on two 2.3.4 device.
I know, this is a 'dirty' way, but there seems to be no other option
to achieve what You're looking for.
Thanks in advance,
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Tez||9/22/11 10:48 AM|
Hmm...this is interesting.
I was also thinking the following:
Suppose I use internal and hidden APIs in a package that is compiled
with the entire Android System itself.
I guess this method should also work.
On Sep 22, 11:20 am, Alexander Starchenko <alex.starche...@gmail.com>
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||d||10/24/11 3:13 PM|
I am also trying to do the same scenario on 2.3.6.
I tried using Alex's solution but the API has been updated so some of
the classes/methods are missing.
Could you please post the solution if you got it.
> > > > Secondly, will there be a properNFCAPI with the ability to create
> > > > LLCP sockets?
> > > > Cheers,
> > > > Earlence
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Nick Pelly||10/25/11 10:36 PM|
We don't currently provide a way to do command/response over P2P. We understand the use cases, and want to make these use cases possible in a clean and future-proof way at some time.
Those (hidden) API's are no longer present in ICS.
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Tez||10/26/11 12:01 PM|
> understand the use cases, and want to make these use cases possible in aIs there any ETA on this? eg: in the next, or within the next 2
Yes, I managed to do it on the gingerbread stock version.
However, it is quite unstable.
Basically, you have to listen for the LLCP system notifications and
piggy back on them.
I will post a link to the code soon.
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||d||10/31/11 1:52 PM|
I am still working on it, would be great if you can share it.
|Re: SEQUENTIAL bidirectional P2P with NFC on Gingerbread||Michael Roland||1/9/13 4:16 AM|
there is still no API for bidirectional P2P communication. However, you
might want to have a look at these two projects:
They do kind-of bidirectional P2P communication over SNEP/NPP. However,
they exchange one message per connection instead of keeping one
On 2012-12-02 13:34, Sam Van Den Berge wrote:
> Is there any recent news concerning this subject? At the moment I'm
> doing a thesis which is related to this subject.
> Is it correct that sending a response withing a single connection is
> still not supported in Jelly Bean?
> Op woensdag 26 oktober 2011 07:36:03 UTC+2 schreef Nick Pelly het volgende:
> For more options, visit this group at> <http://groups.google.com/group/android-platform?hl=en>.