This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Servo Motor

Represent connected servo motor and set angular position value

  • Library:
  • Simulink Coder Support Package for VEX EDR V5 Robot Brain / Actuators

Description

The Servo Motor block represents a servo motor connected to a specified 3-wire port on a VEX® EDR V5 Robot Brain. The input signal to the block sets the angular position value of the servo motor. There are eight 3-wire ports on VEX EDR V5 Robot Brain that you can connect to servo motors.

Ports

Input

expand all

The input signal for the Servo Motor block can be derived from other blocks in the model. For example:

  • If a Gamepad Joystick block is connected as the input for a Servo Motor block, the input value can range from –128 to 127 based on the position of the joystick on the gamepad, which then translates to an angular position value (in degrees) of the servo. For block input value ‘0’, the servo motor is stationary.

  • If a Gamepad Button block along with a Gain block is connected as the input for a Servo Motor block, the input can be set to a particular value for the duration for which the button is kept pressed, which translates to an angular position value (in degrees) of the servo.

Data Types: double

Parameters

expand all

Select the 3-wire port on the VEX EDR V5 Robot Brain that is connected to the servo motor.

Do not assign the same port to more than one Servo Motor block within the same model.

Model Examples

See Also

| |

Introduced in R2018b