Does anyone have experience interfacing directly with a Cognex camera or barcode reader?
I have an R30iB+ Mate. I am looking into what type of data I may be able to read, store, and send to a PLC.
Basically I need to read the code, determine the location of the code, calculate an offset to print another code next to the original, and then send the code to a PLC.
We are replacing an Adept with an LR Mate and the Adept is currently doing all of these operations.
Interfacing with a Cognex camera
-
Racermike123 -
January 7, 2019 at 5:16 PM -
Thread is Resolved
-
- Go to Best Answer
-
Is the camera fixed or mounted on the robot?
-
It's fixed. I got an answer from Cognex. The robot needs the option, Ethernet/IP Scanner. You can then configure digital Inputs and outputs and group inputs.
-
I have a few robots with Ethernet/IP connected to Cognex cameras. It has pretty limited capability compared to a serial interface or using Karel. My application is very basic so I'm triggering the camera with EIP and then using the CIO-Micro to read the discrete outputs from the camera. I didn't spend much time getting specific X, Y, Angle data out of the camera. The attachment shows the DIO configuration that matches the EIP config in the Cognex camera and the EIP config in the robot.
-
Hello,
I've successfully used Cognex 7000 Series camera with profinet molex card (fanuc robot was master). We've used profinet because our whole system in that project was profinet-based. If you install Cognex insight explorer (camera config software downloadable for free online), there is a chapter in help documentation describing camera communication with Fanuc and other robot manufacturers. -
Thanks DaveP and prasolet. The CIO Micro is not an option because I need more than 8 outputs.
I ordered th aoption from Fanuc and I plan to set it up next week if I have time. I'll post the results. -
I have a few robots with Ethernet/IP connected to Cognex cameras. It has pretty limited capability compared to a serial interface or using Karel. My application is very basic so I'm triggering the camera with EIP and then using the CIO-Micro to read the discrete outputs from the camera. I didn't spend much time getting specific X, Y, Angle data out of the camera. The attachment shows the DIO configuration that matches the EIP config in the Cognex camera and the EIP config in the robot.I have used socket messaging, then communicate with the cognex via serial. Then have karel write the offsets to the registers.
-
I have a few robots with Ethernet/IP connected to Cognex cameras. It has pretty limited capability compared to a serial interface or using Karel. My application is very basic so I'm triggering the camera with EIP and then using the CIO-Micro to read the discrete outputs from the camera. I didn't spend much time getting specific X, Y, Angle data out of the camera. The attachment shows the DIO configuration that matches the EIP config in the Cognex camera and the EIP config in the robot.
Thank you so much for this info,
I keep having an issue where I can not get any data from the robot to the camera via ethernet IP.
I can get the data from the camera to the robot without problem.
I only have one scaner connection defined in the robot, do I also need to define an adapter connection?
Do I need to trigger the data writing to the buffer within the robot ? As I understand this should be done automatically.Could you give a brief overview of how the communication from the robot to the camera works.
Thank you so much for the info you provided so far. -
I have 1 scanner defined in the Ethernet/IP list for my camera. The configuration for this device should be in the attached spreadsheet from my earlier post. To trigger the camera, I turn on the Enable DO then pulse the Trigger DO. My results come through the CIO-Micro and a different range of discrete inputs because that is how my vision guy at that time knew how to do it. So I can't help much on getting data back through the EIP inputs. I do use the ONLINE input to verify the camera is ready and I can see the TRIGGER ENABLE input turn ON. If you have the I/O setup as shown in the spreadsheet and you can see the camera ONLINE in the Ethernet/IP window, you should be able to trigger the camera and see some DI's change state. My camera is showing as OFFLINE below because it is from the Roboguide project.
-
It's been a very long time since I did this, and it was on KUKAs, but IIRC, the Cognex InSight cameras (well, the relatively recent ones) can do quite a bit with Ethernet/IP. The Help file in the InSight software is a major resource for this.
I don't know about EasyBuilder, but in the spreadsheet programming environment, you configured cells to act as EIP "inputs" and "outputs", and used formulae to move data between cells. IIRC, the byte "size" of the camera was configurable.
The camera is 100% an Adapter device, which means the robot needs to be the Scanner. You would have to allocate DI/DO and GI/GO to the camera's rack/slot as needed. But it will be a single EIP connection.
-
- Best Answer
I have 1 scanner defined in the Ethernet/IP list for my camera. The configuration for this device should be in the attached spreadsheet from my earlier post. To trigger the camera, I turn on the Enable DO then pulse the Trigger DO. My results come through the CIO-Micro and a different range of discrete inputs because that is how my vision guy at that time knew how to do it. So I can't help much on getting data back through the EIP inputs.
Thank you for your answer.
I figured out what my issue was.
Firstly, I used the wrong configuration of IO-mapping.
I was using the configuration provided in the Cognex Guide. However as I was using a newer camera model (Insight 3805M) the mapping was not correct. The mapping in the Cognex Fanuc Guide works only with Cameras that use Firmware 4.x.x
I found the correct mapping here: In-Sight Object Model for In-Sight vision systems running In-Sight firmware 5.1.0 and laterSecondly, In order to send data back to the camera Spreadsheet and read it with the "ReadInputBuffer" function, I had to activate Set User Data (Bit 0 in Byte 2) in the Robot outputs. Otherwise the camera would not read what is in the buffer.
It works now. I am frustrated how difficult it was to set up and find the correct info. -
Glad you got it working. Thanks for the information on activating the User Data.
-
I am working through the same issue right now, but with an ABB robot. robin_gdwl would you be able to share some of your spreadsheet showing the buffer setup and EIP cells?