Seatback Music and Flight-Tracker App for a Tiny Armrest Display
System DesignModel answerLast updated
Design a resilient, accessible, modular seat-unit app on a 4-inch armrest touchscreen, covering telemetry delivery, offline music sync, shake-tolerant input, lazy module loading and KPIs.
Scenario
An airline wants a passenger app for a small 4-inch touchscreen built into each armrest. The first release has two features: a live view of the flight (position on a map, altitude, time remaining) and a music player. More features, such as meal ordering and duty-free shopping, will arrive later.
Operating conditions
- Physical setting: The aircraft often shakes, so fingers miss targets and touches get interrupted. The UI must tolerate this.
- Network: Connectivity is unreliable. Music is stored on the seat unit itself. Flight data is sent to the seat over the aircraft's internal LAN by an on-board server.
- Accessibility: The app needs a high-contrast mode and must be usable by passengers with limited motor control or low vision.
- Growth: New modules must be addable later without making the first launch slower.
What to deliver
- API and data model: How does a seat unit get flight telemetry from the on-board server? How are playlists and tracks stored and kept in sync?
- UI/UX approach: A navigation structure that needs very few taps and copes with an unsteady, small interface.
- Client architecture: A module-loading strategy that keeps the app responsive as features are added.
- Metrics: Three KPIs that capture both passenger satisfaction and system health.
State your assumptions (seat count, screen resolution, catalog size, update rate) and explain the trade-offs you make.
Hints
Hint 1
Estimate the numbers first: telemetry for a few hundred seats is tiny, so the interesting problem is resilience when data stops, not bandwidth.
Hint 2
For turbulence, think about when an action fires (touch-down vs release), how far a finger may drift before cancelling, and how to undo mistakes without modal dialogs.
Hint 3
Split the app into a small always-present core shell and independently loadable, isolated modules that talk to the shell through a narrow, versioned interface.
Model answer
Medium Try it yourself first — then compare your approach, complexity and edge cases.
What this question is really about
This is a constrained-client design problem, not a large backend one. The seat unit is an edge device that may lose connectivity, is operated by shaky fingers, and must keep growing in features without slowing down. A weak answer describes a generic cloud music app; a strong one is offline-first and designed around the physical setting.
1. Requirements and assumptions
- Hardware: about 350 seats, each with a ~480x800 px screen, a modest ARM CPU, 1-2 GB RAM and ~32 GB flash.
- Telemetry: the server publishes position, altitude, speed and ETA at 1 Hz, about 200 B per frame. 350 seats x 200 B x 1 Hz is roughly 70 KB/s if sent individually, which is trivial.
- Media: about 3,000 tracks at ~5 MB is ~15 GB, stored locally and refreshed on the ground (for example monthly at the gate), not in the air.
- Targets: cold start under 2 s, tap feedback under 100 ms, telemetry staleness under 3 s at p95, and full function with the flight server unreachable.
- Out of scope for v1: payments.
2. API and data model
Telemetry. Push with a pull fallback.
UDP multicast 239.x.x.x:5000 -> TelemetryFrame (1 Hz, protobuf)
GET /v1/telemetry/snapshot -> latest frame (boot, gap recovery)
GET /v1/flight -> origin, destination, route polyline
Multicast sends one packet to all seats, so server load does not depend on seat count. Each frame carries a monotonically increasing seq; if the client sees a gap, or nothing for more than 5 s, it calls /snapshot.
TelemetryFrame { seq, server_ts, lat, lon, alt_ft, ground_speed_kt,
heading_deg, phase, eta_utc, time_to_dest_s }
The client keeps the last frame and its receive time. The UI always shows the last known values with a staleness label ("updated 40 s ago") and never a blank screen. Between frames the plane icon is dead-reckoned from speed and heading so movement looks smooth.
Music sync. The catalog is versioned and content-addressed.
GET /v1/catalog/manifest?since=V -> {version, added[], removed[], playlists[]}
GET /v1/content/{sha256} -> media blob (ground sync)
Track { id, title, artist, duration_s, sha256, path }
Playlist { id, version, name_i18n, track_ids[] }
SeatState{ flight_id, now_playing, position_s, queue[], favorites[], a11y_prefs }
Updates are atomic: download blobs, verify hashes, then switch the manifest pointer, so a half-synced catalog never goes live. SeatState lives in local SQLite and is wiped at the end of the flight, so passenger data stays on the seat.
Local outbox. Analytics (and later, orders) are written to a SQLite outbox with a UUID per event. A background worker batch-posts with exponential backoff; the UUID serves as an idempotency key, which matters once orders exist.
3. UI/UX strategy
Navigation. A home screen with a 2x2 grid: Map, Music, Now Playing, Settings/Accessibility. Future modules become more tiles on a second page. Every primary action is at most two taps away, and a persistent bottom bar holds Home and Play/Pause. Shortcuts such as "Continue listening" avoid deep browsing.
Turbulence-tolerant input.
- Targets of at least ~12 mm with ~3 mm gaps, and no more than about six per screen.
- No fine sliders: volume uses large -/+ buttons.
- Actions fire on release inside the target, not on touch-down.
- Gesture state machine: a press that drifts beyond a slop radius (~8 mm) cancels; a contact shorter than ~50 ms is treated as a bump and ignored; a large contact area (palm) cancels; a long hold triggers a secondary action.
- Destructive actions show an Undo toast rather than a confirmation modal.
- Screen state is persisted so a crash or power cycle restores the same screen and playback position.
Accessibility. A high-contrast theme (7:1 or better), a 1.5x text scale that reflows to a single column, audio screen-reader output through the headphone jack, and switch-style navigation with physical armrest buttons (next, previous, select) plus dwell-to-select. Preferences persist for the flight.
4. Client architecture and module loading
Core shell (~15 MB, in base image)
Router + app state machine | gesture engine | a11y/theme | i18n
Telemetry service | native media player | SQLite | outbox | module host + SDK
| loads on demand
[Map] [Food ordering] [Duty-free] (signed bundles)
- Module contract: each module ships a manifest
{id, version, minSdk, entry, icon, routes, permissions}. - Isolation: modules run in their own WebView or JS context and use only a typed SDK (navigation, outbox, theme, i18n, telemetry subscription). A crashing module returns the user to Home while the shell keeps running.
- Loading: shell and Music load eagerly; Map is prefetched in idle time after first paint; commerce modules lazy-load on first tap behind a skeleton screen, taking well under 300 ms since bundles are on local flash. Per-airline or per-route feature flags in the flight manifest enable modules.
- Deployment: bundles are signed and verified, rolled out on the ground, with the previous version kept for rollback.
5. KPIs
- Task success rate on first tap (satisfaction): share of taps that hit the intended target without a retry or an undo. It directly measures turbulence-tolerance; target above 95%.
- Time to first useful screen and tap latency (health): cold start p95 under 2 s and tap-to-feedback p95 under 100 ms, tracked per device model.
- Telemetry freshness and crash-free sessions (health): p95 staleness under 3 s, plus the percentage of sessions with no shell or module crash (target above 99.9%). Optionally, session length of music playback as an engagement signal.
Trade-offs and common mistakes
- Multicast is efficient but lossy, hence sequence numbers and a snapshot fallback.
- Isolated modules cost memory and startup time, but protect the core, which is the right trade for a safety-adjacent, always-on device.
- Mistakes: assuming constant internet, using small sliders or touch-down actions, loading every module at boot, blank screens when data goes stale, ignoring accessibility until the end, and syncing content in flight.