fDevelopment back on track. I've managed to duplicate an MPGuino using a 3.3v board, which is necessary to transmit data to the pi without a
voltage converter like this one.
I kept frying Arduino Pro Minis -- or so I thought. I gave up on that particular board but I suspect the on-board voltage regulator was overheating. When I switched development to a tinycirctuits tinyduino, the results were much different. In short, it worked as expected.
The first piece of the puzzle is a car-to-board interface. I used a blank prototype board and based the circuit on meelis' 3 resistor design:
Then I soldered the necessary pins to the tinyduino prototype board, letting me quickly connect and disconnect the board using the 28-pin connector. This makes updates super simple.
Since this is still a prototype (I still need to perfect the interface board), I bundled the two pieces (now connected) to a raspberry pi. I used this particular case for the pi as there are few opportunities for a short circuit.
I put the entire thing behind the stereo head unit:
and then sealed it all up (well, I pushed the stereo unit back into position):
Very clean, very professional looking, no more wires sticking out of the side off the dash. The two small looms you see allow me to connect to the Adafruit LCD shield for tank resets and any other housekeeping. I also wired up the Adafruit's reset button, which forces the tinyduino to reset the LCD, which doesn't work well if it's connected to an already-running arduino. (The adafruit buttons can't be used to reset the backlight, as they seem to need to be provisioned or addressed at boot time. (I think this has to do with the i2c bus).
My next order of business is: Leverage the program's internal timer to vary the JSON output every couple of seconds. For example, every two seconds the 'subtitle' on the bottom graph could cycle between displaying drag race data, tank/trip data; or primary and extended drag race data. I see a number of timers scattered throughout the code, so I'll use them as a template. This will address a primary limitation of the JSON/Pi approach, limited screen real-estate.
I've taken my own functions (a copy of the doOutputJSON function, plus a blink function) and I can drop them into newer code revisions as I continue development. This should keep me far from the dreaded code fork.