Tag Based memory Structures

advertisement
COMPACTLOGIX PROJECT STRUCTURE

Everything required for the program to function is contained
within the project.
PROJECT
CONTROLLER ORGANIZER PANEL

The default project provides single task.

A project can have up to 6-tasks. 1769-L32x processor.

task holds information necessary to schedule the programs
execution and determines the execution priority for one or more
programs.
TASKS

Continuous: The continuous task runs all of its programs, and then
it starts again (continuously, you might call it). It’s quite normal to
put most or all of your logic in the continuous task. Example; Fill a
tank to its maximum value and then open a drain valve

Periodic: Periodic tasks are scheduled to run at a pre-defined
period, such as every 100 ms. Example; Read the thickness of a
paper roll every 2 sec.
TASKS

By default, RSLogix 5000 has already created a continuous task called
MainTask. Note the little circular arrow on MainTask – that means it’s a
continuous task.

Inside MainTask, it’s created a program called MainProgram, and it has
one ladder logic routine called MainRoutine inside.

It also has a place for program specific tags. These are tags that are only
visible to logic inside of this program
CONTROLLER ORGANIZER TREE

Program: Each task requires at least one program. A task can have up to
32-programs. Only one program can execute at-a-time.

Main Routine: When a program executes the main routine executes first.
The main routine is used to call(execute) other routines in the program
(subroutines). The main routine in RSLOGIX 5000 is the same as LAD 2 in
RSLOGIX 500.

Routines: Routines are where the executable code resides. Routines can
be written in: Ladder Logic, Sequential Function Chart, Function Block
Diagram, and Structured Text. Routines are used to keep programs
organized.
PROGRAM

Tag based memory structures are what most new generation
PLCs use. A tag is a friendly name for a memory location. This tag
name also has a data type assigned.
TAG BASED MEMORY STRUCTURES

The Scope of the tag defines if a tag is global (controller tags)
and therefore available to all programs or local (program tags)
to a select program group.

Controller Tags are available to all programs.

Program Tags are isolated from other programs.
TAGS
COMPACTLOGIX TAG BASED
MEMORY STRUCTURE

Tag names should be assigned that are descriptive to the data
being stored in them. Example of tag names could be: Start_PB,
Vessel01MixMotor, furnaceTemp.
COMPACTLOGIX TAG BASED MEMORY
STRUCTURE

Base Tag- Directly addresses a memory location. No special
functions.

Alias Tag- Points to an addressed memory location defined by
another tag. Some common uses for Alias Tags are associating
Base tags with Module Defined Input and Output tags.
TAG

Data Type
Description

BOOL
SINT
INT
DINT
2,147,483,647
REAL
1.1754944E-38
Boolean or Bit
Short Integer
Integer
Double Integer
8
16
32
0 or 1
-128 to 127
-32,768 to 32,767
-2,147,483,648 to
Real Number
32
+/-3.402823E38 to +/-
DATA TYPE
Bits
Possible Values
1
Structure Data Type
Timer
counter
Control
Message
PID
MORE DATA TYPE
Type of Stored Data
Control structure for timer instructions
Control structure for counter instructions
Control structure for array instructions
Control structure for the message instructions
Structure for the PID instructions
Download