Vehicle speed sensor

Im working on an odometer project and am going through similar headaches trying to understand the maths!
Another option if it works for you is to use a GPS for your speed... you could set up a controller with LCD to change the spoiler raise speed at the push of a button in your cockpit...