indirtect address invalid subscript

From what I can tell, Screenshot 2 and Screenshot 4 are intended to be equivalent. In Screenshot 4 you don't need to use the MOV at the top. VARIETY[CurrentState].0 is a perfectly valid address definition assuming that VARIETY is an array of SINTs, INTs or DINTs and CurrentState is a single instance (NOT an array) of SINT, INT or DINT. The period in the CLX platform is an element delimiter. It selects a single element in a structure. However, it also is used as a delimiter of a single bit in a SINT, INT or DINT. In that context, basically think of a DINT as a structure of 32 bits. The bit dereference can itself be indexed so:

VARIETY[CurrentState].[DesiredBit]
would also be valid, assuming all the tags are DINT, INT or SINT.

I'm not the one with a plant manager breathing down my neck to get a project complete so I can talk pretty loose. But I would personally steer clear of automatic program conversions and would instead translate the program myself. Yes it takes more time and yes, in most cases, the conversion will work without a hitch. But keep in mind that the CLX family contains structure and tools that weren't available in the older generation processors. The conversion utility will just give you a current instruction set and syntax copy of the old program to the best of its ability. It can't make value judgements. The conversion program won't substitute a 3-dimensional array where it would make sense or convert a multi-file recipe structure into an array of UDTs. It can't make that choice but YOU can. I would always take the opportunity to at least look the original program over carefully and approach it with fresh tools where it makes sense.

Keith
 

Similar Topics

i have two plc 1. s7-1212dc/dc/dc ip; 192.168.0.1 2. s7-1500 1513-1pn ip; 192.168.3.2 i need to get data from plc1 to plc2. any idea how to do...
Replies
5
Views
97
Hi, I wanted to ask is there a way to have a visibility expression use the IP address of the HMI (Dynics, not PV) to show certain elements? The...
Replies
3
Views
200
Hello. I have a few machines that use Kinetix 300 (each machine has two drives). Both drives on one of the machine keep losing IP address. They...
Replies
2
Views
95
Hi Guys, Is it okay to have Redundancy ControlLogix Processor IP address set to DHCP? I had Static IP address on it but removed it via RSLinx...
Replies
3
Views
235
Hi everybody, I have DELTA PLC DVP-32ES and I have make a simple project in WPLSoft. using the input X0 to switch ON the output Y0 and using the...
Replies
0
Views
166
Back
Top Bottom