SITOP: FB1493 UPS1600 FW2.0

: 2016-09-03

: komatic

: SCL



sitop



UPS1600 driver DrvUPS . .



sitop

PCS7.





Name: FB1493
Symbolic Name: UPS1600
Symbol Comment: SITOP UPS1600
Family: SITOP
Version: 1.2
Author: AdvLibSE
Last modified: 09/29/2015
Use: SFB35,SFC20,SFC6
Size: 4024 byte



IF SwRdReq<>W#16#0 THEN (*A7f1*)
IF (((((AcyclData.ReqRd=-1) AND (AcyclData.SlotRd=-1)) AND (AcyclData.RdyRead=-1)) AND (AcyclData.ReqWr=-1)) AND (AcyclData.SlotWr=-1)) AND (AcyclData.RdyWrite=-1) THEN (*A7f2*)
AcyclData.SlotRd:=1;
IF SwRdReq_b[0] THEN (*A7f3*)
AcyclData.ReqRd:=3;
AcyclData.LenRd:=4;
ELSIF SwRdReq_b[1] THEN (*A7f5*)
AcyclData.ReqRd:=16;
AcyclData.LenRd:=4;
ELSIF SwRdReq_b[2] THEN (*A7f2*)
AcyclData.ReqRd:=32;
AcyclData.LenRd:=64;
END_IF;
END_IF;(*A7f2*)
IF AcyclData.SlotRd=1 THEN (*A7f1*)
CASE AcyclData.RdyRead OF
3:
SwRdReq_b[0]:=FALSE;
AcyclData.ReqRd:=-1;
AcyclData.SlotRd:=-1;
IF AcyclData.RetValRd=W#16#0 THEN (*A7fb*)
Ueoc.Value:=INT_TO_REAL(DWORD_TO_INT((SHR(IN:=(AcyclData.Input.Para0 AND DW#16#FFFF0000),N:=16))))/100.0;
Ueoc.ST:=B#16#80;
ELSE (*A7fb*)
SxRdDrErr:=TRUE;
END_IF;

16:
SwRdReq_b[1]:=FALSE;
AcyclData.ReqRd:=-1;
AcyclData.SlotRd:=-1;
SxReadDr:=FALSE;
IF AcyclData.RetValRd=W#16#0 THEN (*A7ff*)
RstUPSCmdErr:=DWORD_TO_WORD(AcyclData.Input.Para0 AND DW#16#FFFF);
ELSE (*A7ff*)
SxRdDrErr:=TRUE;
END_IF;
32:
SwRdReq_b[2]:=FALSE;
AcyclData.ReqRd:=-1;
AcyclData.SlotRd:=-1;
IF AcyclData.RetValRd=W#16#0 THEN (*A803*)
DataRecord_State_Info[0]:=AcyclData.Input.Para0;
DataRecord_State_Info[1]:=AcyclData.Input.Para1;
DataRecord_State_Info[2]:=AcyclData.Input.Para2;
DataRecord_State_Info[3]:=AcyclData.Input.Para3;
DataRecord_State_Info[4]:=AcyclData.Input.Para4;
DataRecord_State_Info[5]:=AcyclData.Input.Para5;
DataRecord_State_Info[6]:=AcyclData.Input.Para6;
DataRecord_State_Info[7]:=AcyclData.Input.Para7;
DataRecord_State_Info[8]:=AcyclData.Input.Para8;
DataRecord_State_Info[9]:=AcyclData.Input.Para9;
DataRecord_State_Info[10]:=AcyclData.Input.Para10;
DataRecord_State_Info[11]:=AcyclData.Input.Para11;
DataRecord_State_Info[12]:=AcyclData.Input.Para12;
DataRecord_State_Info[13]:=AcyclData.Input.Para13;
DataRecord_State_Info[14]:=AcyclData.Input.Para14;
DataRecord_State_Info[15]:=AcyclData.Input.Para15;
Uin.Value:=INT_TO_REAL(WORD_TO_INT(DataRecord_State_Info_w[11]))/1.000000e+002;
Uin.ST:=B#16#80;
Iout.Value:=INT_TO_REAL(WORD_TO_INT(DataRecord_State_Info_w[17]))/2.000000e+002;
Iout.ST:=B#16#80;
Uout.Value:=INT_TO_REAL(WORD_TO_INT(DataRecord_State_Info_w[13]))/1.000000e+002;
Uout.ST:=B#16#80;
Icharge.Value:=INT_TO_REAL(WORD_TO_INT(DataRecord_State_Info_w[15]))/1.000000e+003;
Icharge.ST:=B#16#80;
Ubatt.Value:=INT_TO_REAL(WORD_TO_INT(DataRecord_State_Info_w[16]))/1.000000e+002;
Ubatt.ST:=B#16#80;
ELSE (*A803*)
SxRdDrErr:=TRUE;
END_IF;
ELSE:
;
END_CASE; (*A7f8*)
END_IF; (*A7f1*)
END_IF;
IF (SwRdReq=W#16#0) AND (SwWrReq=W#16#0) THEN (*A805*)
SxRdWrCfgAct:=FALSE;
END_IF;(*A805*)
IF SxReadDr THEN (*A806*)
SrReadDrWait:=SrReadDrWait+SampleTime;
ELSE (*A806*)
SrReadDrWait:=0.0;
END_IF;(*A807*)





sitop

Block checksum , ,
, .



SITOP APL + manual (zip, 2Mb)







: 1322

.

:

(4000 max):

: