Help with skipAttributes parameter

Adriano Miranda10 months ago

Hi everyone,

I'm seeking some guidance regarding the skipAttributes configuration option in Traccar 5.12. Despite my attempts, I'm still encountering command results being filtered even with skipAttributes enabled.

I'm testing with a device using the GT06 protocol. Here's my relevant filter configuration:

<entry key='filter.duplicate'>true</entry>
<entry key='filter.future'>300</entry>
<entry key='filter.outdated'>true</entry>
<entry key='filter.distance'>10</entry>
<entry key='filter.skipAttributes.enable'>true</entry>
<entry key='filter.skipAttributes'>result,command,alarm,event,status</entry>
<entry key='coordinates.filter'>true</entry>
<entry key='coordinates.maxError'>0</entry>

However, whenever my device sends a command result, it gets filtered out by the filter.distance setting. Here's an example of the received package:

787813150b0000000053454e44533a330001001039480d0a

In this package, 53454e44533a33 translates to "SENDS:3", which indicates a command result.

I've confirmed that filter.skipAttributes.enable is set to true, and the attributes listed include "result". Could someone please help me understand why command results are still being filtered and suggest a solution to prevent this?

Thank you.

Anton Tananaev10 months ago

Does Traccar actually decode it as a result?

Adriano Miranda10 months ago

I'm not sure. However, disabling the filter.distance allows the result popup to appear and then I can see it in the Events report (event type as "command result").

Adriano Miranda10 months ago

Ok, Traccar decode it as a result (right?):

JE0EIvn.md.png

Adriano Miranda10 months ago

I think I've found the issue: the outdated filter.

The filter.outdated setting, not filter.distance, was responsible for filtering the received data. I double-checked FilterHandler.java and verified that there's no specific conditional logic within filter.outdated for skipping attributes.

Anton Tananaev10 months ago

Why did it work if you removed only filter.distance previously?

Adriano Miranda10 months ago

I apologize for the confusion. I was mistakenly commenting out both filters (filter.distance and filter.outdated) in my previous attempt to troubleshoot the issue. This led me to believe that filter.distance was the cause of the problem, when in fact it was filter.outdated.