public class PIControlBlock extends CMLControlBlock1stOrderAdapter
ICMLStaticBlock.StaticBlockTypeserialVersionUID| Constructor and Description |
|---|
PIControlBlock(double kp,
double ki)
constructor
|
PIControlBlock(ICMLStaticBlock.StaticBlockType type,
double kp,
double ki,
double max,
double min)
constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
eulerStep1(double u,
double dt)
Perform Euler step-1 calculation
|
void |
eulerStep2(double u,
double dt)
Perform Euler step-2 calculation
|
double |
getKi()
get parameter t
|
double |
getKp()
get parameter kp
|
LimitType |
getLimit()
get the limit object
|
double |
getU0()
get the controller initial input u0, it should be always called after
the intiState() call.
|
double |
getY()
get the controller output
|
boolean |
initStateY0(double y0)
Initial the controller state variables
|
java.lang.String |
toString() |
getState, getU, setDX_dtgetStateX, readData, setStateX, writeDatadebugInfo, getType, getU0, initStateU0, setParameter, setTypeequals, getClass, hashCode, notify, notifyAll, wait, wait, waitgetU0, initStateU0, setParameterpublic PIControlBlock(double kp,
double ki)
kp - ki - public PIControlBlock(ICMLStaticBlock.StaticBlockType type, double kp, double ki, double max, double min)
type - kp - ki - max - min - public boolean initStateY0(double y0)
ICMLStaticBlockinitStateY0 in interface ICMLStaticBlockinitStateY0 in class CMLStaticBlockAdaptery0 - output initial value.public double getU0()
ICMLStaticBlockgetU0 in interface ICMLStaticBlockgetU0 in class CMLStaticBlockAdapterpublic void eulerStep1(double u,
double dt)
ICMLStaticBlockeulerStep1 in interface ICMLStaticBlockeulerStep1 in class CMLControlBlock1stOrderAdapteru - the input variabledt - the time steppublic void eulerStep2(double u,
double dt)
ICMLStaticBlockeulerStep2 in interface ICMLStaticBlockeulerStep2 in class CMLControlBlock1stOrderAdapteru - the input variabledt - the time steppublic double getY()
ICMLStaticBlockgetY in interface ICMLStaticBlockgetY in class CMLControlBlock1stOrderAdapterpublic double getKp()
public LimitType getLimit()
public double getKi()
public java.lang.String toString()
toString in class java.lang.Object