aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java
index 2680e56b2..1f2887859 100644
--- a/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java
+++ b/src/main/java/org/traccar/protocol/RuptelaProtocolDecoder.java
@@ -285,18 +285,18 @@ public class RuptelaProtocolDecoder extends BaseProtocolDecoder {
driverId.release();
}
- Long tcoDriverIdPart1 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 155);
- Long tcoDriverIdPart2 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 156);
- if (tcoDriverIdPart1 != null && tcoDriverIdPart2 != null) {
- ByteBuf driverId = Unpooled.copyLong(tcoDriverIdPart1, tcoDriverIdPart2);
+ driverIdPart1 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 155);
+ driverIdPart2 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 156);
+ if (driverIdPart1 != null && driverIdPart2 != null) {
+ ByteBuf driverId = Unpooled.copyLong(driverIdPart1, driverIdPart2);
position.set(Position.KEY_DRIVER_UNIQUE_ID, driverId.toString(StandardCharsets.US_ASCII));
driverId.release();
}
- Long bleBeaconIdP1 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 760);
- Long bleBeaconIdP2 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 761);
- if (bleBeaconIdP1 != null && bleBeaconIdP2 != null) {
- position.set("bleBeaconId", Long.toHexString(bleBeaconIdP1) + Long.toHexString(bleBeaconIdP2));
+ Long tagIdPart1 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 760);
+ Long tagIdPart2 = (Long) position.getAttributes().remove(Position.PREFIX_IO + 761);
+ if (tagIdPart1 != null && tagIdPart2 != null) {
+ position.set("tagId", Long.toHexString(tagIdPart1) + Long.toHexString(tagIdPart2));
}
positions.add(position);