An Adaptive Cruise Control (ACC) system developed as a 2nd-Semester Project for the MEng Computer Engineering program. This implementation utilizes MATLAB and Arduino to demonstrate real-time sensory feedback, automated speed regulation, and proximity-aware safety logic.
Source Code · Technical Specification · Live Demo
Authors · Overview · Features · Structure · Quick Start · Hardware Components · Tinkercad Simulation · Working Model · Development Roadmap · Usage Guidelines · License · About · Acknowledgments
Important
Special thanks to Brano Bruno Barshmen and Nandeshwar Royal Uppalapati for their meaningful contributions, guidance, and support that helped shape this work.
The Adaptive Cruise Control (ACC) system is a sophisticated embedded control project developed during the 2nd Semester of the MEng in Computer Engineering program at the University of Windsor. The project implements a closed-loop control system that manages vehicle velocity through real-time telemetry. By utilizing an ultrasonic sensor to monitor the distance to leading vehicles, the system dynamically adjusts speed to maintain a safe threshold of 0.3 meters. This project demonstrates the practical application of the MATLAB Support Package for Arduino, bridge-linking high-level computational logic with physical hardware actuators and indicators.
Note
Methodological Significance: This project functions as an intensive case study in Hardware-in-the-Loop (HIL) simulation and modular system design. By establishing a robust bi-directional communication bridge between MATLAB's high-level numerical processing and the Arduino's real-time peripheral control, the architecture validates the feasibility of deploying complex analytical models onto resource-constrained embedded hardware. This methodology underscores the importance of architectural portability and cross-platform algorithmic alignment in modern automotive control engineering.
| # | Resource | Description |
|---|---|---|
| 1 | Project Report | Comprehensive academic report on system design and results |
| 2 | Technical Specification | Technical architecture and control logic specification |
| 3 | ACC Algorithm | Step-by-step logic for speed and proximity regulation |
| 4 | Source Code | Primary MATLAB implementation script |
| 5 | Arduino Working Model | Physical hardware implementation and operational states |
| 6 | Hardware Components | Visual documentation of standalone project components |
| 7 | Tinkercad Simulation | Virtual prototyping results and circuit logic views |
| 8 | MATLAB Repository | Academic repository for Computational Methods and Modeling |
| 9 | Engineering Repository | Master repository for MEng Computer Engineering |
| Feature | Description |
|---|---|
| Normal Mode | Manual velocity regulation via potentiometers with simulated kinetic drag. |
| Cruise Control | Automated maintenance of a user-defined target velocity. |
| Adaptive Logic | Proximity-aware deceleration when safety buffers are breached (< 0.3m). |
| Real-time Feedback | Standard LCD telemetry showing vehicle speed and operational mode. |
| Safety Indicators | Dual-LED system for real-time acceleration (Green) and braking (Red) status. |
| Interactive Simulation | High-fidelity Web PWA mirroring the MATLAB control logic for hardware-agnostic system validation. |
| Hardware Integration | Direct interface with Arduino Uno and HC-SR04 Ultrasonic sensors via MATLAB API. |
Tip
Cyber-Physical Feedback Control: The transition from manual open-loop actuators to automated Closed-Loop Feedback Control is a fundamental paradigm in automotive engineering. By synthesizing real-time telemetric distance data from the HC-SR04 and mapping it through a deterministic control law, this system achieves autonomous speed regulation. Implementing concepts such as the Constant Time-Gap Policy (CTGP) is essential for ensuring "String Stability," which prevents the propagation and amplification of speed disturbances within vehicle platoons.
- Numerical Computing: MATLAB (R2023a+) & Control System Toolbox
- Embedded Controller: Arduino Uno R3 (ATmega328P Architecture)
- Hardware Abstraction: MATLAB Support Package for Arduino Hardware
- Hardware Peripherals: HC-SR04 Ultrasonic Sensor, 16x2 I2C/Parallel LCD Display
- Simulation Web Engine: Vanilla JavaScript (ES6+), CSS3 Flexbox/Grid, and Web Audio API
- Deployment & Architecture: Progressive Web App (PWA) with Service Worker offline caching
- Prototyping Environment: Tinkercad for electrical schematic validation and transient logic modeling
- Libraries & Drivers:
Ultrasonic.h,LiquidCrystal_I2C.h(Hardware),sw.js(Web)
ADAPTIVE-CRUISE-CONTROL/
│
├── .github/
│ └── workflows/
│ └── deploy-pages.yml # GitHub Pages Deployment Workflow
│
├── docs/ # Formal Documentation
│ ├── Matlab Logo.png # MATLAB Branding Asset
│ ├── SPECIFICATION.md # Technical Architecture & Specification
│ └── web/ # Interactive ACC Simulation (GitHub Pages)
│ ├── index.html # Simulation Entry Point
│ ├── style.css # Design System & Styles
│ └── simulation.js # ACC Engine (JS Port of MATLAB Logic)
│
├── Matlab Project/ # Academic Deliverables
│ ├── Final Report/ # Final Project Report & MATLAB Source
│ │ ├── Adaptive Cruise Control Final Report.pdf
│ │ ├── Final Report Cover Page.pdf
│ │ ├── Group32_Amey_Brano_Nandu.m # Team MATLAB Source Code
│ │ └── Summer_2023_Final_Project_Report_&_Presentation_Instructions.pdf
│ │
│ ├── Preliminary Report/ # Initial System Architecture Report
│ │ ├── Adaptive Cruise Control Preliminary Report.pdf
│ │ ├── Cover Page.pdf
│ │ ├── Group 32 - Adaptive Cruise Control Preliminary Report.pdf
│ │ └── Summer 2023 - Primary Report Project Instructions.pdf
│ │
│ ├── Adaptive Cruise Control.pdf # Project Overview Document
│ ├── Project Groups.pdf # Group Allocation Record
│ └── Smart Parking Management System.pdf # Supplementary Reference
│
├── Source Code/ # Core Implementation
│ ├── figures/ # Visual Documentation Assets
│ │ ├── Arduino Working Model/ # Real-world Hardware Implementation
│ │ ├── Hardware Components/ # Standalone Component Visuals
│ │ ├── Tinkercad Simulation/ # Virtual Prototyping Results
│ │ ├── Adaptive Cruise Control Flowchart.png
│ │ ├── Adaptive Cruise Control Overview.jpg
│ │ ├── Component Table.jpg
│ │ └── Project Gantt Chart.jpg
│ │
│ ├── Adaptive Cruise Control.m # Main MATLAB Control Script
│ └── Adaptive Cruise Control Algorithm.txt# Logistical Algorithm Steps
│
├── .gitattributes # Git Configuration
├── .gitignore # Git Ignore Rules
├── CITATION.cff # Citation Metadata
├── codemeta.json # Project Metadata (JSON-LD)
├── LICENSE # MIT License
├── README.md # Main Documentation
└── SECURITY.md # Security Policy & Posture- MATLAB R2023a+: Required for running the ACC control script. Download MATLAB
- MATLAB Support Package for Arduino Hardware: For Arduino-MATLAB interfacing. Install Package
- Arduino Uno R3: Physical microcontroller for hardware deployment.
- Git: For version control and cloning. Download Git
Warning
Hardware Configuration
Ensure the Arduino Uno is properly connected via USB and recognized by MATLAB before executing the control script. The HC-SR04 ultrasonic sensor and LCD display must be wired according to the Technical Specification.
Open your terminal and clone the repository:
git clone https://github.com/Amey-Thakur/ADAPTIVE-CRUISE-CONTROL.git
cd ADAPTIVE-CRUISE-CONTROLIn the MATLAB Command Window, install the required hardware support:
matlabAddonInstallerSearch for and install "MATLAB Support Package for Arduino Hardware".
Launch the primary control script in MATLAB:
run("Source Code/Adaptive Cruise Control.m")Tip
Simulation First
Before deploying on physical hardware, prototype and validate circuit logic using the Tinkercad simulation:
You can also explore the interactive browser-based simulation, no hardware or MATLAB required:
Comprehensive inventory of the physical and electronic assets utilized in the ACC architecture.
Quantified technical breakdown of active and passive components.
| Name | Quantity | Component |
|---|---|---|
| U2 | 1 | Arduino Uno R3 |
| S1, S2, S3, S4, S5 | 5 | Pushbutton |
| R1, R2 | 2 | 10 mΩ Resistor |
| R3, R4, R5 | 3 | 50 mΩ Resistor |
| U3 | 1 | LCD 16 x 2 |
| Rpot2 | 1 | 250 kΩ Potentiometer |
| DIST1 | 1 | Ultrasonic Distance Sensor |
| D1, D2 | 2 | Red LED |
| R6, R7 | 2 | 10 kΩ Resistor |
Core processing unit and the primary visual monitoring dashboard.
Arduino Uno R3: Technical Pinout & Architecture

