




版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Power Programming Hands-On Training,Ulrich Arlt Achim Thomsen GOTC Principal Engineer,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,What is Power Programming?,Power Programming is the suggested Base Template for Rockwell A
2、utomations Sample Code Library The Basic Templates includes A PackML conforming Code Standard using S88 Terminology An Interface for Using and Developing Modular Programs for Machines Hooks to build own Application Notes and use Rockwells build-up of distributable code If you are interested in learn
3、ing more about Power Programming before going through the Training, please select one of the following buttons If you are familiar with the concepts you can also page down to the next slide to receive an overview of the Lessons given.,Background to S88 and PackML,Introduction to the Power Programmin
4、g Template,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Power Programming Predicaments How to get started,Power Programming makes use of a lot of Logix and View Technologies It is strongly recommended to make yourself familiar with the following concepts in theory or in practical tr
5、ainings Logix Task Model / Logix Program Model Subroutines Logix Data Model / Building UDTs / Aliasing Logix Instruction Set This document is supposed to give help to Application Programmers that know Machines and have a basic understanding of Code Design and who want to learn, how Rockwells Applica
6、tion Engineers would design their application.,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson Overview,Copying Equipment Modules,Integrating a new Command / Condition,Advanced Calling,Routine Diagnostics,Integrating a new Command / Condition Advanced,Integrating a second Equipm
7、ent Phase,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 1 Copying Equipment Modules,You need the same or a similar functionality as an existing Equipment Module 01. How can you easily copy the functionality?,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson
8、1: Brief Background Copying Equipment Modules,Equipment Modules attach to a Unit. The Unit covers the Mode / State / Command of the Unit / Machine. The Equipment Modules associated will receive the commands, run the required activities and respond with a Condition to allow the Unit to advance the st
9、ate. In order to copy an Equipment Module the following data will have to be established The Units Command UDT needs to be referenced in the Equipment Module Data We will do this by copying the program tags and aliases to the Controller data The Equipment Modules Condition UDT needs to be referenced
10、 in the Unit Data We will use the existing spare EM configuration in Controller memory The links to all physical devices (Aliases to Controller Data) need to be established We will use an Axis object in this example The HMI screen needs to be copied / the links need to be established to the new data
11、 We will create a new screen and use Tag Substitution To learn more About the S88 Terminology implied PP S88.PPT About the Command Condition Interface PP Program Structure.PPT About the Data exchange PP Data Structure.PPT,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 1: Illust
12、ration of Data Flow Data passed from Unit to Equipment Module,The Equipment Module uses an alias called Unit to access Unit Level Data in Controller scope All data flow in the form of Modes, States and Commands from Unit to Equipment Module happens via this alias,Copyright 2005 Rockwell Automation,
13、Inc. All rights reserved.,Lesson 1: Illustration of Data Flow Unit Level Access of Equipment Module Data,The Equipment Module uses an alias called L_EMConditions to publish its Data to the Equipment Module Conditions in Controller Scope All Status Information flow in form of Conditions from Equipmen
14、t Module to Unit happens via this alias,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 1: Lab Overview Copying Equipment Modules,Step 1: We will copy the Equipment Module Program In our example we will concentrate on a copy within the same controller within the same task. There
15、 is no difference in the implementation within a separate Task. To distribute Equipment Modules for a unit across multiple Processors the Tags need to be communicated. The Unit Tag will be produced to the Processor containing the Equipment Module, the Equipment Module Tag will be produced to the Pro
16、cessor containing the Unit Unit and Equipment Module Tags are unidirectional Step 2: We will link the Physical Data In our example we will use an Axis. There is no difference in the implementation for Discrete IO, Networked IO or Message Instructions Logix uses the same principle of addressing Step
17、3: HMI / Data Modification Both in the Logix and HMI configuration some data points need to be adapted.,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 1: Step 1 Copying Equipment Module Program,Copy the Program EM02_Conveyor and Rename it to Copy the Axis S06_N01_Conveyor and R
18、ename it to,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 1: Step 2 Copying Equipment Modules Hardware Addressing,Create the hardware of the axis Change the Alias of the following Tags in the Program EM03_Conveyor1 To this Alias,Copyright 2005 Rockwell Automation, Inc. All rig
19、hts reserved.,Lesson 1: Step 3 Copying Equipment Modules Data / HMI,In the Logix5000 Project Set the Bit EM03_Conditions.Selected in the Routine R07_CONDITIONS_Modules from the Program UNIT01_ExampleMachine to 1 This bit enables the Condition Interface In the HMI Copy the HMI Screen S102_EM_02 Renam
20、e it to S103_EM_03 Change the Parameter file from this to Buttons to the Parameter file you will use (EM_03_Para) Copy the button for the EM Diag. screen in the Global Object Main_Control Paste and change the Parameter file also to EM_03_Para and the label to EM03 Diag. Screen Now you can test your
21、Program via the HMI, once you have changed the link to your Processor,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,End of Lesson,Return to Lesson Selection,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Integrating a new Command / Condition,After Homing an ad
22、ditional Move is required to put the system Axis into the right position to execute the CAM Profile. - Typical Application: CAM Recovery,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2: Background Command Condition Interface,The Command Condition Interface translates Unit Phas
23、e States into Equipment Module Commands. The States of a Phase are predefined by S88. The Commands and corresponding Conditions are specific to an Application / Way of thinking of the engineer. Commands and Conditions are flexible A Command can be called in multiple States within the same Phase A Co
24、mmand can be called in multiple Phases in the same or different States Multiple Commands can be executed in parallel or in sequence within one State Commands and Condition make for good documentation As the engineer describes the Machine Start / Load or Safety Sequence, he/she effectively creates th
25、e Interface with all activities A Table overview of the commands executed in each state will allow the Maintenance / Customer Engineer a better understanding about the technology of the equipment Commands are broadcast from the Unit to all Equipment Modules, Conditions are unicast from the Equipment
26、 Module to the Unit,16,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Control Module (Routines),Equipment Module,Command Condition Information Flow,Execution Structure,Unit,Equipment Phase,Equipment Phase Routines,Conditions Module,Control Module (Routines),Control Module (Routines),C
27、ontrol Module (Routines),Phase,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Overall Data Interface Unit to Equipment Module in Power Programming - Commands -,Commands are broadcast from the Unit to all associated Equipment Modules Conditions are unicast from the Equipment Module to
28、the associated Unit,Unit 2,Unit 1,Equipment Module 1,Equipment Module 2,Equipment Module 3,Equipment Module 4,Equipment Module 5,(optional),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Lab Overview Integrating a New Command / Condition,In order to integrate a New Command /
29、Condition the following areas need to be modified: Data Structures The new Command has to be entered into the Command Interface in the Unit We will name this the Drive_to_Offset Command The new Condition has to be entered into the Condition Interface in the Equipment Module We will name this Drive_t
30、o_OffsetDone Equipment Module Program (s) A new Routine and call to a Routine will be entered We will name this R04_Drive_to_Offset The required Activity will be programmed We will use an MAM. Handshaking (Active and Done Conditions) will be programmed Unit Level Resetting Commands in Aborted Placin
31、g the Command into the Sequence We will use the Resetting State (=Starting in PackML) Generate a new Collective Condition rung in the Machine Conditions for all Modules (All_Done),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Step 1 Integrate a new Command and Condition in t
32、he UDTs,Task Before executing a CAM the Slave Axis needs to be indexed to a defined offset position Create a new member in the UDT_Commands Create a new member in the UDT_Conditions Background: The Command and Condition Structure are global for all Equipment Modules. This does not mean that all Equi
33、pment Modules need to have a programmed Activity (in our case an MAM) enclosed in it. But it does mean that all Equipment Modules need to respond to the Command (by default by using an immediate XIC Command OTE Condition),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Step 2
34、Integrate a new Command and Condition,Create a new Routine and name it R04_drive_to_offset_position This needs to be done in all Equipment Modules Create the call to the new routine in the Main Routine of the Equipment Module,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Ste
35、p 3 Integrate a new Command and Condition,Routine Contents: Rung 0: Set of the DriveToOffset_active Bit.,Rung 1: Programming the Acitivity (MAM to Position 150) for this Routine,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Step 4 Integrate a new Command and Condition,Rung 2
36、: This Rung signals to the Unit that the Equipment Module has finished the execution of the Command.,Rung 3: If the command is deactivated, the Done Bit and the Active Bit will be reset,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 2 Step 5 Integrate a new Command and Conditio
37、n,Add a new Branch Level in Rung 0 in the Routine Resetting in the Phase U01PH01_Automatic_State_Machine Remark: Any Command can be activated in any State of any Phase Syntactically, though it probably only makes sense in a couple of States,Copyright 2005 Rockwell Automation, Inc. All rights reserve
38、d.,Lesson 2 Step 6 Integrate a new Command and Condition,Add a new Rung in the Routine R07_CONDITIONS_Modules within the Program UNIT01_ExampleMachine Add the Unlatch Command in the Routine S02_ResetCommands within the Phase U01PH01_Automatic_State_Machine,Copyright 2005 Rockwell Automation, Inc. Al
39、l rights reserved.,End of Lesson,Return to Lesson Selection,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Advanced Calling,Advanced Calling is used to optimize execution time by selectively calling the routines for the active commands only,Copyright 2005 Rockwell Automation,
40、 Inc. All rights reserved.,Lesson 4 Background 1 Advanced Calling,Advanced Calling defines a mechanism to significantly increase performance on the Equipment Module Level In a simple Machine with 4-5 Machine Modules and a small set of Services within each Module there is no requirement to increase t
41、he complexity of the call. This is essentially what the Basic Code has been designed for In a larger Machine or a Machine that requires an enhanced performance scope Scan Time Optimization will be a strong requirement for the engineering and development process This is essentially what the Advanced
42、Code has been designed for Take a machine with 15 modules and 12 commands and the product will easily be 180 routines executing each scan. Advanced Calling provides a basis to reduce the scan time overhead. Advanced Calling does not change the Command-Condition Interface Advanced Calling can be impl
43、emented for specific Control Modules Advanced Calling requires the engineer to properly initiate and terminate each Command after completion or in a case of an aborted Command. Advanced Calling uses a predefined sequence within each Routine / Programmed Function to establish Control Module Consisten
44、cy See next slides,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Background 2 Basic vs. Advanced Calling Paradigm,Unit,Unit,Phase States,Commands,Equipment Module,Control Module / Instruction,Equipment Module,CM/ Instruction,Phase States,Commands,Copyright 2005 Rockwell Auto
45、mation, Inc. All rights reserved.,Lesson 4 Background 3 Advanced Calling ROUTINE Requirements,On first scan Reset Conditions (includes .EN bit of Active Edge Instructions) Enable Latching of Routine Active for Execution Continuously Execute Required Commands Report Result On Command Abort Run requir
46、ed Reset of Activities, e.g. Stop the Axis, preset the Timer On Command Termination Unlatch the Routine Active for Execution,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4: Lab Overview Advanced Calling Mechanisms,Step 1: Invocation We will look at the Routine (Control Module
47、) Invocation within the Equipment Module. The same or a very similar mechanism can be used for every Advanced Calling Module Step 2: First Scan and Routine Latching We will look at how the Routine starts its execution with a New Command, and how it will make sure that it will re-execute until it has
48、 completed or aborted the activities. Step 3: Continuous Execution We will look at the normal execution of a Power Programming Control Module We will use an Axis Enable function as the example We will look at how to communicate a Normal Completion of the Activity. Step 4: Reset after Completion We w
49、ill look at how to deal with normal Command Completion Step 5: Abort of a Command We will look at how to ensure Module Integrity after a Command has been aborted.,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Step 1 Advanced Calling Invocation in the Equipment Module,Example
50、 for the Calling of the Routine The Enable Command is the primary source for execution passed by the Sequence of the step in the Phase that is currently active. Enable_Active is the Routine Execution Latching Bit. It is used to latch the calling of the Routine as long as the Activity has not complet
51、ed or terminated. This Bit is also used in the first Scan of a New Command to reset / preset values for the Activity of the Control Module. (See next Slide),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Step 2 Advanced Calling First Scan & Latching,Routine Structure: Rung 0:
52、 Reset of Timers, Error Bits and Enable Bits of Motion instructions, by monitoring the Active Bit condition,Rung 1: By default the Routine Latching Bit is set,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Step 3 Advanced Calling Normal Execution,Rung 2+3 (in this example): e
53、xecution of the functionality of this Routine (Enable the Motor),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Step 4 Advanced Calling Normal Termination,Rung 4: By setting the CommandDone bit this rung indicates to the EM and the Phase that the Module has finished executing
54、 the active Command,Rung 5: If the Command becomes inactive, the latching and done bits are unlatched.,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 4 Step 5 Advanced Calling Command Termination,Rung 6: Abort the Active Command (Reset of Values, Stop the Motor) if the Command
55、terminates without the completion of the Activity (Done = 0),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,End of Lesson,Return to Lesson Selection,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 5 Routine Diagnostics in Advanced calling,How to integrate Diagnost
56、ic functions on an Equipment Module Level (e.g. for Motion Error bits),Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 5 Diagnostic of the Routines,Create a UDT for the faults for the Equipment Module,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 5 Diagnos
57、tic of the Routines,Create this Tags in Controller Scope Create this Tags in Program Scope from the Program EM_03_Conveyer1 Integrate the Watchdog Timer in each Routine in this way,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 5 Diagnostic of the Routines,Integrate the Error L
58、atching in the following scheme Reset the Watchdog timer in Rung 0 of each Routine,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 5 Diagnostic of the Routines,Tags to create in Program Scope Tags to create in Contoller Scope,Copyright 2005 Rockwell Automation, Inc. All rights r
59、eserved.,Lesson 5 Diagnostic of the Routines,R16_Fault_Reset to Reset all Fault Conditions R13_AxisFaultsSERCOS for Error checking,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,End of Lesson,Return to Lesson Selection,Copyright 2005 Rockwell Automation, Inc. All rights reserved.,Lesson 6 Integrate a new Command and Condition usin
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2023八年级数学上册 第13章 全等三角形13.3等腰三角形 2等腰三角形的判定教学设计 (新版)华东师大版
- DNA分子的结构和复制课件
- 合同协议-快速卷帘门购销合同6篇
- 九年级历史下册 第六单元 走向和平发展的世界 第20课 联合国与世界贸易组织教学设计 新人教版
- 一年级品德与社会上册 3 我的一天《我很整洁》教学设计 新人教版
- 九年级化学下册 第七章 第二节 常见的酸和碱教学设计 (新版)沪教版
- 主题三:红色之美 第8课《 人民的光荣-朱德》(教学设计)川教版四年级上册综合实践活动
- 6《古对今》第二课时 教学设计-2024-2025学年语文一年级下册统编版
- 1 《用身体说话》(教学设计)-2023-2024学年四年级下册综合实践活动长春版
- 1 茶香四溢第2课时(教案)-2023-2024学年浙美版(2012)美术四年级下册
- 2025年铅锌矿项目可行性研究报告
- 玻璃更换施工方案
- 2025年中国职工保险互助会贵州省办事处招聘笔试参考题库含答案解析
- 2024年四川省成都市中考地理+生物试卷真题(含答案解析)
- 2024年江苏省苏州市新区中考一模语文试卷
- 精美教案封面(共1页)
- 考试焦虑量表TAI(共2页)
- 初中趣味数学(课堂PPT)
- 刘也-酯交换法聚碳酸酯生产工艺设计和制备
- 砌筑工程计量计价-砌筑工程计量计价
- 直销团队管理办法范本
评论
0/150
提交评论