Sensors values from last message

To get sensors value from the last message, use the command unit/calc_last_message:

svc=unit/calc_last_message&params={"unitId":<long>,
				   "sensors":[<long>],
				   "flags":<uint>}

Parameters

Name Description
unitId unit ID
sensors array of sensors IDs (optional parameter, if not specified or empty - return values of all sensors)
flags flags (optional): if 1, then calculate sensor value by last valid param value

Response

{
	<text>:<double|text>,	/* sensor ID: sensor value */
	...
}
Follow us on Facebook Gurtam Wialon Twitter Gurtam Wialon info@gurtam.com   |   Copyright © 2002-2022 Gurtam