Case study · Learning Time VR
One click, twenty-five headsets
A teacher picks a lesson on a laptop and a cart of VR headsets opens it. Here’s how that worked on the platform I built as founding engineer, what school Wi-Fi and real classrooms broke, and what I’d build differently.
The job
A class of up to 25 students, each in a Pico headset, and one teacher who isn’t wearing one. The teacher runs everything from a laptop: picks a lesson, moves the class through it, opens a VR app, brings everyone back. The headsets belong to the school, live on a cart, move between rooms and buildings, and sit on Wi-Fi that drops.
By the time I handed the platform off in June 2026 there were 200+ headsets in the field. Every school on the full system ran on the same path from a teacher’s click to a headset; a few had standalone headsets that never connected to it.
Two roads to a headset
The first design decision was the one that mattered most: everything that could run in the headset’s browser, did.
- Web lessons ride the live class. The student page in each headset is itself a member of the class room, the same real-time room the teacher’s dashboard is in. When the teacher picks a web lesson, no command goes to any device. The pages see the change and load it.
- VR apps need the device. They go through a second channel: one WebSocket per headset to a small Android service I wrote that runs on every headset and opens or closes apps through Pico’s enterprise device API.
The second road is where the trouble lived. Switching between native apps meant a couple of seconds of Pico’s own system screens flashing into view, a white boot screen, and Android quietly refusing to start an app from the background. A web lesson has none of that, and it works on any headset with a browser. So the native path stayed, for the apps schools already owned, and new content went to the web.
Headsets know a name, not an id
Each headset signs in with its serial number and gets back a token that says which group it’s in. From then on it’s addressed by that group’s name, like “Room 201,” which is what a school admin types and what a teacher sees. The database has its own ids, but no headset ever sees one. When a teacher launches something, the server sends one command per group the teacher is assigned to, and the switchboard fans it out to every live socket filed under that name.
What keeps it working on school Wi-Fi
Most of the code isn’t the happy path. It’s these:
- Skip what’s already done. The server doesn’t send a launch to a headset that’s already on that page or in that app, and the headset ignores any command it has already run. A double click, a retry or a replay can’t restart a student’s app.
- Commands belong to a lesson. Every launch carries the lesson it’s for. When the teacher moves on, the old command is dropped, so nothing from a previous lesson can arrive late and pull a student backwards.
- Late joiners catch up. A headset that connects mid-class gets the group’s last command, but only if it’s for the lesson the group is on now and less than an hour old.
- Notice a dead connection fast. The headset pings every 10 seconds, the server every 30. When the link drops, the headset retries at 2, 4, 8 seconds and up to two minutes, with jitter so a room of headsets coming back from a Wi-Fi blip doesn’t hit the server at once.
- Sleep at night. Outside school hours the helper drops into quieter modes that check in every five minutes, then once a day, instead of every 10 seconds.
One teacher at a time
Teachers share carts, and one teacher’s launch must never land in another teacher’s lesson. So each group has exactly one controlling teacher, recorded in the database, and every launch is checked against it before anything is sent. Control doesn’t time out. If a second teacher clicks, nothing reaches the headsets; they get a warning that says who has the cart, what’s running and for how long, and a button to take over. Taking over closes whatever VR app the first teacher had open, then half a second later brings every headset back to the browser on the new teacher’s class.
The fleet console
In May 2026 I added a console for administrators: a grid of every headset, refreshed every three seconds, showing whether it’s connected, what it’s running and how long since it checked in. From there an admin can open a page or an app on one headset or a whole group, stop an app, or send a headset “to the fish”: stop the browser and cold-start the kiosk page on the waiting scene, which is the fix for a headset that’s stuck somewhere it shouldn’t be. The same commands are open to Claude Code through a skill, so I could check or fix a classroom’s headsets from a terminal without touching one.
What the classroom broke
The headset app went through 63 versions between August 2025 and May 2026. Many of them came from something a classroom found:
- Headsets dropping every 15 seconds. The server never answered the headsets’ pings, so each one decided the link was dead and reconnected.
- “VR” inside “overseas.” A check that closed VR apps matched the letters “vr” inside an unrelated name, force-stopped the browser, and put it in a loop.
- Stopping the wrong thing. Closing apps also closed Pico’s own mixed-reality service, which broke WebXR until the headset was rebooted.
- A reconnect that kicked students out. A headset reconnecting pulled its student out of a YouTube VR video about ten seconds in.
- An audit log that ate the database. One log table grew to 30 million rows and 13 GB before I caught it.
I fixed many of these during or between classes, testing on my own headset against a preview build of each change, mostly with Claude Code writing the fix while I watched the room.
What I’d do differently
I built this fast, with AI writing most of the code, and the gaps are the kind that speed leaves:
- Close the loop on acknowledgements. Headsets confirmed every command, and the server recorded it, but nothing resent a command that wasn’t confirmed. I’d also built a queue for headsets that were offline and never wired it in.
- One rule, everywhere. The fleet console sent its commands straight to headsets and skipped the one-teacher check. An admin is usually right to override, but it should be a decision in the code, not a gap.
- Test the path that matters. There were tests, but none on the fan-out or the control check. That’s the code a classroom depends on.
- Keep the docs honest. The repo’s docs described at least one mechanism that the code never had. When an AI writes code and docs together, the docs need checking against the code like anything else.
- Make the device side less trusting from the start. It’s cheap to tighten on day one and expensive later. The co-founder who took over the platform hardened it after I handed off, and found a reconnect bug in the headset app that I hadn’t.
To be plain about the scale: the largest real group was 25 headsets. I never load-tested the fan-out, so I can’t tell you where it breaks.
Part of Learning Time VR. Related: Two people or two thousand. Questions: nick@bisesi.dev.