Leyke_1970 Posted November 7, 2022 Report Share Posted November 7, 2022 Hi, For a test setup between my Laptop en a PLC i'm trying to configure an Ethernet connection. Easy peasy you would say. Well, apparently not. Init of the TCP/IP card and the socket (socket 1 in this case) is all successful. I made the following settings on de PLC: TCP/IP card init: IP address -> 192.168.0.1, subnetmask -> 255.255.255.0, Default gateway -> 192.168.0.254 Socket init: Socket 1, Protocol -> TCP, Port -> 20256, client/server -> client (master). My laptop's IP address is set to 192.168.0.10 When I ping the PLC from my laptop is this successful. The PLC is set als Master (intentionally). For testing I've also tried set the PLC to Slave. This had no positive result. I can't find the reason why the socket status will not switch to connected. Explanation for the attached picture. please read MB0 as SB2. MB0 is set on start up by SB2. When all initialization is done, MB0 will be reset. In advance, thanks for any help. Leyke Quote Link to comment Share on other sites More sharing options...
MVP 2022 kratmel Posted November 7, 2022 MVP 2022 Report Share Posted November 7, 2022 Please post your PLC model # V700 and other Vision plc (V350...V1210) has different Ethernet setup. Quote Link to comment Share on other sites More sharing options...
DanT Posted November 8, 2022 Report Share Posted November 8, 2022 Hi; I see the note about MB 0 being set by SB2, Are these nets in a subroute? Is the subroutine being called? If not sure - put a Incremental counter ( XI whatever) at the top of the subroutine- attached to the rail. If it counts, the routine is /was active. If not counting, subroutine ius not currently being called. DanT Quote Link to comment Share on other sites More sharing options...
Leyke_1970 Posted November 8, 2022 Author Report Share Posted November 8, 2022 On 11/7/2022 at 4:47 PM, kratmel said: Please post your PLC model # V700 and other Vision plc (V350...V1210) has different Ethernet setup. Sorry, forgot to mention. It's a V350-35-R2 Quote Link to comment Share on other sites More sharing options...
Leyke_1970 Posted November 8, 2022 Author Report Share Posted November 8, 2022 2 hours ago, DanT said: Hi; I see the note about MB 0 being set by SB2, Are these nets in a subroute? Is the subroutine being called? If not sure - put a Incremental counter ( XI whatever) at the top of the subroutine- attached to the rail. If it counts, the routine is /was active. If not counting, subroutine ius not currently being called. DanT Yess, it's called. As long as MB0 is high, the "start-up" subroutine is called (see attached picture). For testing I've put the status of SB 142, (Ethernetcard Initialized), SB144 (Ehternet Socket 1 Initialized), SB151 (Ethernet status: Link) and SB148 (Ethernet socket 1: Connected) on the HMI. Only SB148 stays 0 in my case. Quote Link to comment Share on other sites More sharing options...
MVP 2022 kratmel Posted November 8, 2022 MVP 2022 Report Share Posted November 8, 2022 If you use MB0 with SET condition - your configuration is restartet at every scan. Please use Direct SB2 for Ethernet configuration startup. Quote Link to comment Share on other sites More sharing options...
MVP 2022 Flex727 Posted November 8, 2022 MVP 2022 Report Share Posted November 8, 2022 Nice catch, @kratmel! Quote Link to comment Share on other sites More sharing options...
MVP 2022 Ausman Posted November 9, 2022 MVP 2022 Report Share Posted November 9, 2022 Leyke, do you know about powerup values? You need to go through some of the System Bits and learn what they do. As Kratmel has pointed out, some of your code is causing errors. Other parts are unnecessary. cheers, Aus Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.