Laying in bed thinking about this project, I'm guessing you want to calculate an average speed from the time you hit the go pedal. I pondered how to do that with minimal code. Essentially I came up with:

Durchschnittlich var WORD ;Speed
Geschwindigkeit var WORD ;Average
Teiler VAR WORD ;Divisor
Gesamt VAR LONG ;Total

DO
Durchschnittlich = TMR3 ;Using T3CKI with TMR1
Gesamt = Gesamt + Durchschnittlich
Teiler = Teiler + 1
Geschwindigkeit = Gesamt / Teiler
LOOP

Of course, the DO/LOOP would be paced per TMR1 Interrupt