Don't know if this is a SWConnect or a Spotwalla issue.
i have set the SWConnect Track Logging Interval to 10 minutes as I want to minimise battery drain but when I do a test Trip it shows a location every 5 minutes. I saw somewhere (I think on the SWConnect help) that 5 minutes is required by Spotwalla but I also see people with Spots showing 10 minute intervals on Spotwalla.
I will be doing a 90 hour/ 1200km ride and will be relying on a power bank to keep devices charged (lights on a dynamo hub) and won't have access to power points or time to charge devices.
Both SWConnect and Spotwalla look like fine pieces of software, thanks.
Last Edit: Aug 10, 2019 1:59:39 GMT -6 by latestart
When you take a trial run again, please let me know. It should change the interval to 10 minutes. I will say, however, I am not sure that how large of a battery usage difference you'll see. The GPS will still be on the entire time you're tracking. Apple does not provide a way (without using external servers to send a push message) to wake up at specific intervals. So, the interval in SWConnect is simply a threshold used to ignore incoming data points from the GPS. It will not attempt to connect as often, therefore using the cellular radio less.
Something I might suggest that might help, but at the expense of live tracking. If you do not log in in the app, it will still track and buffer, but not attempt to connect to spotwalla. When you get to a place where you can stop, you can login, select the spotwalla device, and it will send up all the buffered points. Then, if you still have more, logout. (note, there is no official logout button. simply go to the login page, and type in a bogus password. that will effectively log you out). Make sure to select the device after logging in on the settings page (page 2)
Post by latestart on Sept 15, 2019 22:48:21 GMT -6
While I wrote my first computer program 47 years ago and am still trying to master it I know nothing about IOS programming but it would be odd that there is no system function to sleep a process for some interval. Having to interface to the Location Services continuously would be cpu/battery intensive especially when you were throwing away most of the location points until the tracking interval was reached..
In fact this was the experience with most riders using SWConnect or the other IOS alternatives on the recent Paris-Brest-Paris 1200, most found that they couldn't run for the duration (90 hours) unless they had large external batteries or power take off from their dynamo hubs (but only by day as none output enough power to both run lights AND charge external devices). Most gave up having the tracking on. Seems the same is true of Android options although I haven't spoken to enough people to confirm if "user" issues may have been a contributing factor. Most average riders are always pushing the control deadlines and skip sleep so are in a continuous confused state, dealing with their phones running out of battery is an unwelcome and unneeded problem.
A few years ago I used FollowMee app for same function and don't recall it being so intensive, my notes suggest 30% battery drain on a 16 hour 300km ride with a iphone 6 (but it was a while ago so I might mis-remember) I stopped using it as the web api became an expensive subscription option.
I will have to do some tests to gauge the battery drain
Hopefully IOS 13 might give some better functions you can use.
I realise sleep deprived cyclists doing 90 hour / 1220 km riders are not your prime focus so thanks for your reply
PS I might look into the Shortcuts app to see if it could turn on tracking for a period and then turn it off and repeat at some interval
Last Edit: Sept 15, 2019 22:54:32 GMT -6 by latestart
Sorry for the issues you are seeing. I have worked a lot of hours trying to make SWconnect useful, but I will admit, my primary focus was the long distance motorcycle community, and generally there is little problem grabbing power from the motorcycle.
I too started programming over 40 years ago. I am a retired engineer and have programmed all of my adult life. I will admit I am not the foremost expert on IOS programming, so it's very possible that I've missed something obvious in working with tracking. A major difference from 40 years ago and now on IOS is that apps are not intended to run always. The apps get notification when the user changes apps, clicks power off, or the display simply goes to sleep. Apps are suspended at that point, and if they continue processing beyond a set timeout beyond the notification, they are actively killed by the OS.
Navigation apps are a bit different, in they are allowed to continue operating. There are certainly ways to basically stop processing and wake in a set time later, however, I don't know if the OS will allow a backgrounded navigation app continue to process if the GPS is not running. I thought I had tested that previously, but am willing to look into it again.
If I can get the app to continue to function, without the GPS running while backgrounded, then I believe I can handle the situation you are in. IF you are willing to do some beta testing for me, I would be happy to get you a pre-release version to test with.
Well, I gave it my best try. I spent 6+ hours today trying to make this work. I did get the app to suspend, and every 5 minutes it turned on the GPS, got a track location, and turned it off. Worked great! That was until the app is backgrounded . Once the app is backgrounded, there is no further processing if the GPS is not actively sending data to the app.
Interestingly enough, when I wrote this, I used the suggested "deferred updates" methods to basically allow the GPS to buffer locations, but not message the app until it had been at least 5 minutes. This used to work, but it appears that it does no longer. At least, when my iPhone X queries the location manager to see if updates can be deferred, it gets a "no" answer. There is also a couple of other background methods, looking for traveling a certain distance, which I have tried in the past, but wasn't thrilled with it.
If you are interested trying googling "IOS wake up app in background". You'll get hundreds of potential places to see discussions about this.
What can be done, is that I could have the app send a local notification. But the intent here is to have the user tap on the notification, and thus restart the app.
The one other way, which actually would wake an app without user intervention is through a push notification. But, that requires a server on the internet, configured to interact with the Apple Push Notification service. And that would completely fail if you didn't have internet access when it was time to update/wake the app.
I doubt that shortcuts will help, as they require user interaction. If you don't mind interacting yourself every 5-10 minutes, then it's fairly simple to do. (I could make it better with the location notification). Simply (1) turn on the auto-track mode in the settings page. The (2) whenever you see a track is received, turn off tracking and close the app. Every 5-10 minutes simply restart the app. It will go into tracking automatically, and within maybe 20 seconds you should get a fix and can shut down again.
Unfortunately, that seems like a lot to bother with while you're riding a bike. Apple has gone a long way to prevent application developers from launching things in the background, thus affecting battery performance.
Perhaps you're best solution is s Spot device? Yes, they cost money, but, I would expect that they can easily go 90 hours, with perhaps a battery change (I believe they use standard AA cells?)
PS: Really sorry. Wish I could figure a way to make this work for you. If you come up with a solution, let me know and I'll try to implement it.
Last Edit: Sept 22, 2019 15:16:11 GMT -6 by rdavis
Please contact me via PM if you read this. I have developed a different technique an coded up a test version that I would love for you to try. Apple changed the way things worked a couple of versions back. Previously, they had suggested using "deferred" updates. These no longer work, and the app cannot even be put in that mode. After checking with other developers, a suggestion was made instead to lower the accuracy required by the GPS. In initial testing, this seems to have the affect to reducing the number of times the app is woken to process GPS updates from 1 per second, to 1 per 20-45 seconds. My assumption is that this will also seriously help with power usage.
I could really use your help in running this test version to let me know if it works for you, and whether or not it helps with battery usage.