diff --git a/logs/gcode_commands.log b/logs/gcode_commands.log index 575999d..5b19e9c 100644 --- a/logs/gcode_commands.log +++ b/logs/gcode_commands.log @@ -797,3 +797,19 @@ 2026-04-04T14:39:23.187Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 2026-04-04T14:39:37.073Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 2026-04-04T14:39:45.198Z ::ffff:172.21.0.5: G91 G1 X-10 F100 +2026-04-04T16:30:15.281Z ::ffff:172.21.0.5: FShow +2026-04-04T16:30:17.533Z ::ffff:172.21.0.5: G28 +2026-04-04T16:30:20.224Z ::ffff:172.21.0.5: M114 +2026-04-04T16:30:22.006Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:22.182Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:22.350Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:22.520Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:22.689Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:22.994Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:23.218Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:23.443Z ::ffff:172.21.0.5: G91 G1 Y-10 F100 +2026-04-04T16:30:27.758Z ::ffff:172.21.0.5: G91 G1 X-10 F100 +2026-04-04T16:30:29.046Z ::ffff:172.21.0.5: G91 G1 X-10 F100 +2026-04-04T16:30:32.486Z ::ffff:172.21.0.5: G91 G1 X10 F100 +2026-04-04T16:30:32.702Z ::ffff:172.21.0.5: G91 G1 X10 F100 +2026-04-04T16:30:36.979Z ::ffff:172.21.0.5: G91 G1 Y10 F100 diff --git a/logs/pings.log b/logs/pings.log index 7fe5610..1defe2a 100644 --- a/logs/pings.log +++ b/logs/pings.log @@ -5148,3 +5148,16 @@ 2026-04-04T14:52:18.636Z ::ffff:172.21.0.5: Ping 2026-04-04T14:53:00.261Z ::ffff:172.21.0.5: Ping 2026-04-04T14:53:00.826Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:20.226Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:25.163Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:30.176Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:35.176Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:40.166Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:45.178Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:50.243Z ::ffff:172.21.0.5: Ping +2026-04-04T16:30:55.167Z ::ffff:172.21.0.5: Ping +2026-04-04T16:31:00.248Z ::ffff:172.21.0.5: Ping +2026-04-04T16:31:05.242Z ::ffff:172.21.0.5: Ping +2026-04-04T16:31:10.198Z ::ffff:172.21.0.5: Ping +2026-04-04T16:31:15.228Z ::ffff:172.21.0.5: Ping +2026-04-04T16:31:20.170Z ::ffff:172.21.0.5: Ping diff --git a/public/app.js b/public/app.js old mode 100755 new mode 100644 index b9d20a3..d33fc3d --- a/public/app.js +++ b/public/app.js @@ -1,50 +1,72 @@ -document.addEventListener('DOMContentLoaded', function() { - function updateStatus() { - fetch('/api/status') - .then(response => response.json()) - .then(data => { - // WebClients - const clientsUl = document.getElementById('clients'); - clientsUl.innerHTML = ''; - data.clients.forEach(client => { - const li = document.createElement('li'); - li.textContent = client; - clientsUl.appendChild(li); - }); - - // Sender - const sendersUl = document.getElementById('senderList'); - sendersUl.innerHTML = ''; - data.senders.forEach(sender => { - const li = document.createElement('li'); - li.textContent = `${sender.name}: ${sender.status}`; - sendersUl.appendChild(li); - }); - - // Letzte Commands - const commandsUl = document.getElementById('commandList'); - commandsUl.innerHTML = ''; - data.lastCommands.forEach(cmd => { - const li = document.createElement('li'); - li.textContent = cmd; - commandsUl.appendChild(li); - }); - - // Letzte Pings - const pingsUl = document.getElementById('pingList'); - pingsUl.innerHTML = ''; - data.lastPings.forEach(ping => { - const li = document.createElement('li'); - li.textContent = ping; - pingsUl.appendChild(li); - }); - }) - .catch(error => console.error('Error fetching status:', error)); - } - - // Initial load - updateStatus(); - - // Update every 5 seconds - setInterval(updateStatus, 5000); -}); \ No newline at end of file +document.addEventListener('DOMContentLoaded', function() { + function updateStatus() { + fetch('/api/status') + .then(response => response.json()) + .then(data => { + // WebClients + const clientsUl = document.getElementById('clients'); + clientsUl.innerHTML = ''; + data.clients.forEach(client => { + const li = document.createElement('li'); + li.textContent = client; + clientsUl.appendChild(li); + }); + + // Sender + const sendersUl = document.getElementById('senderList'); + sendersUl.innerHTML = ''; + data.senders.forEach(sender => { + const li = document.createElement('li'); + li.textContent = `${sender.name}: ${sender.status}`; + li.classList.add(sender.status.toLowerCase()); + sendersUl.appendChild(li); + }); + + // Letzte Commands + const commandsUl = document.getElementById('commandList'); + commandsUl.innerHTML = ''; + data.lastCommands.forEach(cmd => { + const li = document.createElement('li'); + li.textContent = cmd; + commandsUl.appendChild(li); + }); + + // Letzte Pings + const pingsUl = document.getElementById('pingList'); + pingsUl.innerHTML = ''; + data.lastPings.forEach(ping => { + const li = document.createElement('li'); + li.textContent = ping; + pingsUl.appendChild(li); + }); + }) + .catch(error => console.error('Error fetching status:', error)); + } + + // Initial load + updateStatus(); + + // Update every 5 seconds + setInterval(updateStatus, 5000); +}); + +document.querySelectorAll('.section').forEach(sec => { + const id = sec.dataset.id; + const saved = localStorage.getItem('section_' + id); + if (saved === 'collapsed') sec.classList.add('collapsed'); + + sec.querySelector('h2').addEventListener('click', () => { + sec.classList.toggle('collapsed'); + localStorage.setItem( + 'section_' + id, + sec.classList.contains('collapsed') ? 'collapsed' : 'open' + ); + }); +}); + +/* Initial-Zustand +['clients','pings'].forEach(id => { + if (!localStorage.getItem('section_' + id)) + localStorage.setItem('section_' + id, 'collapsed'); +}); +*/ \ No newline at end of file diff --git a/public/index.html b/public/index.html old mode 100755 new mode 100644 index 74a3a41..eac70e0 --- a/public/index.html +++ b/public/index.html @@ -1,35 +1,36 @@ - - -
- - -