There is a mistake on B13, it should be MIN(B12;B7)
Ioannis
There is a mistake on B13, it should be MIN(B12;B7)
Ioannis
As I turn the pot, the formula should convert from 0 all the way to 1023, to a new range of 100 to 235Code:OutputValue = 100 + (InputValue */ 34)
Many ways to skin a cat but Henriks is the best!
Fast and simple!
Ioannis
That's awesome Henrik. It works like a charm.
Can you explain how you got 34? It's not jumping out at me.
"A simple way to think about '*/' is that it shifts the result 8 places to the right,
resulting in an automatic division by 256."
I'm just not sure how you went about figuring that out.
I'd like to convert 34 into a formula for future use when I have to use a different range (cause I'm sure to have that need - several Flight Sim variables use pots and have their own range of values).
Last edited by Demon; - 15th August 2024 at 20:16.
My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.
Not as dumb as yesterday, but stupider than tomorrow!
My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.
Not as dumb as yesterday, but stupider than tomorrow!
Bookmarks