From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Industrial Communications

cancel
Showing results for 
Search instead for 
Did you mean: 

Vision Builder and Ethernet/Ip communication

Hi, 

I have a Smart Camera NI 1776C and I need to communicate with a robot via Ethernet/IP. I did the network configuration (using .eds file of Camera) through the special tool and it seems to work correctly. Now I set the two devices have to exchange data in 32 bytes format input and 32 bytes output. I realised a vision software with VBAI 2012 and I want to send a data packet (32 bytes format) in which some variables are present with VBAI 2012 software. Can you describe me the method I have to follow, please?

Thanks,

Luca

0 Kudos
Message 1 of 8
(6,847 Views)

Hi,

 

First can you confirm that you want to use the adapter class to communicate with the robot, as opposed to using unconnected messaging used to read and write tags?

National Instruments does not ship by default EDS files describing the Ethernet/IP configuration of the Smart Camera. Can you please attach the EDS file you created?

Which robot and what software are you using to configure Ethernet IP on the robot?

To be able to communicate, you need to configure properly both software: the robot's and Vision Builder AI.

You mentioned that you imported the EDS file on the robot's software side to configure the robot to communicate with the Smart Camera running VisionBuilder AI.

To configure Vision Builder AI to communicate with Ethernet/IP, you need to configure and start the Ethernet/IP server. From Vision Builder AI menu, go to Tools>>Communication Device Manager, then click the Configure button on the Ethernet/IP Server line.

In this dialog, you must set the input and output assembly instances, as well as the sizes to match the configuration of the robot, and what you specified in the EDS file.

Click OK, then click Start Server.

As soon as the server is started, the communication should be initiated between the 2 devices as a background task.

To set value of in the input assembly, and read values from the output assembly of the robot, use the Ethernet/IP Adapter step located in the Communicate tab.

With Vision Builder AI 2012, the assembly configuration of the Vision Builder AI side is fixed. It is configure with a set of 32 bools, 12 SINTs, 12 INTs, 12 DINTs, 12 REALs and 1 string.

To send data as 32 bytes, you would want to write in the DINT section of the Vision Builder AI assembly, which starts at address 40.

To send data to the robot, you need to write to the input assembly of the robot. Go to the write tab, expand the DINT section and check DINT0 for example. a control appears in the value section, letting you specify either a constant or a result produced by a previous step.

To read value that the robot wrote in its output assembly, go to the read tab, and check the register to read. Again if you need to read 32-bit values, you want to use DINTs.

Vision Builder AI also support the notion of Dynamic registers, that let you define the type and address to read, if you don't want to be confined to the layout of the default Vision Builder AI assembly.

 

Hope this helps.

 

Christophe

0 Kudos
Message 2 of 8
(6,830 Views)

Hi Luca,

 

Have you tried things on this page: http://www.ni.com/white-paper/13579/en/?

 

Wendy

0 Kudos
Message 3 of 8
(6,817 Views)

Hi,

I'm using a Racer3 Robot by Comau and I used Sycon.net as network configurator (it was provided by Comau). I found the .eds file in the link posted also by karupinwendy and I had to change some parameters listed in. In particular I changed only the Input Assembly Size and the Output Assembly Size (40 bytes by default), you can find the .eds file I used below.

I resolved the problem of communication and now two devices communicate. In Vision Builder, after starting Ethernet/IP Server you have to add firstly the block called "Ethernet/IP" in which I set the IP address of robot's Ethernet/IP module and after that I added the block called "Ethernet/IP Adapter" in which it's possible seeing the pre-structured Ethernet/IP data packet. In this last block, as ChristopheC said, you have possibility to write and read on the bytes sent.

Now I have still a question: I use 32 bytes, can I transmit a DINT variable considering that in the pre-structured data packet DINT variables start from the 40th byte?

Thank you all for the answers.

Luca

0 Kudos
Message 4 of 8
(6,813 Views)

As I mentioned I my previous post, you can create dynamic registers of size 32bit, that can start at address 1. You would do that by creating them in the bottom list of the Ethernet/IP step.

Let us know if you need additional instructions on how to do that.

The only thing to consider in this case, is that for the assembly that you're writing from Vision Builder (data you're sending from VBAI to the robot), the first 6 bits are reserved by system signals. VBAI will overwrite the data you may be writing at this address if you create a dynamic register at address 0.

Other than that, I believe you can create any number of 32-bit dynamic registers that overlap the built-in ones, starting at address 1.

 

Let me know if you are successfull doing it, or if you need step by step instructions.

 

Best regards,

 

Christophe

 

 

0 Kudos
Message 5 of 8
(6,801 Views)

Thank you for your useful answer. I don't understand how adding dynamic registers. I click the "+" button and in the screen I see, how can I set the byte size, the starting address and the value I want transmit? It seems they are in the same option.

Luca

0 Kudos
Message 6 of 8
(6,792 Views)

I wanna ask please, when you add new device in the Communication Device manager (EIP) protocol, should the new device IP be same or different from the PC IP that the NIVBAI is installed on??? 

 

Many thanks

0 Kudos
Message 7 of 8
(4,311 Views)

@ChristopheC wrote:

Hi,

 

First can you confirm that you want to use the adapter class to communicate with the robot, as opposed to using unconnected messaging used to read and write tags?

National Instruments does not ship by default EDS files describing the Ethernet/IP configuration of the Smart Camera. Can you please attach the EDS file you created?

Which robot and what software are you using to configure Ethernet IP on the robot?

To be able to communicate, you need to configure properly both software: the robot's and Vision Builder AI.

You mentioned that you imported the EDS file on the robot's software side to configure the robot to communicate with the Smart Camera running VisionBuilder AI.

To configure Vision Builder AI to communicate with Ethernet/IP, you need to configure and start the Ethernet/IP server. From Vision Builder AI menu, go to Tools>>Communication Device Manager, then click the Configure button on the Ethernet/IP Server line.

In this dialog, you must set the input and output assembly instances, as well as the sizes to match the configuration of the robot, and what you specified in the EDS file.

Click OK, then click Start Server.

As soon as the server is started, the communication should be initiated between the 2 devices as a background task.

To set value of in the input assembly, and read values from the output assembly of the robot, use the Ethernet/IP Adapter step located in the Communicate tab.

With Vision Builder AI 2012, the assembly configuration of the Vision Builder AI side is fixed. It is configure with a set of 32 bools, 12 SINTs, 12 INTs, 12 DINTs, 12 REALs and 1 string.

To send data as 32 bytes, you would want to write in the DINT section of the Vision Builder AI assembly, which starts at address 40.

To send data to the robot, you need to write to the input assembly of the robot. Go to the write tab, expand the DINT section and check DINT0 for example. a control appears in the value section, letting you specify either a constant or a result produced by a previous step.

To read value that the robot wrote in its output assembly, go to the read tab, and check the register to read. Again if you need to read 32-bit values, you want to use DINTs.

Vision Builder AI also support the notion of Dynamic registers, that let you define the type and address to read, if you don't want to be confined to the layout of the default Vision Builder AI assembly.

 

Hope this helps.

 

Christophe


ya but what do to next..

0 Kudos
Message 8 of 8
(3,869 Views)