- Added new module status
- Added error messages for EtherCAT connection lost
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1" ProductVersion="3.1.4024.12">
|
||||
<TcPlcObject Version="1.1.0.1" ProductVersion="3.1.4026.8">
|
||||
<POU Name="FB_PowerSupplySunspec" Id="{a826dd09-442c-45c5-8ae3-9b71f293003c}" SpecialFunc="None">
|
||||
<Declaration><![CDATA[FUNCTION_BLOCK FB_PowerSupplySunspec
|
||||
VAR_INPUT
|
||||
@@ -216,6 +216,11 @@ END_IF
|
||||
CASE _iState OF
|
||||
|
||||
0: // Off
|
||||
IF _tonPollingTimer.Q THEN
|
||||
_tonPollingTimer(IN := FALSE, PT := _timPollingDelay);
|
||||
_iState := 1;
|
||||
END_IF
|
||||
|
||||
// If enable and INTLK Ok
|
||||
IF xEnable THEN
|
||||
_iState := 10;
|
||||
@@ -224,10 +229,7 @@ CASE _iState OF
|
||||
_tonPollingTimer(IN := TRUE, PT := _timPollingDelay);
|
||||
END_IF
|
||||
|
||||
IF _tonPollingTimer.Q THEN
|
||||
_tonPollingTimer(IN := FALSE, PT := _timPollingDelay);
|
||||
_iState := 1;
|
||||
END_IF
|
||||
|
||||
|
||||
|
||||
1: // Read inverter status
|
||||
@@ -485,6 +487,7 @@ CASE _iState OF
|
||||
_iState := 25;
|
||||
// Check for valid value
|
||||
IF (_iWMaxSF < -10) OR (_iWMaxSF > 10) OR (_iWMaxSF = 16#8000) THEN
|
||||
ADSLOGSTR(msgCtrlMask := ADSLOG_MSGTYPE_HINT, msgFmtStr := 'FBInverter into error state from: %s', strArg := TO_STRING(_iState));
|
||||
// Goto error state
|
||||
_iState := 1000;
|
||||
END_IF
|
||||
@@ -1190,17 +1193,41 @@ _fbErrorInverterAlarm.CreateEx(stEventEntry := TC_EVENTS.Inverter.InverterError,
|
||||
_fbErrorInverterAlarm.ipArguments.Clear().AddString(_sName);]]></ST>
|
||||
</Implementation>
|
||||
</Method>
|
||||
<Property Name="Name" Id="{ef8c6e8f-7c1b-4781-b201-87f759acb289}">
|
||||
<Declaration><![CDATA[PROPERTY Name : string]]></Declaration>
|
||||
<Get Name="Get" Id="{bc17161e-727d-4abd-a845-a7eacc08f995}">
|
||||
<Declaration><![CDATA[VAR
|
||||
END_VAR
|
||||
]]></Declaration>
|
||||
<Implementation>
|
||||
<ST><![CDATA[Name := _sName;]]></ST>
|
||||
</Implementation>
|
||||
</Get>
|
||||
<Set Name="Set" Id="{7fdecf53-efe5-43de-bc46-5f24fb6a7ffb}">
|
||||
<Declaration><![CDATA[VAR
|
||||
END_VAR
|
||||
]]></Declaration>
|
||||
<Implementation>
|
||||
<ST><![CDATA[_sName := Name;
|
||||
|
||||
_fbErrorInverterAlarm.ipArguments.Clear().AddString(_sName);]]></ST>
|
||||
</Implementation>
|
||||
</Set>
|
||||
</Property>
|
||||
<LineIds Name="FB_PowerSupplySunspec">
|
||||
<LineId Id="774" Count="10" />
|
||||
<LineId Id="1550" Count="0" />
|
||||
<LineId Id="785" Count="3" />
|
||||
<LineId Id="785" Count="0" />
|
||||
<LineId Id="4104" Count="2" />
|
||||
<LineId Id="4103" Count="0" />
|
||||
<LineId Id="4107" Count="0" />
|
||||
<LineId Id="786" Count="2" />
|
||||
<LineId Id="2615" Count="0" />
|
||||
<LineId Id="790" Count="0" />
|
||||
<LineId Id="2614" Count="0" />
|
||||
<LineId Id="2613" Count="0" />
|
||||
<LineId Id="2616" Count="1" />
|
||||
<LineId Id="2906" Count="0" />
|
||||
<LineId Id="2618" Count="2" />
|
||||
<LineId Id="2616" Count="0" />
|
||||
<LineId Id="2619" Count="1" />
|
||||
<LineId Id="3661" Count="0" />
|
||||
<LineId Id="2621" Count="0" />
|
||||
<LineId Id="2623" Count="15" />
|
||||
@@ -1262,7 +1289,9 @@ _fbErrorInverterAlarm.ipArguments.Clear().AddString(_sName);]]></ST>
|
||||
<LineId Id="1725" Count="0" />
|
||||
<LineId Id="1721" Count="0" />
|
||||
<LineId Id="1433" Count="0" />
|
||||
<LineId Id="816" Count="28" />
|
||||
<LineId Id="816" Count="24" />
|
||||
<LineId Id="4096" Count="0" />
|
||||
<LineId Id="841" Count="3" />
|
||||
<LineId Id="1171" Count="0" />
|
||||
<LineId Id="845" Count="5" />
|
||||
<LineId Id="3656" Count="0" />
|
||||
@@ -1429,5 +1458,11 @@ _fbErrorInverterAlarm.ipArguments.Clear().AddString(_sName);]]></ST>
|
||||
<LineId Id="11" Count="0" />
|
||||
<LineId Id="7" Count="1" />
|
||||
</LineIds>
|
||||
<LineIds Name="FB_PowerSupplySunspec.Name.Get">
|
||||
<LineId Id="1" Count="0" />
|
||||
</LineIds>
|
||||
<LineIds Name="FB_PowerSupplySunspec.Name.Set">
|
||||
<LineId Id="1" Count="2" />
|
||||
</LineIds>
|
||||
</POU>
|
||||
</TcPlcObject>
|
||||
Reference in New Issue
Block a user