parameter tuning

This commit is contained in:
Ulrich Mohr 2022-08-24 17:19:45 +02:00
parent e34664d265
commit 61b4e68f3d

View File

@ -40,6 +40,11 @@ class Parameter : public ParameterIF {
return value; return value;
} }
Parameter& operator =(const T& newValue){
value = newValue;
return *this;
}
#ifdef FSFW_INTROSPECTION #ifdef FSFW_INTROSPECTION
Types::ParameterType getType() override { Types::ParameterType getType() override {
return enumHelper<std::is_base_of<EnumIF, T>::value>::template getType<T>(); return enumHelper<std::is_base_of<EnumIF, T>::value>::template getType<T>();
@ -66,7 +71,6 @@ class Parameter : public ParameterIF {
bool setFloating(double value) override { bool setFloating(double value) override {
if (getType() != Types::FLOATING) { if (getType() != Types::FLOATING) {
puts("fups");
return false; return false;
} }
this->value = T(value); this->value = T(value);
@ -75,7 +79,6 @@ class Parameter : public ParameterIF {
bool setSigned(int64_t value) override { bool setSigned(int64_t value) override {
if ((getType() != Types::SIGNED) && (getType() != Types::ENUM)) { if ((getType() != Types::SIGNED) && (getType() != Types::ENUM)) {
puts("sups");
return false; return false;
} }
this->value = T(value); this->value = T(value);