25 April, 2019

ReadyMixTracking & flespi: a perfect mix for concrete mixers

A tale of how bravery, willingness to succeed, and humble listening led to enhanced performance and better architecture.

About ReadyMix

Our partner from Brazil — ReadyMix Tracking — is doing some great things for the construction industry. 

ReadyMix Tracking is a completely automated system for tracking of concrete mixers all the way from the concrete loading to on-the-go tracking, discharge tracking, way-back tracking, and cycle integration.

readymix tracking interface

Since the solution focuses on a niche concrete mixer market, the development of such a solution is challenging because it differs from mainstream fleet management platforms and requires a specific combination of functional elements: GPS tracking, sensor data processing, real-time visualization, high-performance analytics, responsive storage, and more.

Initially, the project was implemented using NoSQL MongoDB database, however, numerous performance problems forced the team to seek a better alternative. 

Halfway through the project ReadyMix came across the flespi platform and gave it a try. After successful trials and consulting from the flespi team, they decided to start switching the infrastructure to flespi. It was a daring move that required an immense work to be done and redone but that eventually paid off.

Why flespi?

Flespi appeared to be an all-in-one solution for the tasks and challenges outlined above. It’s not a turn-key platform but a do-it-yourself construction set — exactly what ReadyMix needed. They simply got handy tools to achieve the results they clearly realized quickly and easily.

The primary reasons to use flespi as the backend for their ReadyMix platform were the following:

  • No need to worry about hardware integration — flespi already supports hundreds of device types

  • ReadyMix, in turn, gets all the data from trackers in a unified JSON format regardless of the device manufacturer, which makes data management more straightforward.

  • Flespi serves as a single gateway for ReadyMix to integrate the data from trackers, Wialon, and any other third-party platform.

  • Flespi analytics engine ensures rapid data preprocessing.

  • On top of these, flespi offers own specialized telematics-focused MQTT broker for instant data updates.

The fact that most components of the solution are made by flespi guarantees natively smooth operation and high performance.

Scheme of work

So, what’s under the hood of the ReadyMix Tracking system? Let’s have a look.

Here’s a modular basic diagram showing the interaction between different parts of the platform:

readymix and flespi scheme of work

Let’s unfold the above diagram into a more meaningful explanation:

  • The data comes to flespi from GPS trackers directly or is retranslated from Wialon.

  • The messages are collected by the flespi channels (one channel per protocol) and converted into the unified JSON format.

  • ReadyMix uses a pipeline script that subscribes to the channel via MQTT to get data from this channel in real-time.

  • This pipeline then transforms all messages according to the business needs (omit some parameters, add other parameters) and publishes the resulting data packets to another channel — generic MQTT channel.

  • Then messages are grouped per flespi device with all related data: sensors, geofences, status, etc.

  • Another piece of software processes messages stored in devices and calculates intervals using flespi analytics API. Flespi device intervals provide everything necessary to transform data in milliseconds.

  • After that, the calculated data is inserted into a MySQL database.

  • Once the data is in the database, it’s possible to generate customer reports.

What’s so special?

We asked our client to share some of the determinative factors that made him pick flespi over other alternatives. Here’s what he pointed out:

  • The superior reliability of a secure and scalable gateway at a very interesting cost — this is a critical criterion since the backend is a part of a system you cannot change easily and would prefer to never change at all.

  • Good documentation/support — flespi involves programming efforts on the customer side and feeling comfortable in the new environment might take time. We are always ready to help along the way.

  • Fast integration process — flespi is easily embeddable into the existing product infrastructure thanks to multiple ways you can interact with it.

Challenges overcome

One of the major challenges in the project was to achieve high performance at high data volumes.

For instance, there is a standard report that calculates intervals for specific sensors. A combination of sensor values corresponds to the specific asset status, e.g. 0100 = Working, 0111 = Lunch Time, 1100 = idle inside customer, etc.

readymix tracking report

One concrete mixer generates around 4,000 messages a day.

If we need to create a report for 1,000 units for the period of one month, it results in 

31 days x 1,000 units x 4,000 = 124,000,000 messages

With MongoDB, the aforementioned routine took 180,000 ms to run. 

With flespi, the same task takes less than 1,800 ms. It's 100x faster. 

Isn’t it worth a major project overhaul?!

Bonus: consulting

Flespi is a technological brand — it develops technologies and designs tools for effective use of these technologies. The team has 16+ years of experience in telematics. And it’s ready to share the wisdom with anyone interested. 

Initially, ReadyMix application was not going to rely on MQTT and organize communication via MQTT broker. But they followed architectural guidance from flespi and reorganized the project architecture. This resulted in a huge performance win and simplified data management. It’s better done late than never. Because if the core is not performant enough, you cannot compensate this on the higher levels.

Just describe the project needs and we’ll be glad to help you become better.


We are grateful to the ReadyMix team for using flespi and for sharing their experience with us (and with you).

The bottom line is that flespi is the preferred choice for companies that are not afraid of getting their hands dirty doing some programming and that value high stability and personalized support.

P.S. Some fleet management systems offer API that can be used to build your own apps similarly to flespi, however, it’s the question of rationality and cost that sets flespi apart — why pay for the entire toolbox when you are going to use one screwdriver only?