diff options
Diffstat (limited to 'src/org/traccar/protocol/CguardProtocolDecoder.java')
-rw-r--r-- | src/org/traccar/protocol/CguardProtocolDecoder.java | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/org/traccar/protocol/CguardProtocolDecoder.java b/src/org/traccar/protocol/CguardProtocolDecoder.java index f1d593944..e1274d9d8 100644 --- a/src/org/traccar/protocol/CguardProtocolDecoder.java +++ b/src/org/traccar/protocol/CguardProtocolDecoder.java @@ -65,14 +65,14 @@ public class CguardProtocolDecoder extends BaseProtocolDecoder { position.setTime(parser.nextDateTime()); position.setValid(true); - position.setLatitude(parser.nextDouble()); - position.setLongitude(parser.nextDouble()); - position.setSpeed(UnitsConverter.knotsFromKph(parser.nextDouble())); + position.setLatitude(parser.nextDouble(0)); + position.setLongitude(parser.nextDouble(0)); + position.setSpeed(UnitsConverter.knotsFromKph(parser.nextDouble(0))); - position.setAccuracy(parser.nextDouble()); + position.setAccuracy(parser.nextDouble(0)); - position.setCourse(parser.nextDouble()); - position.setAltitude(parser.nextDouble()); + position.setCourse(parser.nextDouble(0)); + position.setAltitude(parser.nextDouble(0)); return position; } |