RSeries astromech firmware
ServoSequencer Class Reference

#include <ServoSequencer.h>

Detailed Description

Plays a sequence of servo commands using a servo group mask.

+ Inheritance diagram for ServoSequencer:
+ Collaboration diagram for ServoSequencer:

Public Member Functions

 ServoSequencer (ServoDispatch &dispatch)
 
void playVariableSpeed (const ServoStep *sequence, uint16_t length, uint32_t servoGroupMask, uint16_t speedMinMS, uint16_t speedMaxMS, float startPos=0.0, float endPos=1.0, float(*onEasingMethod)(float)=NULL, float(*offEasingMethod)(float)=NULL)
 
void play (const ServoStep *sequence, uint16_t length, uint32_t servoGroupMask, uint16_t speedMS=0, float startPos=0.0, float endPos=1.0)
 
void stop ()
 
bool isFinished () const
 
virtual void animate () override
 Subclasses must implement this function to run through a single frame of animation/activity. More...
 
ServoDispatchdispatch ()
 
- Public Member Functions inherited from AnimatedEvent
 AnimatedEvent ()
 Default Constructor. More...
 
void setLoopDoneCallback (AnimatedLoopDone loopProc)
 

Additional Inherited Members

- Static Public Member Functions inherited from AnimatedEvent
static void process ()
 Calls animate() for each created AnimatedEvent subclass. More...
 

Constructor & Destructor Documentation

◆ ServoSequencer()

ServoSequencer::ServoSequencer ( ServoDispatch dispatch)
inline

Member Function Documentation

◆ animate()

virtual void ServoSequencer::animate ( )
inlineoverridevirtual

Subclasses must implement this function to run through a single frame of animation/activity.

Subclasses should not call delay() or otherwise block.

Implements AnimatedEvent.

◆ dispatch()

ServoDispatch& ServoSequencer::dispatch ( )
inline

◆ isFinished()

bool ServoSequencer::isFinished ( ) const
inline

◆ play()

void ServoSequencer::play ( const ServoStep sequence,
uint16_t  length,
uint32_t  servoGroupMask,
uint16_t  speedMS = 0,
float  startPos = 0.0,
float  endPos = 1.0 
)
inline

◆ playVariableSpeed()

void ServoSequencer::playVariableSpeed ( const ServoStep sequence,
uint16_t  length,
uint32_t  servoGroupMask,
uint16_t  speedMinMS,
uint16_t  speedMaxMS,
float  startPos = 0.0,
float  endPos = 1.0,
float(*)(float)  onEasingMethod = NULL,
float(*)(float)  offEasingMethod = NULL 
)
inline

◆ stop()

void ServoSequencer::stop ( )
inline

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