diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2016-02-22 23:08:29 +1300 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2016-02-22 23:08:29 +1300 |
commit | 7118504798b62b4f0c0186a19e8417463d653383 (patch) | |
tree | 934b58cd04d5f1344f417e39ec8d334096ffe691 /src/org/traccar | |
parent | 8436dd58c37545973803dd292d36aaad3c2fdc70 (diff) | |
download | traccar-server-7118504798b62b4f0c0186a19e8417463d653383.tar.gz traccar-server-7118504798b62b4f0c0186a19e8417463d653383.tar.bz2 traccar-server-7118504798b62b4f0c0186a19e8417463d653383.zip |
Decode battery for Telic (fix #1735)
Diffstat (limited to 'src/org/traccar')
-rw-r--r-- | src/org/traccar/protocol/TelicProtocolDecoder.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/org/traccar/protocol/TelicProtocolDecoder.java b/src/org/traccar/protocol/TelicProtocolDecoder.java index 3ba81de6e..6e6e94325 100644 --- a/src/org/traccar/protocol/TelicProtocolDecoder.java +++ b/src/org/traccar/protocol/TelicProtocolDecoder.java @@ -50,6 +50,8 @@ public class TelicProtocolDecoder extends BaseProtocolDecoder { .number("(d+),") // speed .number("(d+),") // course .number("(d+),") // satellites + .expression("(?:[^,]*,){7}") + .number("(d+),") .any() .compile(); @@ -92,6 +94,7 @@ public class TelicProtocolDecoder extends BaseProtocolDecoder { position.setCourse(parser.nextDouble()); position.set(Event.KEY_SATELLITES, parser.next()); + position.set(Event.KEY_BATTERY, parser.nextInt()); return position; } |