Software Engineering
October 09, 2026
EngTT: software for road freight based on operational costs and ANTT parameters
Engtt: Software for Road Freight Motor Based on Operational Costs and Antt Parameters
Lucas Santos Villar Arias; Arthur Pinheiro de Araújo Costa
DOI: 10.22167/2675-6528-202603186
Article derived from a Course Conclusion Work (TCC), with content based on the student’s original work and adapted to the editorial format of the E&S Magazine with the support of the ResumeAI tool, an artificial intelligence solution developed by Instituto Pecege for textual synthesis and organization.
Summary
Road transport represents the main logistics modality in Brazil, with the composition of freight costs regulated by the National Land Transport Agency (ANTT). Given the absence of a structured methodology for freight calculation and the sector’s dependence on isolated spreadsheets, the EngTT software was developed. The objective was to create a decision support tool that integrated operational variables, calculated the total cost per route, and compared the results with the ANTT’s minimum floor, identifying non-compliance and margin compression scenarios before pricing. The adopted methodology was applied, quantitatively and experimentally, with incremental construction oriented towards the Minimum Viable Product (MVP) concept. The system was structured in three modes of use – Build Visual Route, Batch by spreadsheet, and Scrape routes – sharing a decoupled calculation engine and centralized parameters. The results obtained demonstrated that the software met the proposed objective, showing margin and regulatory compliance variations between the analyzed routes. It was observed that longer routes, such as Ribeirão Preto × Guarujá, presented an increase in cost due to the need for additional driver per diems, while shorter routes, such as Cajamar × Guarujá, showed greater adherence to the ANTT’s regulatory floor. It was concluded that the developed solution is applicable to the road freight transport sector as an effective tool for pricing and operational management.
Keywords: ANTT; Containerized cargo; Software engineering; Road freight; Python.
1. Introduction
Road freight transport is the main logistics modality in Brazil, being responsible for approximately 62% of the total cargo movement in the country (AGÊNCIA CIDADES, 2025). This structural dependence of the Brazilian economy is reflected in national logistics costs, which reach about R$ 940 billion annually, with an average growth of 7% per year (ASSOCIAÇÃO BRASILEIRA DE OPERADORES LOGÍSTICOS, 2024). The relevance of this modal imposes the need for efficient and transparent processes for its cost management.
The composition of road freight costs is complex, involving fixed and variable variables, such as fuel, maintenance, tolls, depreciation, insurance, taxes, and waiting time. To ensure compliance and fairness in operations, the minimum road freight is regulated by the National Land Transport Agency (ANTT), which updates its minimum floor table semi-annually or whenever there is a variation greater than five percent in the price of diesel oil (NATIONAL LAND TRANSPORT AGENCY, 2025). Furthermore, Law No. 10.209/2001 establishes the mandatory toll voucher, and Law No. 13.103/2015 regulates the professional driver’s journey, establishing eight daily hours with the possibility of up to two overtime hours and integrating waiting time into the journey (BRAZIL, 2001; BRAZIL, 2015).
Despite the regulation and complexity involved, a large part of the organizations in the sector still face significant challenges in calculating freight. The common practice is the use of isolated spreadsheets, which lack methodological standardization, traceability of premises, and systematic comparison with current regulatory parameters. This absence of a structured methodology compromises pricing accuracy, hinders operational and commercial decision-making, and exposes companies to risks of regulatory non-compliance.
Given this scenario, the need for a tool that integrates operational variables and regulatory parameters becomes evident, offering a standardized, auditable, and reproducible solution for freight calculation. The present work proposes the development of a software named EngTT, whose name combines the concept of a calculation engine, derived from the English word Engine, with a reference to the ANTT regulatory table, synthesizing its central purpose of structuring road freight calculation in accordance with the agency’s norms.
The research is justified by the practical and theoretical gap in the management of costs for containerized road freight, aiming to offer a decision support tool that addresses the absence of a structured methodology for freight calculation in organizations in the sector. To this end, the research objective is to develop a decision support software capable of resolving the absence of a structured methodology for calculating containerized road freight in organizations in the sector, which today operate with isolated spreadsheets, without traceability of premises and without systematic comparison with current regulatory parameters. To this end, the EngTT software integrates operational variables such as fuel, tolls, tires, driver’s daily wages, and layover times, calculates the total cost of the operation per route, and compares the result with the minimum floor established by ANTT, allowing the identification of scenarios of regulatory non-compliance and margin compression before pricing to the contractor.
2. Material and Methods
The research was characterized as applied, quantitative, and experimental, aiming to develop a standardized tool for the structured and auditable calculation of containerized road freight. Iterative development was adopted, oriented towards the Minimum Viable Product (MVP) concept, with cycles of review, testing, and refinement, following Software Engineering principles (PRESSMAN, 2016). The study used parameterized operational data, constructed from real industry references, without company identification, ensuring impartiality and replicability. The initial focus was on containerized cargo operations with six-axle vehicles, a common configuration in long-distance transport in Brazil.
The methodological process involved literature review, requirements definition, architecture modeling, software implementation, parameterization and data collection, module execution and validation, and results analysis. This iterative flow allowed for the progressive construction of the solution.
For the development of the EngTT software, Python (v3.11.9) was employed as the main language and the Django web framework for the local interface. The architecture was modular and layered (SOMMERVILLE, 2019), with Presentation, Application, Domain, Data, and Integration. Libraries such as Pandas (v2.2.3) and openpyxl handled Excel spreadsheets (.xlsx), and Selenium automated data capture from the QualP portal. PyInstaller was used for packaging into a Windows executable, and Visual Studio Code (v1.90.1) as the development environment.
The input data and operational parameters were centralized in Excel files. `config.xlsx` stored standard premises (base addresses, axes, ANTT table, markup, waiting hours), while `EngTT_Cost_Model.xlsx` consolidated vehicle economic parameters (consumption, tires, daily rates, insurance). `EngTT_RouteDatabase.xlsx` was used for batch processing.
The EngTT calculation engine, in the `engine/` directory, was structured to break down freight into traceable components. The route was modeled as a sequence of segments (base, depot, client, port, return to base), with associated distance and times. Variable costs were calculated based on fuel, tires, tolls (Law No. 10.209/2001), and layover. The driver’s journey and daily rates were parameterized according to Law No. 13.103/2015, with adjustments for excess operating times. ANTT’s minimum floor parameters were integrated as a regulatory reference for direct comparison with operational cost (NATIONAL AGENCY OF LAND TRANSPORT, 2025), applying a 92% empty return factor for sections without cargo.
The EngTT was structured into three usage modes. The Visual Route Builder allowed individual route simulation, configuring parameters to obtain total cost, selling price, and comparison with the ANTT floor. The Spreadsheet Batch processed multiple routes from a standardized input spreadsheet, generating an output file with history and comparative graphs. Route Scrape performed automated enrichment of the route database with data from the QualP portal (distance, toll, estimated time, minimum ANTT floor), operating as assisted integration via Selenium, with manual authentication. Files such as `EngTT_Scrape.xlsx` and `EngTT_Scrape_output.xlsx` were used for Scrape input and output, with final results stored in `runtime_exports/` with a timestamp.
3. Results and Discussion
The implementation of the EngTT software represented a functional and robust solution for the challenge of structured calculation of containerized road freight, according to the central objective of this research. The system demonstrated the ability to perform analyses both individually and in batch, integrating with the regulatory parameters of the National Land Transport Agency (ANTT) and offering a mechanism for automated enrichment of external data. The development process rigorously followed modern Software Engineering practices, with special attention to code modularity, centralization of operational premises, and clear separation of responsibilities by layers, ensuring the tool’s maintainability and scalability.
The architecture of EngTT, organized in Presentation, Application, Domain, Data, and Integration layers, facilitated the management of requirements and the incremental construction of the Minimum Viable Product (MVP). This approach allowed the system to be developed in Python, with a local web interface, and for the calculation engine to be decoupled, which contributes to flexibility and code reuse. The centralization of operational and regulatory parameters in a `config.xlsx` file eliminated the need for direct coding, making the model auditable and accessible to non-technical users for adjustments and validation of premises.
The EngTT calculation engine was designed to break down freight into traceable components, addressing route composition as a sequence of segments that include base departure, depot transit, customer service, port (if applicable), and base return. Each segment had its associated distance, travel time, and dwell time, distinguishing between productive movement and unproductive time. This granularity in calculation is fundamental for pricing accuracy and for identifying operational bottlenecks.
Regarding costs, the software calculated variable components, such as fuel per kilometer, based on the vehicle’s average consumption, and tire cost per kilometer. Tolls were treated as a mandatory and segregated component, in accordance with Law No. 10.209/2001, which establishes the toll voucher. The stay cost was determined by the vehicle’s dwell time at the shipper’s or consignee’s premises, a critical factor that frequently impacts the profitability of transport operations.
The driver’s journey and daily rates were parameterized based on Law No. 13.103/2015, which establishes a regular eight-hour workday, with the possibility of up to two overtime hours, and integrates waiting time into the workday. When the total operation time exceeded the legal daily limits, the system automatically increased the number of daily rates and, consequently, the total estimated cost. This functionality is crucial to ensure labor compliance and the correct allocation of labor-related costs.
The composition of the suggested selling price by EngTT was obtained by applying a commercial markup percentage, defined in the `config.xlsx` file, to the total estimated cost of the route. This selling price was then compared with the minimum freight floor established by ANTT, allowing the identification of scenarios of regulatory compliance, margin compression, or price underestimation. This direct comparison is one of the pillars of the tool, offering a clear view of the commercial and regulatory viability of each operation.
The execution of the computational model allowed simulating diverse route configurations, using as a case study the routes Cajamar × Guarujá, Guarulhos × Guarujá, Extrema (MG) × Guarujá, and Ribeirão Preto × Guarujá. These routes were selected because they represent different distance ranges and operational profiles, which enabled a comprehensive analysis of the impacts of cost variables. The results demonstrated significant cost variations among the routes, mainly influenced by the distance traveled, toll incidence, dwell time, and the need for additional daily allowances for the driver.
On longer routes, such as Ribeirão Preto × Guarujá, the total operation time frequently exceeded the driver’s legal daily working hours, resulting in a significant increase in the estimated total cost due to the need for additional daily allowances. This finding highlights the importance of considering labor legislation in freight calculation, as non-compliance can generate unforeseen costs and legal risks for transport companies.
On the other hand, shorter routes, such as Cajamar × Guarujá, showed greater adherence to the ANTT’s regulatory floor, with a lower probability of operational margin compression. This result corroborates the technical literature in the sector, which indicates the proportional incidence of tolls and waiting times for loading and unloading as the most critical factors on shorter routes, while the driver’s journey has a predominant impact on the total cost on longer routes (Ballou, 2016).
The comparative analysis between the cost calculated by EngTT and the ANTT’s minimum regulatory floor for the simulated routes revealed distinct scenarios. For the Cajamar × Guarujá route, the operational cost calculated by EngTT was R$ 3,045.91, with a suggested selling price of R$ 3,198.21 (applying a 5% markup), while the ANTT floor was R$ 3,398.58. Similarly, for Extrema (MG) × Guarujá, the EngTT cost was R$ 3,149.40, the selling price R$ 3,306.87, and the ANTT floor R$ 3,763.69. In both cases, the selling price suggested by EngTT was below the ANTT’s regulatory floor, indicating a scenario of potential non-compliance or the need for markup adjustment to meet the regulation.
In contrast, for the Guarulhos × Guarujá route, the EngTT cost was R$ 2,512.56, the selling price R$ 2,638.19, and the ANTT floor R$ 2,454.54. In this case, the selling price suggested by EngTT exceeded the minimum ANTT floor, indicating a positive margin and regulatory compliance. For Ribeirão Preto × Guarujá, the EngTT cost was R$ 5,791.68, the selling price R$ 6,081.26, and the ANTT floor R$ 8,468.47, again with the selling price below the regulatory floor. This distinction between operational cost, suggested selling price, and the ANTT regulatory floor is crucial for evaluating the economic and regulatory viability of each route, allowing for more strategic pricing decisions.
The execution of the Route Scrape module demonstrated the technical feasibility of assisted integration with the QualP portal for automated route base enrichment. The capture flow, after manual login confirmation by the user, successfully collected distance data, toll per axle, estimated travel time, and the minimum ANTT floor for the informed routes. The decision to maintain manual authentication proved to be correct, given the variability in the QualP portal’s login flows, which would make full automation fragile and difficult to maintain. The Scrape output file was generated in a standard format, allowing direct chaining with the Batch mode without the need for intermediate data transformations.
The layered architecture adopted in EngTT proved effective in separating responsibilities, facilitating system maintenance and incremental evolution. Centralizing parameters in the `config.xlsx` file eliminated the practice of “hardcodes” distributed throughout the code, making the model’s premises explicit and auditable, a valuable attribute for both the scientific validity of the research and traceability in professional use contexts. This approach aligns with the principles of cohesion and low coupling, fundamental in Software Engineering (Pressman, 2016; Sommerville, 2019).
The separation of the three usage modes – Visual Route Assembly, Batch by spreadsheet, and Route Scrape – allowed each workflow to be optimized for its specific purpose, without compromising the coherence of the underlying calculation engine. Practical validation of the `.exe` executable confirmed that the solution is technically distributable and accessible to users without technical knowledge in Python, which expands its application potential in the sector. In summary, the results obtained demonstrate that EngTT is capable of calculating the total operation cost per route, incorporating operational and regulatory variables, and comparing the values with the ANTT minimum floor, effectively responding to the objective of providing a structured methodology and a decision support tool for the pricing of containerized road freight.
4. Conclusion
The present study sought to develop a decision support software to address the absence of a structured methodology in the calculation of containerized road freight, integrating operational and regulatory variables for comparison with the ANTT minimum floor. It was verified that the EngTT software proved to be a functional and robust solution, capable of performing total cost analyses per route, both individually and in batch, and of incorporating regulatory parameters from the National Land Transport Agency. It was observed that the tool allowed for the identification of regulatory non-compliance scenarios and margin compression before pricing, by comparing the suggested selling price with the ANTT minimum floor. The analysis of simulated routes, such as Cajamar × Guarujá and Ribeirão Preto × Guarujá, highlighted significant cost variations, influenced by travel distance, toll incidence, dwell time, and the need for additional driver per diems, according to Law nº 13.103/2015. It was noted that longer routes showed an increase in cost due to per diems, while shorter routes showed greater adherence to the regulatory floor. The modular architecture and the centralization of parameters in the `config.xlsx` file ensured the maintainability and auditability of the model.
The main contribution of EngTT lies in its ability to transform a freight pricing process, previously dependent on isolated spreadsheets with low traceability, into a standardized, auditable, and reproducible methodology, offering strategic support to logistics and commercial management. However, the current model presents limitations, such as the dependence on manual authentication on external portals for the Route Scrape module, the inherent fragility of integrations based on third-party web interfaces, the need for Excel files in the execution environment, and the initial coverage restricted to containerized cargo. For future studies, it is suggested to publish the software in a production environment with a persistent database, expand the handling of the ANTT table for other vehicle configurations, develop management reports with logistic performance indicators, and integrate with application programming interfaces (APIs) for route and toll inquiries, aiming for a more complete desktop application experience.
Bibliographic References
AGÊNCIA CIDADES. Rodovias são responsáveis por 62% do transporte de cargas no Brasil. Brasília, 2025. Disponível em: https://www.agenciacidades.com.br/reportagens/rodovias-sao-responsaveis-por-62-do-transporte-de-cargas-no-brasil/697/. Acesso em: 1 nov. 2025.
AGÊNCIA NACIONAL DE TRANSPORTES TERRESTRES (ANTT). Tabela de Pisos Mínimos do Transporte Rodoviário de Cargas. Brasília, 2025.
ASSOCIAÇÃO BRASILEIRA DE OPERADORES LOGÍSTICOS (ABOL). Gastos com transportes no Brasil sobem 7% e chegam a R$ 940 bilhões. São Paulo, 2024. Disponível em: https://abolbrasil.org.br/noticias/noticias/gastos-com-transportes-no-brasil-sobem-7-e-chegam-a-r-940-bilhoes/. Acesso em: 1 nov. 2025.
BALLOU, Ronald H. Logística Empresarial: Transportes, Administração de Materiais e Distribuição Física. São Paulo: Atlas, 2016.
BRASIL. Lei nº 10.209, de 23 de março de 2001. Institui o vale-pedágio obrigatório sobre o transporte rodoviário de carga e dá outras providências. Diário Oficial da União, Brasília, 2001.
BRASIL. Lei nº 13.103, de 2 de março de 2015. Dispõe sobre o exercício da profissão de motorista; altera a Consolidação das Leis do Trabalho (CLT) e dá outras providências. Diário Oficial da União, Brasília, 2015.
PRESSMAN, Roger S. Engenharia de Software: uma abordagem profissional. 8. ed. Porto Alegre: AMGH, 2016.
SOMMERVILLE, Ian. Software Engineering. 10th ed. São Paulo: Pearson, 2019.
Article originating from the Final Course Work of the Specialization in Software Engineering of the MBA USP/Esalq
To learn more about the course, click here and access the MBX Academy platform