clamp head position

Signed-off-by: Otakode <marchal.cl@gmail.com>
smoothing inputs

Signed-off-by: Otakode <marchal.cl@gmail.com>