@@ -384,11 +384,33 @@ failed as "busy or locked", and no process held the handle.
384384asking for the same replug you were trying to avoid, having also lost the
385385program that was running.
386386
387- So: ** on a native-USB S3, never try to reach download mode in software.** Ask
388- for the physical BOOT-and-plug. The network is the useful discriminator if you
389- do end up guessing — a board that answers HTTP is running your firmware, and a
390- board that answers nothing while its COM port refuses to open is in ROM mode
391- behind a stale USB node.
387+ The stale node is repairable, and that changes the whole procedure. Restart
388+ the device node with elevation and Windows enumerates what the chip is
389+ actually presenting:
390+
391+ ``` bash
392+ powershell.exe -NoProfile -Command " Start-Process pnputil -Verb RunAs \
393+ -ArgumentList '/restart-device','USB\VID_303A&PID_4001\<serial>' -Wait"
394+ ```
395+
396+ That pops one UAC prompt, grants nothing that outlives it, and needs a human
397+ to click Yes — but it is a click, not a walk to the bench. On the T-Embed
398+ (2026-09-16, 17:34) the board went straight from the stale ` 303A:4001 ` node to
399+ ` 303A:1001 ` on a new COM number, esptool flashed it there, and it rebooted
400+ into the new firmware ** without a button press** — the whole flash cycle with
401+ no hands on the hardware. ` tools/windows/restart-esp-usb.ps1 ` in this repo
402+ does the same for whatever Espressif board is attached.
403+
404+ So the order to try is: ` machine.bootloader() ` over ` exec ` , then the elevated
405+ device-node restart, then flash the ` 1001 ` port. Fall back to the physical
406+ BOOT-and-plug only if nobody is there to click. The network is the
407+ discriminator while you are guessing — a board that answers HTTP is running
408+ your firmware, and a board that answers nothing while its COM port refuses to
409+ open is in ROM mode behind a stale USB node.
410+
411+ To lose the prompt as well, an administrator can register a scheduled task
412+ that runs the restart with SYSTEM privileges and let ordinary accounts start
413+ it; an agent must not create that task itself.
392414
393415### Ctrl-C is not an interrupt inside ` atexit `
394416
0 commit comments