blah work

This commit is contained in:
newtbot
2023-12-20 22:20:34 +08:00
parent 68ba9f8f67
commit 81553bd091
8 changed files with 307 additions and 12 deletions

0
IoT-sensor/index.js Normal file
View File

View File

@ -13,7 +13,7 @@
3) send the coap request to the server
*/
const { isNumber } = require("./functions/validateData");
const { isNumber } = require("../functions/validateData");
let region = ["central", "north-east", "north", "east", "west"];
@ -51,7 +51,7 @@ function getRandomValue(min, max) {
return Math.random() * (max - min) + min;
}
function iot_sensor_data() {
async function iot_sensor_data() {
//5 minutes
setInterval(() => {
var json = generateRandomData();

View File