Not a massive issues as It's an interrupt so you wanted to close anyway, but need to handle this scenario.
2020/06/23 10:30:55 PM5 error: Unresolvable connection error: can't scan: context deadline exceeded
^C2020/06/23 10:30:58 signal received from os: interrupt
panic: close of closed channel
goroutine 1 [running]:
github.com/go-ble/ble/linux/hci/socket.(*Socket).Close(0x1043660, 0x0, 0x0)
/home/pi/go/src/github.com/go-ble/ble/linux/hci/socket/socket.go:148 +0x30
github.com/go-ble/ble/linux/hci.(*HCI).close(0x107c360, 0x0, 0x0, 0x101a03c, 0x101a03c)
/home/pi/go/src/github.com/go-ble/ble/linux/hci/hci.go:327 +0x50
github.com/go-ble/ble/linux/hci.(*HCI).Close(0x107c360, 0x1000194, 0x108d14)
/home/pi/go/src/github.com/go-ble/ble/linux/hci/hci.go:169 +0x2c
github.com/go-ble/ble/linux.(*Device).Stop(0x100eb00, 0x108d0c, 0x10000e0)
/home/pi/go/src/github.com/go-ble/ble/linux/device.go:105 +0x20
github.com/go-ble/ble.Stop(0x1000001, 0x1077f9c)
/home/pi/go/src/github.com/go-ble/ble/gatt.go:52 +0x34
main.unsetBT()
/home/pi/go/src/github.com/mrverrall/go-row-cycle/go-row-cycle.go:65 +0x14
main.main()
/home/pi/go/src/github.com/mrverrall/go-row-cycle/go-row-cycle.go:33 +0x104