An IoT Kickstart is a Scaleway instance providing an application for a typical IoT use case.
Scaleway will spawn, install and configure the instance for you with the required software so messages flowing through your IoT Hub end up in the application.
The data visualisation Kickstart provides a metric storage and visualisation application.
It will setup and configure the following software:
First go to the Kickstarts page in your Scaleway console and click the
+ button, then :
Telegraf will subscribe to all topics on your IoT Hub and expect messages containing a single numeric value in their payload.
mosquitto_pub -h iot.fr-par.scw.cloud -i <device id> -t home/bedroom/temperature -m 19.4
These values will be stored in a measurement named
iot within the InfluxDB
scwiot database. A
topic tag will be attached to the value, this tag will contain the topic the message was published to.
scwiot> select * from iot name: iot time topic value ---- ----- ----- 1567159540648140455 home/bedroom/temperature 19.4
Then, you can go to your Kickstart dashboard (the link is on the Kickstart list page), this will open Grafana interface. Credentials are
admin as the login and the password is the one you provided when creating the Kickstart.
An initial Grafana dashboard containing a graph panel has been pre-configured for you. This panel will show a chart on which there is a line per topic for which you sent a message to the IoT Hub and containing compatible data (a single numeric value). You may want, on top right of the screen, to select the time span that suits the data you’re looking at.
That’s it ! You’re done creating and using the Kickstart. Next we’ll see how to tweak Kickstart configuration to betted fit your needs.
Now you’ve seen how to use IoT data visualization Kickstart, here is how to get further.
Data ingestion is performed by Telegraf, it’s configuration file is located at
/etc/telegraf/telegraf.conf. Interresting values are in
topics: this is the list of topics Telegraf should subscribe to on your IoT Hub. Default is the
#wildcard which means “all topics”. More information about MQTT topics here.
data_type: this is the format of the expected message payload. Default is
floatwhich means Telegraf expects a single numeric value which can be a floating value. Telegraf can handle more complex message payloads, more information about data types here.
name_override: this directive tells Telegraf to store the metrics in the
iotmeasurement in InfluxDB. When using different
data_formatsettings, this information may be received in the message payload.
You can learn more about Telegraf settings on official website.
After changing settings, you should restart Telegraf daemon with the following command:
systemctl restart telegraf
Data visualization is performed by Grafana.
You can set up multiple dashboards and charts to suit your needs, please see this guide for help.
Learn more about Scaleway IoT Hub, discover how to add Devices to the hub, check the IoT Hub metrics or learn how to interact with other parts of the Scaleway Elements ecosystem by setting up IoT Hub Routes.