ignore 0 coordinates

Angelo10 months ago

hi,
got something in the log:

2024-03-01 20:04:25  INFO: [T377df513] id: 860501044912117, time: 2024-03-01 20:04:20, lat: 0.00000, lon: -0.00000, course: 0.0
2024-03-01 20:04:25  INFO: [T377df513] id: 860501044912117, time: 2024-03-01 20:04:20, lat: 0.00000, lon: -0.00000, course: 0.0

how to configure the server to ignore this kind of data?
also since it's already in the database, how to remove that?
Thanks

Cristian10 months ago
<entry key='filter.zero'>true</entry>

filter.zero config

Filter zero coordinates. Zero latitude and longitude are theoretically valid values, but it practice it usually indicates invalid GPS data.

Angelo10 months ago

thanks

Henrick Langner9 months ago

I copied your line, entered it to my config and restarted the traccar.service but when I open a device history, there are still zero coordinates shown… is it working for you?

Anton Tananaev9 months ago

Filtering won't change history. It will only apply to the new data.

Henrick Langner9 months ago

Thanks. I fixed it with this MySQL-command:

DELETE FROM tc_positions WHERE latitude = "0";