Command issue on KHD protocol

Ahmad Makki6 months ago

Dear team,I am facing some issues sending a command on the KHD protocol. I am sending this command: AS9876*269#C# and received the following error: "Odd number of characters. - DecoderException (... < DataConverter:29 < BaseProtocol:110 < DeviceSession:66 < ...)". When I decoded this, I found it's a format issue. Can you please tell me the correct format or point out where I am mistaken?

Thank you.

Anton Tananaev6 months ago

It's probably expecting HEX format.

Ahmad Makki6 months ago

@Anton, I converted the command AS9876*269C#00 to hex as 4153393837362A32363943233030 and sent it to the devices via the frontend. In the database, I received the response {"result":"2"}.

Anton Tananaev6 months ago

OK, great.

Ahmad Makki6 months ago

"Anton, I have not received the response to this command. Instead, I always receive {"result":"2"} in the database and reports. Can you help me understand why I am not receiving the correct response?"

Anton Tananaev6 months ago

Have you checked with your device vendor?

Ahmad Makki6 months ago

Yes, I have checked and tested this on other portals as well, and everything is fine. However, in Tracacr, command responses are not being received

Anton Tananaev6 months ago

What is the expected response? Have you checked the logs to see if the device is actually sending it?

Ahmad Makki6 months ago

@Anton, the some 1 or2 Teltonika devices are sending a response with the following data:

{"result":"Data Link: 1 GPRS: 1 Phone: 0 SIM: 0 OP: 42003 Signal: 5 NewSMS: 0 Roaming: 0 SMSFull: 0 LAC: 4338 Cell ID: 43013 NetType: 1 FwUpd:-65536"}

However, the KHD protocol is only showing this:

 {"result":"2"}
Anton Tananaev6 months ago

Why would you compare Teltonika with KHD? Those are completely different protocols and almost definitely different response format.

Ahmad Makki6 months ago

I am not comparing Teltonika and KHD here, just giving an example. KHD has not provided any response.