iot-edge-v1 icon indicating copy to clipboard operation
iot-edge-v1 copied to clipboard

[v1] Error on Raspberry Pi 3 - Physical Device / BLE Sample

Open IshamMohamed opened this issue 7 years ago • 2 comments

I tried https://github.com/Azure/iot-edge/blob/master/v1/samples/ble_gateway/iot-hub-iot-edge-physical-device.md and keeps getting

Error: Time:Thu Jan 25 15:26:37 2018 File:/home/pi/iot-edge/v1/modules/ble/src/bleio_seq_linux_schedule_read.c Func:on_read_complete Line:39 An error occurred while executing instruction of type 1 for characteristic F000AA01-0451-4000-B000-000000000000
Error: Time:Thu Jan 25 15:26:37 2018 File:/home/pi/iot-edge/v1/modules/ble/src/bleio_seq_linux_schedule_read.c Func:on_read_complete Line:45 BUFFER_create failed.
Error: Time:Thu Jan 25 15:26:37 2018 File:/home/pi/iot-edge/v1/modules/ble/src/ble.c Func:on_read_complete Line:602 A read instruction for characteristic F000AA01-0451-4000-B000-000000000000 of type READ_PERIODIC failed.
Error: Time:Thu Jan 25 15:26:38 2018 File:/home/pi/iot-edge/v1/modules/ble/src/ble_gatt_io_linux_read.c Func:on_sequence_error Line:284 Read characteristic failed with - GDBus.Error:org.freedesktop.DBus.Error.UnknownMethod: Method "ReadValue" with signature "" on interface "org.bluez.GattCharacteristic1" doesn't exist

after setting up everything, modifying the configuration file per my settings and running ./build/samples/ble_gateway/ble_gateway ./samples/ble_gateway/src/gateway_sample.json any helps?

IshamMohamed avatar Jan 25 '18 15:01 IshamMohamed

Hello @IshamMohamed

Have you tried caching the BLE characteristics? The sample needs this to be done before it works.

You connect to the device using bluetoothctl and run the list-attributes command. Wait for the attributes to get listed and then you can disconnect and exit from bluetoothctl. This basically causes the BLE characteristics to get cached by the bluetooth stack.

This is the most common cause for problems in the sample.

darobs avatar Jan 25 '18 23:01 darobs

I am getting this same error on Ubuntu 18.04 with bluetoothd 5.48. iot-edge is build from master as of today. I had run bluetoothctl with list-attributes as specified. Attaching bluetoothctl logs. Is there way to check if characteristics are cached correctly?

gateway successfully created from JSON gateway shall run until ENTER is pressed Error: Time:Fri Jul 20 17:35:06 2018 File:/home/dk300/ble/iot-edge-v1/v1/modules/ble/src/ble_gatt_io_linux_read.c Func:on_sequence_error Line:284 Read characteristic failed with - GDBus.Error:org.freedesktop.DBus.Error.UnknownMethod: Method "ReadValue" with signature "" on interface "org.bluez.GattCharacteristic1" doesn't exist

Error: Time:Fri Jul 20 17:35:06 2018 File:/home/dk300/ble/iot-edge-v1/v1/modules/ble/src/bleio_seq_linux_schedule_read.c Func:on_read_complete Line:39 An error occurred while executing instruction of type 0 for characteristic 00002A24-0000-1000-8000-00805F9B34FB Error: Time:Fri Jul 20 17:35:06 2018 File:/home/dk300/ble/iot-edge-v1/v1/modules/ble/src/bleio_seq_linux_schedule_read.c Func:on_read_complete Line:45 BUFFER_create failed. Error: Time:Fri Jul 20 17:35:06 2018 File:/home/dk300/ble/iot-edge-v1/v1/modules/ble/src/ble.c Func:on_read_complete Line:602 A read instruction for characteristic 00002A24-0000-1000-8000-00805F9B34FB of type READ_ONCE failed.

kiranpradeep avatar Jul 20 '18 12:07 kiranpradeep