This component can control the positions of multiple axes. More...
#include <nAxesControllerPosVel.hpp>
Public Member Functions | |
| nAxesControllerPosVel (std::string name) | |
| Constructor of the class. | |
| virtual bool | configureHook () |
| Configures the component, make sure the properties are updated using the OCL::DeploymentComponent or the marshalling interface of the component. | |
| virtual bool | startHook () |
| Starts the component. | |
| virtual void | updateHook () |
| Updates the output using the control equation, the measured and the desired position. | |
| virtual void | stopHook () |
Protected Attributes | |
|
RTT::ReadDataPort< std::vector < double > > | p_meas_port |
| The measured positions. | |
|
RTT::ReadDataPort< std::vector < double > > | p_desi_port |
| The desired positions. | |
|
RTT::ReadDataPort< std::vector < double > > | v_desi_port |
| The desired velocities. | |
|
RTT::WriteDataPort < std::vector< double > > | v_out_port |
| The calculated output velocities. | |
|
RTT::Property< std::vector < double > > | gain_prop |
| The control gain value for each axis. | |
| RTT::Property< unsigned int > | num_axes_prop |
| The number of axes to configure the components with. | |
This component can control the positions of multiple axes.
It uses a simple position-feedback and velocity feedforward to calculate an output velocity. velocity_out = K_gain * ( position_desired - position_measured) + velocity_desired.
The initial state of the component is PreOperational
Definition at line 45 of file nAxesControllerPosVel.hpp.
| nAxesControllerPosVel | ( | std::string | name | ) |
Constructor of the class.
| name | name of the TaskContext |
Definition at line 33 of file nAxesControllerPosVel.cpp.
References nAxesControllerPosVel::gain_prop, nAxesControllerPosVel::num_axes_prop, nAxesControllerPosVel::p_desi_port, nAxesControllerPosVel::p_meas_port, nAxesControllerPosVel::v_desi_port, and nAxesControllerPosVel::v_out_port.
| bool configureHook | ( | ) | [virtual] |
Configures the component, make sure the properties are updated using the OCL::DeploymentComponent or the marshalling interface of the component.
The number of axes and the control gains are updated.
Definition at line 58 of file nAxesControllerPosVel.cpp.
References nAxesControllerPosVel::gain_prop, nAxesControllerPosVel::num_axes_prop, and nAxesControllerPosVel::v_out_port.
| bool startHook | ( | ) | [virtual] |
Starts the component.
Definition at line 83 of file nAxesControllerPosVel.cpp.
References nAxesControllerPosVel::p_desi_port, nAxesControllerPosVel::p_meas_port, and nAxesControllerPosVel::v_desi_port.
1.6.3