JNP3 16/17

Dependencies:   mbed nRF24L01P

Revision:
62:eb9a2599684c
Parent:
26:52e8eee05dc6
Child:
64:5f41e3054045
diff -r 9e4e08aae8d0 -r eb9a2599684c frontend/kubus.js
--- a/frontend/kubus.js	Thu Jan 19 13:20:50 2017 +0100
+++ b/frontend/kubus.js	Mon Jan 23 10:52:18 2017 +0100
@@ -151,7 +151,7 @@
     }
 }
 
-class BoolChart extends SensorChart {
+class NumberOfUpdatesChart extends SensorChart {
     render() {
         this.chart = new Chart(this.canvas, this._getConfig([]));
     }
@@ -159,8 +159,6 @@
     _getConfig(data) {
         const config = super._getConfig(data);
         config.data.datasets[0].steppedLine = true;
-        config.options.scales.yAxes[0].ticks.max = 1;
-        config.options.scales.yAxes[0].ticks.min = 0;
         return config;
     }
 }
@@ -175,7 +173,7 @@
                 });
                 break;
             case "bool":
-                return new BoolChart(sensor.name);
+                return new NumberOfUpdatesChart(sensor.name);
                 break;
             default:
                 throw Error(`Sensor type ${sensor.type} not supported`);
@@ -222,4 +220,4 @@
     fakeUpdate();
 } else {
     update();
-}
\ No newline at end of file
+}