User Tools

Site Tools


eeros_architecture:control_system:available_blocks:peripheraloutput

Peripheral Output

This block allows to write to a hardware output. This could be a digital output or an analog output. Such a block will always write to an output defined in the Hardware Abstraction Layer. The constructor of this block looks like

PeripheralOutput(std::string id, bool exclusive = true);

As a parameter you must indicate the designator of the corresponding output in the Hardware Abstraction Layer. Please make sure that the name is identical to the name in the Hardware Abstraction Layer. If not the constructor will throw a fault. A second optional parameter indicates if the output has exclusive rights on the signal defined in the HAL. Create a new output with

PeripheralOutput<> setValue("anOut0"); // anOut0 must be defined in hardware configuration file
PeripheralOutput<bool> enable("dOut4"); // dOut4 must be defined in hardware configuration file
eeros_architecture/control_system/available_blocks/peripheraloutput.txt · Last modified: 2021/05/28 13:41 by ursgraf