Functional Programming for the Internet of Things: A LoRa-MQTT Gateway written in Elixir - Branch, Philip; Weinstock, Phillip (Australasian Telecommunication Networks and Applications Conference [proceedings], 2023)
Networks for the Internet of Things typically use a gateway to provide connectivity between a low bit rate, low capability sensor network and the broader Internet. The gateway can be subject to very high traffic loads, many concurrent processes and needs to be highly reliable. Functional programming languages such as Erlang and Elixir have proven to be an effective programming paradigm for such scenarios, notably in large scale telecommunications switches. In this paper we report on our experiences of developing a gateway between a LoRa network and an MQTT broker using the functional programming language Elixir. Our experience suggests that the discipline imposed by functional programming results in a system that is more compact, supports concurrent processes well and is more reliable than similar systems developed using conventional languages. However, we also note that subsystems to support the development of such systems are primitive and that functional programming has a considerably steep learning curve. Nevertheless we conclude that functional programming has considerable potential for the Internet of Things and plan to continue research in this area.