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 obtained 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, which is a specification of LPWAN (Low Power Wide Area Network), in which the devices have a low power consumption and a very low transmission power. The price paid for this low energy consumption and this low transmission power is low transmission speeds, which for a sensor network is enough.
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.
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 gateways to be installed (seven in our case) in order to guarantee a proper coverage in the city. This study is very important because we are talking about devices that cover the whole city, but whose transmission power is equivalent of any mobile phone you can carry in your pocket.
Terrassa’s LoRaWAN Architecture
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).
End-devices (or end-nodes): A LoRaWAN end device can be a sensor, an actuator, or both. They are often battery operated. These end devices are wirelessly connected to the LoRaWAN network through gateways using LoRa RF modulation.
Gateways: A gateway receives LoRa messages from end-devices and forwards them to the network server. Gateways are connected to the internet through an IP link. IP traffic from gateway to the network server can be transmitted through different technologies such as mobile links, WiFi, Ethernet, fiber-optic or another kind of radio links.
Network Server: The network server manages the entire LoRaWAN network. It receives IP traffic from gateways. The Network Server is responsible for network management functions such as devices activation, messaging routing, or data rate control, among others.
Application Server/s: The application server processes application-specific data messages received from end-devices. It is also responsible for generating application information to the end-devices that is delivered through the network server. A LoRaWAN network can have more than one application server. The collected data can be interpreted by applying techniques like machine learning and artificial intelligence to solve business problems.
In order to facilitate the management of the data integration (which have an initial treatment in the network server) and due to 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 a EAI system (Enterprise Application Integration) allows us to extract the data and integrate it into the different consuming applications.
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).
This ready and functioning architecture, as a starting point, allows the city to deploy a network of sensors and actuators, which are the most important devices in an IoT network. With the information generated by the different sensorised elements, used in a proper way, it will be possible to improve people’s quality of life.
LoRaWAN website, referring architecture:
LoRaWAN Network Server, The Things Network Stack V3:
(EAI) Enterprise Application Integration, Wikipedia: https://en.wikipedia.org/wiki/Enterprise_application_integration
(CEP) Complex Event Processing, Wikipedia: