corrects calculation of speed in kmh
This commit is contained in:
parent
4c3b640a54
commit
e611b21d80
@ -56,7 +56,7 @@ function addSerialSpeedData() {
|
||||
let speeds = []
|
||||
|
||||
indexes.forEach(index => {
|
||||
speeds.push((allSpeedsSerial[index].toFixed(2) * 3.6 * 3.6))
|
||||
speeds.push((allSpeedsSerial[index] * 3.6).toFixed(2))
|
||||
})
|
||||
myChart.data.datasets[0].data = speeds;
|
||||
myChart.update();
|
||||
@ -71,7 +71,7 @@ function addTCPSpeedData(sensordataList) {
|
||||
return;
|
||||
}
|
||||
let speed = sensordata.Speed
|
||||
speedsTCP.push(speed * 3.6);
|
||||
speedsTCP.push((speed * 3.6).toFixed(2));
|
||||
let time = sensordata.Servertime
|
||||
times.push(time)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user