RCKit
Public Member Functions | List of all members
ServoSetter Class Reference

Setter class that limits its input to between specified min and max values. More...

#include <ServoSetter.h>

Inheritance diagram for ServoSetter:
Inheritance graph
[legend]
Collaboration diagram for ServoSetter:
Collaboration graph
[legend]

Public Member Functions

 ServoSetter (Servo *servo)
 
virtual void input (int value)
 
virtual void failsafe ()
 Called when the source of input data is lost, and the Setter is required to fail in a safe way.
 
- Public Member Functions inherited from Setter
 Setter ()
 Constructor. More...
 
 Setter (Setter *target)
 Constructor with setting the target.
 
virtual void setTarget (Setter *target)
 
void setFailsafeValue (int failsafeValue)
 Sets the failsafeValue.
 
int failsafeValue ()
 

Additional Inherited Members

- Protected Attributes inherited from Setter
Setter_target
 This is the instance of Setter that will be given the transfotmed output value.
 
int _failsafeValue
 

Detailed Description

Setter class that limits its input to between specified min and max values.

Constructor & Destructor Documentation

◆ ServoSetter()

ServoSetter::ServoSetter ( Servo *  servo)
Parameters
[in]servoThe target Servo instance. It is the callers job to attach the Servo to the servo output pin
Author
Mike McCauley (mikem.nosp@m.@air.nosp@m.spayc.nosp@m.e.co.nosp@m.m)

Member Function Documentation

◆ input()

void ServoSetter::input ( int  value)
virtual

Input the value to be used to set the servo Servos are controlled within the range 0 to 180 degrees Input values in the range 0-255 are scaled to 0-180 Values outside that range are limited to 0 and 255

Parameters
[in]valueThe input value

Reimplemented from Setter.


The documentation for this class was generated from the following files: