Smart Traffic Light Berbasis ESP32 dan Internet of Things menggunakan Logika Fuzzy untuk Pengendalian Kepadatan Lalu Lintas
DOI:
https://doi.org/10.59024/jiti.v4i3.2315Keywords:
ESP32, Internet of Things, Mamdani Fuzzy Logic, Smart Traffic Light, Telegram BotAbstract
Traffic congestion and zebra crossing violations are common problems at road intersections due to fixed-time traffic light systems that are less adaptive to traffic conditions. This research aims to design and implement an ESP32 and Internet of Things (IoT)-based Smart Traffic Light system using the Mamdani Fuzzy Logic method to automatically regulate traffic light duration based on vehicle density. The system utilizes an inframerah sensor to detect vehicle density and an ultrasonic sensor to detect zebra crossing violations. Sensor data are processed by the ESP32 through fuzzification, inference, and defuzzification to determine the appropriate traffic light duration. The system is equipped with traffic light LEDs, a TM1637 countdown timer, a buzzer, and a Telegram Bot for real-time monitoring. Testing results showed that the inframerah sensor successfully detected vehicle density, while the ultrasonic sensor accurately detected objects at distances of 5–25 cm. The fuzzy logic system produced green light durations of 5, 20, and 30 seconds for low, medium, and high traffic densities, respectively. In addition, the Telegram Bot successfully sent real-time notifications of zebra crossing violations. The proposed system operates automatically, adaptively, and effectively to support traffic management and zebra crossing monitoring.
References
’Abid, A., Pratama, F. F., & Fauzi, I. (2023). Perancangan Pengendalian dan Optimalisasi Lampu Lalu Lintas pada Persimpangan Jalan Muktisari Kebumen Menggunakan Algoritma Fuzzy Logic. Technology and Informatics Insight Journal, 2(1), 1–11. https://doi.org/10.32639/tiij.v1i1.390
Al-Fuqaha, A., Guizani, M., Mohammadi, M., Aledhari, M., & Ayyash, M. (2015). Internet of Things: A Survey on Enabling Technologies, Protocols, and Applications. IEEE Communications Surveys & Tutorials, 17(4), 2347–2376. https://doi.org/0.1109/COMST.2015.2444095
Azis, A., Emidiana, E., & Azukruf, F. (2023). Perancangan Prototipe Robot Pembawa Barang Otomatis Berbasis Arduino Uno DIP dengan Sensor Ultrasonik. Elektrika, 15(1), 29–38. https://doi.org/10.26623/elektrika.v15i1.5924
Azis, A., & Kartika, I. (2021). Rancang Bangun Alat Cuci Tangan Pintar Menggunakan Sensor Inframerah Berbasis Arduino. Electrician: Jurnal Rekayasa Dan Teknologi Elektro, 15(3), 224–238. https://doi.org/10.23960/elc.v15n3.2177
Bestari, D. N., & Wibowo, A. (2023). An IoT-Based Real-Time Weather Monitoring System Using Telegram Bot and Thingsboard Platform. International Journal of Interactive Mobile Technologies, 17(6), 4–19. https://doi.org/10.3991/ijim.v17i06.34129
Desmira, Hamid, M. A., Bakar, N. A., Nurtanto, M., & Sunardi. (2022). A Smart Traffic Light using a microcontroller based on the fuzzy logic. IAES International Journal of Artificial Intelligence, 11(3), 809. https://doi.org/10.11591/ijai.v11.i3.pp809-818
Hamid, M. A., Bakar, N. A., & Nurtanto, M. (2022). A Smart Traffic Light using a microcontroller based on the fuzzy logic. 11(3), 11591. https://doi.org/10.11591/ijai.v11.i3.pp809-818
Kusumo, B., & Salam, F. (2023). Rancang Bangun Sistem Kontrol dan Alat Monitoring Traffic Light Menggunakan ESP8266 Berbasis IoT. Jurnal Elektro, 11(2), 247–256. https://doi.org/https://jurnalteknik.unkris.ac.id/index.php/jie/article/view/280
Machdani, A., Attamimi, S., & Husodo, B. (2020). Sistem Kontrol Lampu Lalu Lintas Untuk Layanan Darurat Berbasis Internet of Things (IoT). Jurnal Teknologi Elektro, 10(3), 188–193. https://doi.org/10.22441/jte.v10i3.007
Maier, A., Sharp, A., & Vagapov, Y. (2017). Comparative Analysis and Practical Implementation of the ESP32 Microcontroller Module for the Internet of Things. Internet Technologies and Applications (ITA), 143–148. https://doi.org/10.1109/ITECHA.2017.8101926
Nurdiana, N., Azis, A., & Perwati. (2022). Perancangan Pengendali Temperatur pada Alat Pengering Makanan Berbasis IoT. Electrician: Jurnal Rekayasa Dan Teknologi Elektro, 16(3), 247–252. https://doi.org/10.23960/elc.v16n3.2263
Pebrianti, I. K., & Azis, A. (2025). Perancangan Alat Pencuci Tangan Otomatis Menggunakan Sensor Inframerah Berbasis Arduino Uno. Jurnal Surya Energy, 9(2), 97–108. https://doi.org/10.32502/jse.v9i2.440
Putra, E. K., & Oktaviandi, O. (2022). Prototipe Peringatan Pelanggaran Zebra Cross Pada Lampu Lalu Lintas Dengan Sirine Menggunakan Arduino. Jurnal Teknik Elektro, 11(2), 51–56. https://doi.org/10.21063/JTE.2022.31331108
Rahmawati, Y., Simanjuntak, I. U. V., & Simorangkir, R. B. (2022). Rancang Bangun Purwarupa Sistem Peringatan Pengendara Pelanggar Zebra Cross Berbasis Mikrokontroller ESP-32 CAM. Jambura Journal of Electrical and Electronics Engineering, 4(2), 189–195. https://doi.org/10.37905/jjeee.v4i2.14499
Ramadhan, Z. A., Mohammed, B. K., & Alwaily, A. H. (2021). Design and implement a Smart Traffic Light controlled by Internet of Things. Periodicals of Engineering and Natural Sciences, 9(4), 542–548. https://doi.org/10.21533/pen.v9i4.2351
Sriharyani, L., Hadijah, I., & Samping, H. (2023). Kepadatan Lalu Lintas Akibat Hambatan Samping Ruas Jalan Ki Hajar Dewantara Kota Metro. TAPAK (Teknologi Aplikasi Konstruksi): Jurnal Program Studi Teknik Sipil, 12(2), 179–189. https://doi.org/10.24127/tp.v12i2.2596
Tunc, I., & Soylemez, M. T. (2023). Fuzzy logic and deep Q learning based control for traffic lights. Alexandria Engineering Journal, 67, 343–359. https://doi.org/10.1016/j.aej.2022.12.028
Tunc, I., Yesilyurt, A. Y., & Soylemez, M. T. (2021). Different fuzzy logic control strategies for traffic signal timing control with state inputs. IFAC PapersOnLine, 54(2), 265–270.
Variani, V. I. (2021). Performance of Fuzzy Inference System for Calorific Value Predicting by Using The Mamdani Method. Indonesian Journal of Applied Physics, 11(1), 87–94. https://doi.org/10.13057/ijap.v11i1.44122
Yusuf, A. N. A., Arifin, A. S., & Zulkifli, F. Y. (2021). Recent development of Smart Traffic Lights. IAES International Journal of Artificial Intelligence, 10(1), 224–233. https://doi.org/10.11591/ijai.v10.i1.pp224-233
Downloads
Published
Issue
Section
License
Copyright (c) 2026 JURNAL ILMIAH SAINS TEKNOLOGI DAN INFORMASI

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.








