diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2017-06-01 23:11:02 +1200 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2017-06-01 23:11:02 +1200 |
commit | 77a475886aea9604030efd5e5deeb634990312f3 (patch) | |
tree | 565a6b613cf879a74354ce5f196258b3efd692cd /src | |
parent | 7de54a8363cb3e24a7c53c6c3dfb8c17c2957b30 (diff) | |
download | trackermap-server-77a475886aea9604030efd5e5deeb634990312f3.tar.gz trackermap-server-77a475886aea9604030efd5e5deeb634990312f3.tar.bz2 trackermap-server-77a475886aea9604030efd5e5deeb634990312f3.zip |
Fix FlexComm time decoding
Diffstat (limited to 'src')
-rw-r--r-- | src/org/traccar/protocol/FlexCommProtocolDecoder.java | 6 |
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()); |