Sierra Wireless GNX-6 with OBD2 data

Jason C5 years ago

Our small organization has been using vehicle tracking software that was developed in-house about 10 years ago. I am new to the organization and was auditing the software and it is in need of a major rewrite. Before diving into that project I stumbled across Traccar and decided to give it a go and with very little effort I was able to get our old CalAmp units reporting to it just fine.

However, we are currently testing out Sierra Wireless GNX-6 OBD2 units which I've been a lot happier with. Besides the basic data they also send us a lot of data from the OBD2 connection such as VIN, Odometer, RPM, Coolant Temp, Fuel Levels, and voltage (yes CalAmp has models that do this too but they sometimes get stuck for days if the vehicle temporarily goes out of cell service range). The way the GNX-6 units are currently configured as is where they send a HEX string that contains two rows of CSV data. The first row is a header row with the field names, the second row is the actual data. This method allows us in our old system to try different configurations without ever worrying about messing up the order of the values sent to the server. Traccar doesn't seem to like that and is expecting only the data in a specific order/format. Has anyone one else gotten GNX-6 units working with Traccar while still also getting the OBD data as well? Or is there another protocol that already supports this flexibility in the type of data they receive?

Anton Tananaev5 years ago

Are you using TAIP protocol? It should support additional data.

Jason C5 years ago

I saw mention of the TAIP protocol, I wasn't sure if that was changing how the device formats the data it sends, or if it was getting the device to send to port 5031 which is parsed via the TAIP protocol on the server end. I tried the port 5031 and it shows in the log a HEX going to protocol taip but after that line it does not show a decoded line like it does for the CalAmp units.

If it is changing how the GNX6 formats the data I'll need to contact the manufacturer to get more specifics on how to do that.

Jason C5 years ago

I currently have the .cfg file for the units set to:
REPORT_FORMAT=0 //ascii
REPORT_COLUMNS=28.3.4.7.8.10.11.13.17.23.36.130.82.46.41.61.56.70.93.74.75.77.89.90.112.113.99;
Which produces data like this:
SerialNumber,Latitude,Longitude,UniqueID,LocAge(mins),ReasonCode,Ign,Speed(km/h),VehHdg,Odometer(km),EventTime(GMT),ExternalTemp,IBID,SVFix,PwrSupply(mV),LI(mV),BusStatus,BusOdometer(km),DerivedOdometer(km),CoolantTemp(C),VehicleSpeed(km/h),EngineSpeed(rpm),FuelConsumed(L),DeltaFuelConsumed(L),EngTotalHours,EngIdleHours,FuelLevel0

I have documentation that shows me what each of those numbers in REPORT_COLUMNS is as well as other ones I could use.

Anton Tananaev5 years ago

So, which protocol is working?

Jason C5 years ago

If I send to port 5013 I see just 3 lines in the logs:

INFO: [ae7c97d5] connected
INFO: [ae7c97d5: taip < IP] HEX: (hex data)
INFO: [ae7c97d5] disconnected

no errors are shown but no info is shown afterwards with decoded data and it isn't showing anything based off what my unique ID should be

If I send to port 5148 I see in logs:

INFO: [da04fb74] connected
INFO: [da04fb74: genx < IP] HEX: (hex data)
WARN: Unknown device - SerialNumber (IP)
WARN: error - Unparseable date: "Latitude" = ParseException....
WARN: error - Unparseable date: "51.66032" - ParseException...
INFO : [da04fb74] disconnected

So the GenX protocol seems to work at least in part but obviously with my device sending things in a different order (and having two rows of data) is where it gets stuck. I could likely get help from the manufacturer helping me configuring it so it sends it as traccar is expecting it but first I need to understand how Traccar is expecting that data.

Ideally the GENX protocol could see the header row and match accordingly that way (or let us set the report format in the config file if we can turn the header row off on the device so it doesn't send the same headers over and over). Maybe this is already a thing.

Anton Tananaev5 years ago

Without any samples or protocol documentation we won't be able to help you.

Jason C5 years ago

Thanks for your help, although I'm a bit confused, are you saying you do not know what format the GenX protocol built into Traccar expects to get the data? If not I'll dive in to your code and try and figure it out but I've never used Java before so it might take a bit. If I write docs can I send them to you to go on the website for the next person?

As for a sample, the HEX data my unit is sending is:

53657269616c4e756d6265722c4c617469747564652c4c6f6e6769747564652c556e6971756549442c4c6f63416765286d696e73292c526561736f6e436f64652c49676e2c5370656564286b6d2f68292c5665684864672c4f646f6d65746572286b6d292c4576656e7454696d6528474d54292c45787465726e616c54656d702c494249442c53564669782c507772537570706c79286d56292c4c49286d56292c4275735374617475732c4275734f646f6d65746572286b6d292c446572697665644f646f6d65746572286b6d292c436f6f6c616e7454656d702843292c56656869636c655370656564286b6d2f68292c456e67696e6553706565642872706d292c4675656c436f6e73756d6564284c292c44656c74614675656c436f6e73756d6564284c292c456e67546f74616c486f7572732c456e6749646c65486f7572732c4675656c4c6576656c300a3030303034313030383233352c35312e36363033322c2d3131322e37363432372c39302c312c33312c4f46462c302c302c302e30302c313536363932313938332c303a303a303a302c302c302c31313934392c333936352c4e2c302e3030302c302e3030302c2d39352e302c2d312e302c302c302e303030302c302e303030302c302e30322c302e30312c300a
Anton Tananaev5 years ago

It looks similar to GENX protocol, but I don't think it would work as it is.