Reputation: 21
I'm programming download data from my server. My idea: i set time for download, my app is running in background, my device on battery charging. When my device is sleeping, if schedule on time, app download data. But, wifi sleep when device sleep. How to re-active or keep wifi alive.
Upvotes: 2
Views: 3276
Reputation: 118681
Try setting the UIRequiresPersistentWiFi key in your Info.plist.
Upvotes: 3
Reputation: 44633
If your app is in the background, you can't run in the background automatically. You will need the user's approval to download the new content. It will have to come out of sleep for such a thing to occur.
Upvotes: 0