Add web dashboard OTA upload with live progress.
Share UART OTA logic between CLI and serve via POST /api/ota, WebSocket progress events, and a dashboard upload UI showing the running partition. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+1
-1
@@ -40,7 +40,7 @@ func runServe(portName string, baud int, args []string) error {
|
||||
go runPoller(link, portName, hub, *interval, stop)
|
||||
|
||||
mux := http.NewServeMux()
|
||||
mountServeAPI(mux, link)
|
||||
mountServeAPI(mux, link, hub)
|
||||
mux.HandleFunc("/ws", func(w http.ResponseWriter, r *http.Request) {
|
||||
conn, err := wsUpgrader.Upgrade(w, r, nil)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user