aboutsummaryrefslogtreecommitdiff
path: root/src/org
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2017-06-01 23:11:02 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2017-06-01 23:11:02 +1200
commit77a475886aea9604030efd5e5deeb634990312f3 (patch)
tree565a6b613cf879a74354ce5f196258b3efd692cd /src/org
parent7de54a8363cb3e24a7c53c6c3dfb8c17c2957b30 (diff)
downloadtrackermap-server-77a475886aea9604030efd5e5deeb634990312f3.tar.gz
trackermap-server-77a475886aea9604030efd5e5deeb634990312f3.tar.bz2
trackermap-server-77a475886aea9604030efd5e5deeb634990312f3.zip
Fix FlexComm time decoding
Diffstat (limited to 'src/org')
-rw-r--r--src/org/traccar/protocol/FlexCommProtocolDecoder.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/org/traccar/protocol/FlexCommProtocolDecoder.java b/src/org/traccar/protocol/FlexCommProtocolDecoder.java
index 086a2de0b..33b4c0abb 100644
--- a/src/org/traccar/protocol/FlexCommProtocolDecoder.java
+++ b/src/org/traccar/protocol/FlexCommProtocolDecoder.java
@@ -89,8 +89,8 @@ public class FlexCommProtocolDecoder extends BaseProtocolDecoder {
}
position.setDeviceId(deviceSession.getDeviceId());
- position.setValid(parser.next().equals("1"));
position.setTime(parser.nextDateTime());
+ position.setValid(parser.next().equals("1"));
position.setLatitude(parseSignedValue(parser, 6));
position.setLongitude(parseSignedValue(parser, 6));
position.setAltitude(parseSignedValue(parser, 0));
@@ -104,8 +104,8 @@ public class FlexCommProtocolDecoder extends BaseProtocolDecoder {
position.setNetwork(new Network(CellTower.from(
parser.nextInt(), parser.nextInt(), parser.nextHexInt(), parser.nextHexInt())));
- position.set(Position.KEY_INPUT, parser.nextInt());
- position.set(Position.KEY_OUTPUT, parser.nextInt());
+ position.set(Position.KEY_INPUT, parser.nextBinInt());
+ position.set(Position.KEY_OUTPUT, parser.nextBinInt());
position.set(Position.KEY_FUEL_LEVEL, parser.nextInt());
position.set(Position.PREFIX_TEMP + 1, parseSignedValue(parser, 0));
position.set(Position.KEY_BATTERY_LEVEL, parser.nextInt());