Controller

public interface Controller

Adjusts control parameters in response to values provided by the analyzer. A controller receives the output of the analyzer as input, and then adjusts its internal state accordingly. It can be asked for its state at any time by the WorkerThread.

Author:Marcel Stefko

Methods

getCurrentOutput

public double getCurrentOutput()

Returns an output value derived from the controller’s internal state.

Returns:The controller’s new output value for the control signal.

getName

public String getName()

Returns a unique name for the controller.

Returns:A unique name for the controller.

getSetpoint

public double getSetpoint()

Returns the current value for the setpoint.

Returns:The current setpoint value.

getStatusPanel

public ControllerStatusPanel getStatusPanel()

Returns the controller’s status panel that will be displayed in the GUI. If no panel is implemented, this method should return null. In this case, the corresponding space in the MonitorGUI will appear blank.

Returns:The status panel of the controller, or null.

nextValue

public double nextValue(double value)

Receives next input from the WorkerThread (this the batched output of the analyzer). This method must be able to accept Double.NaN, which the analyzer will produce if if can not produce an output for some reason.

Parameters:
  • value – The analyzer’s input value.
Returns:

The controller’s new output value for the control signal.

setSetpoint

public void setSetpoint(double new_setpoint)

Sets a new values for the controller’s setpoint.

Parameters:
  • new_setpoint – The desired value for the process variable.