|AutomationDirect Live Chat|
This video details the process of connecting the Nitra CMV valve to a Productivity CPU over Implicit Ethernet/IP protocol.
Here are the minimum requirements to use Ethernet/Ip with the Productivity series CPU. For the Productivity CPU to communicate to the Nitra Valve, these are the communication parameters that we will need for this setup. So the input data is what you are reading from the Valve and the output data is what we are writing to. The input as we see here consist of a 5 bytes which is 8 bits. The output word consists of 2 bytes or 16 bits. 1 bit for each solenoid possible on the valve. To setup the CMV valve for etherent communication, you will need obtain the Ethernet/Ip configuration tool from our website. So, Navigate to our website and under downloads select software. Find the EIP software download and install into your PCthe software.”. Once installed open up the EIP configuration tool and then select “Scan for devices. Once you see your OEM Device. Select and put in the Ip Address you need for your system. I am going the following Ip address for my valve. So, Open up the Productivity project you will be using. Double click on the Hardware configuration and then select the Ethernet/IP Tab from the top. Now Drag the generic client into the grey area. You can place an induvial tag for all of these elements or you can check the box Use Structure. This will create a structure of tags that can be used for this device making it a lot easier on the programmer to create, use and find the correct tags. I am going to select the Use Structure and give it the following name. Give your Device a name. Type in the Ip address that we configured into the CMV valve. Now the TCP port number for the CMV valve will always be 44818. Click on the Green cross select Select IO messaging. These tags will also be part of the original Structure created above. This tag will become important later. When it is enabled, It will start the Reads and write to the data blocks at the RPI that we select for each.. Here you see that there are now 3 tabs. Lets’s start with the Input data block From this information we see the assembly instance should be 101. Now This array portion is a part that catches some. The data array data type that we use here must match the data size of the input data blocks. The size of the input data block is in bytes and there are 5 bytes total. So we need to create a data array of a 8 bit type, which matches the bytes, and has at least 5 columns. SO type in the name of the Data block you want to create and when you try to select the Number of elements you will then be asked to create this array. Select the Data type as 8 bit unsigned and increase the number columns to 5. Select ok. And then Increase the Number of elements to 5. Now select the output tab . The Assembly instance is 100. I am going to name my output data array as the following and when I select the number of elements I will be asked to create the array. Change the data type to 8 bit unsigned and the column size to 2. Click ok. Now Change the number of elements to be 2. Now to setup the Configuration word Enter the Assembly instance of 3. I am going to enter the following data array and when I click on number of elements this dialog will show up. Change the data type to 8 bit unsigned and the Columns can remain as 1. Select ok. And then number of elements can remain as zero. That completes the client setup to the valve. When we select Ok her we will be completing structure for this device Next we need to address the Solenoid outputs in the output data block. From this table we can see how the 2 bytes address each of the solenoids that are possible to the valve. SO we take the 2 column data array, that we created, this would be how the outputs are distributed inside that array. SO I am going place a Normally open contact with this Boolean to trigger this bit of word that would address the 1st solenoid. Now if you remember from the configuration we had an enable bit. When this bit is enabled the auotpolling of the input and output block will begin at the RPI rate that we had selected in the config. SO I am going to make a Normally open contact with this Boolean to trigger the enable member of the Device structure. That completes the ladder code now transfer to your CPU. With the project transferred and the PLC in Run, let’s open up the Dataview to quickly test our code. Enter the tags to enable the comms and to control the 1st solenoid. Send the edit to First enable the communication. Now send the edit to turn on the solenoid. You should immediately see the valve turn on. We can also view the status of the Read by entering in the CMV_Read data array here. This table defines what the status word indicatates on the valve. If you need any help with using an Automation Direct device please contact Automation Direct’s free, award winning Technical support team during regular business hours – they will be happy to help. And don’t forget the forums. There are lots of folks there that love to share their years of experience. Just don’t post questions directed at Automation Direct’s Technical support staff there, they do not monitor the forums on a regular basis.