I know the OBDII can provide the miles driven, it's displayed right there on the odometer. But I think it would be easier to just buy one pre-made calculator
http://www.scangauge.com/The only problem with an OBDII based unit is the inaccuracy of the measurement. Just changing the tires can throw it off. A GPS based unit would probably be more accurate.