Block Object
The Block object in MechaWare firmware is the basis for control loops in MechaWare. It can be a summation block, a PID block, a state space observer, etc. The Model object is made up of one or more Blocks.
Static Methods
CreateBlock | Factory method for creating Blocks. | |
TypeToString | Returns a string that corresponds to the MechaWare BlockType passed in. |
Instance Methods
The Block class is an abstract base class that all specific block types inherit from. Each type of block implements its own derived class. Calling GetType() on a Block informs you what its class is, allowing you to use C++’s dynamic_cast<> operator to access its parameters. For member variables of subclasses, see the C++ tab of the Block Documentation for each block type.
GetType | Gets the BlockType of the Block in question. | |
Read | Reads the Block’s coefficients and working data from the controller. | |
Write | Writes the Block’s coefficients to the controller. | |
WriteAll | Writes the Block’s coefficients and working data to the controller. | |
Index | Returns the index of the Block. | |
Compare | Returns true if same as Block passed as an argument. Ignores pointer differences. |
|
CompareExact | Returns true if same as Block passed as an argument. Considers pointer differences. |
|
Sends a string-based presentation of the Block to std::cout. |