Search the Community

Showing results for tags 'structures'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Found 2 results

  1. Hi Everyone, Apologies if this has been asked somewhere, I couldn't find anything. I have a PLC program written for an Omron NX102 controller. There are multiple structure datatypes in this program, primarily to help keep variables for specific equipment together and readily accessible. I want to create some IAG's for the HMI programming to reduce programming time, and these IAG's will need variables using the same structure's that are in the PLC program (will be using an NA series HMI). Is there an easy/quick way to copy the structures from the PLC program datatypes into the IAG datatypes? I can't seem to paste anything into the IAG datatypes except for basic text (ie. a single member name for example), however I can copy the PLC program datatype (and paste them into Excel) I do realise that some of the base types are different between the NX and the NA, but Sysmac Studio seems to automatically correct these when I type them in anyway. No big deal if there isn't a way to just copy them over, it's not too much hassle to just manually put them in. But figured it can't hurt to ask  Thanks in advance.
  2. Hi, This is going to be a long question, but I want to be thorough so please bear with me. We have a system consisting of ABB equipment for motion control and IO handling. In order to simplify the overall architecture, we want to replace the motion control part of this system (which at present consists of a bunch of different CPU cards and PCBs) with one Omron NJ controller an use its SW library for motion control instead. With regards to IO handling we want to leave the IOs as they are now and just map them from the ABB PLC to the NJ controller and back using an Anybus X-gateway (i.e. the ABB PLC will collect the IOs from its modules, send them via Profinet to the Anybus, which will map them on EtherCAT to the NJ controller). Now, in the NJ controller, rather than putting all the IOs in the global variable list, I want to create structures (one Digital Input structure consisting of booleans, one Analog Input structure consisting of long reals and so on). The reason I want to use a structure rather than an array, is that the structure let's me specify variable names, which is nice. Here is my problem: How can I map the digital inputs from the Anybus to the Digital Input structure? The data from the Anybus is packed into bytes of data, so I want to find the most convenient way to take these bytes from my IO-table, split them up and map them to the bools of my structure. I can't seem to find good solutions to this problem online. From the Omron Instruction docs W502, the function AryByteTo seems to do exactly what I want, but it seems like my output variable in that case needs to be an array instead of a struct. If I don't find a good solution to this I am stuck with just hard coding every DI to its variable in my struct, which is time consuming to say the least considering well over thousand IOs. Hope someone will help. Thanks in advance.