modified: static/js/sensor-1.js
This commit is contained in:
parent
87f47bb595
commit
4c4c9a74a7
@ -21,7 +21,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
.then(response => response.json())
|
||||
.then(data => {
|
||||
// 如果已有200个数据则移除最旧的一条
|
||||
if (timestamps.length >= 200) {
|
||||
if (timestamps.length >= 50) {
|
||||
timestamps.shift();
|
||||
temperatures.shift();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user