As someone who did a similar build in high school (though with a screen - no fancy VR smartphones back then): a cheap laser mouse actually works quite well as a speed measuring device, and requires no electronics hacking. I just calculated the speed of the cursor and translated that into game speed - and reversing comes for free :)<p>We also had a turning detector using a rod to connect the front-wheel to a 8€ USB joystick. It actually end up costing us ~20€, not counting the PC, bike and stand.