Skip to content

The state object

The gateway keeps its own state and that of its sensors in a single object, delivered by stateupdate and kept current by statepatch.

{
"nodes": {},
"deviceInfo": {},
"phantomSync": [],
"basicconfig": {}
}
Property Contains
nodes Every sensor the gateway is seeing, or has seen, keyed by serial number
deviceInfo Running state of the gateway itself
phantomSync Array of PHANTOM® Sync groups
basicconfig Gateway configuration

Keyed by sensor serial number. A vibration sensor looks like this:

{
"189281421": {
"lastseqchange": 1679600932675,
"lastseen": 1679600932676,
"phantomCode": 189281421,
"type": 3,
"version": 183,
"rssi": -50,
"advdatav2": {
"battery": 3.28,
"batteryType": 1,
"temperature": 30.75,
"updateInterval": 3600,
"txPower": 8,
"minRMSFreq": 14,
"maxRMSFreq": 1000,
"rms": [0.52, 0.24, 0.19],
"range": 8,
"recordingSettings": 0,
"seq": 1
}
}
}
Property Meaning
phantomCode Sensor serial number
type Sensor type — see the table below
version Firmware version
rssi Signal strength
lastseen Milliseconds since 1970, gateway clock, when the sensor was last seen by the gateway’s Bluetooth radio
lastseqchange Milliseconds since 1970, gateway clock, when the sensor’s seq last changed — i.e. when the gateway last got new data from it
advdatav2 The sensor’s advertised measurements and settings
isPaired, isFavorite, isDFUmode, hasupdate Sensor flags
lastcollection, lastManualCollection When a waveform was last collected

The type property in nodes:

Code Sensor
3 Vibration triaxial, high range
5 Vibration triaxial, low range
6 Vibration triaxial, low range, different internal accelerometer (includes Gen4)
7 All in one
10 Thermal camera
14 PHANTOM® Max, high range
15 PHANTOM® Max, low range
20 Thermocouple temperature
21 Thermocouple temperature v2
25 Infrared temperature
26 4-20 mA general purpose
27 0-10 V general purpose
30 Current
31 Dry contacts
32 Current v2
40 Speed (RPM)
60 -2 V to 2 V high speed

The batteryType property inside advdatav2:

Code Battery
1 1/6D (3.6 V)
2 AAA (3.0 V)
3 CR2032 (3.0 V)
4 CR2477 (3.0 V)
6 D size, PHANTOM® Max (3.6 V)

Running information about the gateway itself:

Property Meaning
serialNumber Gateway serial number
version Main application firmware version
btVersion Firmware version of the Bluetooth controller
osversion Operating system version
btTemperature Bluetooth controller temperature, °C
cpuTemperature Main CPU temperature, °C
netinfaces Active network interfaces and their settings
wifimac MAC address of the Wi-Fi interface
ethmac MAC address of the Ethernet interface
apmac MAC address of the Wi-Fi interface in access point mode
uptime Gateway uptime in minutes
totalmem / freemem Total and free RAM