aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2016-05-04 23:16:14 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2016-05-04 23:16:14 +1200
commit59f466092c9c875c2bbcb70a2a402aad0edd7639 (patch)
tree7cdde52dd76abce49eaf838169c9aab988b1d153 /src
parent852343a73b52d3e2c924f1803a0fa2d3ca8443de (diff)
downloadtrackermap-server-59f466092c9c875c2bbcb70a2a402aad0edd7639.tar.gz
trackermap-server-59f466092c9c875c2bbcb70a2a402aad0edd7639.tar.bz2
trackermap-server-59f466092c9c875c2bbcb70a2a402aad0edd7639.zip
Decode Astra reason and status
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/protocol/AstraProtocolDecoder.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/AstraProtocolDecoder.java b/src/org/traccar/protocol/AstraProtocolDecoder.java
index d19b68761..8f40abedf 100644
--- a/src/org/traccar/protocol/AstraProtocolDecoder.java
+++ b/src/org/traccar/protocol/AstraProtocolDecoder.java
@@ -78,8 +78,9 @@ public class AstraProtocolDecoder extends BaseProtocolDecoder {
position.setCourse(buf.readUnsignedByte() * 2);
int reason = buf.readUnsignedMedium();
- buf.readUnsignedShort(); // status
+ position.set(Event.KEY_EVENT, reason);
+ position.set(Event.KEY_STATUS, buf.readUnsignedShort());
position.set(Event.PREFIX_IO + 1, buf.readUnsignedByte());
position.set(Event.PREFIX_ADC + 1, buf.readUnsignedByte());
position.set(Event.KEY_BATTERY, buf.readUnsignedByte());