The function block MotorValve is the control for a motor valve. By using the override function, you can set it to manually open or close. If it is in auto, the input decides if it is open or closed. From the function block, we get the status of the valve. So, if it is manually overridden open or closed, or if it is auto on or off. If motion is activated then the valve will open if it is in auto. It will stay open as long as the exercise input is on. 


Override ventiler

Override ValueDescription
0Auto
1Manual On
2Manual Off

Valve states,

Override Alarm ValueDescription
0Auto Off
1Auto On
2Manual On
3Manual Off
4Motion


With everything explained the Inputs and Outputs are the following,

INPUT

  • IN → BOOL
  • CDPInput → INT
  • Mosjonering → BOOL

OUTPUT

  • OUT → BOOL
  • CDPout→ INT


CODED SOLUTION

Variable Decleration:

CODE:






  • No labels