From 78a3d28440b4de89eaab79664fef512e6e869030 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Thu, 12 May 2022 17:19:32 -0700 Subject: Support Envotech IVM format --- src/main/java/org/traccar/protocol/EnvotechProtocolDecoder.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/main/java/org') diff --git a/src/main/java/org/traccar/protocol/EnvotechProtocolDecoder.java b/src/main/java/org/traccar/protocol/EnvotechProtocolDecoder.java index 347063547..65d5e3859 100644 --- a/src/main/java/org/traccar/protocol/EnvotechProtocolDecoder.java +++ b/src/main/java/org/traccar/protocol/EnvotechProtocolDecoder.java @@ -48,7 +48,8 @@ public class EnvotechProtocolDecoder extends BaseProtocolDecoder { .number("(ddd),") // battery .number("(xx)") // inputs .number("(xx),") // outputs - .number("(xxx)?,") // fuel + .number("(xxx)?") // fuel + .number("(xxx)?,") // weight .number("(x{8}),") // status .expression("[^']*'") .number("(dd)(dd)(dd)") // date (ddmmyy) @@ -99,6 +100,7 @@ public class EnvotechProtocolDecoder extends BaseProtocolDecoder { position.set(Position.KEY_INPUT, parser.nextHexInt()); position.set(Position.PREFIX_OUT, parser.nextHexInt()); position.set(Position.KEY_FUEL_LEVEL, parser.nextHexInt()); + position.set("weight", parser.nextHexInt()); position.set(Position.KEY_STATUS, parser.nextHexLong()); position.setFixTime(parser.nextDateTime(Parser.DateTimeFormat.DMY_HMS)); -- cgit v1.2.3