Someone Had to Actually Write That Defeat Device Code

Someone Had to Actually Write That Defeat Device Code

Tech News emissions-scandal engineering software-ethics volkswagen

I spent most of Friday and this weekend reading about the Volkswagen thing, and I keep getting stuck on the same detail everyone else seems to be skating past. The EPA put out its notice of violation on Friday, saying VW had been running software on about 482,000 diesel cars in the US - Jettas, Golfs, Beetles, Passats, the Audi A3, mostly 2009 through 2015 model years - that could tell when the car was hooked up to emissions testing equipment and behaving differently than it did on the actual road. Cleaner during the test, dirtier the rest of the time. Reports are throwing around numbers like the cars emitting up to 40 times the legal limit of nitrogen oxide once they're off the dyno and out in the real world.

Everyone's writing about this as a corporate scandal, and sure, it is one. But Im a programmer by trade, not a car guy, and what I cant stop thinking about is that this isnt some emergent side effect of sloppy engineering. Somebody had to sit down and write that. Somebody had to build logic that checks things like steering input and whether the wheels are moving in a pattern consistent with a standardized test cycle, and then branch the emissions behavior based on that check. That's not a bug. Thats a feature, with a very specific and very deliberate purpose, and it shipped in nearly half a million cars for six years without anyone outside the company blowing the whistle on it.

I dont know why that distinction matters to me so much more than it seems to matter to most of the coverage Ive read, but it does. A defective part is a defective part. This is different. This is code that was written to detect a specific test condition and lie about what it does the moment that condition isnt present anymore. Its basically an if-statement built entirely to deceive a regulator, and I cant get over how casually that must have been treated internally at some point - as an engineering problem to solve, a target to hit, rather than the thing it actually is.

My buddy Dave has had a Jetta TDI since 2011. He bought it specifically because of the whole "clean diesel" pitch VW was running back then - the ads with the diesel engine next to normal gas ones, all that "this isnt your dads diesel, it doesnt smoke, it doesnt smell, it gets 40+ mpg and its still basically clean" messaging. He loves that car. Hes brought it up unprompted at two different dinners because he genuinely thought he was doing something responsible with it. I texted him Friday night when the story broke and he just sent back "well thats great." Nothing else for like ten minutes. I dont think hes mad about the mileage or the resale value yet, hes mad because the whole reason he picked that car over something else was the marketing claim, and the marketing claim was apparently propped up by code written to make sure a lab never found out it wasnt true.

Ive been rolling my eyes at "clean diesel" as a phrase for years honestly, mostly because diesel exhaust just smells like diesel exhaust to me no matter what the badge on the trunk says, but I never assumed the emissions numbers themselves were fake. I assumed the marketing was optimistic. Turns out the marketing was closer to fiction, backed by actual software specifically engineered to keep the fiction alive during the one scenario where someone might check.

Ive also been updating my own phone to iOS 9 this week without thinking twice about what any of the code on it is actually doing when Im not looking, which is a weird thing to sit with right after reading four thousand words about a car doing exactly that. I dont think Apple is cooking test results for me, to be clear. Im not trying to build some grand thesis about software and trust here. Its just a strange coincidence of timing that made me sit at my kitchen table this morning turning the idea over: we mostly just believe what our devices tell us theyre doing, because checking is hard and most of us dont have a dyno in the garage.

Anyway. I dont think this story is finished, not by a long shot, and Im not going to pretend I know where it ends up. Im mostly just annoyed on Daves behalf, and a little rattled that "write code that lies convincingly to a specific test" was apparently somebody's actual job for a while.