We provide a variety of ready-to-use classes depending on the type of input:

  • BooleanMonitor → To track boolean values.
  • StringMonitor → To track one or more string values.
  • IntervalMonitor → To track if a value is inside a given interval or a certain threshold (below, equal or above).
  • ZoneMonitor → Signal if a point is inside a given geographic zone.

Do you happen to have a use case that is not covered by our ready-to-use classes ? Don’t worry, just contact us at contact@heex.io and we will work with you to provide a custom class.

Monitor Build

To integrate monitors and recorders in your project you have to build with Heex libraries. See HeexSDK integration for details.

Monitor main APIs

BaseMonitor(uuid, serverIp, serverPort)

  • Uuid : Monitor unique ID, can be retrieved on the Heex Cloud
  • serverIp : IP address to contact Heex Agents
  • serverPort : Port to contact Heex Agents

updateValue(inputValue) : Send to Heex Agents the value of the dataflow monitored

updateValue(inputValue, timestamp) : Send to Heex Agents the value of the dataflow monitored with the timestamp in the form of a string.

Monitor implementation

Let’s do an example with IntervalMonitor, but all the four other monitors behave the same exact way. The IntervalMonitor can monitor a speed dataflow in a range.

First thing you need to do is define which of the above mentionned monitors provided you need to use. The web platform has generated a blueprint code for your monitor and we advise you to use it as a starting point.

You have to include IntervalMonitor.h

Then, instantiation is done calling the constructor API :

IntervalMonitor myMonitor("D-1a7453c0-ef64-4290-a9c3-5019e8bb43fa", "127.0.0.1", 4242);
myMonitor.awaitReady();

Using the awaitReady() allows to wait until your monitor establish a connection with the Heex Agents.

To allow the monitor to detect events, you need call as often as possible the UpdateValue() API with the value of the checked signal. You need to send the speed value to the monitor as often as possible. It could be at regular time intervals or when the speed changes. This is highly dependant to your edge system.

myMonitor.updateValue(speed);

💡 Tip: 🎉 CONGRATULATIONS!

This is it!

You don’t need to care about the bounds set in the Heex Cloud when specifying the trigger. All the checking will occur behind the scene and the Heex Agents will take care of detecting when matching conditions are met to trigger events.

ℹ️ Info: timestamp

It is recommended to call UpdateValue() API method, giving as second argument the exact timestamp of your signal value formatted in ISO 8601-1:2019. Otherwise the current system time is applied by default to your signal value.

For more information go to Timestamp Formatting page.

Monitor Samples:

You can check them here samples.