Skip to content

Commit

Permalink
Merge pull request #48 from klauer/squash_fixup
Browse files Browse the repository at this point in the history
ENH: Included interlock device name in VFS_Interface issue #44
  • Loading branch information
klauer authored Jun 26, 2020
2 parents e24e1f6 + 1fe04b6 commit f912a6c
Show file tree
Hide file tree
Showing 6 changed files with 91 additions and 65 deletions.
3 changes: 3 additions & 0 deletions L2SIVacuum/DUTs/Gauges/ST_VG.TcDUT
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rVAC_SP: REAL := 0.001; /// At vacuum setpoint for all gauges
/// Protection setpoint for ion gauges at which the gauge turns off, not used for pirani
Expand All @@ -110,6 +111,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rPRO_SP: REAL := 0.001;
{attribute 'pytmc' := '
Expand All @@ -119,6 +121,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
/// Protection setpoint hysteresis
rHYS_PR: REAL := 0.001;
Expand Down
2 changes: 2 additions & 0 deletions L2SIVacuum/DUTs/Pumps/ST_PIP.TcDUT
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rHVEna_SP : REAL := 1.0E-4;
Expand Down Expand Up @@ -74,6 +75,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
/// Protection setpoint hysteresis
rHYS_PR: REAL := 0.001;
Expand Down
2 changes: 2 additions & 0 deletions L2SIVacuum/DUTs/Pumps/ST_PTM.TcDUT
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ NOTE: This is an archetype, use an extension of this structure for a specific pu
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rBackingPressureSP : REAL := 0.01;
{attribute 'pytmc' := '
Expand All @@ -107,6 +108,7 @@ NOTE: This is an archetype, use an extension of this structure for a specific pu
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rInletPressureSP : REAL := 0.02; //20mTorr
(*State*)
Expand Down
13 changes: 8 additions & 5 deletions L2SIVacuum/DUTs/Valves/ST_VGC.TcDUT
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rAT_VAC_SP : REAL := 0.000001; // Interlock setpoint for gauges on both sides of valve
rAT_VAC_SP_LAST : REAL :=0.000001 ; // Interlock setpoint for gauges on both sides of valve
Expand All @@ -32,11 +33,13 @@ STRUCT
field: LOPR 0
field: PREC 2
field: EGU "TORR"
autosave_pass1: VAL DESC
'}
rAT_VAC_HYS : REAL :=0.000001; // Hysteresis of the vacuum sp
{attribute 'pytmc' := '
pv: HYST_PERC ;
io: o;
autosave_pass1: VAL DESC
'}
rHYST_PERC : REAL := 0.80; // Hysteresis percentage
Expand All @@ -54,34 +57,34 @@ STRUCT
pv: ERR_DifPres;
field: ZNAM NO ERROR ;
field: ONAM Diffrential error present ;
io: o;
io: i;
'}
xERR_DifPres : BOOL;
{attribute 'pytmc' := '
pv: ERR_SP;
field: ZNAM NO ERROR ;
field: ONAM Setpoint error present ;
io: o;
io: i;
'}
xERR_SP : BOOL;
{attribute 'pytmc' := '
pv: ERR_Ext;
field: ZNAM NO ERROR ;
field: ONAM External error present ;
io: o;
io: i;
'}
xERR_ExtFault : BOOL;
xAlmSum : BOOL;
(*ILK Devices*)
{attribute 'pytmc' := '
pv: ILK_DEVICE_US;
io: o;
io: i;
'}
sIlkUSDeviceName: STRING;
{attribute 'pytmc' := '
pv: ILK_DEVICE_DS;
io: o;
io: i;
'}
sIlkDSDeviceName: STRING;
Expand Down
118 changes: 64 additions & 54 deletions L2SIVacuum/L2SIVacuum.tmc

Large diffs are not rendered by default.

18 changes: 12 additions & 6 deletions L2SIVacuum/POUs/Functions/Valves/Interfaces/FB_VFS_Interface.TcPOU
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,11 @@ VAR_IN_OUT
END_VAR
VAR
{attribute 'pytmc' := '
pv: GFS;
io: i;
'}
sGFS: String;
(*outputs*)
q_xPRESS_OK AT%Q*: BOOL;
{attribute 'pytmc' := '
Expand Down Expand Up @@ -59,47 +63,49 @@ VAR
pv: TRIG;
field: ZNAM TRIG_OFF;
field: ONAM TRIG_ON;
io: io ;
io: i ;
'}
i_xTrigger AT %I* : BOOL;
{attribute 'pytmc' := '
pv: IS_OPEN;
field: ZNAM NOT OPEN;
field: ONAM OPEN;
io: io ;
io: i ;
'}
i_xVFS_Open AT %I* : BOOL;
{attribute 'pytmc' := '
pv: IS_CLOSED;
field: ZNAM NOT CLOSED;
field: ONAM CLOSE;
io: io ;
io: i ;
'}
i_xVFS_Closed AT %I* : BOOL;
{attribute 'pytmc' := '
pv: VAC_FAULT_OK;
field: ZNAM FAULT ;
field: ONAM FAULT OK;
io: io ;
io: i ;
'}
i_xVAC_FAULT_OK AT%I*: BOOL; (*Valve Vacuum OK, is set to False when there is Vacuum Fault*)
{attribute 'pytmc' := '
pv: FFO_OK;
field: ZNAM FAULT ;
field: ONAM FAULT OK;
io: io ;
io: i ;
'}
i_xMPS_OK AT%I*: BOOL;(*MPS Fault OK, is set when the Valve is Open and there is no trigger*)
END_VAR]]></Declaration>
<Implementation>
<ST><![CDATA[(*soft IO Mapping*)
q_xPRESS_OK := IG.xPRESS_OK;
sGFS := IG.sPath;
]]></ST>
</Implementation>
<LineIds Name="FB_VFS_Interface">
<LineId Id="68" Count="1" />
<LineId Id="9" Count="0" />
<LineId Id="163" Count="0" />
<LineId Id="71" Count="0" />
</LineIds>
</POU>
Expand Down

0 comments on commit f912a6c

Please sign in to comment.