kevin91172
Member
PLC 06
I am trying to program a 2 hour oven batch timer using 1 60 timer that counts up a minute counter that counts up a hour counter. Next I want to display this 2 hour count down on a EZ-T10C-F HMI.Now how can I not put preset minutes the counter and just put 2 in the hour counter for this thing to work. I am just confusing myself. Any suggestions? The below is just not working for me.
// Rung 1
// Address 0
STR SP0
LD K400
OUT V700
LDA O2000
OUT V701
LD K0
OUT V703
OUT V704
OUT V706
// Rung 2
// Address 9
STRN T0
TMRF T0 K1000
// Rung 3
// Address 13
STR T0
LD V3005
BTOR
DIVR R4.0949998
RTOB
BCD
OUT V1400
// Rung 4
// Address 22
STRN T0
TMRF T1 V1400
// Rung 5
// Address 25
STR X30
SET C0
// Rung 6
// Address 27
STR CT1
AND CT3
RST C0
// Rung 7
// Address 30
STRN T1
ANDNE TA1 K0
AND X1
AND V2002 K5000
OUT Y0
// Rung 8
// Address 37
STR V2000 V3002
AND C0
STRN C0
OR T2
TMRA T2 K20
// Rung 9
// Address 45
STR T2
STRN C0
OR CT0
CNT CT0 V5000
// Rung 10
// Address 50
STR CT0
STR CT3
CNT CT3 K3
// Rung 11
// Address 55
STR CT0
STRN C0
CNT CT1 V5002
// Rung 12
// Address 59
STR SP1
ANDN CT3
LD V5000
SUB CTA0
OUT V4000
// Rung 13
// Address 64
STR SP1
LD V5002
SUB CTA1
OUT V4002
// Rung 14
// Address 68
END
// Rung 15
// Address 69
NOP
#BEGIN ELEMENT_DOC
"X1","","","WE HAVE AIR FLOW"
"X2","","","ELEMENT TEMPERATURE TO HIGH"
"X30","","TOUCH SCREEN","START CYCLE"
"X31","","TOUCH SCREEN","RESET CYCLE"
"X41","","TOUCH SCREEN",""
"Y0","","","HEATERS"
"Y1","","","CYCLE IS DONE"
"C0","","","START CYCLE"
"C1","","","RESET CYCLE"
"T0","","","PID LOOP 1 TIMER #1"
"T1","","","PID LOOP 1 TIMER #2"
"CT0","","","Minute counter"
"CT1","","","Hour counter"
"CT2","","","second counter"
"V2000","","","OVEN TEMPERATURE"
"V2002","","","ELEMENT TEMPERATURE"
"V3002","","","OVEN TEMPERATURE SET POINT"
#END
I am trying to program a 2 hour oven batch timer using 1 60 timer that counts up a minute counter that counts up a hour counter. Next I want to display this 2 hour count down on a EZ-T10C-F HMI.Now how can I not put preset minutes the counter and just put 2 in the hour counter for this thing to work. I am just confusing myself. Any suggestions? The below is just not working for me.
// Rung 1
// Address 0
STR SP0
LD K400
OUT V700
LDA O2000
OUT V701
LD K0
OUT V703
OUT V704
OUT V706
// Rung 2
// Address 9
STRN T0
TMRF T0 K1000
// Rung 3
// Address 13
STR T0
LD V3005
BTOR
DIVR R4.0949998
RTOB
BCD
OUT V1400
// Rung 4
// Address 22
STRN T0
TMRF T1 V1400
// Rung 5
// Address 25
STR X30
SET C0
// Rung 6
// Address 27
STR CT1
AND CT3
RST C0
// Rung 7
// Address 30
STRN T1
ANDNE TA1 K0
AND X1
AND V2002 K5000
OUT Y0
// Rung 8
// Address 37
STR V2000 V3002
AND C0
STRN C0
OR T2
TMRA T2 K20
// Rung 9
// Address 45
STR T2
STRN C0
OR CT0
CNT CT0 V5000
// Rung 10
// Address 50
STR CT0
STR CT3
CNT CT3 K3
// Rung 11
// Address 55
STR CT0
STRN C0
CNT CT1 V5002
// Rung 12
// Address 59
STR SP1
ANDN CT3
LD V5000
SUB CTA0
OUT V4000
// Rung 13
// Address 64
STR SP1
LD V5002
SUB CTA1
OUT V4002
// Rung 14
// Address 68
END
// Rung 15
// Address 69
NOP
#BEGIN ELEMENT_DOC
"X1","","","WE HAVE AIR FLOW"
"X2","","","ELEMENT TEMPERATURE TO HIGH"
"X30","","TOUCH SCREEN","START CYCLE"
"X31","","TOUCH SCREEN","RESET CYCLE"
"X41","","TOUCH SCREEN",""
"Y0","","","HEATERS"
"Y1","","","CYCLE IS DONE"
"C0","","","START CYCLE"
"C1","","","RESET CYCLE"
"T0","","","PID LOOP 1 TIMER #1"
"T1","","","PID LOOP 1 TIMER #2"
"CT0","","","Minute counter"
"CT1","","","Hour counter"
"CT2","","","second counter"
"V2000","","","OVEN TEMPERATURE"
"V2002","","","ELEMENT TEMPERATURE"
"V3002","","","OVEN TEMPERATURE SET POINT"
#END