From 6dfcc849cb42138667acdd06b5ac81a602e10225 Mon Sep 17 00:00:00 2001 From: cse47242 Date: Sat, 9 Jan 2021 16:06:08 +0000 Subject: [PATCH] Upload files to '' --- README.md | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index e520f7b..5800154 100644 --- a/README.md +++ b/README.md @@ -35,11 +35,15 @@ node index.js Open browser to -http://localhost:8086 +http://localhost:8888 or if it does not work find the IP from net tools (ifconfig), usually some form of 172.0.... and use Chronograf UI to visualize generated data. +In Chronograf go to the influx DB Admin tab and create a database named "dummy-data" so that the data created by the fake devices have a database to be stored + +after creating the database just go to the "explore" tab and select the type of data you want to see and from which device they derive from (for example select the "airforce" data type and select the device id you want to track, lastly select "value" on the right for the data to be displayed) + ## Usage const FakeDeviceManager = require('./src/fake-device-manager') @@ -48,14 +52,15 @@ and use Chronograf UI to visualize generated data. const connection = FakeDeviceConnection() const deviceManager = FakeDeviceManager({ - deviceCount: 100, - metricsInterval: 30, + deviceCount: 10, + metricsInterval: 30000, connection: FakeDeviceConnection, onUpdateStats: updateStats, measurements: { - usage: {type: 'integer', min: 0, max: 100}, - voltage: {type: 'integer', min: 0, max: 15}, - temperature: {type: 'integer', min: -20, max: 60} + temperature: {type: 'integer', min: -20, max: 60}, + air_humidity: {type: 'integer', min: 20, max: 100}, + ground_humidity: {type: 'integer', min: 20, max: 100}, + airforce: {type: 'integer', min: 0, max: 10} } }) deviceManager.start() @@ -105,12 +110,3 @@ Methods * `stop`: Stop all spawned instances * `send`: Send data to data store * `getData`: Get data buffer - -## Todos - - - Write Todo list :) - -License ----- - -MIT