Skip to content

Commit

Permalink
Changed goal to value for bps
Browse files Browse the repository at this point in the history
  • Loading branch information
wardru committed Nov 7, 2023
1 parent 4355699 commit bff05f1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions source/pza/interfaces/bps_chan_ctrl.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ bps_chan_ctrl::bps_chan_ctrl(device *device, const std::string &name)
_att_current("current"),
_enable("enable")
{
_att_voltage.add_rw_field<double>("goal");
_att_voltage.add_rw_field<double>("value");
_att_voltage.add_ro_field<double>("min");
_att_voltage.add_ro_field<double>("max");
_att_voltage.add_ro_field<int>("decimals");

_att_current.add_rw_field<double>("goal");
_att_current.add_rw_field<double>("value");
_att_current.add_ro_field<double>("min");
_att_current.add_ro_field<double>("max");
_att_current.add_ro_field<int>("decimals");
Expand All @@ -36,7 +36,7 @@ int bps_chan_ctrl::set_voltage(double volts)
return -1;
}

return _att_voltage.get_field<double>("goal").set(volts);
return _att_voltage.get_field<double>("value").set(volts);
}

int bps_chan_ctrl::set_current(double amps)
Expand All @@ -49,7 +49,7 @@ int bps_chan_ctrl::set_current(double amps)
return -1;
}

return _att_current.get_field<double>("goal").set(amps);
return _att_current.get_field<double>("value").set(amps);
}

int bps_chan_ctrl::set_enable(bool enable)
Expand All @@ -75,4 +75,4 @@ void bps_chan_ctrl::add_enable_callback(const std::function<void(bool)> &callbac
void bps_chan_ctrl::remove_enable_callback(const std::function<void(bool)> &callback)
{
_enable.get_field<bool>("value").remove_get_callback(callback);
}
}

0 comments on commit bff05f1

Please sign in to comment.