Servo motor control

日本語のページ

Tsumicky allows you to control servo motors.
Servo motor related blocks are in the "Servo motor" group.

Servo motor related blocks

Initialization

First, initialize the servo motor using the block "Initialize servo motor ... of ... with pulse width ..." and assign it to the pin.

Initializing the servo motor

Assign the pin in the "assign ... pin of ... to variable ..." block in the "Basic I/O" group.
If the servo motor does not rotate correctly from 0 degrees to 180 degrees, adjust the minimum and maximum pulse width values.

Specifying the angle

Next, specify the rotation angle of the servo motor in the "set the angle servo motor ... of ... to ... degrees" block.
Specify the angle in the range of 0 degrees to 180 degrees.

Specifying the servo motor angle

Example

This is an example of controlling a servo motor with pin 4.
Change the angle of the servo motor from 0 degrees - 90 degrees - 180 degrees - 90 degrees - 0 degrees - ... every second.
This program can be downloaded from here.

Example of rotating a servo motor