DaveE Posted October 15, 2020 Report Posted October 15, 2020 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. 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 Thanks
MVP 2023 Ausman Posted October 15, 2020 MVP 2023 Report Posted October 15, 2020 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
DaveE Posted October 15, 2020 Author Report Posted October 15, 2020 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
MVP 2023 kratmel Posted October 16, 2020 MVP 2023 Report Posted October 16, 2020 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.
DaveE Posted December 4, 2020 Author Report Posted December 4, 2020 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 Joe Tauser Posted December 6, 2020 MVP 2023 Report Posted December 6, 2020 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.
DaveE Posted December 7, 2020 Author Report Posted December 7, 2020 I always knew you cared Joe Yes SI 103 and 104 I was only using socket 0 and 1
MVP 2023 Ausman Posted December 8, 2020 MVP 2023 Report Posted December 8, 2020 I don't want to start a "me-too" movement, but I care as well! Do I get a smiley, Dave? 💤💻 🙂
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now