GT06 protocol - Wrong Date and Time noticed in the log

Harshana Srimal5 months ago

I found an abnormal device and when I check the log I seen this.

2024-08-08 03:54:58  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 7878312418080803363800019d0104f81b00644d68f81b00808b4ff81b004a5454f81b00644c4900000000000000000000f6a4540d0a
2024-08-08 03:54:58  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 03:54:58  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878052400f6606a0d0a
2024-08-08 03:55:08  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047d0200f7e1f80d0a
2024-08-08 03:55:08  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 03:55:08  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300f77b480d0a
2024-08-08 03:58:08  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047e0200f83cc20d0a
2024-08-08 03:58:08  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 03:58:08  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300f883bf0d0a
2024-08-08 03:59:09  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 79790020940a086711106220220241301668887704008994010216688877041600f9e23b0d0a
2024-08-08 03:59:09  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:01:09  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047e0200fa1fd00d0a
2024-08-08 04:01:09  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:01:09  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300faa0ad0d0a
2024-08-08 04:04:09  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047e0200fb0e590d0a
2024-08-08 04:04:09  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:04:09  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300fbb1240d0a
2024-08-08 04:04:10  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 79790020940a086711106220220241301668887704008994010216688877041600fcb5960d0a
2024-08-08 04:04:10  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:07:10  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047e0200fd6b6f0d0a
2024-08-08 04:07:10  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:07:10  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300fdd4120d0a
2024-08-08 04:09:10  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 79790020940a086711106220220241301668887704008994010216688877041600fe96840d0a
2024-08-08 04:09:10  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:10:10  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1304f0047e0200ff487d0d0a
2024-08-08 04:10:10  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:10:10  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878051300fff7000d0a
2024-08-08 04:10:30  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78783124180808040a1d00019d0104f81b00644c68f81b00808b51f81b00644d44f81b00644e4f0000000000000000000100729e0d0a
2024-08-08 04:10:30  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:10:30  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 787805240100eb0b0d0a
2024-08-08 04:11:46  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78783124180808040b2c00019d0104f81b00644d68f81b00808b50f81b004a4f5df81b004a53550000000000000000000101ef660d0a
2024-08-08 04:11:46  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:11:46  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 787805240101fa820d0a
2024-08-08 04:12:14  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1306f0037e0201027aa80d0a
2024-08-08 04:12:14  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:12:14  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 787805130102c2b20d0a
2024-08-08 04:13:16  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78783124180808040d0f00019d0104f81b00644e68f81b004a4f61f81b00644d44f81b00808b52000000000000000000010392d60d0a
2024-08-08 04:13:16  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0
2024-08-08 04:13:16  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 787805240103d9900d0a
2024-08-08 04:13:32  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78782222180808040d1ec800cd6b54089f5db90014ae019d01f81b00644d010000010447bd0d0a
2024-08-08 04:13:32  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-08 04:13:30, lat: 7.47909, lon: 80.36775, course: 174.0
2024-08-08 04:13:32  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 7878052201047bf60d0a
2024-08-08 04:14:11  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 79790020940a08671110622022024130166888770400899401021668887704160105c6000d0a
2024-08-08 04:14:11  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-08 04:13:30, lat: 7.47909, lon: 80.36775, course: 174.0
2024-08-08 04:14:57  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1344f00477020106058e0d0a
2024-08-08 04:14:57  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-08 04:13:30, lat: 7.47909, lon: 80.36775, course: 174.0
2024-08-08 04:14:57  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 78780513010684960d0a
2024-08-08 04:17:58  INFO: [Tf8bbc4aa: gt06 < XXX.245.171.109] 78780a1344f00383020107211c0d0a
2024-08-08 04:17:58  INFO: [Tf8bbc4aa] id: 867111062202202, time: 2024-08-08 04:13:30, lat: 7.47909, lon: 80.36775, course: 174.0
2024-08-08 04:17:58  INFO: [Tf8bbc4aa: gt06 > XXX.245.171.109] 787805130107951f0d0a

I tried to decode the packet manually and I noticed the data is wrong.

see example below

78783124180808040d0f00019d0104f81b00644e68f81b004a4f61f81b00644d44f81b00808b52000000000000000000010392d60d0a

Its timestamp is 180808040d0f which mean 2024-08-08 04:13:14 but the decoded data from the log is different.

id: 867111062202202, time: 2024-08-07 12:01:36, lat: 7.47732, lon: 80.36757, speed: 7.6, course: 133.0

I seen many data came from the device but the decoded log keep saying time: 2024-08-07 12:01:36

Anton Tananaev4 months ago

Looks like it's not supported. In our current implementation message type 0x24 is for a LBS message type.

Harshana Srimal4 months ago

According to the document, 24 means LBS packet but still the flag has datetime and some other details.

Here is the protocol document.

could you have a look.

Anton Tananaev4 months ago

I suspect you're mixing up device time and fix time.

Harshana Srimal4 months ago

I dont think so. my device time and the server time both have GMT 0 time zone. so the fix time must be device time right?

also I see below packet decoded correctly

78782222180808040d1ec800cd6b54089f5db90014ae019d01f81b00644d010000010447bd0d0a

it says time: 2024-08-08 04:13:30 in log.

Anton Tananaev4 months ago

I recommend searching forum to understand the different between different timestamps and how we use it. Your current assumption is wrong.

Harshana Srimal4 months ago

Thank you so much for the advice. I will search and read.

Harshana Srimal4 months ago

Fix time: came from the device. this time is the time obtained with last position packet.

Device time: this one also came from the device with any packet.

Server time: the server time when the position data saved

here what I understood from the old posts. Please correct me if I’m wrong.

Anton Tananaev4 months ago

Kind of. Fix time is the time of last GPS fix. In your case it's not a GPS message, so it will use the last known fix time.

Harshana Srimal4 months ago

Thanks for the clarification ❤️