summaryrefslogtreecommitdiffstats
path: root/app/Dashboard.qml
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2024-08-17 12:38:30 +0000
committerGerrit Code Review <gerrit@automotivelinux.org>2024-08-17 12:38:30 +0000
commitb1b67ab525555a082ca257ad08fc4fba9b1f74e3 (patch)
tree57cc9f9543af68a0be80b6f55b6d0ccf0245b733 /app/Dashboard.qml
parente259522fe8a671da34d101275a8ee628a15b543b (diff)
parentfeaa51384448d7277b6ea115a954c456a9069b2c (diff)
Merge "Fix engine speed signal type"
Diffstat (limited to 'app/Dashboard.qml')
-rw-r--r--app/Dashboard.qml6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/Dashboard.qml b/app/Dashboard.qml
index 1a797c6..3c1a73b 100644
--- a/app/Dashboard.qml
+++ b/app/Dashboard.qml
@@ -33,7 +33,7 @@ ApplicationWindow {
}
property double vehicleSpeed: 0
- property double engineSpeed: 0
+ property int engineSpeed: 0
property bool mphDisplay: false
Component.onCompleted : {
@@ -74,8 +74,8 @@ ApplicationWindow {
else
vehicleSpeed = parseFloat(value)
} else if (path === "Vehicle.Powertrain.CombustionEngine.Speed") {
- engineSpeed = parseFloat(value)
- tachometer.value = engineSpeed / 7000
+ engineSpeed = parseInt(value)
+ tachometer.value = engineSpeed / 7000.0
} else if (path === "Vehicle.Cabin.Infotainment.HMI.DistanceUnit") {
if (value === "km") {
mphDisplay = false