In the industrial framework, machines are essential, but controlling them effectively is still a difficult task. With the help of the STM32 platform and the system identification toolbox, this study presents a real-time implementation of a Blackbox DC motor using a Proportional Integral-Derivative (PID) controller under both load and no-load conditions. After undergoing extensive testing with a range of parameter values and stages, the experimental setup showed impressive efficiency. But more improvements are required, which means optimization algorithms must be created to improve the system’s functionality. The crucial nexus between motor systems and control engineering is clarified by this study, providing information for further developments in the area.