Possible duplicate:
Android: How to transfer a Bluetooth connection to another action?
I have an application in which I am going to transfer data via a Bluetooth connection.
In my proof of conceptual application, I was able to put the Bluetooth connection into another stream and save all my other work in one action (using ViewFlipper).
However, for my next iteration, I will need to use several different βscreensβ (actions). The stream will look something like this:
My initial activity will be connecting to the Bluetooth device from which I receive data.
One of the activities of the "main" activity will be to obtain a list of data from the BT device and display it in a list. Then, when I click on an item, I will need to get a more detailed view of the data (which is shown in another OTHER activity, but also needs to access the BT connection).
From the "main" activity, additional specific actions will be performed.
So my question is how best to manage this when I initiate the ONCE Bluetooth connection and do not need to start it again for every action?
source share