Because the only time 'tenths' gets displayed is AFTER you've cleared it to zero...
Main:
SerOut2 SO,16468,["Milage = ",DEC Miles,".", DEC Tenths ,13]
VSSCount = 0 ' Clear VSS counter
TMR0 = 0 ' Clear TMR0 counter
Loop:
VSSCount = TMR0 ' Get TMR0 count
IF VSSCount > 99 Then
VSSCount = 0
Tenths = Tenths + 1
IF Tenths > 9 Then
Tenths = 0
Miles = Miles + 1
GoTo Main
EndIF
EndIF
GoTo Loop
And milage is spelled MILEAGE...![]()
Bookmarks