当前位置:网站首页>[reprint]rslogix 5000 instance tutorial
[reprint]rslogix 5000 instance tutorial
2022-06-25 23:54:00 【wenroudelang8888】
The software is introduced
RSLOGIX5000 Time America AB Developed by the company for use in PLC Software for product programming . It has the following characteristics :1 Unified project view
2 Flexible ladder editor
3 Drag and drop operations
4 Ladder view options
5 Custom data monitoring
6 Status file classification display
7 Simple communication configuration
8 Powerful database editor
9 Find and replace
10 Intuitive windows Interface
11 Project verification can quickly correct program errors, etc .
Create a project
How to use RSLogix5000, First create a new RSLogix5000 Engineering documents . The specific steps are as follows :1 open RSLogix5000, See the picture 1-1
chart 1-1
The open window is RSLogix5000 The engineering of , See the picture 1-2:
First you have to give PLC Processor definition for , The defined content has a name 、 type 、 The back plate of the rack Slot No 、 Created file path, etc . The processor type here is 1756 L1 controllogix 5550, Name a PLC,description Set it as an exercise , The backplane is set as 13 Slot , Slot No 0 Slot , Path default .
Click on ok Complete set , Show RSLogix5000 Engineering interface
1. First put forward tag( label ) The concept of , label : It is the variable in the actual project , There are analog quantities such as water level 、 pressure 、 temperature . Digital quantity such as switch start and stop 、 Status display, etc . We use it in our programs to program , View status online in the window , The tag value can also be output to the upper computer .
2. Label type
One base Basic types include : 1 BOOL Boolean type 1 BIT
2 SINT Short 1 BYTE
3 INT integer 2 BYTE
4 DINT Double integer 4 BYTE
5 REAL Real type 4 BYTE
Two STRUTURES Type of structure 1 predefined Scheduled to type
chart 1-3
User-defined User defined : This example uses the custom PUMPPARAMETERS For example Define the structure members as ACCTIME,RUNTIME,SEQUENCE,STATUS,FIRSTPUMP, And determine their respective types .
Users can use tag names to refer to members in the structure , The format is :tag_name.member_name.
If the structure is defined as an array , Then use the array label , This is followed by the position in the array (position)
And substructures (substucture) And member name (member). The format is :array_tag[position].member.
The following introduces the concept of alias label : A label used to represent other labels , Useful when defining simplified label names for structural elements or arrays . Users can use the tag editor to create an alias , Or before you enter logic and use new tags (new tag) Dialog box to define an alias, enter the alias label . See the picture 1-5
1. In the tag editor, select the tag that needs to be aliased to alarm For example Can be directly in alias Enter alias under , You can also right click in the blank , Select from the pop-up menu edit tag properties,
Label scope : Users can group tags in a separate program , Or make the label open to the instruction within the controller . When a user defines a label , You need to specify that the tag is used as the program tag ( Local ) Or as a controller label ( overall situation ).
1 The local scope label in the program
Program labels are composed of data that is restricted to routines within the main program . So for the main program , These labels make local . A routine in another program cannot access a program tag in another program .
chart 1-7
2 Global scope label of the controller
The controller tag is composed of data applicable to all routines in the controller , Whatever task or program contains these routines . For control , These labels are global .
Development procedure
1 Tissue engineering
The controller operating system is a preemptive multitask system , follow IEC1131-3 standard . This work platform can provide :1 Multitasking is used to configure the controller to execute ;
2 Programs are used to combine data and logic ;
3 Routines are used to encapsulate executable code written in a programming language .
2 Define the task
A task can provide scheduling and priority information for one or more groups of programs , These procedures are performed according to specific standards , The user can configure the task in continuous mode or periodic mode
Task type | LOGIX5550 The total number of tasks supported by the controller |
Continuous mode | 1 |
Cycle mode | If it includes a continuous task, the controller supports a total of 31 A mission , No is 32 A mission |
Each task in the controller has a priority . When multiple tasks are triggered , The hype system is more wired to decide which task to perform . For periodic tasks , Yes 15 Configurable priority levels , It ranges from 1-15, among 1 Have the highest priority and 15 Has the lowest priority . High priority tasks have the right to interrupt lower priority tasks . Continuous tasks have the lowest priority , Therefore, it can be interrupted by periodic tasks at any time .
A task can have at most 32 A separate program , Each program has its own executable routine and program scope label (program-scoped tags). Once a task is triggered ( To be activated ), Then all the programs assigned to the task will be executed according to their grouping order . The program can only appear once in the project manager of the controller , And cannot be shared by multiple tasks .
Each task has a watchdog timer , Used to monitor the execution of tasks . When the task starts , The watchdog timer starts timing , When all the procedures in the task are completed , The watchdog timer stops .
Here is how to create a task
When the user RSLogix5000 When opening a new controller project in , Main task (Maintask) Has been defined as a continuous task . Users can change the default task type to suit their project .
chart 2-1
Right click... In the above figure tasks, choose new task , The above dialog box pops up .
name | Enter task name |
Description( explain ) | Enter a description of the task |
type | Choose continuous (continuous) Or cyclical (periodic), Control only supports 1 Consecutive tasks .
|
Watchdog( watchdog ) | Default 500 millisecond |
Priority( priority ) | 1-15 |
Rate | For recurring tasks , Indicates how fast the controller is performing tasks |
3 Define the program
Each program contains a program label 、 An executable main routine 、 Other routines and an optional fault routine . Each task can be scheduled at most 32 Procedures .
The program scheduled in the task will run from the first program to the last program . Programs that do not belong to any task will be displayed as bit scheduling programs . Before the controller can scan a program , The user must specify the program in the task .
The following describes how to create a program . When the user opens a new project in the editing software , The main task has been (maintask) A main program is defined (mainprogram). Users can change this program just as they add other programs .
To create a new program :
1 Choose a task ( For this example “maintask”)
2 Click the right mouse button , choice new program See the picture below 2-2
The following dialog box will pop up
Above picture schedule in ( Scheduled on ) Define the tasks of the user scheduler . The programming software will display a list of available tasks .
4 Define routines
A routine is a set of logic instructions written in a programming language . For example, ladder logic . Routines provide executable code for projects in the controller . Routines are similar to plc or slc A program file or subroutine of a processor instance .
Each program has a main routine . When the controller starts the associated task and invokes the associated program , The process of first implementation in major cities . Other routines can be called with logic , for example JSR Instructions .
The user can also develop an optional program fault routine . When the controller encounters instruction execution failure in the course of the associated program (instrution-execution fault) when , The controller executes the specified fault routine .
Here's how to create a routine
When the user opens a new project in the editing software , Has been the main program (mainprogram) Defines a main routine (mainroutine). The user can change the main routine just like adding other programs .
To create a new routine :
1 1 Select a program ( For this example “mainprogram”)
2 Click the right mouse button , choice new routine See the picture below 2-3
The following dialog box will pop up
In the diagram above in program ( Program ) Define the program that the user plans to run the routine . The programming software will display a list of available programs .
5 Input ladder logic
logix5550 The controller supports the format that each step in the logic program contains multiple output instructions . The output instructions in the rung can be arranged in order ( Series connection ) Or mixed input and output instructions , As long as the last instruction in the rung is an output instruction .
The controller according to the step condition before the command ( Step input conditions ) To determine the ladder instruction . Input conditions and instructions according to the steps , The controller sets the step condition following the command ( Step input conditions ) Then follow the order of instructions , Will affect subsequent instructions .
chart 2-5
If the step input condition of an input command is true (true), This controller will determine the command and set the step input condition according to the command result . If the instruction is determined to be true ; If the instruction is false (false), This step output condition is false .
The output command does not change the step output condition . If the step input condition of an output command is true , Then the step output condition will be set to true . If the step input condition of an output command is false , The step output condition will be set to false .
Input branch : There are no restrictions on the maturity of parallel branches supported by the controller . The figure below shows an example that contains 5 Parallel branch of layer . The main level is the first branch layer , Behind a 4 Additional branches .
chart 2-6
The maximum number of edges you can nest is 6 layer . The following illustration shows a nested edge . The output instruction at the bottom is located in the with 3 Nested edge of layer depth .
边栏推荐
- Alipay payment interface sandbox environment test and integration into an SSM e-commerce project
- Unsigned and signed vernacular
- Apache Doris1.0版本集群搭建、负载均衡与参数调优
- 实例:用C#.NET手把手教你做微信公众号开发(21)--使用微信支付线上收款:H5方式
- STL教程5-STL基本概念及String和vector使用
- SSM整合学习笔记(主要是思路)
- Apache doris1.0 cluster setup, load balancing and parameter tuning
- keil编译运行错误,缺少error:#5:#includecore_cm3.h_过路老熊_新浪博客
- Run the dronekit flight control application on Shumei faction under px4-jmavsim software simulation environment
- 关于运行scrapy项目时提示 ModuleNotFoundError: No module named 'pymongo‘的解决方案
猜你喜欢
随机推荐
Circuit de fabrication manuelle d'un port série de niveau USB à TTL pour PL - 2303hx Old bear passing Sina blog
一文讲透研发效能!您关心的问题都在
数组常用的一些操作方法
static关键字详解
解析產品開發失敗的5個根本原因
猕猴桃酵素的功效_过路老熊_新浪博客
idea 查看单元测试覆盖率
7.常用指令(下)v-on,v-bind,v-model的常见操作
P3052 [USACO12MAR]Cows in a Skyscraper G
Spark日志分析
OpenResty篇01-入门简介和安装配置
如何配置SQL Server 2008管理器_过路老熊_新浪博客
Two ways to center block level elements
4个要点,助力产品管好项目
对伪类的理解
关于运行scrapy项目时提示 ModuleNotFoundError: No module named 'pymongo‘的解决方案
Apache doris1.0 cluster setup, load balancing and parameter tuning
Px4 simulation basis
Studio5k v28安装及破解_过路老熊_新浪博客
记录一些cf的题