Interactive Demo
Anti-pinch control of a vehicle window in real time, implemented as WebAssembly components.
This demonstration runs with the same WebAssembly binaries intended for ECU deployment – in the browser, without modification. The components are written in Rust, compiled once to WebAssembly, and connected via formal WIT interfaces.
What the demo concretely shows:
- Single artefact – the same
.wasmfiles running here in the browser are designed to run unchanged on the target ECU - Versioned interfaces – WIT interfaces such as
aptiv:antipinch/motor-driver-v2@0.1.0define the component protocol in a machine-readable, toolchain-neutral format
Three WebAssembly components work together:
- Anti-Pinch – Detects pinch forces via motor current measurement
- Motor Driver – Simulates the window lift motor with realistic current behaviour
- Soft Start/Stop – Smooth acceleration and deceleration via PWM ramps
Use the Up/Down buttons to move the window. When the Auto switch is active, the window runs automatically until it reaches the end stop or a pinch event is detected.
Once the window is open far enough (more than 14 % opening), the Finger switch becomes available. This reveals virtual fingers that can be positioned anywhere in the 20 %–85 % opening range using the Finger slider, placing them in the window’s path to simulate a pinch event. The slider is bounded at the bottom by the current window position — the fingers cannot be placed below the window’s top edge.
Outside the 20 %–85 % range the Finger switch is disabled and the slider has no effect.
Window Lift Control
Motor Control Signals
Next: News · Publications


