Server communication with GPS Watch

Atul8 years ago

Hello,

I am trying to understand how does server communicates with GPS watches (Chinese Q50 or similar devices) for setting up some configuration, like SOS number or timezone. Is this possible with Traccar Server? Also there are lot of different features like Watch removal alert, remote power off, Sleep monitor are available with such gps devices, can this be used in Traccar Server? I do get location information and which works perfectly well, but not sure of others.

Can someone help with this?

Thanks,
AB

Anton Tananaev8 years ago

I'm assuming it's using Watch protocol. It supports a number of commands: WatchProtocol.java.

Atul8 years ago

Yes, thats the one. Thanks much Anton.

I have tried to send the cmd using Web and checked the log for debug info, I get something below, but no response back:

2016-11-19 15:46:32  INFO: [5DFCB24F] id: 6105050887, command type: sosNumber sent
2016-11-19 15:46:32 DEBUG: [5DFCB24F: 5093 > IPAddresshere] HEX: 5b43532a363130353035303838372a303031322a534f537b696e6465787d2c7b70686f6e657d5d

When I converted HEX it says

[CS*6105050887*0012*SOS{index},{phone}]

How can I pass a value to this from Web as well in API? Sorry this could be very basic question, but I am unable to find much info on this.

*** Editing the post to add more info ***

I tried with RebootDevice Cmd, I get this

5b43532a363130353035303838372a303030352a52455345545d ==> [CS*6105050887*0005*RESET]

and response as

78780512010926bd0d0a ==> xx8 ÅûѲì‡ð4Á”'1Ï ž<

I remember when I tried the first time, I did get a good response & not the cryptic like above

An example of API would be of great help. Thanks much again.

Thanks,
AB

Atul8 years ago

I have also tried with "Custom" command like [CS61050508870009*UPLOAD,10] - still no success.

I must be missing something basic, could you please suggest?

Thanks,
AB

Anton Tananaev8 years ago

It seems like your device is using GT06 protocol, and not Watch.

Atul8 years ago

No, its a watch protocol. I can see that on Traccar UI under "State" for selected device, protocol is set to "Watch".

Can you please share a example of how can I set SOS number using API, I can give a try for that? With current API, I don't find an option to set the number [Even from UI as well]

Thanks,
AB

Anton Tananaev8 years ago

Well, the response example that you provided is from GT06 protocol.

I don't have an example, but you can take a look at what parameters are required here:

https://github.com/tananaev/traccar/blob/master/src/org/traccar/protocol/WatchProtocolEncoder.java

Atul8 years ago

Oh Sorry, my bad ... I have GT06 devices as well, so I must have copied GT06 response as that's what it was showing immediately on the next line I believe.

I'll look at the code you provided and update.

Thanks,
AB

Tamerlan8 years ago

Hi, I have a watch and a TCP sever running on a Windows 2012 server. I want to get GPS Coordinates, but the device keeps sending data me like this: [3G*6907041365*0009*LK,0,0,95]. I'm sending back [3G*6907041365*0002*LK] but I still cannot get GPS information. Can you help me pelase?

Anton Tananaev8 years ago

@Tamerlan, it doesn't sound like you question is related to Traccar in any way.

Tamerlan8 years ago

But I have a watch and I'm asking this question according to your documentation about watches. There is also related code in your "WatchProtocolDecoder" class.

Anton Tananaev8 years ago

You are asking question in Traccar server forum. Please explain how is your question related to Traccar server? If you want to ask a general device question, you should create a topic in the devices forum:

https://www.traccar.org/forums/forum/devices/

iorgu1237 years ago

Hi,
I have a small issue with the Chinese Q50 watch, it's connecting to traccar, sending coordinates, speed, altitude, but also send an alarm: Overspeed although the watch it's on desk, and obviously the speed it's 0.
I've tried also to disable events in config file or in attributes, put on device speedLimit = 100, etc., no change, on every update still receive overspeed.
This is the reading:

[3G*6105689122*00C2*UD,100717,100259,V,50.934960,N, 2.6635900,W,0.00,0.0,0.0,0,95,100,0,0,00000008,6,255,234,10,30030,32978,141,21428,22144,136,21428,22499,127,30030,22978,126,21428,12144,122,21428,12499,118,0,21.4]

Thank you

Anton Tananaev7 years ago

Here is the alarms field from your message:

00000008

I guess alarm types might be different between devices. I would need protocol documentation to check.

rdentandt7 years ago

Hi Anton

I have the exact same issue. I don't have the document but what I have discovered is that the alarm is generated when the watch is not worn. This alarm is a function of the watch to notify that the watch was removed from the arm.

Please can you update the Alarm description for this alarm to notify Watch removed....can we possibly do it ourselves? Please note that I am not a developer at all.

The alarm is definitely for "Watch Removed"

Thank You