we are stuck on sending GPRS commands

Ahmad Makki8 months ago

we are sending a command getgps protocol name teltonika but we received a response in api {id: 0, attributes: {data: " getgps"}, deviceId: 488, type: "custom", textChannel: false,…} this,
and show logs on server this "id: 864636062478215, command type: custom sent" , not received command reply,
I need your guidance on how we could receive response from server and log into logs

Anton Tananaev8 months ago

Have you checked HEX data in the log to see if the command was sent and response received?

Cristian8 months ago

are you sending the command with spaces before?

I ask this because I see the spaces, in teltonika when you send an sms and the device has no user or password you must add 2 spaces before, but when you send it from Traccar it is not necessary.

Ahmad Makki8 months ago

@anton i just received this on server logs

2024-05-07 05:04:57  INFO: [T8f7dba43] id: 354018114033321, command type: custom sent
2024-05-07 05:04:57  INFO: [T8f7dba43: teltonika > 116.71.170.173] 00000000000000120c01050000000a20206765746770730d0a010000fb9a
Ahmad Makki8 months ago

@cristian can you please tell me how you send a GPRS command trough traccar FrontEnd to device,

Ahmad Makki8 months ago

@cristian in further elaboration to my question:
I'm sending the commands to device from live track -> device -> Send command option.
We've activated the notifications to get the reply displayed somewhere. Problem is in either case, with username or password or with , device isn't responding to us or we're unable to see/fetch the reply of device.

Anton Tananaev8 months ago

If device is not response, you should probably contact your device vendor for support.

Cristian8 months ago

Ahmad Makki I send the command getgps to the teltonika devices from the popup and everything works, this is the response from the device:

Ingrid - MG ZX command result received: GPS:1 Sat:16 Lat:****** Long:****** Alt:118 Speed:0 Dir:133 Date: 2024/5/6 Time: 16:42:2 at 2024-05-06 12:41:21
(The coordinates have been edited)

Have you tried sending a text message from a mobile phone to check what Anton says, that the device is not responding.

Ahmad Makki7 months ago

@Cristian can you please tell me your flow of sending commands using popup,
because i received response from a mobile phone, but not on a popup(traccar portal),
and how you are marking the response in database???

Cristian7 months ago

https://ibb.co/9hBjJQ8
I do it like this. I have never checked anything in the database regarding custom commands.

Ahmad Makki7 months ago

https://ibb.co/Y3RW9js
@Cristian i also send commands like this, but i don't received any response,
if i mistake some please identify

Anton Tananaev7 months ago

It seems like you have some extra spaces before the command.

Cristian7 months ago

I sent the command with spaces before and the response was this
unknown command or invalid format

Is the gps device reporting directly to your server or are you receiving the data from another server running an instance of Traccar?

Ahmad Makki7 months ago

@Cristian yeah we are deployed a traccar frontend and Backend separately deployed on server

Ahmad Makki7 months ago

@Cristian still waiting your response