My application currently works as I am able to retrieve the values from the decoding location_and_speed characteristic. However, I am having difficulties reading the documentation from Bluetooth to decode/extract the values from the device.
Below is my code:
func peripheral(_ peripheral: CBPeripheral, didUpdateValueFor
characteristic: CBCharacteristic, error: Error?) {
print(#function)
print(characteristic.value?.count ?? 0)
guard let data = characteristic.value else {return}
let byteArray = [UInt8](data)
// TODO: decode the value to available gps data???
}
Any help would be appreciated, Thank You!