Add update weather command to itctl

This commit is contained in:
2022-02-23 21:22:03 -08:00
parent 2f14e70721
commit 9e63401db3
7 changed files with 107 additions and 2 deletions

View File

@@ -642,6 +642,10 @@ func handleConnection(conn net.Conn, dev *infinitime.Device, fs *blefs.FS) {
},
})
}
case types.ReqTypeWeatherUpdate:
// Send weather update signal
sendWeatherCh <- struct{}{}
json.NewEncoder(conn).Encode(types.Response{Type: req.Type})
case types.ReqTypeCancel:
if req.Data == nil {
connErr(conn, req.Type, nil, "No data provided. Cancel request requires request ID string as data.")