-->
Page 1 of 1

MAP function would be useful to me

PostPosted: Wed Jan 04, 2017 12:30 am
by ptribbey
Like the arduino map funtion:

long map(long x, long in_min, long in_max, long out_min, long out_max)
{
return (x - in_min) * (out_max - out_min + 1) / (in_max - in_min + 1) + out_min;
}

Thank You
Paul