C# Class CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider

A servo provider for servos attached to a PCA9685 servo controller.
Inheritance: IServoProvider
ファイルを表示 Open project: cyrusbuilt/MonoPi

Public Methods

Method Description
Dispose ( ) : void

Releases all resource used by the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider object.

Call Dispose when you are finished using the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider. The Dispose method leaves the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider in an unusable state. After calling Dispose, you must release all references to the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider so the garbage collector can reclaim the memory that the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider was occupying.

GetServoDriver ( IPin servoPin ) : IServoDriver

Gets a driver for the requested pin.

PCA9685GpioServoProvider ( PCA9685GpioProvider provider ) : System

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider class with the GPIO provider for the PCA9685.

Method Details

Dispose() public method

Releases all resource used by the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider object.
Call Dispose when you are finished using the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider. The Dispose method leaves the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider in an unusable state. After calling Dispose, you must release all references to the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider so the garbage collector can reclaim the memory that the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider was occupying.
public Dispose ( ) : void
return void

GetServoDriver() public method

Gets a driver for the requested pin.
/// The specified pin cannot be driven by any available servo driver /// because it is not a defined servo pin. /// /// No driver is assigned to the specified pin - or - Cannot drive servo /// from specified pin - or - another initialization error occurred. ///
public GetServoDriver ( IPin servoPin ) : IServoDriver
servoPin IPin /// The pin the driver is needed for. ///
return IServoDriver

PCA9685GpioServoProvider() public method

Initializes a new instance of the CyrusBuilt.MonoPi.Components.Servos.PCA9685GpioServoProvider class with the GPIO provider for the PCA9685.
/// cannot be null. ///
public PCA9685GpioServoProvider ( PCA9685GpioProvider provider ) : System
provider CyrusBuilt.MonoPi.IO.PCA.PCA9685GpioProvider /// A GPIO provider for the PCA9685 ///
return System