From 9e41b5f94063fa9f40725d115d16b9a2c1842720 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Fri, 19 Apr 2024 08:15:23 -0700 Subject: Additional GPS Watch data --- .../traccar/protocol/TrvProtocolDecoderTest.java | 27 +++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) (limited to 'src/test/java') diff --git a/src/test/java/org/traccar/protocol/TrvProtocolDecoderTest.java b/src/test/java/org/traccar/protocol/TrvProtocolDecoderTest.java index 370775735..a17fc341f 100644 --- a/src/test/java/org/traccar/protocol/TrvProtocolDecoderTest.java +++ b/src/test/java/org/traccar/protocol/TrvProtocolDecoderTest.java @@ -2,6 +2,7 @@ package org.traccar.protocol; import org.junit.jupiter.api.Test; import org.traccar.ProtocolTest; +import org.traccar.model.Position; public class TrvProtocolDecoderTest extends ProtocolTest { @@ -13,6 +14,30 @@ public class TrvProtocolDecoderTest extends ProtocolTest { verifyNull(decoder, text( "TRVAP00352121088015548")); + verifyAttribute(decoder, text( + "IWAP10080524A2232.9806N11404.9355E000.1061830323.8706000908000502,460,0,9520,3671,01,zhcn,00,HOME|74-DE-2B-44-88-8C|97&HOME1|74-DE-2B-44-88-8C|97&HOME2|74-DE-2B-44-88-8C|97&HOME3|74-DE-2B-44-88-8C|97"), + Position.KEY_ALARM, Position.ALARM_SOS); + + verifyAttribute(decoder, text( + "IWAP49,68"), + Position.KEY_HEART_RATE, 68); + + verifyAttribute(decoder, text( + "IWAPHT,60,130,85"), + "pressureDiastolic", 85); + + verifyAttribute(decoder, text( + "IWAPHP,60,130,85,95,90,36.5,,,,,,,"), + "temperature", 36.5); + + verifyAttribute(decoder, text( + "IWAP50,36.7,90"), + Position.KEY_BATTERY_LEVEL, 90); + + verifyAttribute(decoder, text( + "IWAP03,06000908000102,5555,30"), + Position.KEY_STEPS, 5555); + verifyPosition(decoder, text( "TRVYP14080524A2232.9806N11404.9355E000.1061830323.870600090800010200011,460,0,9520,3671,Home|74-DE-2B-44-88-8C|97&Home1|74-DE-2B-44-88-8C|97&Home2|74-DE-2B-44-88-8C|97& Home3|74-DE-2B-44-88-8C|97")); @@ -40,7 +65,7 @@ public class TrvProtocolDecoderTest extends ProtocolTest { verifyPosition(decoder, text( "IWAP10080524A2232.9806N11404.9355E000.1061830323.8706000908000502,460,0,9520,3671,00,zh-cn,00,HOME|74-DE-2B-44-88-8C|97&HOME1|74-DE-2B-44-88-8C|97&HOME2|74-DE-2B-44-88-8C|97&HOME3|74-DE-2B-44-88-8C|97")); - verifyNull(decoder, text( + verifyAttributes(decoder, text( "IWAP03,06000908000102,5555,30")); verifyNull(decoder, text( -- cgit v1.2.3