Hi Darrel,

Thanks a lot this is working perfect

Imagine if I would like to do the opposite

so from a 10 or 12bit value (representing 1 revolution) to deg.xx
Can you put me on the right tracks to do that ?

Decimal_value_10bit var word '(0-1024)
Decimal_value_12bit var word '(0-4098)
degrees var word '(0-360)
degrees_fraction var byte '(.xx)
degree_Total var word