LCD Display (16x2): Pin Configuration & Interface

Environmental perception via ultrasonic telemetry and modular circuit interconnects.
| Ultrasonic Sensor (HC-SR04) | Jumper Wires: Connectivity |
|---|---|
![]() |
![]() |
| Resistor Color Codes | Breadboard Technical Layout |
![]() |
![]() |
Tactile actuators and variable resistance inputs for manual system overrides.
| Potentiometer Control | Push Button | Digital Input |
|---|---|---|
![]() |
![]() |
![]() |
Detailed virtual breadboard layout demonstrating sensor-to-controller mapping.

Electrical representation of the ACC logic, highlighting terminal interconnectivity.

Visualizing discrete state transitions between manual cruise and autonomous adaptive speed control.
| Welcome Message | Group Details |
|---|---|
![]() |
![]() |
| Initial Resting State | Cruise Active |
![]() |
![]() |
| Cruise (Zero Speed) | Adaptive (Safe) |
![]() |
![]() |
Macro-perspective of the finalized Arduino assembly within the hardware enclosure.

Real-time performance of the physical system across various cruise and safety scenarios.
| Activation Screen | Member Display |
|---|---|
![]() |
![]() |
| System Resting | Cruise Velocity |
![]() |
![]() |
| Adaptive Control | Hazard Detected |
![]() |
![]() |
Strategic timeline and logic execution architecture from project inception to final realization.
Algorithmic sequence for sensory feedback, speed regulation, and adaptive braking.

