Hey guys,
I have a bluetooth app that connects to a device. What I want to achieve is this: when a user switches apps or goes to the homescreen, I want to disconnect from the bluetooth device but when a user hits the lock screen, I want the bluetooth connection to be maintained.
I am not super familiar with swift and ios dev so any advice would be great.
Is there a way to determine whether a app is backgrounded due to the user going to the homescreen and when a user simply locks the phone?
Thanks in advance.