diff options
author | telubato <telmotomas@gmail.com> | 2021-12-08 15:58:56 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-08 15:58:56 +0000 |
commit | b845750ff5be762098b8d246fbb2ca4f35b7e9c5 (patch) | |
tree | 82f937101dda27730fe7803100ebf9617a39493c | |
parent | 955c1abe0753a030846db552c6eea262d7d326d1 (diff) | |
download | trackermap-server-b845750ff5be762098b8d246fbb2ca4f35b7e9c5.tar.gz trackermap-server-b845750ff5be762098b8d246fbb2ca4f35b7e9c5.tar.bz2 trackermap-server-b845750ff5be762098b8d246fbb2ca4f35b7e9c5.zip |
Add new IO's
-rw-r--r-- | src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java index 5c2885a8b..2812d22ff 100644 --- a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java @@ -102,6 +102,12 @@ 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; @@ -110,22 +116,19 @@ public class RuptelaProtocolDecoder extends BaseProtocolDecoder { case 80: position.set(Position.PREFIX_TEMP + (id - 78), readValue(buf, length, true) * 0.1); break; - case 198: - if (readValue(buf, length, false) > 0) { - position.set(Position.KEY_ALARM, Position.ALARM_OVERSPEED); - } - break; - case 199: - case 200: + case 134: if (readValue(buf, length, false) > 0) { position.set(Position.KEY_ALARM, Position.ALARM_BRAKING); } break; - case 201: + case 136: 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; |