GE GFK-0804B manual Indirect Move, Specifying a Location in the Pointer Register

Models: GFK-0804B

1 160
Download 160 pages 24.24 Kb
Page 75
Image 75

4

Indirect Move

The Indirect Move function copies a constant or the content of register to a variable register location. The first part of this function specifies the data to be copied. The second part is a register that points to the actual register where the data will be placed. This allows the register where the data is placed to be changed as required for the program.

In the example on the facing page, an Indirect Move function copies the content of register R002 into a register which is pointed to by register R003. During one program scan, R003 might point to register R020. In another scan, it might point to register R021.

Specifying a Location in the Pointer Register

Ordinarily, the variable register for an Indirect Move function is placed into the pointer register by a Move instruction in the application program. It is also possible to enter a location from the programmer, however.

In either case, enter the number of any register from R001 to R500.

Example:

 

[ R1 !

@R20

]

 

 

 

! @ R20

 

 

 

 

 

R1

 

2162

 

 

 

 

 

 

 

 

 

 

R385

2162

 

 

46140

385

Programming Software Instructions

1.Select I±Move (F7) from the Math/Move function keys.

2.Enter the number to be moved. This can be a constant, or the contents of a specified memory location (see above). For example: R001. Then press the Enter key.

3.Enter a memory location to contain the result. Press the Enter key.

4-34

Micro PLC Programmer's Guide ± April 1994

GFK-0804B

Page 75
Image 75
GE GFK-0804B manual Indirect Move, Specifying a Location in the Pointer Register