Custom XML, units for targetId

I calculate my speed based on the hall effect sensor in the rear diff. I calculate this in MPH. I see in the targetId 64 that speed is KPH. Do I need to calculate the speed in KPH, then realdash will convert to my local MPH units?

Same for intake air temp, in C but I calculate it in F. Should I just calculate everything in metric?

If I do mph and F, how do I go about it?

thanks,
david

Yes, RealDash handles everything internally in metric units. The units conversion is done just before displaying the value.

If you are using a connection XML, you can specify that values will be MPH or F for example.

units="MPH"
or
units="F"

This instructs RealDash to convert the incoming values to metric.

For my odometer, which I store in my FRAM as miles, what are the units I use in the XML?

If your device sends data as miles set:

units="MPH"

If your device sends data as kilometres set:

units="KPH"

Is there documented somewhere the supported units? I’ve look in the targetId doc and see the ones there, but what else if available?

PSI vs Bar
F vs C

I hate to ask for all units :slight_smile:

thanks
david

Here:

RealDash-extras/RealDash-CAN/realdash-can-description-file.md at master · janimm/RealDash-extras · GitHub

Search for word ‘units’

1 Like