Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

105 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TRAFFI🚦

Overview

TRAFFI is a dynamic traffic light control simulation aimed at optimizing traffic flow by reducing car wait times at junctions. The project features a user-friendly interface where users can create and simulate different junctions. The system will intelligently adjust traffic light timings based on real-time conditions to improve efficiency. The backend will control Three.js objects to visualize the junction in 3D.

Features✨

  • React-based GUI: An intuitive front-end interface for junction selection and traffic visualization.
  • Graph-based Traffic Control: The system will use graph structures to model junctions and determine optimal traffic light patterns.
  • Dynamic Traffic Light Adjustments: Prioritizes emergency vehicles and optimizes green light distribution.
  • Real-time Simulation: Cars will be dynamically added and removed during the simulation.
  • Three.js Integration: The junction visualization will be implemented using Three.js, controlled by the backend.

Tech Stack🛠️

Installation & Usage🚀

Prerequisites

Recommended Versions

  • Node ^=20.12.0
  • npm ^=10.5.0
  • JDK ^=21
  • Apache Maven ^=3.9.9

Running the Backend

cd Backend
mvn spring-boot:run

First time running the Frontend

cd Frontend
npm install
npm start

Second time running the Frontend

cd Frontend
npm start

Roadmap🗺️

  • Frontend
    • Create the hero section
    • Create navbar
    • Adding smooth scroll
    • Implement Three.js visualization
  • Backend
    • JSON parsing
    • Car class
    • Lane class
    • TrafficLight class
    • TraffiApplication class
    • Junction class
    • Edge-cases
  • Both
    • Create Start Simulaion logic
    • Car's web socket
    • traffic light's web socket
    • Implement Pause/Resume logic
    • Provide statistics

Contribution🤝

Contributions are welcome! Feel free to submit issues or pull requests.

License📄

This project is licensed under the MIT License.

Credits🥰

UI inspiration - Grok (Before the renovation) & Curser

Private car model - kulonee

Motorcycle model - animanyarty

Police model - Daniel Zhabotinsky

Ambulance model - Jasmin Daniel

About

TRAFFI is a modern traffic junction simulator designed to rethink how we manage urban traffic flow. Powered by precise traffic light logic, it delivers a seamless top-down 2D experience.

Topics

Resources

Stars

Watchers

Forks

Releases

Used by

Contributors

Languages