Rancang Bangun Modul Kontrol Berbasis PID untuk Pengaturan Kecepatan dan Posisi Motor DC Menggunakan STM32 dan Rotary Encoder
DOI:
https://doi.org/10.55123/insologi.v4i4.6081Keywords:
PID Control, DC Motor, STM32, Rotary Encoder, Closed-Loop System, Intelligent Control ModuleAbstract
Precision control of DC motors in industrial and robotics applications is often compromised by external loads and the limitations of open-loop systems, which cause instability in rotational speed and angular position. This study aims to design and build a PID-based intelligent control module for integrated DC motor speed and position control using an STM32F103C8T6 microcontroller and a rotary encoder as feedback. This system is designed as a closed-loop system to reduce the error between the setpoint and the actual value. Tests were conducted under no-load and with-load conditions at various speed setpoints (10–30 RPM) and angular changes (slow and fast). The results show that the system is able to stabilize motor performance with an average speed error of −0.3033 and 0.2766 RPM (no-load) for Motors A and B, and 0.2633 and 3.47 RPM (with-load). For angular position control, the average errors were 0.69° and 0.895° (without load), and 0.475° and 0.335° (with load). These findings demonstrate the effectiveness of the PID-based intelligent control module in improving system accuracy and stability. This system offers a compact and practical solution for industrial automation and robotics applications requiring precise motor control.
Downloads
References
Al-Mahasneh, A. J., & Maghari, A. Y. M. (2020). Optimization of PID Parameters Using Genetic Algorithm for DC Motor Speed Control. Applied Soft Computing, 87, 105924. https://doi.org/10.1016/j.asoc.2019.105924
Bitriá, R., & Palacín, J. (2022). Optimal PID Control of a Brushed DC Motor with an Embedded Low-Cost Magnetic Quadrature Encoder for Improved Step Overshoot and Undershoot Responses in a Mobile Robot Application. Sensors, 22(20), 7817. https://doi.org/10.3390/s22207817
Chen, L., Liu, Y., & Wang, X. (2023). Real-Time Position Control of DC Motors Using Quadrature Encoders and STM32 Timers. Microprocessors and Microsystems, 98, 104567. https://doi.org/10.1016/j.micpro.2023.104567
Firdaus, F., Priatna, E., Hiron, N., & Busaeri, N. (2022). PROTOTYPE SISTEM KENDALI KECEPATAN MOTOR DC DENGAN PROPORTIONAL INTEGRAL DERIVATIVE (PID) CONTROLLER. 4(1).
Gupta, S., & Singh, R. (2023). Design and implementation of a compact PID controller for DC motor speed regulation using STM32. Journal of Control, Automation and Electrical Systems, 34, 112–121. https://doi.org/10.1007/s40313-022-00945-6
Gurauskis, D., Marinkovic, D., Mažeika, D., & Kilikevičius, A. (2024). Self-Calibratable Absolute Modular Rotary Encoder: Development and Experimental Research. Micromachines, 15(9), 1130. https://doi.org/10.3390/mi15091130
Islam, M. R., Ahmed, S., & Rahman, M. T. (2022). An integrated control module for DC motors in robotic applications. Robotics and Autonomous Systems, 150, 103945. https://doi.org/10.1016/j.robot.2022.103945
Kurniawan, A., Setiawan, D., & Pratama, R. (2023). Development of a low-cost smart motor controller for industrial automation. Journal of Physics: Conference Series, 2501(1), 012034. https://doi.org/10.1088/1742-6596/2501/1/012034
Lee, J., & Park, S. (2021). Embedded Motor Control Systems: Trends and Challenges. Electronics, 10(14), 1678. https://doi.org/10.3390/electronics10141678
Li, Z., & Liu, Y. (2021). Embedded Systems for Motor Control: A Review. IEEE Transactions on Industrial Electronics, 68(7), 5890–5902. https://doi.org/10.1109/TIE.2020.3003821
Ma’arif, A. (2021). Embedded Control System of DC Motor Using Microcontroller Arduino and PID Algorithm. IT Journal Research and Development, 6(1), 30–42. https://doi.org/10.25299/itjrd.2021.vol6(1).6125
Manuel, N. L., İnanç, N., & Lüy, M. (2023). Control and performance analyses of a DC motor using optimized PIDs and fuzzy logic controller. Results in Control and Optimization, 13, 100306. https://doi.org/10.1016/j.rico.2023.100306
Murtono, A., & Kamajaya, L. (2021). Implementasi Kontrol PID untuk Analisis Pengaturan Kecepatan Motor DC Menggunakan STM32.
Nguyen, T. H., & Le, V. D. (2022). Embedded system design for precise position control of DC motors using quadrature encoder feedback. Sensors and Actuators A: Physical, 345, 113789. https://doi.org/10.1016/j.sna.2022.113789
Patel, K., & Desai, H. (2023). PID-based speed control of DC motor using STM32F103C8T6: A comparative study. International Journal of Electrical and Computer Engineering, 13(1), 456–465. https://doi.org/10.11591/ijece.v13i1.pp456-465
Pop, A. A. (2022). Incremental Encoder Speed Acquisition Using an STM32 Microcontroller and NI ELVIS. Sensors, 22(14), 5127. https://doi.org/10.3390/s22145127
Pradana, R., Suryadi, D., & Nugraha, A. (2023). Development of miniaturized motor driver module for educational robotics. Jurnal Teknologi, 85(4), 111–120. https://doi.org/10.14710/jteknol.85.4.111-120
Prayogo, R. C., Triwiyatno, A., & Riyadi, M. A. (2023). Field Oriented Control Implementation on BLDC Motor Controller with PI and SVPWM using STM32F103C8T6. Journal of Physics: Conference Series, 2622(1), 012025. https://doi.org/10.1088/1742-6596/2622/1/012025
Rahman, M. A., & Hossain, M. K. (2022). Comparative Study of PID Tuning Methods for DC Motor Control. International Journal of Electrical and Computer Engineering, 12(3), 2456–2465. https://doi.org/10.11591/ijece.v12i3.pp2456-2465
Rashid, Y. G., & Hussain, A. M. A. (2021). Implementing optimization of PID controller for DC motor speed control. Indonesian Journal of Electrical Engineering and Computer Science, 23(2), 657. https://doi.org/10.11591/ijeecs.v23.i2.pp657-664
Sozański, K. (2023). Low Cost PID Controller for Student Digital Control Laboratory Based on Arduino or STM32 Modules. Electronics, 12(15), 3235. https://doi.org/10.3390/electronics12153235
Suman, S., & Gupta, D. (n.d.). Closed Loop Speed Control of Brushless DC Motor Using STM32 Microcontroller.
Thai, N. L., & Kieu, N. T. (2022). Real-Time PID Controller for a DC Motor Using STM32F407. Saudi Journal of Engineering and Technology, 7(8), 472–478. https://doi.org/10.36348/sjet.2022.v07i08.007
Wang, X., Li, Z., & Liu, Y. (2023). Design of Integrated Control Module for Brushed DC Motors in Mobile Robots. Robotics and Autonomous Systems, 160, 104321. https://doi.org/10.1016/j.robot.2023.104321
Yıldırım, Ş., Bingol, M. S., & Savas, S. (2024). Tuning PID controller parameters of the DC motor with PSO algorithm. International Review of Applied Sciences and Engineering, 15(3), 281–286. https://doi.org/10.1556/1848.2023.00698
Yulianto, B., Karjadi, M., & Dwinanto, B. (2024). Sistem Pengereman Dinamik Dan Pengendali Kecepatan Pada Motor DC. Syntax Idea, 6(8), 3669–3680. https://doi.org/10.46799/syntax-idea.v6i8.4313
Zhang, Y., & Wang, H. (2023). Compact Motor Control Module for Robotics Using STM32 and Integrated Feedback. IEEE Access, 11, 12345–12356. https://doi.org/10.1109/ACCESS.2023.3245678
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2025 Doris Juarsa, Muhammad Fadli, Erliyan Redy Susanto

This work is licensed under a Creative Commons Attribution 4.0 International License.
Hak cipta pada setiap artikel adalah milik penulis.
Penulis mengakui bahwa INSOLOGI (Jurnal Sains dan Teknologi) sebagai publisher yang mempublikasikan pertama kali dengan lisensi Creative Commons Attribution 4.0 International License.
Penulis dapat memasukan tulisan secara terpisah, mengatur distribusi non-ekskulif dari naskah yang telah terbit di jurnal ini kedalam versi yang lain, seperti: dikirim ke respository institusi penulis, publikasi kedalam buku, dan lain-lain. Dengan mengakui bahwa naskah telah terbit pertama kali pada INSOLOGI (Jurnal Sains dan Teknologi).
























