Teltonika protocol decoder

Victor Butler2 years ago

Hi,

I can see Teltonika protocol was changed, in terms this code was added:

static {
        var fmbXXX = Set.of(
                "FMB001", "FMB010", "FMB002", "FMB020", "FMB003", "FMB110", "FMB120", "FMB122", "FMB125", "FMB130",
                "FMB140", "FMU125", "FMB900", "FMB920", "FMB962", "FMB964", "FM3001", "FMB202", "FMB204", "FMB206",
                "FMT100", "MTB100", "FMP100", "MSP500");```

I assume the aim here is to properly decode the parameters for this group of devices.

The question is, how do we indicate to Traccar that the sending device is FMB001 for example, so that it knows to place it within fmbXXX set?

Anton Tananaev2 years ago

You set the device model field when you create a device.

Victor Butler2 years ago

Thank you, Anton!

A follow up question:

If a parameter is decoded, let's day 24 -> speed, does Traccar record both values in positions table, or it only records the speed parameter?

This is the relevant code:
register(24, fmbXXX, (p, b) -> p.setSpeed(UnitsConverter.knotsFromKph(b.readUnsignedShort())));