Currently, the Internet of Things (IoT) applied to cities has become one of the most important and useful technologies for Smart Cities, due to the numerous applications it offers.

In general terms, the use of the IoT technology is able to improve urban management in qualitative ways and in different areas, such as transport, energy efficiency, urban waste management or maintenance of urban assets.

This is achieved by collecting and making use of data in order to offer a better quality of life to their residents, always based on efficiency. For this purpose, an intelligent data processing is carried out, in conjunction with the use of sensors and low-cost data processing technologies.

Terrassa's commitment to this type of technology involves the deployment of its own IoT Network, which is based on LoRa/LoRaWAN technologies.

LoRa (Long Range) enables long-range transmissions with low power consumption. It is based on spread spectrum modulation techniques, which uses the 868 MHz sub-gigahertz radio frequency in Europe. LoRa only covers the physical layer, while other technologies and protocols such as LoRaWAN (Long Range Wide Area Network) cover the upper layers. LoRaWAN is also responsible for managing the communication frequencies, data rate, and power for all devices.

Coverage Study

One of the aspects to be taken into account when designing the network architecture is to have a good digital model of the city orography. With this cartography (in medium-high resolution quality), it is possible to calculate a good propagation model, which allows to make an estimation/validation of the number of devices to be installed, in order to guarantee a proper coverage in the city.

Terrassa’s LoRaWAN Architecture

Lorawan network additional

For the deployment of its network, the city of Terrassa has followed the standard architecture of LoRaWAN networks, consisting of a bunch of end-nodes (such as sensors and actuators that transmit when they have data available to send), a proper number of gateways and a network server, plus several application servers (which use the data generated by the end-devices).

To facilitate the management of the data integration (which have an initial treatment in the network server) and the fact that each sensor can send different types of data, with different levels of security, we added an intermediate system between the network server and the application servers, called Node-RED, which acting as ETL allows us to extract, transform and load the information in the application servers.

As a further improvement, Sentilo (an open source sensor and actuator platform) has been used, which allows us to have a centralised repository of data, visualise it and make it possible for any application to subscribe to it.

Finally, and essential for this smart city architecture, Node-RED has been used again, but this time in order to work as Complex Event Processor (or CEP), with the aim of applying business rules to enable decision-making and the execution of actions (for example, sending an order for a truck to collect waste when the container's sensor indicates that it is full).