ontent = "Status: Device disconnected";
                        log("Device disconnected");
                    });

                    statusDiv.textContent =
                        "Status: Connected and watching for input";
                } catch (error) {
                    statusDiv.textContent = `Status: Error - ${error}`;
                    log(`Error: ${error.message}`);
                    console.error("Error:", error);
                }
            }
        </script>
    </body>
</html>
