https://github.com/dhanushgit03/dc-motor-speed-control-simulation
Simulink-based closed-loop DC motor speed control system using a PID controller, with motor parameter initialization via MATLAB scripts and performance analysis through scopes.
https://github.com/dhanushgit03/dc-motor-speed-control-simulation
control-systems dc-motor matlab matlab-project motor-simulation pid pid-controller simulink
Last synced: 6 months ago
JSON representation
Simulink-based closed-loop DC motor speed control system using a PID controller, with motor parameter initialization via MATLAB scripts and performance analysis through scopes.
- Host: GitHub
- URL: https://github.com/dhanushgit03/dc-motor-speed-control-simulation
- Owner: DhanushGit03
- Created: 2025-06-18T05:03:58.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2025-06-24T03:57:38.000Z (10 months ago)
- Last Synced: 2025-06-26T11:02:09.764Z (10 months ago)
- Topics: control-systems, dc-motor, matlab, matlab-project, motor-simulation, pid, pid-controller, simulink
- Language: MATLAB
- Homepage:
- Size: 69.3 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# DC Motor Speed Control Simulation ๐
This repository contains a Simulink-based simulation project to model and control the speed of a DC motor using classical control techniques such as the **PID controller**. This project is useful for students and enthusiasts interested in control systems, modeling, and real-time simulation with MATLAB & Simulink.
---
## ๐ง Project Objectives
- Model a DC motor using its physical parameters.
- Design and tune a PID controller to maintain desired motor speed.
- Analyze performance (overshoot, settling time, rise time).
- Visualize system response with scopes and plots.
- Demonstrate closed-loop speed regulation under step inputs.
---
## ๐ ๏ธ Files Included
| File/Folder | Description |
|----------------------------|--------------------------------------------------------------|
| `MyModel.slx` | Main Simulink model file |
| `MyModel.slxc` | Simulink cache file (auto-generated, ignored going forward) |
| `Machine_Parameters.m` | MATLAB script defining motor parameters |
| `DCMotorSpeedControlSimulation.prj` | Simulink Project file |
| `resources/project/` | Additional model assets or references |
**Note:** You can ignore `.slxc` โ it's an auto-generated Simulink cache file not needed for version control or manual editing.
---
## ๐งช Technologies Used
- **MATLAB** (for scripting and parameter definition)
- **Simulink** (for block diagram-based modeling)
- **Control System Toolbox**
- **PID Controller Tuning**
---
## โ๏ธ How to Run
1. Clone the repository:
```bash
git clone https://github.com/DhanushGit03/DCMotorSpeedControlSimulation.git
2. Open the `.prj` file in MATLAB by navigating to the cloned folder using the `Open Folder` option.
3. Now right-click on the `Simulink model` and select `Model Properties`.
4. Navigate to the `Call Backs` tab, then paste the saved file contents from `Machine_Parameters.m` into the appropriate callback section (such as `InitFcn`).
5. Click `Apply` and then `OK`.
6. Click the `Run` button in Simulink to start the simulation.