How mhieu1296/led_xe_buyt_transerco works
Project type and purpose
• This is a single-page, front-end web application that simulates the LED-display signs used on Hanoi’s public buses.
• It isn’t a multi-tier or server-based system; it runs entirely in the browser, using HTML/CSS/JavaScript to render and animate “LED” segments and to accept user input (route info, modes, controls).
File structure
• Top-level HTML pages:
• index.html – the main display and control interface
• input.html – the form where the user enters route code, endpoints, company name
• Static assets:
• assets/fonts/*.otf – custom LED fonts
• Style layer:
• css/main.css – layout, positioning of LED grid
• css/input.css – styling the data-entry form
• css/font.css – font face declarations
• Behavior layer (JavaScript):
• js/window_onload.js – bootstraps the app on page load
• js/theme.js – theme switching logic (e.g. night mode)
• js/dieu_khien_LED.js – control module: starts, stops, freezes, reverses LED
• js/hien_thi_LED.js – display module: runs each “mode,” schedules timers, toggles individual LED cells
README for additional insights
• There are six display “modes” (Xe điện 1, Xe điện 2, etc.), each a sequence of timed show/erase effects.
• Core functions: show route code, endpoints, logos, company names, blink code, reverse scroll, freeze, clear.
• Parameters (route code, names) are user-configurable and stored client-side (likely localStorage).