Phased development lifecycle including hardware selection, circuit design, and code optimization.

This repository is openly shared to support learning and knowledge exchange across the academic community.
For Students
Use this project as reference material for understanding MATLAB-Arduino Interfacing, Sensor Fusion, and Closed-Loop Control Logic. The source code and simulation documentation are available for study to facilitate self-paced learning and exploration of cyber-physical systems and automated control architecture.
For Educators
This repository serves as a practical implementation of real-time embedded systems. Attribution is appreciated when utilizing content.
For Researchers
The technical specification and modular code structure provide insights into the behavioral modeling of adaptive cruise systems in a controlled academic environment.
This repository and all linked academic content are made available under the MIT License. See the LICENSE file for complete terms.
Note
Summary: You are free to share and adapt this content for any purpose, even commercially, as long as you provide appropriate attribution to the original author.
Copyright © 2023 Amey Thakur
Created & Maintained by: Amey Thakur
Academic Journey: Master of Engineering in Computer Engineering (2023-2024)
Course: GENG 8030 · Computational Methods and Modeling for Engineering Applications
Institution: University of Windsor, Windsor, Ontario
Faculty: Faculty of Engineering
This project showcases the Adaptive Cruise Control (ACC) system, a real-time engineering solution developed to address automotive safety and efficiency. It serves as a milestone in the academic study of computational methods and modeling for engineering applications.
Connect: GitHub · LinkedIn · ORCID
Grateful acknowledgment to my Major Project teammates, Nandeshwar Royal Uppalapati and Brano Bruno Barshmen, for their collaborative excellence and shared commitment throughout the semester. Our collective efforts in synthesizing complex datasets, developing rigorous technical architectures, and authoring comprehensive engineering reports were fundamental to the successful realization of our objectives. This partnership not only strengthened the analytical depth of our shared deliverables but also provided invaluable insights into the dynamics of high-performance engineering teamwork.
Grateful acknowledgment to Jason Horn, Writing Support Desk, University of Windsor, for his distinguished mentorship and scholarly guidance. His analytical feedback and methodological rigor were instrumental in refining the intellectual depth and professional caliber of my academic work. His dedication stands as a testament to the pursuit of academic excellence and professional integrity.
Special thanks to the mentors and peers whose encouragement, discussions, and support contributed meaningfully to this learning experience.
Authors · Overview · Features · Structure · Quick Start · Hardware Components · Tinkercad Simulation · Working Model · Development Roadmap · Usage Guidelines · License · About · Acknowledgments
MATLAB Repository · 🚘 Adaptive Cruise Control
Computer Engineering (M.Eng.) - University of Windsor
Semester-wise curriculum, laboratories, projects, and academic notes.











.jpg)
.jpg)
.jpg)
.jpg)


.jpg)
.jpg)
.jpg)
.jpg)