Quote Originally Posted by RFsolution View Post
thank you melanie

Well this is what i want to do and would show on the display:

I read the Real position from the encoder as a 10bit word (0-1024) as the encoder is absolute
i might want to add or substract an offset so that how the encoder mechanicly is fixed
i still can correct it by the offset but need to keep 1024 as resolution for 1 revolution

So i want to display or have new variables with:
the position +/- it's offset but between 0 and 1024
Conversion of the position +/- offset to 0 - 360 deg (keep the 10bit resolution)

I dont see how I can do that

Can you point me out ?
So, you add your offset...
If it's above 360, subtract 360...
If it's below 360 (i.e. negative, somewhere above 65000, if using words), add 360...
Get the picture yet?