Omron CJ2 CPU UNIT SOFTWARE User Manual page 151

Cj2 cpu unit software
Hide thumbs Also See for CJ2 CPU UNIT SOFTWARE:
Table of Contents

Advertisement

For example, the same member (e.g., the speed) can be specified for each machine.
Structure Variables Called Machine1, Machine2, and Machine3
Machine1
Member variable
Speed
C
Direction
Alarm
Combining Data Structures with Arrays
Placing Structure Variables in an Array
When there is a large volume of data in the same form, as with recipe data for different products,
structure variables can be placed in an array. This is used to create a database. In this case, the
structure variable becomes one record and each member becomes a field in the database.
Array S(x) of Structure Variables
S(1)
Member
A
S(0)
Member
B
A
C
B
C
For example, this can be used to specify the processing results for each production lot.
Example of Structure Variables in an Array: Product Processing Results (x)
Product processing results (1)
Product processing results (0)
CJ2 CPU Unit Software User's Manual
Speed of machine 1
Speed of machine 2
Machine2
Member variable
Speed
C
Direction
Alarm
S(2)
A of S(2)
Member
B
C
A
A of S(1)
C
B
A of S(0)
C
C
Product processing results (2)
Member
B
Lot
002
Member
C
B
108
001
Lot
Member
C
B
105
C
°
C
000
Lot
C
100
Temperature
°
C
0
Alarm
5 Understanding Programming
Speed of machine 3
Machine3
Member variable
Speed
C
Direction
Alarm
Product processing results (2) = Temperature
for lot 002
°
C
Product processing results (1) = Temperature
for lot 001
Product processing results (0) = Temperature
for lot 000
5
5-59

Advertisement

Table of Contents
loading

Table of Contents