This repository contains a series of self-driving car simulations in MATLAB. The simulations are mainly focused on Controlls, Sensor Fusion, State Estimation and Localization in the context of Self-Driving Cars.
This project uses the principlas of computer vision and control to simulate a lane keeping assist system for self driving cars in simulink. The computer vision toolbox in simulink is used to detect the lane lines, and a PID controller is utulized to drive the vehicle in between the lane lines.
First, the sequence of images captured by the camera are converted to the HSV color space. A threshold is applied to the S-channel in the HSV color space to isolate the lane lines. The binary image is transformed using a projective transformation to obtain a bird's eye view of the scene. Finally, the bird's eye view is processed using a 2D point cloud analyzer in a Simulink User-defined function to detect the left and right lanes.
The dynamics of the car is implemented and a PID controller drives the car towards the specified Goal while avoiding the obstacle in the map. The dynamics of the car and the controller are all implanted in Car.m file using object-oriented programming in MATLAB. The main function runs the car model and plots the results to generate the GIF file for this simulation.
NOTE: Run the Main.m file in each of the the folders for the simulation to start.
The code associated with each of simulations are categorized in different folders. The code is standalone and should run on any MATLAB version without requiring additional dependencies.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。