Examples for Application Programs
330
SICAM RTUs, User Manual SICAM CMIC
DC8-001-2.09, Edition 08.2016
B.7
Speed Comparison
PLC_RESET:
LD 100
ST PLC_CYCLETIME
(*cycle time in ms*)
PLC_INIT:
LD 1000
(*drop off delay in ms*)
ST TOF_FLAENDSTEIG0.PT
ST TOF_FLAENDFALL0.PT
PLC_START:
(*Check speed value on change*)
LD I_034_016_000_000.S
(*load spontaneous bit speed value*)
JMPN NO_CHANGE
(*jump if no change of value*)
(*Change of speed value present*)
LD
I_034_016_000_000.VALUE
(*load speed value*)
ST M_REAL_WERTNEU
(*current speed value to flag*)
ST SUB.IN0
LD M_REAL_WERTALT
(*load old speed value*)
ST SUB.IN1
CAL SUB
(*form difference value*)
ST M_REAL_WERTDIF
(*difference value to flag*)
(*Take over change of value*)
LD M_REAL_WERTNEU
(*load current value*)
ST M_REAL_WERTALT
(*save current value for next *)
(*change of value*)
(*Value comparison speed ascending*)
LD M_REAL_WERTDIF
(*load diff. value*)
ST GT.IN0
LD 0
ST GT.IN1
CAL GT
(*diff. value > 0: speed ascending*)
ST
M_BOOL_DZST
(*set flag speed ascending*)
(*Value comparison speed descending*)
LD M_REAL_WERTDIF
(*load diff. value*)
ST LT.IN0
LD 0
ST LT.IN1
CAL LT
(*diff. value < 0: speed descending*)
ST M_BOOL_DZFA
(*set flag speed descending*)
NO_CHANGE:
(*jump mark if no change of value*)
(*Drop-off delay speed ascending*)
LD M_BOOL_DZST
(*load flag speed ascending*)
ST TOF_FLAENDSTEIG0.IN
CAL TOF_FLAENDSTEIG0
(*drop-off delay*)
LD TOF_FLAENDSTEIG0.Q
ST
O_030_048_000_000.VALUE
(*reset output*)
(*Drop-off delay speed descending*)
LD M_BOOL_DZFA
(*load flag speed descending*)
ST TOF_FLAENDFALL0.IN
CAL TOF_FLAENDFALL0
(*drop-off delay*)
LD TOF_FLAENDFALL0.Q
ST
O_030_049_000_000.VALUE
(*set binary output*)
(*Reset flags for speed ascending, descending*)
LD 0
ST M_BOOL_DZST
(*reset flag speed ascending*)
ST M_BOOL_DZFA
(*reset flag speed descending*)
Summary of Contents for SICAM CMIC
Page 8: ...Preface 8 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 46: ...Installation 46 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 62: ...Interfaces and Circuitry 62 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 102: ...Preparing the Engineering 102 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 334: ...Error Handling 334 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 404: ...Use Cases 404 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 ...
Page 414: ...Glossary 414 SICAM RTUs User Manual SICAM CMIC DC8 001 2 09 Edition 08 2016 X Z ...