aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/org/traccar/protocol/MegastekProtocolDecoder.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/org/traccar/protocol/MegastekProtocolDecoder.java b/src/org/traccar/protocol/MegastekProtocolDecoder.java
index d014869d8..ee7c5df2c 100644
--- a/src/org/traccar/protocol/MegastekProtocolDecoder.java
+++ b/src/org/traccar/protocol/MegastekProtocolDecoder.java
@@ -67,12 +67,12 @@ public class MegastekProtocolDecoder extends BaseProtocolDecoder {
"(\\d+)," + // Battery
"(\\d+)," + // Flags
"(\\d+)," + // Inputs
- "(\\d+)," + // Outputs
- "(\\d\\.\\d{2})," + // ADC 1
- "(\\d\\.\\d{2})," + // ADC 2
- "(\\d\\.\\d{2})," + // ADC 3
+ "(?:(\\d+),)?" + // Outputs
+ "(\\d\\.?\\d*)," + // ADC 1
+ "(?:(\\d\\.\\d{2})," + // ADC 2
+ "(\\d\\.\\d{2}),)?" + // ADC 3
"([^;]+);" + // Alarm
- ".+"); // Checksum
+ ".*"); // Checksum
private boolean parseGPRMC(String gprmc, Position position) {