I am working with dmx that gives me values from 0 to 255 and the motor moves from -270 to 270. I need the calculation that this program uses.
(i am using lua)
Luke100000 gave the following formulas: 1- dmx / 255 * 540 - 270 = motor 2- motor (x) = 9/138176 x ^ 2 + 290313/138176 x - 270
the first if I get a value of 255 gives me 270 the second if I get a value of 255 it gives me 265.7724569868085
so the first would be the most accurate.
Thanks for the help.