Implementação de sistema multitarefa para controle de dispositivos LED utilizando FreeRTOS em microcontrolador ESP32
uma abordagem de computação embarcada para aplicações de tempo real
DOI:
https://doi.org/10.47385/tudoeciencia.2594.2025Palavras-chave:
FreeRTOS. ESP32. Sistemas Embarcados. Tempo Real; Multitarefa. GPIO.Resumo
Este trabalho apresenta o desenvolvimento e análise de um sistema multitarefa implementado no microcontrolador ESP32 utilizando o sistema operacional de tempo real FreeRTOS para controle independente de três dispositivos LED com diferentes frequências de intermitência. O sistema implementa três tarefas concorrentes com prioridades distintas, demonstrando a capacidade do FreeRTOS em gerenciar múltiplas operações simultâneas em sistemas embarcados de baixo custo. Os LEDs verde, amarelo e vermelho foram configurados para piscar em intervalos de 300ms, 1000ms e 2000ms respectivamente, conectados aos pinos GPIO 7, 6 e 5 do ESP32. A implementação utilizou o paradigma de programação baseada em tarefas (task-based programming), aproveitando as funcionalidades do kernel FreeRTOS para escalonamento preemptivo e gerenciamento de recursos. Os resultados obtidos demonstraram a eficácia do sistema em manter a sincronização temporal precisa entre as diferentes tarefas. O trabalho contribui para o entendimento das aplicações de sistemas operacionais de tempo real em microcontroladores de 32 bits, fornecendo uma base sólida para desenvolvimento de sistemas embarcados mais complexos que requerem processamento paralelo e determinismo temporal.
Downloads
Referências
AUDSLEY, N. C.; BURNS, A.; RICHARDSON, M. F.; TINDELL, K.; WELLINGS, A. J. Applying new scheduling theory to static priority pre-emptive scheduling. Software Engineering Journal, v. 8, n. 5, p. 284-292, 1993.
BARRY, R. Using the FreeRTOS real time kernel: a practical guide. Real Time Engineers Ltd., 2010.
BARRY, R.. FreeRTOS Reference Manual API Functions and Configuration Options. Real Time Engineers Ltd., 2017.
BUTTAZZO, G. C. Hard real-time computing systems: predictable scheduling algorithms and applications. 3rd ed. New York: Springer, 2011.
GANSSLE, J. The Art of Designing Embedded Systems. 2nd ed. Burlington: Newnes, 2008.
KOLBAN, N. Kolban's Book on ESP32. Texas: Leanpub, 2017.
KOPETZ, H. Real-time systems: design principles for distributed embedded applications. 2nd ed. New York: Springer, 2011.
LEE, E. A. Cyber physical systems: design challenges. In: 11th IEEE International Symposium on Object and Component-Oriented Real-Time Distributed Computing (ISORC). Proceedings... Orlando: IEEE, 2008. p. 363-369.
LIU, C. L.; LAYLAND, J. W. Scheduling algorithms for multiprogramming in a hard-real-time environment. Journal of the ACM, v. 20, n. 1, p. 46-61, 1973.
MAIER, A.; SHARP, A.; VAGAPOV, Y. Comparative analysis and practical implementation of the ESP32 microcontroller module for the internet of things. In: Internet Technologies and Applications (ITA). Proceedings... Wrexham: IEEE, 2017. p. 143-148.
MONK, S. Programming Arduino Next Steps: Going Further with Sketches. 2nd ed. New York: McGraw-Hill Education, 2018.
SHA, L.; ABDELZAHER, T.; ÅRZÉN, K. E.; CERVIN, A.; BAKER, T.; BURNS, A.; BUTTAZZO, G.; CACCAMO, M.; LEHOCZKY, J.; MOK, A. K. Real time scheduling theory: a historical perspective. Real-time systems, v. 28, n. 2-3, p. 101-155, 2004.
OLIVEIRA, Gessé; LIMA, George. Evaluation of Scheduling Algorithms for Embedded FreeRTOS-Based Systems. In: SIMPÓSIO BRASILEIRO DE ENGENHARIA DE SISTEMAS COMPUTACIONAIS (SBESC), 10. , 2020, Evento Online. Anais [...]. Porto Alegre: Sociedade Brasileira de Computação, 2020 . p. 183-190. ISSN 2237-5430.
YIU, J. The Definitive Guide to ARM Cortex-M23 and Cortex-M33 Processors. Oxford: Newnes, 2020.
Downloads
Publicado
Como Citar
Edição
Seção
Licença
Copyright (c) 2025 Tudo é Ciência: Congresso Brasileiro de Ciências e Saberes Multidisciplinares

Este trabalho está licenciado sob uma licença Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.