added error returns to the SendData method on the peripheral interface

This commit is contained in:
2026-09-18 16:37:30 +01:00
parent a2e14ba6a9
commit 174b27004f
5 changed files with 37 additions and 13 deletions
+5 -1
View File
@@ -159,7 +159,11 @@ func (ds *DeviceService) transmit(ctx context.Context) {
// the data locked
ds.mu.RLock()
for _, dev := range ds.Devices {
dev.SendData(&data)
err := dev.SendData(&data)
if err == peripheral.ErrDeviceTimedOut {
// What do we do here?
// TODO: somehow we need to handle reconnection
}
}
ds.mu.RUnlock()