Hi,
I have a DB in my program with all the alarms of a machine, but the machine is divided in stations. So I want to check if any station is with an alarm set.
Exemple:
Station 1 is DB1 bytes 0 to 9; Station 2 is DB1 bytes 10 to 19; Station 3 DB1 bytes 20 to 29, etc.
I'm trying to make a block to check part of the DB. Something like this:
OPN #My_DB
L DBB [#Start_Byte]
Compare if == 0 ten (or more, if I have more bytes) times and return if true (or false, that doesn't matter).
My problem is that I don't know how to indirect address the bytes or words of the DB (this: DBB [#Start_Byte]).
How can I do it?
I have a DB in my program with all the alarms of a machine, but the machine is divided in stations. So I want to check if any station is with an alarm set.
Exemple:
Station 1 is DB1 bytes 0 to 9; Station 2 is DB1 bytes 10 to 19; Station 3 DB1 bytes 20 to 29, etc.
I'm trying to make a block to check part of the DB. Something like this:
OPN #My_DB
L DBB [#Start_Byte]
Compare if == 0 ten (or more, if I have more bytes) times and return if true (or false, that doesn't matter).
My problem is that I don't know how to indirect address the bytes or words of the DB (this: DBB [#Start_Byte]).
How can I do it?