bluetooth icon indicating copy to clipboard operation
bluetooth copied to clipboard

Windows Implementation needs to use ReadValueWithCacheModeAsync

Open KeganHollern opened this issue 3 years ago • 0 comments

Hello,

I am testing on the dev branch with an Aranet4 device.

The my sample code for reading characteristic values works from Linux and OSX, but the windows implementation is not functioning.

I believe this stackoverflow post explains the problem. By using the ReadWithAsync function exposed by winrt-go, you're using the windows cache. My BT device does not send notifications on value change, so this cache is never updated.

the iGattCharacteristic interface exposed by go-winrt contains ReadValueWithCacheModeAsync which allows you to specify the cache mode. I would need to call this method with BluetoothCacheModeUncached to get my device working on windows.

I need a way to specify that the read should not use the cache & should instead read directly from the device.

Please fix before the windows support is added to Release! 🙏

KeganHollern avatar Sep 23 '22 12:09 KeganHollern