Trouble Code notification not working?

John Smith5 years ago

Hello, I can't seem to get the Trouble Code notification working. I can see it in the logs, but have searched and not found the correct settings. Under Notifications in the webservice page there doesn't seem to be one for OBD Trouble Code or CEL. Have tried Maintenance Required. Do I need to create a custom notification perhaps through Command Result? If so, what would the Attributes be. Here is an example hex message from a Coban 306A device:

696d65693axxxxxxxxxxxxxxxxxxxxxxxxxxxxxx2c4f42442c3139303932303030353534302c36383137382c302e30302c
3136372e31342c323238302c3132322c35392e3631252c38352c32342e3331252c323936392c31332e39332c2c2c2c3b

You can see the message is garbled, I used to get the actual p0000 code when using SMS, so I think there is something off with the HEX alignment, but it does say OBD in the beginning and that at least lets me know the car has a trouble code. However, there is no notification for it. My other notifications are working.

Also, a minor question about Notifications.. If I set one to "All Devices", that means I don't have to click the checkmark for that notification on each individual device, correct? Or do I?

Thanks very much in advance

Anton Tananaev5 years ago

It's garbled because you've added a space in your HEX.

John Smith5 years ago

Thanks Anton. I haven't added anything. This is how they all look. But, thank you. I will troubleshoot the location to see if I can correct it. What could be causing that?

John Smith5 years ago

I found it. There is a space added from copying two lines from the terminal. Here is the full message:

imei:,OBD,190920005540,68178,0.00,167.14,2280,122,59.61%,85,24.31%,2969,13.93,,,,;

I think the CEL code is p2280.

Anton Tananaev5 years ago

It should be decoded just fine, but we don't have any notifications for those codes.

John Smith5 years ago

Okay, thanks. Any plans to add notifications for OBD Trouble Codes? It's the second most important reason I use traccar beside theft prevention, to monitor for engine problems.

Anton Tananaev5 years ago

No plans yet, but you can always use computed attributes to generate an alarm.

John Smith5 years ago

Okay, great. That was what I was hoping. Is there documentation on the Computer Attributes? Or an example setup?

I already created one, with a name 'ODB' but not sure what the value should be.

John Smith5 years ago

Interesting, I am recieving DTC 'Diagnostic Trouble Codes' from another device. The messsage comes in with a different prefix DTC instead of OBD, and has the p0000 code:

imei:,DTC,190920031253,,F,191253.000,A,4732.6546,N,12223.2115,W,0.02,299.55,,1,,,P0420,;

So, that is good. It is reported to the webservice as a 'Fault' event. I wonder which notification category this falls under? 'Alarm' perhaps?

Well, I will work on creating the Computed Attributes for the 'OBD' messages. I think these are 'pre-fault' messages warning of potential DTCs, which will also be good to have a notification for.

For others, here is the documentation link:
Computed Attributes - Documentation - Traccar
https://www.traccar.org/documentation/computed-attributes/