|
Re: Create a low speed drive in programming
Quote:
|
Originally Posted by Bharat Nain
We can't just divide all the values by 2 because that moves the center from 127 to 63.5.
|
You can divide by 2 then add 63.5.
[edit]
You might want to tweak that reduction ratio a little, though. For example, you might want to multiply by 2/3 or 3/4 instead of 1/2. Whatever you decide to do, you can recenter your range by adding whatever it takes to get your center back to 127.
So a formula would be:
x1*reduction_ratio + (127-127*reduction_ratio)
And the same for y1
__________________
George
"Darkness cannot drive out darkness; only light can do that. Hate cannot drive out hate; only love can do that."
-- Martin Luther King, Jr.
Last edited by George1902 : 15-10-2004 at 22:34.
|