Processing blocks¶
A processing block is a block of code that consumes data from its inputs, processes this data based on the provided configuration, and produces the result on its output signals.
The number of inputs, outputs & parameters of the processing block and its behavior are defined by a template. The templates can be loaded from files provided by Prodrive Technologies or can be created yourself. In Control Loop Customization is described how to generate custom processing block templates via Simulink and C++. This section describes the processing block templates provided by Prodrive Technologies.
Note
Compiled processing block templates are provided for different processor architectures. Make sure to use the binary that corresponds with the architecture of your target platform. For processing block <name> the following are available:
<name>-linux-x86_64.bin- PMP simulator on Linux. This file is only available in the Linux installer.<name>-windows-x86_64.bin- PMP simulator on Windows. This file is only available in the Windows installer.<name>-bb-x86_64.bin- x86 based controller, e.g. the Poseidon-CFL motion controller.<name>-bb-armv8a_64.bin- ARM based controller, e.g. the Arcas motion controller.<name>-bb-x86_64-avx512.bin- x86 based controller that support AVX512 instructions, e.g. the Poseidon-EGS motion controller.
Note
Sources for processing block templates are provided for use in MATLAB Simulink. For processing block <name> the following are available:
<name>Subsystem.mdl- A masked subsystem file. This file is intended to be instantiated once or multiple times in a simulation model using the Simulink “Subystem Reference” block, possibly with different mask parameters for each instantiation. The subsystem mask contains a parameter for each Read-Write signal or Updatable of the processing block template.<name>Model.mdl- A compilation model. Uses the<name>Subsystem.mdlmodel for the implementation. Used for re-compiling the processing block template. See below for the commands to perform this compilation.init.m- Configuration of the metadata for all Read-only signals, Read-Write signals and Updatables necessary for compiling the compilation model.
Below is a prototype script to re-compile the templates using the compilation models using the PmpRunCodeGen function: The command can be completed by filling in <name>, changing the target architecture to the desired one possibly adding one or multiple of the remaining optional arguments.
init;
PmpRunCodeGen('<name>Model','<name>',PmpTargetPlatform.bb_x86_64, 'auto');
Control networks¶
Name |
Description |
|---|---|
Feedforward implementation with Coulomb, viscous, acceleration, jerk and snap feedforward. |
|
Position feedback control implementation with PID, 4 biquad filters, settling state machine and delay matching. |
|
Position feedback control implementation with PID and 2 biquad filters. |
|
Velocity feedback control implementation with PID, 2 biquad filters, velocity state observer and delay matching. |
|
Velocity feedback control implementation with PID and a biquad filter. |
|
Generic feedback control implementation for control processes unrelated to motion. |
|
Second order mechanical model for plant simulation. |
Signal routing and conversion¶
Name |
Description |
|---|---|
Sum with 2 or 10 inputs. |
|
Gain with an offset after the gain, for example for position feedback scaling from encoder counts to SI units. |
|
Gain with offsets before and after the gain. |
|
Electrical angle determination from a position sensor using the pole pair count and the pole distance. |
|
Temperature determination from a resistance using the Steinhart-Hart equation. |
Waveform generators¶
Name |
Description |
|---|---|
Pseudo-random noise generator. |
|
Sine waveform generator with support for sine sweeps. |
|
Trapezium waveform generator. |
|
User-defined sequence waveform generator with 10k or 1M samples. |
Event generators¶
Name |
Description |
|---|---|
Event generation based on a boolean condition. |
|
Moving mean, variance and standard deviation calculation with anomaly detection based on dynamically calculated thresholds. |
Miscellaneous¶
Name |
Description |
|---|---|
Additional general purpose read-write signals. |
See also
- Processing block templates
General concept of template creation, instantiation and configuration.