hybridgroup / gobot

Golang framework for robotics, drones, and the Internet of Things (IoT)
https://gobot.io
Other
8.95k stars 1.04k forks source link

BLE: How to check if device is still connected or not ? #581

Open medteck opened 6 years ago

medteck commented 6 years ago

I've tried with: if(!connexion_initialized && !trying_connection && !robot.Running()) { fmt.Printf("Parrot minidrone is disconnected") } I've also tries with: robot.Connections().Len() which returns "1" even after my device turns off.

I need it because I want to reconnect to my drone whenever it turns on.

deadprogram commented 6 years ago

Hi @medteck thanks for posting. It will require a few additions to the ble package in order to support the functionality you are asking for. I will think about it a bit.

medteck commented 6 years ago

Thank you! :+1:

gen2thomas commented 1 year ago

Hi @deadprogram is there any progress on this topic?