From aa59b968c7d6a89b8e6285647ab2e6e62f02cf7f Mon Sep 17 00:00:00 2001 From: Iván Ávalos Date: Mon, 27 Dec 2021 20:48:47 -0600 Subject: Revert "Merge branch 'master' into suntech-fixes" This reverts commit f03b999d6d17e53c1c1e1aa2f9271d03f12f2264, reversing changes made to 3a528ddc88f72f39ff9566cf5e0f54938b1584ef. --- .../org/traccar/protocol/RuptelaProtocolDecoder.java | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) (limited to 'src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java') diff --git a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java index 2812d22ff..5c2885a8b 100644 --- a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java @@ -102,12 +102,6 @@ public class RuptelaProtocolDecoder extends BaseProtocolDecoder { case 5: position.set(Position.KEY_IGNITION, readValue(buf, length, false) == 1); break; - case 29: - position.set(Position.KEY_POWER, readValue(buf, length, false)); - break; - case 30: - position.set(Position.KEY_BATTERY, readValue(buf, length, false) * 0.001); - break; case 74: position.set(Position.PREFIX_TEMP + 3, readValue(buf, length, true) * 0.1); break; @@ -116,19 +110,22 @@ public class RuptelaProtocolDecoder extends BaseProtocolDecoder { case 80: position.set(Position.PREFIX_TEMP + (id - 78), readValue(buf, length, true) * 0.1); break; - case 134: + case 198: + if (readValue(buf, length, false) > 0) { + position.set(Position.KEY_ALARM, Position.ALARM_OVERSPEED); + } + break; + case 199: + case 200: if (readValue(buf, length, false) > 0) { position.set(Position.KEY_ALARM, Position.ALARM_BRAKING); } break; - case 136: + case 201: if (readValue(buf, length, false) > 0) { position.set(Position.KEY_ALARM, Position.ALARM_ACCELERATION); } break; - case 197: - position.set(Position.KEY_RPM, readValue(buf, length, false) * 0.125); - break; default: position.set(Position.PREFIX_IO + id, readValue(buf, length, false)); break; -- cgit v1.2.3