4 Implementation and Evaluation
4.1 Materials
The Gateway is a Raspberry Pi 3 which is a small size board with 1 GB of Ram and
1.2 GHz processor [12]. As an Operating System for the gateway, we use Raspbian the
pre-compiled Debian OS which is especially optimized for the Raspberry Pi.
We install the InfluxDB database which is an open-source Time Series Database
written in Go. At its core is a custom-built storage engine called the Time-Structured
Merge (TSM) Tree, which is optimized for time-series data. InfluxDB supports SQLlike query languages named InfluxQL and has the advantage of easy scale-out. It
provides support for mathematical and statistical functions across time ranges, also it is
developed for custom monitoring, metrics collection and real-time analytics [13].
We use the mosquito implementation as a messages’ broker and Node JS clients as
subscribers [14].
The messages exchange is ensured by MQ Telemetry Transport (MQTT) protocol
[15]. MQTT protocol is a lightweight application layer protocol designed for resourceconstrained devices. It runs over TCP/IP, or over other network protocols that provide
ordered, lossless and bidirectional connections. It uses the publish/subscribe messaging
system combined with the concept of topics to provide one-to-many message distribution. The headers of MQTT messages are small and the connection set up does not
require a synchronous handshake which could support a range of 10 to 100 messages
per second.
MQTT applies topic-based filtering of messages with a topic being part of each
published message. The broker uses the topics to determine whether a subscribing
client should receive the message or not. Clients can subscribe to as many topics as
they are interested in.
4.2 Evaluation and Results
The evaluation of the presented solution was done from a resource use point of view to
analyze whether the self-adaptative algorithm would result in a better performance
parameter. The parameters that were taken into account were memory use for stored
data and the CPU use of the gateway.
To prove the benefits of the customized use of the gateway, we consider a scenario
of controlling the temperature data of one patient with two different scenarios. The first
is called fixed case, it is the standard case in which the data are collected with a unique
interval of time. In the second case, the interval of data collection changes depending
on the patient’s score calculation.
In Fig. 4, we illustrate a result of the self-adaptivity configuration. We support 3
levels of data storage frequency depending on the corresponding score. The green
signal presents the temperature measurements of a patient. The frequency of saving the
sensed data changes when successful augmentation of temperature value is detected.
The second signal which does not respect the self-adaptative algorithm contains
unnecessary information for the first seven hour and before the increase of patient’s
temperature.
24
I. Ben Ida et al.
4.1 Materials
The Gateway is a Raspberry Pi 3 which is a small size board with 1 GB of Ram and
1.2 GHz processor [12]. As an Operating System for the gateway, we use Raspbian the
pre-compiled Debian OS which is especially optimized for the Raspberry Pi.
We install the InfluxDB database which is an open-source Time Series Database
written in Go. At its core is a custom-built storage engine called the Time-Structured
Merge (TSM) Tree, which is optimized for time-series data. InfluxDB supports SQLlike query languages named InfluxQL and has the advantage of easy scale-out. It
provides support for mathematical and statistical functions across time ranges, also it is
developed for custom monitoring, metrics collection and real-time analytics [13].
We use the mosquito implementation as a messages’ broker and Node JS clients as
subscribers [14].
The messages exchange is ensured by MQ Telemetry Transport (MQTT) protocol
[15]. MQTT protocol is a lightweight application layer protocol designed for resourceconstrained devices. It runs over TCP/IP, or over other network protocols that provide
ordered, lossless and bidirectional connections. It uses the publish/subscribe messaging
system combined with the concept of topics to provide one-to-many message distribution. The headers of MQTT messages are small and the connection set up does not
require a synchronous handshake which could support a range of 10 to 100 messages
per second.
MQTT applies topic-based filtering of messages with a topic being part of each
published message. The broker uses the topics to determine whether a subscribing
client should receive the message or not. Clients can subscribe to as many topics as
they are interested in.
4.2 Evaluation and Results
The evaluation of the presented solution was done from a resource use point of view to
analyze whether the self-adaptative algorithm would result in a better performance
parameter. The parameters that were taken into account were memory use for stored
data and the CPU use of the gateway.
To prove the benefits of the customized use of the gateway, we consider a scenario
of controlling the temperature data of one patient with two different scenarios. The first
is called fixed case, it is the standard case in which the data are collected with a unique
interval of time. In the second case, the interval of data collection changes depending
on the patient’s score calculation.
In Fig. 4, we illustrate a result of the self-adaptivity configuration. We support 3
levels of data storage frequency depending on the corresponding score. The green
signal presents the temperature measurements of a patient. The frequency of saving the
sensed data changes when successful augmentation of temperature value is detected.
The second signal which does not respect the self-adaptative algorithm contains
unnecessary information for the first seven hour and before the increase of patient’s
temperature.
24
I. Ben Ida et al.
