MotorHat.CreateDCMotor(Int32) Method

Definition

Creates a Iot.Device.DCMotor object for the specified channel.

public Iot.Device.DCMotor.DCMotor CreateDCMotor (int motorNumber);
member this.CreateDCMotor : int -> Iot.Device.DCMotor.DCMotor
Public Function CreateDCMotor (motorNumber As Integer) As DCMotor

Parameters

motorNumber
Int32

A motor number from 1 to 4.

Returns

Remarks

The motorNumber parameter refers to the motor numbers M1, M2, M3 or M4 printed in the device.

Applies to