1 #ifndef ORG_EEROS_CONTROL_SATURATION_HPP_
2 #define ORG_EEROS_CONTROL_SATURATION_HPP_
11 template<
typename T =
double,
typename enable =
void>
20 for(
unsigned int i = 0;
i < lowerLimit.size();
i++) {
37 T outVal = this->in.getSignal().getValue();
39 for(
unsigned int i = 0;
i < outVal.size();
i++) {
40 if(outVal[
i] > upperLimit[
i]) outVal[
i] = upperLimit[
i];
41 if(outVal[i] < lowerLimit[i]) outVal[
i] = lowerLimit[
i];
44 this->out.getSignal().setValue(outVal);
45 this->out.getSignal().setTimestamp(this->in.getSignal().getTimestamp());
87 T outVal = this->in.getSignal().getValue();
89 if(outVal > upperLimit) outVal = upperLimit;
90 if(outVal < lowerLimit) outVal = lowerLimit;
92 this->out.getSignal().setValue(outVal);
93 this->out.getSignal().setTimestamp(this->in.getSignal().getTimestamp());
virtual void run()
Definition: Saturation.hpp:86
Saturation()
Definition: Saturation.hpp:71
virtual void enable()
Definition: Saturation.hpp:96
virtual void setLimit(T lower, T upper)
Definition: Saturation.hpp:104
Saturation(T sym)
Definition: Saturation.hpp:76
T upperLimit
Definition: Saturation.hpp:110
Definition: Saturation.hpp:12
Saturation(T lower, T upper)
Definition: Saturation.hpp:31
Saturation(T lower, T upper)
Definition: Saturation.hpp:81
virtual void disable()
Definition: Saturation.hpp:52
bool enabled
Definition: Saturation.hpp:111
virtual void disable()
Definition: Saturation.hpp:100
Saturation(T sym)
Definition: Saturation.hpp:26
virtual void setLimit(T lower, T upper)
Definition: Saturation.hpp:56
type
Definition: Sequencer.hpp:15
Definition: Block1i1o.hpp:12
Saturation()
Definition: Saturation.hpp:19
bool enabled
Definition: Saturation.hpp:63
virtual void run()
Definition: Saturation.hpp:36
T upperLimit
Definition: Saturation.hpp:62
int i
Definition: RingBufferTest.cpp:12
virtual void enable()
Definition: Saturation.hpp:48