E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved.
Rev. February 2007 Rev. February 2007
MTCe56r
Exercise: Modifying Timer and Exercise: Modifying Timer and Counter Instructions in an Counter Instructions in an RSLogix 5000 Project RSLogix 5000 Project
In this exercise, you will practice modifying the appropriate timer and counter instructions to meet given functional specifications.
Context:
You are responsible for portions of the Logix5000 ladder logic projects in the steel mill process. Your supervisor has assigned you the task of troubleshooting the Logix5000 Conveyor System program.
Your supervisor has informed you of the following key points concerning this program:
• A pushbutton on the works tation will indicate fe edback that coke is being loaded or not loaded.
• It takes 8 seconds for the oper ator to load the coke on to each conveyor system.
• A ladder logic instr uction will keep trac k of the time and retain the time until it is reset, even if the loading process is interrupted.
• A pushbutton on the workst ation will reset the conve yor count once every 24 hour period.
• Once the conveyor system has bee n enabled by an operator for five cycles it should trigger an automatic preven tive maintenance alarm.
For help performing steps in this exercise, see the associated job aid(s).
Directions:
1.
1. Open the MTC_1756r_A1.acd MTC_1756r_A1.acd project file.
2.
2. Determine the tag name, base tag, and the workstation device for the digital inputs used in the program North_Conveyor:
Workstation Workstation Device
Device TTaag g NNaamme e BBaasse e TTaag g ((iinnppuutt))
Exercise A
Exercise A
10
10 ---- 1818 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved. Rev. Rev. February February 20072007 MTCe56r 3.
3. Determine the tag name, base tag and the workstation device for the digital outputs used in the program North_Conveyor:
Workstation Workstation Device
Device Tag Tag NameName Base Base TagTag (output) (output)
4.
4. Determine the tag name, base tag and the workstation device for the digital inputs used in the program South_Conveyor:
Workstation Workstation Device
Device TTaag g NNaamme e BBaasse e TTaag g ((iinnppuutt))
5.
5. Determine the tag name, base tag and the workstation device for the digital outputs used in the program South_Conveyor:
Workstation Workstation Device
Device Tag Tag NameName Base Base TagTag (output) (output)
6.
6. In the North Conveyor progr am, what is the prese t value of the counter on rung 1?
7.
7. How many times w ill the operator need to enable the coun ter in the North Conveyor program before the North_Conveyor output will be enabled?
8.
8. In the North Conveyor progr am, modify the prese t value of the counter on rung 1 so that each time the operator enables the rung the North_Conveyor output will be enabled.
9.
9. In the North Conveyor progr am, what did you change the prese t value of the counter on rung 1 to?
10.
10. In the South Conveyor progra m, what is the preset value of thecounter on rung 1?
10 10 ---- 1919 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved.
Rev. February 2007 Rev. February 2007
MTCe56r 11.
11. In the South Conveyor progra m, modify the preset valu e of the counter on rung 1 so that each time the operator enables the rung the South_Conveyor output will be enabled.
12.
12. In the South Conveyor progra m, what did you change the preset value of the counter on rung 1 to?
13.
13. Download the project to the controller in slot 1 and go online.
14.
14. In the North Conveyor progr am, what condition or condit ions cause rung 3 to be true?
15.
15. In the North Conveyor prog ram, what happen s when rung 3 is true?
16.
16. In the North Conveyor prog ram, what type of timer is used ?
17.
17. In the South Conveyor progra m, what type of timer is used?
18.
18. What type of timer is used to retain the acc umulated value if ther e is a power loss or the rung is disabled for some reason?
19.
19. Go offline and modify the timer , if needed, in both programs, to the type that will retain its accumulated value if there is a power loss, etc.
20.
20. In what program did you modify the timer type and wha t type did you change it to?
21.
21. In the North and South Conveyor prog rams, modify the preset value for the timers to time for 8 seconds.
22.
22. In the North Conveyor prog ram, what will caus e rung 3 to become false, and what will happen when it becomes false?
23.
23. In the North Conveyor prog ram, which bit will enable the cou nter on rung 5?
10
10 ---- 2020 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved. Rev. Rev. February February 20072007 MTCe56r 24.
24. In the North Conveyor progr am, modify the prese t value of the counter on rung 5 to the correct value.
Use the project documentation (the rung comments) to determine what should occur on the rung.
25.
25. In the South Conveyor progra m, modify the preset value of the counter on rung 5 to the correct value.
26.
26. Download the project and verify that both program s contain an RTO timer.
27.
27. Start the project and verif y the following inputs and outputs in the North_Conveyor program on the workstation and in the project:
A.
A. Enable the pushbutto n input DI1 and verify that the counter counts up and the North_Conveyor output (DO0) is enabled.
B.
B. Enable the pushbutto n input DI2 for 8 seconds while the RTO timer times which simulates coke loading onto the conveyor.
C.
C. Verify that the North_Coke_Loading_Timer.DN bit is enabled after 8 seconds and that the preventive maintenance counter incremen ts by 1.
28.
28. Verify the following inputs and outputs in the South_Conveyor program on the workstation and in the project:
A.
A. Enable the pushbutto n input DI8 and verify that the counter counts up and the South_Conveyor output (DO5) is enabled.
B.
B. Enable the pushbutto n input DI10 for 8 seconds while the RTO timer times which indicates that coke loading onto the conveyor.
29.
29. In the North Conveyor progr am, what is the purpose of rung 0?
30.
30. In the North Conveyor progr am,what is the purpos e of rung 1?
31.
31. In the South Conveyor program ,what is the purpose of rung 4?
32.
32. In the North Conveyor program, descr ibe what will happen when the inputs and outputs on rung 5 are enabled?
33.
33. Go offline.
"
Tip
Tip
10 10 ---- 2121 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved.
Rev. February 2007 Rev. February 2007
MTCe56r 34.
34. Save the project.
Turn to the Answers section.
How Did You Do?
How Did You Do?
10
10 ---- 2222 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved. Rev. Rev. February February 20072007 MTCe56r
Exercise A Exercise A
2.
2. The following table lis ts the the tag name, base tag and the workstation device for the digital inputs used in the program
North_Conveyor:
DII0 0 NNoorrtthh__PPuusshhBBuuttttoonn__RReesseett__CCoouunntteer r LLooccaall::22::II..DDaattaa..00 D
DII1 1 NNoorrtthh__SSttaarrtt__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..11 D
DII2 2 NNoorrtthh__CCookkee__LLooaaddiinngg__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..22 D
DII3 3 NNoorrtthh__PPuusshhBBuuttttoonn__RReesseett__TTiimmeer r LLooccaall::22::II..DDaattaa..33 D
DII4 4 NNoorrtthh__SSttoopp__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..44 D
DII5 5 NNoorrtthh__PPuusshhBBuuttttoonn__RReesseett__PPMM__CCoouunntteer r LLooccaall::22::II..DDaattaa..55
3.
3. The following table lis ts the the tag name, base tag and the workstation device for the digital outputs used in the program
North_Conveyor:
DOO0 0 NNoorrtthh__CCoonnvveeyyoor r LLooccaall::00::OO..DDaattaa..00 D
DOO1 1 NNoorrtthh__PPMM__AAllaarrm m LLooccaall::00::OO..DDaattaa..11
4.
4. The following table lis ts the the tag name, base tag and the workstation device for the digital inputs used in the program
South_Conveyor:
DII6 6 SSoouutthh__SSttoopp__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..66 D
DII7 7 SSoouutthh__PPuusshhBBuuttttoonn__RReesseett__CCoouunntteer r LLooccaall::22::II..DDaattaa..77 D
DII8 8 SSoouutthh__SSttaarrtt__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..88 D
DII9 9 SSoouutthh__PPuusshhBBuuttttoonn__RReesseett__TTiimmeer r LLooccaall::22::II..DDaattaa..99 D
DII110 0 SSoouutthh__CCookkee__LLooaaddiinngg__PPuusshhBBuuttttoon n LLooccaall::22::II..DDaattaa..1100 D
DI1I11 1 SSoouuthth__PPuushshBBuuttttoonn_R_Reesseet_t_PMPM__CCoouunnteter r LLooccaal:l:22:I:I.D.Datataa.1.111
5.
5. The following table lis ts the the tag name, base tag and the workstation device for the digital outputs used in the program
South_Conveyor:
DOO5 5 SSoouutthh__CCoonnvveeyyoor r LLooccaall::00::OO..DDaattaa..55 D
DOO6 6 SSoouutthh__PPMM__AAllaarrm m LLooccaall::00::OO..DDaattaa..66
6.
6. The preset value is 10.
Answers
Answers
10 10 ---- 2323 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved.
Rev. February 2007 Rev. February 2007
MTCe56r 7.
7. The operator will have to enable the counter by pressi ng the North_Start_Pushbutton (DI1) on the workstation 10 times before the done bit (.DN) will enable the North_Conveyor output (DO0).
9.
9. The preset value could have be en changed to 0 or 1.
10.
10. The preset value is 8.
12.
12. The preset value could have be en changed to 0 or 1.
14.
14. Rung 1 must be enabled in order for the North_C onveyor output (DO0) to enable rung 3. Also, the
North_Coke_Loading_PushButton must be enabled. These 2 conditions will then cause the North_Coke_Loadin g_Timer to be enabled.
15.
15. The North_Coke_Loading_Timer will time.
16.
16. The North Conveyor program contains an RTO timer.
17.
17. The South Conveyor programs contains a TON timer.
18.
18. An RTO timer is the type of timer used if the accumulated value needs to be retained if an interruption occurs during the timing process.
20.
20. In the South_Convey or program. It should have bee n changed to an RTO timer.
22.
22. If the North_Sto p_PushButton (DI4) is enabled, the
North_Conveyor output (DO0) will become disabled . Also, if the North_Coke_Loa ding PushButton is disabled the rung becomes false and the timer stops timing.
23.
23. The North_Coke_Loading_Timer.DN bit.
29.
29. This rung contains the RES ins truction for the counter on rung 1.
30.
30. This rung will enable the Nor th_Conveyor output (D O0) and count how many times the rung transitions from false to true.
31.
31. This rung contains the RES ins truction for the counter on rung 5.
32.
32. Each time the North_Coke_Loading_Timer.DN bit is enabled the North_Conveyor_ PM_Counter will count. Once the counter has reached the preset value (5) the
North_Conveyor_PM_Counter.DN bit will enable the North_PM_Alarm output (DO1).
10
10 ---- 2424 Exercise: Modifying Timer and Counter Instructions in an RSLogix 5000 Project
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved. Rev. Rev. February February 20072007 MTCe56r
Lesson Lesson 1 11 1
E 2007 Rockwell Automation, Inc. All rights reserved.2007 Rockwell Automation, Inc. All rights reserved.
Rev. February 2007
After completing this lesson, you should be able to modify program control instructions.
Why These Skills Are Important Why These Skills Are Important
Knowing when and how to change the flow of logic will help you more effectively and efficiently modify ladder logic according to your project.
Program Control Instructions Program Control Instructions
Program control instructions are used to change the flow of logic.
The following table outlines the use of program control instructio ns:
Use this instruction . . . Use this instruction . . . If you want to . . . to the routine, execute the
to the routine, execute the routine,, , routine,,,SSuubbrroouuttiinne e SSBBRR and return results
and return results RReettuurrn n ffrroom m SSuubbrorouuttiinne e RREETT Jump over a section of logic that does
Jump over a section of logic that does not always need to
not always need to be executed orbe executed or JJuummp p tto o LLaabbeel l JJMMPP repeat a section of logic until certain
repeat a section of logic until certain conditions are met
conditions are met LLaabbeel l LLBBL L Disable all the rungs in a section of
Disable all the rungs in a section of logic
logic MMaasstteer r CCoonnttrrool l RReesseet t MMCCRR D
Diissaabblle e uusseer r ttaasskks s UUsseer r IInntteerrrruuppt t DDiissaabblle e UUIIDD E
Ennaabblle e uusseer r ttaasskks s UUsseer r IInntteerrrruuppt t EEnnaabblle e UUIIEE Mark a temporary end that halts
Mark a temporary end that halts routine execution
routine execution TTeemmppoorraarry y EEnnd d TTNNDD D
Diissaabblle e a a rruunng g AAllwwaayys s FFaallsse e IInnssttrruuccttiioon n AAFFII IInnsseerrt t a a ppllaacceehhoollddeer r iin n tthhe e llaaddddeer r llooggiic c NNo o OOppeerraattiioon n NNOOPP For more information on program control instructions and their functionality, see the Documentation Reference Guide.
What You Will Learn What You Will Learn
Before You Begin Before You Begin
Mention that in RSLogix 5000 software Mention that in RSLogix 5000 software the Help drop-down menu could be used the Help drop-down menu could be used as an
as an online user manual. Tell studentsonline user manual. Tell students they will be able to find a substantial they will be able to find a substantial amount of information on ladder logic amount of information on ladder logic instructions, among other useful