Data is invalid but adds totalDistance

opengrace 9 years ago

Hello,

I use wialon mobile app to traccar server,

i found this record valid=true but distance is not reasonable.

2017-05-12 12:35:34 DEBUG: 
value = {
   "valid": "false",
   "protocol": "wialon",
   "speed": "0.0",
   "master_group": "track@lacak.co",
   "altitude": "0.0",
   "server_time": "12-05-2017 12:35:34",
   "adc1": "0.0",
   "device_time": "12-05-2017 12:35:31",
   "adc2": "0.0",
   "ip": "217.23.132.215",
   "id": "104177945417",
   "course": "0.0",
   "input": "0",
   "distance": 11853898.55,
   "sat": 0,
   "event": "42",
   "name": "Driver 41",
   "totalDistance": 11935946.36,
   "longitude": "0.0",
   "latitude": "0.0",
   "group": "pana@lacak.co",
   "output": "0",
   "fix_time": "12-05-2017 12:35:31"
}

2017-05-12 12:35:50 DEBUG:
value = {
   "valid": "true",
   "protocol": "wialon",
   "speed": "0.0",
   "master_group": "track@lacak.co",
   "altitude": "0.0",
   "server_time": "12-05-2017 12:35:50",
   "adc1": "0.0",
   "device_time": "12-05-2017 12:35:49",
   "adc2": "0.0",
   "ip": "217.23.132.215",
   "id": "104177945417",
   "course": "0.0",
   "input": "0",
   "distance": 11877092.38,
   "sat": 8,
   "event": "2",
   "name": "Driver 41",
   "totalDistance": 23813038.74,
   "longitude": "106.79258",
   "latitude": "-6.130163333333333",
   "group": "pana@lacak.co",
   "output": "0",
   "fix_time": "12-05-2017 12:35:49"
}

Total distance calculation becomes unreasonable.
how to solve this ?

opengrace 9 years ago

valid true or false, data from device or traccar do ?

Anton Tananaev 9 years ago

I don't know where you get those JSON logs, but they are not from official version of Traccar.

opengrace 9 years ago

I modified the display log.

please help

Anton Tananaev 9 years ago

Valid flag is either reported by device, or it's set to "true" if protocol doesn't support this flag.

danny.chiang91 9 years ago

Hi Anton,

is there any way in traccar to automatically dump tracking data with flag "valid=false" and lat long 0,0 ?
so that i won't appear when i retrieve Reports > Type = Route

danny.chiang91 9 years ago

based on my opinion, if we succeed to dump data with flag "valid=false"
the distance value won't be like that..

Anton Tananaev 9 years ago

@danny.chiang91, have you tried searching for an answer before asking? It has been discussed countless number of times. Traccar has filtering options that can remove invalid positions and even zero coordinates.