servo
Connection to servo motor on Arduino MKR Motor Carrier or Nano Motor Carrier
Since R2020a
Add-On Required: This feature requires the MATLAB Support Package for Arduino Hardware add-on.
Description
This object represents a connection to a servo motor with the specified motor number on an MKR Motor Carrier or a Nano Motor Carrier. You can control the servo motor using the functions listed under Object Functions.
Creation
Description
creates a connection to the servo motor at the specified motor number on the Arduino® MKR Motor Carrier or Nano Motor Carrier.servoObj
= servo(mcObj
,motornumber
)
Input Arguments
Properties
Object Functions
Use these object functions to create a connection to the servo motor.
writePosition | Write position of servo motor connected to MKR Motor Carrier or Nano Motor Carrier |
Examples
Version History
Introduced in R2020a
See Also
arduino
| dcmotor
| motorCarrier
| pidMotor
| rotaryEncoder