CtrlRampStep (FB)
FUNCTION_BLOCK CtrlRampStep EXTENDS AbbETrig3
This function block processes input signal with ramp algorithm according to PLC cycle time (scan period) and processes output variable as Out. This is a ramp processing FB with defined steps.
Transfer Function = U(s)/ E(s) = Gain * [ In / (Step / Cycle Time in Sec )]
- InOut:
Scope
Name
Type
Initial
Comment
Input
ModeBYTE1
- 2: Process mode:
0 = Out = In,
1 = Out = Gain*(In/Step)
InREAL0
3: Input of the signal to be processed by Ramp function
KpREAL1
4: Propotional gain of CtrlRampStep function block, Kp >=0.
StepWORD1
5: Step to reach the input target value In, 10000.0>=Step>=0. Input step refers to the Steps per cycle time. For example, If cycle time = 10ms and Step = 5, then the output will increase 5 steps per 10ms. To observe this operation, execute the block with 1s task cycle time.
Output
ErrorID3: error identifier if an invalid value was applied to an input
OutREAL0
4: Input signal In is processed by CtrlRampStep function block, the manipulated output signal is sent to Out