mirror of
https://github.com/jam422470459/EPD-nRF52-hema213.git
synced 2025-12-06 08:32:54 +08:00
update html
This commit is contained in:
@@ -312,7 +312,13 @@ function handleNotify(value, idx) {
|
||||
updateDitcherOptions();
|
||||
} else {
|
||||
if (textDecoder == null) textDecoder = new TextDecoder();
|
||||
addLog(textDecoder.decode(data), '⇓');
|
||||
const msg = textDecoder.decode(data);
|
||||
addLog(msg, '⇓');
|
||||
if (msg.startsWith('t=') && msg.length > 2) {
|
||||
const t = parseInt(msg.substring(2)) + new Date().getTimezoneOffset() * 60;
|
||||
addLog(`远端时间: ${new Date(t * 1000).toLocaleString()}`);
|
||||
addLog(`本地时间: ${new Date().toLocaleString()}`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user