diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2017-06-23 15:45:05 +1200 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2017-06-23 15:45:05 +1200 |
commit | a24f48627b914b6a8fe60bc3b5f76abc4f6fc574 (patch) | |
tree | 52fdf3095e25b0f98274eb6d87374311dc21e7bb /src/org | |
parent | 18ffeeb37c5efa54ffea852ad500f2d06ddba5be (diff) | |
download | trackermap-server-a24f48627b914b6a8fe60bc3b5f76abc4f6fc574.tar.gz trackermap-server-a24f48627b914b6a8fe60bc3b5f76abc4f6fc574.tar.bz2 trackermap-server-a24f48627b914b6a8fe60bc3b5f76abc4f6fc574.zip |
Add CalAmp ignition support (fix #2752)
Diffstat (limited to 'src/org')
-rw-r--r-- | src/org/traccar/protocol/CalAmpProtocolDecoder.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/org/traccar/protocol/CalAmpProtocolDecoder.java b/src/org/traccar/protocol/CalAmpProtocolDecoder.java index 60b19ab06..557e2d6e6 100644 --- a/src/org/traccar/protocol/CalAmpProtocolDecoder.java +++ b/src/org/traccar/protocol/CalAmpProtocolDecoder.java @@ -104,7 +104,9 @@ public class CalAmpProtocolDecoder extends BaseProtocolDecoder { position.set(Position.KEY_HDOP, buf.readUnsignedByte()); } - position.set(Position.KEY_INPUT, buf.readUnsignedByte()); + int input = buf.readUnsignedByte(); + position.set(Position.KEY_INPUT, input); + position.set(Position.KEY_IGNITION, BitUtil.check(input, 0)); if (type != MSG_MINI_EVENT_REPORT) { position.set(Position.KEY_STATUS, buf.readUnsignedByte()); |