Hacks & Buildsraspberry-pisecuritysmart-home
Glovebox turns a Raspberry Pi Zero in a Tesla's USB port into a dashcam that backs itself up to your NAS, and holds a key that can drive the car
Glovebox is free software that makes a Raspberry Pi Zero 2 W the Tesla's dashcam drive, copies Sentry clips home to a NAS over Wi-Fi, and keeps the car awake with a Bluetooth key strong enough to drive it.

Every minute after you park, a Raspberry Pi in your glovebox asks your Tesla to close its charge port. That’s how Glovebox keeps the car awake long enough to back up your dashcam footage.
The project comes from Sasha Papo, who goes by lubaxe on GitHub, and it “was inspired by, and started from, teslausb.” The trick underneath is old. A Pi Zero can pretend to be a USB stick, so the car writes TeslaCam footage to it like any other drive, and the Pi reads that footage from copy-on-write snapshots so it never touches a file the car is still writing.
Home is the trigger. Glovebox checks every 30 seconds whether your NAS answers, and once it has for 20 seconds, “the car is home.” Then it copies “Sentry first, then Saved, newest event first, so the important footage gets out before the car sleeps,” according to its how-it-works notes. Drive off halfway through and it “picks up where it left off.”
The catch is the car. “A sleeping Tesla cuts USB power,” the README says, and Sasha tested what actually keeps it up. Waking the car, reading its state, re-setting the charging current and Keep Accessory Power On “all left the car cutting the USB power about 12 minutes after it woke.” The charge port command was the one that worked. With a cable plugged in, the car refuses to close the port, “which still counts.”
There’s one problem with that. The car only takes the charge port command from a Driver key, and it “refuses to close the charge port for Charging Manager and Fleet Manager keys.” So the Pi pairs with the Driver role, over Tesla’s own open-source vehicle-command tools, and the README spells out the bill: “someone who took the Pi could use the key to unlock and drive the car.” Its advice is to turn on PIN to Drive, and to delete the key under Controls → Locks → Keys if the Pi ever goes missing.
The small stuff is thought through, too. Footage the car records while parked at home isn’t uploaded (an awake car in a garage records the garage). The keep-awake runs for “at most an hour,” then leaves the car alone for six. And deletion has one rule: Glovebox “only ever deletes events from the car’s drive once they’re on your NAS at full size.” Encryption is optional, with a key you hold instead of Tesla, though the README admits the Pi Zero 2 W “has no secure chip,” so someone who takes the Pi “and knows what they’re doing can still decrypt it.”
It’s tested on exactly one car, a 2026 Model 3 with HW4, and the site says other models “may work, but are not confirmed.” The repo went up October 17. Three releases shipped on October 19 alone, and the site is now floating an assembled kit “at a target price of $199 USD.” Whether a kit buyer turns on PIN to Drive is the open question.
Car makers keep building the storage, the encryption and the viewer, and owners keep routing around them with a Pi. The more cars ship with fine-grained key roles, the more this tension shows up: the role that’s safe to hand a gadget often can’t do the one thing the gadget needs. Expect projects like this to keep asking manufacturers for a “stay awake” permission that can’t also start the car.
Until then, it’s a $15 computer in the glovebox holding a car key.