IN THIS ARTICLE

Radio Status API Integration

Incorrect email!

The article was successfully sent to the email

The API version must match the installed TRBOnet build.
API packages for release builds are available in the Downloads section on the website or this article.
If you are running a non-release or different build, contact support@trbonet.com and provide the exact TRBOnet build number.

6.3 and Newer

Use the TRBOnet API to load device objects and receive status events.

Refer to the API example:
"How to: Load objects (radios, beacons, map objects, etc.) and receive events from Server."

Online/Offline status is provided through the same event stream.
To check state, use the Device class property:
Device.IsActive

Prior to 6.3

The same functionality is provided via device state change events.

Example (C#): Receiving Radio State Updates
client.DeviceStateChanged += new EventHandler<Objects.Event_args.DeviceStateChangedEventArgs>(client_DeviceStateChanged);

void client_DeviceStateChanged(object sender, Objects.Event_args.DeviceStateChangedEventArgs e)
{
    Device device = m_devices.Find(d => d.ID == e.DeviceId);
    if (device == null) return;

    device.BeginUpdate();
    try
    {
        device.DeviceState = e.State;
        device.ActiveMasterId = e.ActiveMasterId;
    }
    finally
    {
        device.EndUpdate();
    }
}

Helpful?
We're glad this article helped.

Thanks for letting us know. What went wrong?