Indirect assignment – IDEC High Performance Series User Manual

Page 1016

Advertising
background image

5 Script Coding Examples

20-52

WindO/I-NV2 User’s Manual

Indirect assignment

Script

Operation description
When the value of D20 is 8, the value of LDR18, the device 8 words from LDR10, is read and stored in LDR200.

Script

Operation description
When the value of D20 is 3, the constant 1234 is stored in LDR13, the device 3 words from LDR10.

Example 5.7.36 Indirect read

[LDR 200] = OFFSET([LDR 10],[D 20]);

Read

0000

LDR10

0008

D20

+8

1234

LDR18

1234

LDR200

Example 5.7.37 Indirect write

OFFSET([LDR 10],[D 20]) = 1234;

Write

0000

LDR10

0003

D20

+3

1234

LDR13

1234

Advertising
This manual is related to the following products: