How to keep Tinker app connected without wifi connection

argon
Tags: #<Tag:0x00007f1ca65b52d8>

#1

I am at EMC testing and we are trying to do Bluetooth coexistence testing. Initially I thought I would just use the Tinker program and the Particle app to show connectivity. When in a big metal box and not connected to the cloud, the app does not communicate with Bluetooth. It keeps trying to connect and doesn’t run the program.

I have SYSTEM_MODE(SEMI_AUTOMATIC) so the program can run without being connected to the cloud. This is not working.

Any thoughts on how I can have Bluetooth active without wifi?


#2

Not sure what you are after. Tinker is not meant to communicate via BT so no surprise you cannot tinker with it without WiFi.
Next, when you block 2.4GHz WiFi with a metal box, why would 2.4GHz Bluetooth work?

Also SYSTEM_MODE(SEMI_AUTOMATIC) doesn’t really let your code run freely once you called Particle.connect(). Yes, your program will start running immediately, but when your code demands a connection you’ll be back in the same spot as with AUTOMATIC mode.
However, you can use SYSTEM_THREAD(ENABLED) to mostly decoulple the radio connection and the application thread.

And finally, what kind of BT stuff are you intending to do?
Currently BT only works for setting up devices but isn’t exposed for user applications - that will come with device OS revision 1.2.0


#3

Thanks for your response ScruffR. We are trying to do Bluetooth coexistence testing. The big metal box I refer to is the testing chamber. I am sitting in there with it try to show the Bluetooth connection stays connected as a high powered router is moved closer.

We intend to use Bluetooth for the end user to assign wifi password and to transmit data if there is no a wifi network.

Do you know any way with the current firmware revision to establish a Bluetooth connection and demonstrate it is connected during a test?


#4

The standard setup with the mobile app uses BT. For that you need to put your device in Listening Mode (blinking blue) and let the app scan for the device.
But I can’t provide any details how that’s done, but @rickkas7 may be able to assist or get a mobile engineer to respond here.


#5

I was able to keep the Argon in listening mode and pair with Bluetooth as long as I had a network connection for my phone. Hopefully 1.2 is out soon so we can start developing our app to use Bluetooth as a backup.


#6

Not sure exactly if this is implemented yet for the Argon / mesh devices, but for my photons I set a timeout such that if I can’t find a network within X minutes I explicitly trigger listening mode using SystemThread and WiFi.listen(). It’s likely that “listening mode” when triggered as above on the mesh devices can also pop BT on, though I’m not certain and can’t test myself at the moment.

I’m closely monitoring the progress of the self setup / BT for providing WiFi credentials and such, as that would be critical for productionizing the device in my application. Will be curious to see how you and others are able to make this work in a production-ish setting!