removed junk
This commit is contained in:
@@ -4,7 +4,7 @@ const sensorData = {};
|
||||
let liveGraphs = [];
|
||||
let nodeArray = [];
|
||||
let nodeDict = {};
|
||||
|
||||
let graphArray = [];
|
||||
// letiables
|
||||
let intervalDelay = 5000;
|
||||
let amountOfNodes = 3;
|
||||
@@ -101,29 +101,6 @@ async function nodeAdressHandler(node, dataTypes) {
|
||||
}
|
||||
}
|
||||
|
||||
function createGauge(node, dataType) {
|
||||
// Create a new gauge here
|
||||
let gauge = new GaugeGroup(node, dataType); // Assuming Gauge is the name of the class
|
||||
sensorData[node][dataType] = gauge; // Store the gauge in the sensorData object for later use
|
||||
}
|
||||
|
||||
|
||||
//function for making the html elements for the following html code
|
||||
function nodeData(data) {
|
||||
let nodeData = document.createElement("div");
|
||||
nodeData.innerHTML = data;
|
||||
// nodeData.setAttribute("id", "node" + node);
|
||||
document.body.appendChild(nodeData);
|
||||
// console.log("Hello World");
|
||||
}
|
||||
|
||||
|
||||
function updateGauge(nodeNumber, dataType, value) {
|
||||
// Update the gauge here
|
||||
let gauge = sensorData[nodeNumber][dataType]; // Get the gauge from the sensorData object
|
||||
gauge.update(value); // Assuming the Gauge class has an update method
|
||||
}
|
||||
|
||||
function getNodeInfo(node){
|
||||
return fetch("http://145.92.8.114/getNodeInfo?macAdress=" + node)
|
||||
.then(response => {
|
||||
@@ -143,3 +120,4 @@ function getNodeInfo(node){
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user