setdevice

Send a new setting to a device.

Command's fields description:

  • txtUser1 field is the “username” of MyWakes account.

  • txtUser2 field is the “password” of MyWakes account.

  • txtCommand field contains the command: “setdevice”.

  • txtFormat optional field specifies txtParameters and response formats. more info.

  • txtParameter field contains a structure like this:

<?xml version="1.0" encoding="utf-8" ?> 
<setdevice>
	<consumer>44</consumer>
	<imei>123456789012345</imei>
	<sender>+393351234567</sender>
	<phone>+393357654321</phone>
	<psw>0000</psw>
	<cmd>apn</cmd>
	<parameters>
		<par>apn.carrier.com</par>
	</parameters>
	<time>20101025183000</time> 
</setdevice>
{
  "setdevice": {
    "consumer": "44",
    "imei": "123456789012345",
    "sender": "+393351234567",
    "phone": "+393357654321",
    "psw": "0000",
    "cmd": "apn",
    "parameters": { "par": "apn.carrier.com" },
    "time": "20101025183000"
  }
}

 

Where

  • <consumer> mandatory. It is the consumer's ID.

  • <imei> mandatory. It is the consumer's IMEI code.

  • <sender> optional. Can contain the sender telephone number. If used, the confirmation message from the device will be sent to this number.

  • <phone> mandatory. Telephone number of the SIM into the device.

  • <psw> mandatory. Device's password.

  • <cmd> mandatory.The command to execute. Depending of the command and the device it will need more or less parameters. Here is the list of existing commands per device and their parameters.

  • <parameters> a collection containing the command's related parameters.

    • <par> command's parameter. This tag is repeated for each parameter required for the specific command..

  • <time> mandatory, date and time in UTC. The accepted format is “yyyyMMddhhmmss”.

  • txtProvider field must contain the application calling ID and generated characters.

  • txtSignature field must contain the signature based on the string made of “Command Name” + “consumer” + “time” + “generated character to 32”.

Looking at the previous example, the string on which calculate the check will be:
“setdeviceI123420101025183000xxxx”


Therefore the txtProvider field will be:
“76a865d4-fab8-51cd-ba78-2da325f6955axxxx”

Command's list table reference

Command Parameters Devices
apn
sets APN
APN address for GPRS connection. For Daggy sets also MyWakes service IP address. Daggy
Angelo
APN username (not for Daggy)
Password APN (not for Daggy)
interval
sets interval
If set to 0 (zero) disables this function. Otherwise it sets the device sampling in minutes accepting only 5, 10, 30 or 60 minutes. Daggy
Angelo
Sets the device to send many grouped sampling (not for Daggy).
server
configure MyWakes services
Connection mode to My Wakes platform, can be: 0 (zero) not connected, 1 (one) sets Server IP and connects to My Wakes platform Angelo
gpson
turns on GPS

 

Daggy
gpsoff
turns off GPS

 

Daggy
geo
set up a virtual fence
Virtual fence latitude in degree and decimal degrees. If the position is in the southern hemisphere the value will be negative so it will be preceded by a minus sign. If virtual fence is a circle this value is the latitude of the center of the circle, otherwise the top left of the area. Daggy
Angelo
Virtual fence longitude in degree and decimal degrees. If the position is in the western hemisphere the value will be negative so it will be preceded by a minus sign. If virtual fence is a circle this value is the latitude of the center of the circle, otherwise the top left of the area.
Virtual fence latitude in degree and decimal degrees. If the position is in the southern hemisphere the value will be negative so it will be preceded by a minus sign. It is the latitude of the bottom right of the area. If the virtual fence is a circle this value represents the radius in meters.
Virtual fence longitude in degree and decimal degrees. If the position is in the western hemisphere the value will be negative so it will be preceded by a minus sign. It is the latitude of the bottom right of the area. This value exists only if the virtual fence is rectangular
centerphone
central telephone number
Phone number to sent SMS and fences alarms to Angelo
phonebook
telephone numbers
First telephone number Angelo
Second telephone number
Third telephone number
alarms
set alarm's actions
Action Id for SOS alarm Angelo
Action Id for GEO fence alarm

Returns a structure like the following:

<?xml version="1.0" encoding="utf-8" ?> 
<furesult> 
	<message><![CDATA[ OK ]]></message>
	<smsres>OK</smsres>
	<sms>25</sms>
</furesult>
{
  "furesult": {
    "message": " OK ",
    "smsres": "OK",
    "sms": "25"
  }
}

 

Where

  • <message> contains OK or Error description
  • <smsres> the execution result of the command. In case of success the message will be “OK” otherwise it will be the error
  • <sms> user's number of SMS left

If MyWakes server returns an error, the format of this answer is described in the error section.

Terms Of Use | Privacy Statement | Company info
  • © Cedac Sistemi srl
  • Head office: Via Toscana, 3 40035 Castiglione dei Pepoli (Italy) Tel.: +39 0534-93811 Fax: +39 0534-93899
  • Branch office: Via del Lavoro, 47 40033 Casalecchio di Reno (Italy)
  • Branch office: Via Parini, 1 40033 Casalecchio di Reno (Italy)
  • Share capital Euro 26,000.00 - Company Register of Bologna / VAT no / fiscal code 01695261204