diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2017-03-08 19:14:23 +1300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-08 19:14:23 +1300 |
commit | e3a3f06cc07bc5d75d3d670e045abb5d6c91fcad (patch) | |
tree | ee424dc1b6b86abb54abcc5fe4f2068ac0cbf286 /src/org/traccar/model | |
parent | b7e53f57689e1f8a1c0705aeea32dc6e69f3fcb3 (diff) | |
parent | f94613b97cf80af64154ae571920a273771fa1d3 (diff) | |
download | trackermap-server-e3a3f06cc07bc5d75d3d670e045abb5d6c91fcad.tar.gz trackermap-server-e3a3f06cc07bc5d75d3d670e045abb5d6c91fcad.tar.bz2 trackermap-server-e3a3f06cc07bc5d75d3d670e045abb5d6c91fcad.zip |
Merge pull request #2979 from jon-stumpf/jss-add-info
Additional Protocol Information
Diffstat (limited to 'src/org/traccar/model')
-rw-r--r-- | src/org/traccar/model/Position.java | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/src/org/traccar/model/Position.java b/src/org/traccar/model/Position.java index 96dc1d2ad..82b7e03ce 100644 --- a/src/org/traccar/model/Position.java +++ b/src/org/traccar/model/Position.java @@ -31,15 +31,20 @@ public class Position extends Message { public static final String KEY_EVENT = "event"; public static final String KEY_ALARM = "alarm"; public static final String KEY_STATUS = "status"; - public static final String KEY_ODOMETER = "odometer"; // meters - public static final String KEY_TRIP_ODOMETER = "tripOdometer"; + public static final String KEY_ODOMETER = "odometer"; // meters + public static final String KEY_ODOMETER_SERVICE = "serviceOdometer"; // meters + public static final String KEY_ODOMETER_TRIP = "tripOdometer"; // meters public static final String KEY_HOURS = "hours"; public static final String KEY_INPUT = "input"; public static final String KEY_OUTPUT = "output"; - public static final String KEY_POWER = "power"; - public static final String KEY_BATTERY = "battery"; - public static final String KEY_FUEL = "fuel"; - public static final String KEY_FUEL_CONSUMPTION = "fuelConsumption"; + + // The units for the below four KEYs currently vary. + // The preferred units of measure are specified in the comment for each. + public static final String KEY_POWER = "power"; // volts + public static final String KEY_BATTERY = "battery"; // volts (or percentage appending '%') + public static final String KEY_FUEL_LEVEL = "fuel"; // liters + public static final String KEY_FUEL_CONSUMPTION = "fuelConsumption"; // liters/hour + public static final String KEY_RFID = "rfid"; public static final String KEY_VERSION_FW = "versionFw"; public static final String KEY_VERSION_HW = "versionHw"; @@ -49,22 +54,23 @@ public class Position extends Message { public static final String KEY_CHARGE = "charge"; public static final String KEY_IP = "ip"; public static final String KEY_ARCHIVE = "archive"; - public static final String KEY_DISTANCE = "distance"; // meters - public static final String KEY_TOTAL_DISTANCE = "totalDistance"; + public static final String KEY_DISTANCE = "distance"; // meters + public static final String KEY_TOTAL_DISTANCE = "totalDistance"; // meters public static final String KEY_RPM = "rpm"; public static final String KEY_VIN = "vin"; public static final String KEY_APPROXIMATE = "approximate"; public static final String KEY_THROTTLE = "throttle"; public static final String KEY_MOTION = "motion"; public static final String KEY_ARMED = "armed"; - public static final String KEY_ACCURACY = "accuracy"; public static final String KEY_GEOFENCE = "geofence"; public static final String KEY_ACCELERATION = "acceleration"; - public static final String KEY_DEVICE_TEMP = "deviceTemp"; + public static final String KEY_DEVICE_TEMP = "deviceTemp"; // celsius + public static final String KEY_OPERATOR = "operator"; + public static final String KEY_COMMAND = "command"; public static final String KEY_DTCS = "dtcs"; - public static final String KEY_OBD_SPEED = "obdSpeed"; - public static final String KEY_OBD_ODOMETER = "obdOdometer"; + public static final String KEY_OBD_SPEED = "obdSpeed"; // knots + public static final String KEY_OBD_ODOMETER = "obdOdometer"; // meters public static final String KEY_RESULT = "result"; @@ -215,7 +221,7 @@ public class Position extends Message { this.longitude = longitude; } - private double altitude; + private double altitude; // value in meters public double getAltitude() { return altitude; |