Jump to content

Recommended Posts

Posted

Good Afternoon

I have a V570 that is connected over TCP/IP to 2 cognex cameras. for some reason that I cannot establish when I start the system, the first 3 or 4 scans will not trigger the scan. Neither MB33 or MB38 go high when the camera is triggered to take a picture. After the first couple of scans it seems to start working properly. The logic in my head tells me that the camera for some reason isnt sending the scans over properly, but that doesnt make sense to me either. This is the initialize in the main routine.image.thumb.png.7c6df9dbfed469b67705bcb8629604ba.png

If I go to the sub routine (and yes it is being called) if the positive edge of MB33 or MB38 is not seen, the whole system stops.

I have to be missing something, I have time outs set, so If I lose communication for some reason is starts again. I am missing something and hoping a genius out there can assist my brain

image.thumb.png.1745bbca1f9beebfef5691a80cd1df34.png

image.png.02b9d489f1a362d6332cc58b55651bbe.png

 

Thanks

 

  • MVP 2023
Posted
3 hours ago, DaveE said:

the first 3 or 4 scans will not trigger the scan

I guess you are meaning the first 3 or 4 scans of the cameras?  Not the plc?  (which would be a pretty quick production line!)

Without looking too closely, you have a lot of different stuff going on in some rungs/nets.  I would be splitting things up a whole lot more and only doing a particular type of action in one rung.  By the sound of it actions are needing to occur before it all settles....... have you tried the old chestnut of things slightly out of order, such that rearranging the same elements in the sequence can fix the issue?  Humans are very good at missing this bit, but the plc only does what it is told!

cheers, Aus

Posted

Aus

Yes you are correct scans of the camera (slip of the brain)

The issue I have is that even if I just stay on the first 5 lines of the main routine, and dot run anything else at all, the MB33 and the MB38 do not increment to start with, and then "wake up"

(Those are attached to the TCP/IP scan)

One thing that was suggested to me today, which I forgot about was to go into info mode and scan then, to see if the PLC is getting something and doing nothing with the data, or not getting anything

image.png.50cb2534c9252558180e0064b7552ed4.png

 

  • MVP 2023
Posted

Is it possible that socket1 used in application - also as default used for Visilogic connection (internal)?

Then sw. to camera takes some time.

Described behavior looks like USB port 1 used when Modbus on com port1 configured... After USB disconnect - some times needed for port go to modbus mode.

Please try with different socket.

  • 1 month later...
Posted

Just if anyone cares, I fount the issue

The socket was going to sleep after the time outs ended, and it took a while to wake them back up again

I set them to the maximum and it still wasnt enough, I ended up having to set the time outs to 0 and then I always got the data coming in.

Not the way I wanted to do it, but hey it worked

 

  • MVP 2023
Posted

I care.  Thanks for posting.

I've had socket timeout issues but it's usually been on networks that were spread far and wide.  Where did you set the timeouts to 0 - in the SI 103-109 registers?

Joe T.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

This site uses cookies. By clicking I accept, you agree to their use.