Azure / connectthedots

Connect tiny devices to Microsoft Azure services to build IoT solutions
http://connectthedots.io
MIT License
399 stars 274 forks source link

Windows Phone and Band Application Communication Timeout with Azure #215

Closed redraven984 closed 8 years ago

redraven984 commented 8 years ago

Hi Everyone,

I have been using the Windows Phone and Band Application to stream my sensor readings to Azure. However, Ive noticed that the application stops streaming data to Azure after about 30-45 minutes. The application is responsive but it looks like the Band is not updating the sensor readings.

Is there a timeout on the Bluetooth connection between the band and the phone? Is there a timeout on the phone itself that is causing this problem?

If none of these are reasonable, what code would I have to insert in the Application to periodically reset the Bluetooth connection to the band?

Thanks for your help!

olivierbloch commented 8 years ago

For starters, the WP app has been developed for short time demos and trials. It doesn't run in the background and the first thing you might want to do is to enable the app to run in the background.

redraven984 commented 8 years ago

Thanks for your comment and applogies about the late reply. I found the issue to be lifetime of SAS token.

I would like to enable background application as well. How would I do this? Ive enabled location services in the application manifest. What code do I need in the body to keep the application alive?