Unregistered
Guest
U
Dear gentlemen,
Hi, a very gOod day to you all... I had trying it out but still encounter error. Hope some experts over here can advise me up what goes wrong with me. Thank you.
I encounter an error when trying to write the macro for a 'bit lamp' for the omron's touch screen. The case is like this, I would like to display the bit lamp based on the omron plc's system address bits status.
eg. I indicate the bit lamp as $B500, the system bits as SerialA:1025.00 and SerialA:1025.01. So, I would like bit lamp turn ON when both the 1025.00 AND 1025.01 address contain '1'.
The first way of writing is like this (which is working),
READCMEM($B200,[SerialA:01525.00],1);
READCMEM($B201,[SerialA:01525.01],1);
$B500=$B200 & $B201;
However, if i write directly as below and it is not working when do 'test run' on the software.
$B500=[SerialA:01525.00] & [SerialA:01525.01];
May I know where the second way of writing goes wrong? Also, is there a better way of writing this?
Very sorry for the inconvenience caused to you all over here. Hope you all don't mind to read it and give some guidelines to me. Thank you...
Hi, a very gOod day to you all... I had trying it out but still encounter error. Hope some experts over here can advise me up what goes wrong with me. Thank you.
I encounter an error when trying to write the macro for a 'bit lamp' for the omron's touch screen. The case is like this, I would like to display the bit lamp based on the omron plc's system address bits status.
eg. I indicate the bit lamp as $B500, the system bits as SerialA:1025.00 and SerialA:1025.01. So, I would like bit lamp turn ON when both the 1025.00 AND 1025.01 address contain '1'.
The first way of writing is like this (which is working),
READCMEM($B200,[SerialA:01525.00],1);
READCMEM($B201,[SerialA:01525.01],1);
$B500=$B200 & $B201;
However, if i write directly as below and it is not working when do 'test run' on the software.
$B500=[SerialA:01525.00] & [SerialA:01525.01];
May I know where the second way of writing goes wrong? Also, is there a better way of writing this?
Very sorry for the inconvenience caused to you all over here. Hope you all don't mind to read it and give some guidelines to me. Thank you...