15

Question: What is the underlining design behind an “Embedded Agent” in relationship to low powered Internet of Things (IoT) edge devices?

Some of the IoT cloud service vendors keep referring to installing an embedded agent on the sensor based edge devices. It appears to be a proprietary piece of software which vendors install on each device connecting to the cloud. Below are two images of software stacks with references to Agent. A portion of the of software stack reside in the microcontroller.

IOT Agent - 1

IOT Agent

Also here is very broad explanation Thingworx blog

An agent is an embedded program that runs on or near an IoT device and reports the status of some asset or environment. There is always some agent present in an IoT application. Typically the agent reads the status from sensors or local connectivity to an asset, applies some rules or logic about how often the sender has to aggregate the information, and then sends the information over a long-haul communications network to the server. This process can operate in reverse as well.

It is my assumption this agent consist of connectivity information such as IP address, server name, SSID type information to aid connectivity. Does these Embedded Agents have other functionality beyond providing connectivity?

References:

1
  • Please, could you give the reference of the IoT architecture (2nd picture) ? Thanks
    – BiG_TooTh
    Aug 21, 2017 at 14:05

1 Answer 1

13

Generally speaking, an agent is a 'bi-directional' piece of software; i.e., it reads parameters from the device and the communicates the same to cloud or even a gateway. More often than not, an OEM will control the libraries for development of the software to control the parameters of the device. Whereas, the OEM may choose any of the popular communication protocols (MQTT, HTTP, etc.) to publish the values read. Typically, integration of these two is the space where a System Integrator comes in.

For example, an agent could be running on a Windows desktop to read the rpm of the fan every 5 seconds. This value is then communicated over to a cloud platform over an agreed protocol.

Sample code from Paho MQTT (Python) web site:

mqttc.connect("iot.eclipse.org")
mqttc.loop_start()

while True:
    temperature = sensor.blocking_read()
    mqttc.publish("paho/temperature", temperature)

The above snippet is roughly an agent because there is the 'from device' part in the form of the function sensor.blocking_read() and the 'to cloud' part in the form of a mqttc.publish().

Advanced agents will have mechanisms to handle offline storage, TLS support for communication towards cloud, respond to any updates from cloud (including reboots, if needed) gracefully, etc. And, in the specific case of this question, the agent will handle power constraints too. For example, respond to device level triggers such as sleep, wake-up, etc.

2
  • That's an interesting definition of bi-directional. I would not call a sensor bi-directional if it only reads and reports. I'd say it has to be able to receive at least one sort of message to be bi-directional. Reading the fan speed is its intrinsic justification for being, not a communication.
    – Helmar
    Dec 7, 2016 at 7:05
  • I don't understand your use of “bi-directional” here. An agent is software on the device that operates on behalf of the server (in this context). It doesn't necessarily communicate with the server (although that's a very common use case). For example It could be there solely to set configuration parameters, or to download updates. Feb 1, 2017 at 22:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.