feature request : Opening to the world

binooetomo8 years ago

Dear Developer.

  1. Hex Data in forward.url
    From response at : https://www.traccar.org/forums/topic/are-there-server-hooks/#post-1934
    Could you please add :
    a. alldata : this is all decoded data, OR
    b. hexdata : this is a received hex data, so I can forward --> <entry key='forward.url'>http://example.com:8080/fromtraccar?deviceId={deviceId}&protocol={protocol}&hex={hexData}.

  2. command API :
    I thing it'll more flexible if the REST API can receive 'deviceId' and 'encodedCommand'.
    traccar only query the database for ip address of deviceId and send encodedCommand
    other developer (coming with diferrent programming/scripting language) will then learn his/her device protocol from it's documentation.

ps : I'm a python script-kiddies, I know how to convert from hex to strings and viseversa, but have no knowledge in Java.

Sincerely
-bino-

Anton Tananaev8 years ago
  1. Most decoded data (latitude, longitude, speed etc) is already available as parameters.

  2. There is a way to send raw command. The type is called "custom" and you need to provide "raw" parameter.

binooetomo8 years ago

Dear Mr.Tananaev.
I really Appreciate your response.

  1. I read https://github.com/tananaev/traccar/blob/master/src/org/traccar/WebDataHandler.java#L99

You right, most decoded data is there.
But some device have more data, i.e : ADC, SOS , etc etc.

  1. I will take a deeper look on the API part source code.

Sincerely
-bino-

Anton Tananaev8 years ago
  1. Those are part of "attributes" field.
binooetomo8 years ago

Dear Mr.Tananaev.

Thankyou for your help.
But I really don't know what you mean.
No, it's not your fault. It's because I have no Java knowledge.

I'll ask my Java friend here in my area.

Sincerely
-bino-

Anton Tananaev8 years ago

I mean that "ADC, SOS, etc etc" are part of {attributes} parameter.

binooetomo8 years ago

Dear Sir.

Could you please give me example on how to use it ?

Sincerely
-bino-

Anton Tananaev8 years ago

Something like this:

<entry key='forward.enable'>true</entry>
<entry key='forward.url'>http://example.com:8080/?id={uniqueId}&amp;attributes={attributes}</entry>
binooetomo8 years ago

Done !!!

You are the man.

Sincerely
-bino-