System Information API
It may be desireable to confirm the system information for the RockREMOTE device.
Devices can make a HTTP GET request on port 8080 to the local IP address of the RockREMOTE
(default 192.168.250.1
), as follows:
http://<rockremote ip>/api/public/system-information
The response will be a JSON formatted string containing the system information including (but not limited to):
Status
Errors
Firmware Versions
Hardware Configuration
Any response code other than 200 should be treated as disconnected.
System Information JSON structure
Break down of the System Information structure:
Field | Type | Description |
---|---|---|
status | Boolean | Indicates whether the API request was successful. Should always be true. |
errors | Array | An array of any errors that occurred. Should always be empty. |
info | Object | Contains more detailed information about the device. |
processor | String | A string that identifies the processor of the RockREMOTE. |
serial | String | The serial number (RockThreeWords) of the RockREMOTE. |
xferTmpDir | String | The path to the temporary directory which Cloudloop Device Manager (CDM) uses. |
fwMain | Object | The firmware version for the RockREMOTE. |
fwMCU | Object | The firmware version for the Power MCU. |
fwIridium | Object | The firmware version for the Iridium modem. |
appServerConfDir | String | The path to the directory where the device stores configuration files for the local application server. |
platform | Object | A collection of information about the device's platform. |
kernel | String | The kernel version on the device. |
uptime | Integer | The uptime of the device in seconds. |
hostname | String | The hostname of the device. |
hardwareRevision | String | The hardware revision of the device. |
temperature | Float | The temperature of the device in degrees Celsius. |
time | Integer | The current time on the device in Unix epoch seconds. |
load1 | Float | The load average for the 1-minute period. |
load5 | Float | The load average for the 5-minute period. |
load15 | Float | The load average for the 15-minute period. |
memoryTotal | String | The total amount of memory on the device in bytes. |
memoryFree | String | The amount of free memory on the device in bytes. |
storageTotal | String | The total amount of storage on the device in bytes. |
storageFree | String | The amount of free storage on the device in bytes. |
formFactor | String | The form factor of the device. Rugged or Standard. |
usbAvailable | Boolean | Whether or not the device has USB connectivity. Limited to bespoke units. |
isTimeTrustworthy | Boolean | It indicates the Time has been synced with either a NTP server or a GNSS fix. |
modems | Array | An array of objects that describe the modems on the device. |
interface | String | The interface of the modem. |
IMEI | String | The IMEI of the modem. |
serial | String | The serial number of the modem. |
ICCID | String | The SIM ICCID of the modem. |
manufacturer | String | The manufacturer of the modem. |
model | String | The model of the modem. |
signalLevel | Integer | The signal level of the modem in dBm. |
signalStrength | Integer | The signal strength of the modem in percent. |
networkInterfaces | Array | An array of objects that describe the network interfaces on the device. |
name | String | The name of the network interface. |
interface | String | The interface of the network interface. |
MAC address | Object | The MAC address of the network interface. |
up | Boolean | Whether or not the network interface is up. |
carrier | Boolean | Whether or not the network interface has a carrier. |
MTU | Integer | The MTU of the network interface. |
voltages | Object | A collection of voltage readings for the device. |
input | Float | The input voltage in volts. |
v12 | Float | The 12V rail voltage in volts. |
v5 | Float | The 5V rail voltage in volts. |
cap1 | Float | The voltage of super capacitor 1 in volts. |
cap2 | Float | The voltage of super capacitor 2 in volts. |
cap3 | Float | The voltage of super capacitor 3 in volts. |
cap4 | Float | The voltage of super capacitor 4 in volts. |
fwCellular | Object | The firmware version for the cellular modem on the device. |
Signal Information Example
This system information can be parsed to report firmware revisions, platform information, network interfaces and modems. The example python script below will request the system information from 192.168.250.1
(the default RockREMOTE IP). Parse the response and report the signal strengths of the Iridium and Cellular Modem.
import requests
# IP and port of the API
api_ip = '192.168.250.1'
api_port = 8080
# API endpoint to request information
api_url = f'http://{api_ip}:{api_port}/api/public/system-information'
# Make the request to the API
response = requests.get(api_url)
# Check if the request was successful
if response.status_code == 200:
# Parse the JSON response
data = response.json()
# Get the list of modems
modems = data['info']['modems']
# Report the interface and signal strength for each modem
for modem in modems:
interface = modem['interface']
signal_strength = modem['signalStrength']
print(f"Modem Interface: {interface}, Signal Strength: {signal_strength} %")
else:
print(f"Error: {response.status_code} - {response.reason}")