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.

Clean speed gauge is 0 km/h.
P
mode
Off
17:54
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.

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.

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.

Dashboard composer

Arrange gauges as widgets

Preview settingsWide · 12x4 · Metric · AmberLocal document
Layout
Gridx
Theme
State
Normal driving state for balanced readability.Local document
LayoutWideGrid12x4Widgets4
Select a widget on the canvas
Clean speed gauge is 60 km/h.
Range is 218 km.
Average speed is 45 km/h.
Clean RPM gauge is 2200 rpm.

  1. v3.0

    Canvas instrument system

    The dashboard started moving from one hand-built cockpit toward configurable gauge families and drivetrain-aware layouts.

    Changed
    • 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.
  2. v2.1

    Study refresh

    The page moved to the current Design Lab study structure used by Smiley Spheres.

    Changed
    • 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.
  3. v2.0

    Simulation cockpit

    The dashboard became a richer cockpit with multiple powertrains, procedural audio, and controller input.

    Changed
    • 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.
  4. v1.0

    Initial dashboard

    First working browser dashboard with core gauges and a testable vehicle simulation.

    Included
    • 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.