|
Stepdance Software Library
|
Used for generating a position signal that advances at a constant speed. More...
#include <generators.hpp>
Public Member Functions | |
| void | begin () |
| Initialize the VelocityGenerator. Must be called to set up the generator. | |
Public Attributes | |
| volatile ControlParameter | speed_units_per_sec = 0 |
| ControlParameter specifying the generation speed in units per second. You can set it directly or map an input to it. | |
| BlockPort | output |
| Output BlockPort for the generated position signal. | |
Protected Member Functions | |
| void | run () |
Used for generating a position signal that advances at a constant speed.
A VelocityGenerator maintains an internal target position and increments it over time at a specified speed (units per second). This can be used to move a downstream component at a specified rate. Here's an example of how to instantiate and configure a VelocityGenerator:
| BlockPort VelocityGenerator::output |
Output BlockPort for the generated position signal.