Car Dashboard

A live browser cockpit where gauges, drivetrain simulation, engine sound, gamepad input, and acceleration tests read from one simulated car.

Speed, RPM, fuel, gear state, audio, and controls update from the same loop.

Loading cockpitMounting the simulation, gauges, and input loop.
Clean speed gauge is 0 km/h.
P
mode
Off
13:53
000000 km
Clean speed gauge is 0 km/h.

Vehicle configuration

Change the drivetrain setup and apply it to the live cockpit simulation.

Try the acceleration test
  • Astro
  • React
  • TypeScript
  • Web Audio API
  • Gamepad API
  • Motion
  • Deterministic simulation

The dashboard is assembled from small pieces, but the visible result behaves like one cockpit.

Instrument layer

Speed, RPM, fuel, coolant temperature, gear state, and the on-board computer pages all share the same live car state.

Simulation layer

Car, chassis, powertrain, transmission, wheels, brakes, and fuel storage are modeled as focused TypeScript classes with unit coverage.

Input layer

Keyboard and Gamepad API input are merged every animation frame, while cockpit controls stay outside the instrument panel.

Audio layer

A procedural Web Audio graph follows RPM, throttle, engine type, and cylinder count without relying on recorded engine samples.

The same gauges, driver controls, and on-board computer are also mounted outside the car frame for inspection:open the instrument primitives.

A fresh car instance starts, shifts into Sport, runs full throttle, and reports the resulting acceleration numbers.

Benchmark inputs

Each control changes one physical assumption before the same acceleration run is replayed.

Engine power
Changes acceleration and drag-limited top speed.
Vehicle mass
Changes inertia, so the same engine needs more time to reach speed.
Rev limit
Changes shift timing and the RPM window used by the automatic transmission.
Fuel model
Keeps the dashboard values live while the benchmark still runs deterministically.
Loading acceleration benchHydrating the replay controls.

Configurable run

Change the car setup and compare how quickly the simulated vehicle reaches speed.

200 HP
80600
1500 kg
8002500
6000 rpm
40009000
73%
50100

The audio is generated in the browser. No engine samples are played back.

Loading sound playgroundPreparing the Web Audio controls.

Sound playground

Listen to how RPM, throttle, cylinders, and engine type change the procedural engine sound.

Engine type
Cylinders
800 rpm
4008000
0%
0100

Keyboard and controller input feed the same simulation loop.

The durable part of the study is the shared state model behind the instruments.

The cockpit is becoming a configurable instrument system instead of one fixed dashboard layout.

Canvas gauge recipes

Round dials, segmented strips, compact metrics, ticks, labels, arcs, and needles now render from reusable Canvas recipes.

Shared dashboard snapshot

The simulation is translated into one instrument-ready state, so visual gauges do not need to know how the car model is built.

Drivetrain-aware layouts

Combustion, electric, and hybrid dashboards can choose different instrument presets while staying on the same data contract.

The same gauge recipes can now be arranged, bound to vehicle data, tuned, saved, and reloaded as a dashboard document.

Loading dashboard composerPreparing the editor surface.

Dashboard composer

Arrange and edit gauges

Dashboard settingsWide · 12x4 · Metric · AmberLocal document
Layout
Gridx
Theme
State
Normal driving state for balanced readability.Local document
LayoutWideGrid12x4Widgets4
1Select widget2Edit gauge3Save dashboard
Choose a gauge on the canvasThe gauge editor opens after a widget is selected.
Clean speed gauge is 60 km/h.
Range is 218 km.
Average speed is 45 km/h.
Clean RPM gauge is 2200 rpm.

  1. Vehicle physics

    Vehicle-specific road load, tyre grip, shifting, braking, and energy recovery now run through one portable simulation document.

    • Separated aerodynamic drag, rolling resistance, tyre traction, and mechanical efficiency instead of hiding them in one drivetrain-loss value.
    • Added automatic shift schedules with kickdown, hysteresis, and timed torque interruption while preserving the manual transmission path.
    • Added separate friction braking and blended regenerative braking that returns recovered energy to the EV or hybrid battery.
    • Added calibrated reference configurations for the Hyundai i10, Mazda2, BMW 220d, Porsche 911 Carrera, Kia Niro HEV, Kia EV6 Air RWD, and three-motor GMC Hummer EV Pickup 3X.
    • Kept benchmark and live journey results deterministic across frame rates, with saved vehicle configurations restored after reload.
  2. Canvas instrument systemThe dashboard started moving from one hand-built cockpit toward configurable gauge families and drivetrain-aware layouts.

    • Added a Canvas gauge renderer with reusable primitive recipes for dials, strips, ticks, labels, arcs, needles, icons, and readouts.
    • Added an instrument snapshot layer that separates simulation values from visual gauge recipes.
    • Added drivetrain-aware layout and preset selection for combustion, electric, and hybrid dashboard variants.
    • Added a component gallery for inspecting the new gauge vocabulary outside the live cockpit.
    • Added a dashboard composer prototype for arranging, binding, tuning, saving, and reloading gauge modules.
  3. Study refreshThe page moved to the current Design Lab study structure used by Smiley Spheres.

    • Moved the public URL to /design-lab/studies/car-dashboard.
    • Reframed the page around the working demo, acceleration test stand, procedural audio, input model, release log, and references.
    • Kept the old case-study URL as a permanent redirect.
  4. Simulation cockpitThe dashboard became a richer cockpit with multiple powertrains, procedural audio, and controller input.

    • Added gasoline, diesel, and electric powertrain variants.
    • Added automatic and manual transmission models with ECU-driven shift behavior.
    • Built procedural engine audio with Web Audio API oscillators, filtered noise, and soft clipping.
    • Added Gamepad API support with analog throttle and brake triggers.
    • Added the configurable acceleration benchmark and on-board computer pages.
  5. Initial dashboardFirst working browser dashboard with core gauges and a testable vehicle simulation.

    • Core instruments: Speedometer, Tachometer, circular gauges, linear gauges, and fuel level.
    • Physics classes for car, chassis, engine, fuel tank, transmission, and wheels.
    • Manual gear-shift logic with transmission utility tests.
    • Full dashboard layout and component previews for the instrument primitives.

Source material and browser APIs that shaped the study.

  1. WWDC 2024: Say hello to the next generation of CarPlay design systemAutomotive interface reference for adaptable dashboard surfaces.
  2. Misha Charoudin on YouTubeVehicle behavior and performance reference for powertrain feel.
  3. Web Audio APIBrowser audio graph used for the procedural engine sound.
  4. Gamepad APIBrowser controller surface used for analog throttle and brake input.