Supported platforms: CODESYS 2.3, CODESYS 3.5

 

Ramp_Linear (FB)

Description

This ramp FB can be used when a fully linear ramp is required. Ascend and descend speeds depend on the adjusted ramp parameters.

Ramp parameters are defined as ms, i.e. how many milliseconds it takes to ramp from 0 to 32767.

 

The FB takes care of ascending and descending ramps.

When i_Enable input falls, the output is immediately set to zero without a ramp.

 

Inputs

Input variable name

Data type

Range

Description

i_Enable

BOOL

TRUE/FALSE

Enables controlling of the output

i_ControlIn

UINT

0..32767

Control signal from e.g. joystick

i_AscendRamp

UINT

1…65535 ms

Ascending speed

i_DescendRamp

UINT

1…65535 ms

Descending speed

Outputs

Output variable name

Data type

Range

Description

o_ControlOut

UINT

0..32767

Calculated (ramped) control request

Example code

 

 

Source file Topic000325.htm

Last updated 24-Apr-2025