(****** QuickLD compiler *******************************)
(****** Copyright Rockwell Automation Canada, Ltd ******)
(****** ST *********************************************)

(*************** Rung **********************************)
(*Set de la Dirección*)
__STEPPRAGMA
0,1
__ENDSTEPPRAGMA
(*Label :*)(**)
__EDTB1 := PF_525_1_CMDFWD_MANUAL AND NOT(PF_525_1_CMDREV_MANUAL) ;
IF __EDTB1 THEN
(*Set coil*)
PF_525_1_DIREC := TRUE ;
END_IF ;

(*************** Code for the end of Rung **************)
__GL __LG0001 ;


(*************** Rung **********************************)
(*Control del PowerFlex 525 (Velocidad): MENSAJERÍA IMPLÍCITA*)
__STEPPRAGMA
0,3
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PF525_VEL *)
RA_PF525_VEL_1(TRUE, PF_525_1_START, PF_525_1_STOP, PF_525_1_JOG, PF_525_1_DIREC, PF_525_1_CLRFLT, PF_525_1_SPEEDREF, PF_525_1_I) ;
PF_525_1_READY := RA_PF525_VEL_1.Ready ;
PF_525_1_ACTIVE := RA_PF525_VEL_1.Active ;
PF_525_1_FLT := RA_PF525_VEL_1.Faulted ;
PF_525_1_OUTFREC := RA_PF525_VEL_1.OutputFreq ;
PF_525_1_ACTDIREC := RA_PF525_VEL_1.ActualDir ;
PF_525_1_ATREF := RA_PF525_VEL_1.AtRef ;
PF_525_1_O := RA_PF525_VEL_1.Ref_Output ;

(*************** Code for the end of Rung **************)
__GL __LG0002 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,12
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_2(TRUE, '192.168.10.12', 1000, 3) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_2.CIPErrorStatus ;
PF_525_1_OUTCURRENT := RA_PFx_ENET_PAR_READ_2.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0003 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,17
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_3(TRUE, '192.168.10.12', 1000, 4) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_3.CIPErrorStatus ;
PF_525_1_OUTVOLTAGE := RA_PFx_ENET_PAR_READ_3.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0004 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,22
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_4(TRUE, '192.168.10.12', 1000, 5) ;
PF_523_1_ERROR := RA_PFx_ENET_PAR_READ_4.CIPErrorStatus ;
PF_525_1_DCBUSV := RA_PFx_ENET_PAR_READ_4.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0005 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,27
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_5(TRUE, '192.168.10.12', 1000, 27) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_5.CIPErrorStatus ;
PF_525_1_DTEMP := RA_PFx_ENET_PAR_READ_5.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0006 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,32
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_6(TRUE, '192.168.10.12', 1000, 21) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_6.CIPErrorStatus ;
PF_525_1_EKWH := RA_PFx_ENET_PAR_READ_6.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0007 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,37
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_7(TRUE, '192.168.10.12', 1000, 23) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_7.CIPErrorStatus ;
PF_525_1_ENESAV := RA_PFx_ENET_PAR_READ_7.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0008 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,42
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_1(TRUE, '192.168.10.12', 1000, 25) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_1.CIPErrorStatus ;
PF_525_1_ACCCOSTSAV := RA_PFx_ENET_PAR_READ_1.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG0009 ;


(*************** Rung **********************************)
(*Lectura de Parámetros adicionales: MENSAJERÍA EXPLICITA*)
__STEPPRAGMA
0,47
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_READ *)
RA_PFx_ENET_PAR_READ_8(TRUE, '192.168.10.12', 1000, 7) ;
PF_525_1_ERROR := RA_PFx_ENET_PAR_READ_8.CIPErrorStatus ;
PF_525_1_ERRORCODE := RA_PFx_ENET_PAR_READ_8.ParameterValue ;

(*************** Code for the end of Rung **************)
__GL __LG000A ;


(*************** Rung **********************************)
(*Escribir tiempo de aceleración*)
__STEPPRAGMA
0,52
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_WRITE *)
RA_PFx_ENET_PAR_WRITE_1(TRUE, '192.168.10.12', 1, 41, PF_525_1_ACCEL_TIME1) ;
PF_525_1_ERRORW := RA_PFx_ENET_PAR_WRITE_1.CIPErrorStatus ;

(*************** Code for the end of Rung **************)
__GL __LG000B ;


(*************** Rung **********************************)
(*Escribir tiempo de desaceleración*)
__STEPPRAGMA
0,58
__ENDSTEPPRAGMA
(*Label :*)(**)
(* FB call: RA_PFx_ENET_PAR_WRITE *)
RA_PFx_ENET_PAR_WRITE_2(TRUE, '192.168.10.12', 1, 42, PF_525_1_DECEL_TIME1) ;
PF_525_1_ERRORW := RA_PFx_ENET_PAR_WRITE_2.CIPErrorStatus ;

(*************** Code for the end of Rung **************)
__GL __LG000C ;


(*************** Code for the end of File **************)
__GL __LG0000 ;



(*************** Local Symbols table *******************)
(* __EDTB1 *)

