Servo 360 degree, direction with two buttons

Hi! I would like to run directions with push buttons. It works with SELECT nod, but it does not stop, if no button is preset. How to stop the servo?
Thank you!
Alex

Your current code sets a value for the servo to aim for (with 360 degree servo, this is basically a speed to move), and you always keep the servo turned on.

There are two options to stop the servo. Either disable the servo (servo-ACT false) or select the stop “speed”. The two options have different results for normal servo (free-wheel vs hold center position), but I’m guessing the end result of either solution is the same for 360 degree servos (free-wheel). The advantage of disabling the servo to stop is you don’t have to determine what the stop value is (it should be 0.50, but might be slightly different and can change if servo is replaced).

Disable servo:
image
The servo is only enabled if (at least) one button is pressed

Set stop speed:


The puls… nodes are pulse-on-false (i.e. when button is released)

1 Like

It works. Thank you!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.