GET IN TOUCH

IoT Messaging Library for Electric Scooter Ecosystem

IoT Solutions System software development Middleware development Transportation

There are a number of problems that you might face living in a big city anywhere in the world. Among them are overpopulation, long traffic jams, and environmental issues. Our customer, located in Germany, tries to solve these problems to make big city life easier and more comfortable.

They manufacture electric scooters - eco-friendly, smart transport able to solve traffic problems. The company decided to integrate an IoT solution into their product to make it more functional and user-friendly.

Request

The e-scooter network consists of a scooter with a rechargeable battery and a charging cabinet. The keyless e-scooters and the battery chargers are accessed and controlled by a mobile application. The scooters are equipped with a GPS tracker, which makes it possible to track their geolocation. The charging start/stop time, the scooter lock/unlock time, GPS data, distances covered, and other data are stored on a cloud database.

The major task of the customer was to connect and synchronize all the devices of this IoT ecosystem. Our team was hired to develop an IoT infrastructure consisting of a server, a client, a dashboard, and a RestAPI to provide remote access to the system from the mobile application.

The customer had certain requirements for the system's functionality, but they had no specific instructions on technology that can be used to deliver this project. Thus, our mission was to offer a viable IoT solution to ensure effective interaction between the components of the network, namely a web dashboard, a server, and a charger.

E-scooter IoT ecosystem. Components highlighted in blue were implemented by the Integra team.
E-scooter IoT ecosystem. Components highlighted in blue were implemented by the Integra team.

Solution

There are various standard protocols that provide efficient client-server communication. In our project, we used HTTP to access the web dashboard on the server.

However, this solution didn't seem to be efficient enough for the communication between the server and the charger. Some chargers may work even on a 2G network that cannot provide a high bandwidth capacity and stable management of the charging cabinet. 

We needed a solution to save traffic and ensure a stable and predictable connection with the chargers. So we decided to use a custom TCP-based protocol and develop our own library to optimize the client-server interaction between the chargers and the server device. The IoT messaging library works as a mediator between the frontend application with business logic and the data packets.

The library consists of several components. The key component of the library is Session that allows identifying the messaging client in the messaging system. Session software module provides a high-level interface for sending/receiving messages and storing data necessary for the management of the latest session. The library's users can extend the parameters of the stored data by themselves.

SessionManager, as one of the key components of the library, manages sessions, and provides an interface to create them. Transport, another component of the library, delivers a mechanism of message transporting and is responsible for the storage of the sent and received messages. Thus, users do not need to create their own mechanisms to implement this functionality.

Library components
Library components

Scope of Work

Integra’s team provided an IoT solution for the project by introducing the key components of the network.

We developed the server that can also work as a cloud solution and the client for the charging cabinet. We built a cross-platform application for the server's interaction with the charger's hardware via CAN and UART interfaces with custom protocols.

Our team developed a simple UI to manage IoT devices. This is a web dashboard that allows for monitoring and controlling the devices and collecting data and analytics, thus helping the manufacturer to optimize their product.

Screenshot of the web dashboard
Screenshot of the web dashboard

We developed RestAPI for a mobile application. This is an additional module on the server's side that allows for the electric scooter's communication with the charger and the database.

And finally, we wrote the library with a number of components to implement a messaging system between the devices of the IoT network. The library unites all parts of the system, connecting them with each other. Above that, the server and the client are powered by the library that ensures their smooth performance.


Technologies Used


Result

We developed a multi-component library that facilitates the implementation of message-oriented middleware intended for messaging in distributed systems. The library serves for the development of client-server applications and other apps interacting in peer-to-peer networks.

Our messaging solution can be used for the purposes of message exchange, data serialization, session management, and network interaction. It identifies message types, creates messages with fieldsets, and is able to record long messages. Besides, the library has a spam filtering system protecting it from malware or any unwelcome message. 

The solution we developed has a light architecture, and consequently very low overhead. It is easy to implement and deploy. The library is highly flexible and customizable, so it can be used in various C++ applications. Because of its high scalability, it allows users to add as many devices as their server’s capacity permits. 

You might also like...

We use cookies to improve your experience on our website. Our Cookies Policy explains what cookies are, how we use cookies and how third-parties we may partner with may use cookies. Please find more information here.