-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Labels
bugdone on devthe feature or bug is solved on dev branch and wait for merge to release branchthe feature or bug is solved on dev branch and wait for merge to release branch
Description
To initiate a retry after a failing "robot.Start()", an "robot.Stop()" could be useful to get rid of all devices, which are successfully connected until this point.
If the BLE device was not connected at this time, the disconnect fails because the "extDevice" is still not defined in btwrapper.go.
// Disconnect from the BLE device. This method is non-blocking and does not wait until the connection is fully gone.
func (btd *btDevice) disconnect() error {
return btd.extDevice.Disconnect()
}
this needs to be changed to something like this:
// Disconnect from the BLE device. This method is non-blocking and does not wait until the connection is fully gone.
func (btd *btDevice) disconnect() error {
if btd!=nil && btd.extDevice!= nil{
return btd.extDevice.Disconnect()
}
return nil
}
Metadata
Metadata
Assignees
Labels
bugdone on devthe feature or bug is solved on dev branch and wait for merge to release branchthe feature or bug is solved on dev branch and wait for merge to release branch