The Pico W emulation runs in THIS browser tab via requestAnimationFrame. Opening the gateway with target=_blank / window.open backgrounds the emulation tab; the browser then pauses its rAF, the simulated chip freezes, and the gateway can no longer reach the server on it — the request times out (502) and toggles do nothing. Render the served page in a same-tab iframe panel (openDeviceGateway) for the Pico W so the emulation stays in the foreground and keeps answering. The ESP32 is unchanged (its server runs in QEMU on the backend, immune to tab visibility), so it keeps opening in a new tab. Also: the async-led page now shows the LED state (the board's onboard LED isn't drawn on the canvas) so the toggle has visible feedback. |
||
|---|---|---|
| .. | ||
| __pro_stub__ | ||
| __tests__ | ||
| assets | ||
| components | ||
| data | ||
| desktop | ||
| hooks | ||
| i18n | ||
| lib | ||
| pages | ||
| services | ||
| simulation | ||
| store | ||
| tokens | ||
| types | ||
| utils | ||
| velxio-elements | ||
| App.css | ||
| App.tsx | ||
| entry-server.tsx | ||
| index.css | ||
| main.tsx | ||
| seoRoutes.ts | ||
| vite-env.d.ts | ||