-1
In my new app I have build up an BLE bluetoothManager which works fine to communicate with an external Sensor. The bluetoothManger is an observableObjekt and in this way connected with the app. To change informations between the different views I use as a kind of backbone an environmentObject-construction
But now to the problem I have: Every time I change an item shared over environmentObject within the app the bluetooth switches off and on a the BLE connection is out of order for a few seconds.
On the console I receive the following some partly self programmed messages in this time:
XPC connection invalid
Bluetooth disabled, Calypso disconnected
Bluetooth enabled
searching .
Bluetooth disabled, Calypso disconnected
discovered <CBPeripheral: 0x302628270, identifier = 95AB751A-67C8-00A5-CF9B-C194C5D0EA8A, name = ULTRASONIC, mtu = 0, state = connecting>
Connected!
The question is: What is the reason and how can I fix it?
Many thanks for your assistance!