Subnet mask? I want 3 devices in 192.168.0.x to talk to existing 192.168.1.x network.

evilspoons

Senior member
Oct 17, 2005
321
0
76
So at work I have an existing network. It has a fairly typical setup in that we have a gateway at 192.168.1.1 and a bunch of PCs at 192.168.1.x where "x" is anything from 2 to 254.

Unfortunately I've procured a device (a robot motion controller) that MUST talk to a remote I/O module... and said robot is stupidly hard-coded to 192.168.0.y. The "y" is set by flipping DIP switches on a card (on a device that costs in the tens of thousands of dollars! WTF?!).It also has a hard-coded subnet mask of 255.255.255.0.

I don't know a lot about subnet masking beyond the usual "set it to 255.255.255.0 and you will be happy at home".

The deal is the remote I/O module must be able to talk to the robot. I then need to be able to talk to the remote I/O module from a PC. The PC must be able to connect to the internet through our existing 192.168.1.1 gateway and (preferably) to the rest of the 1.x PCs.

I'm assuming I'll be setting the remote I/O module to a 192.168.0.y IP and then changing its subnet mask somehow, and then setting the PC to a 192.168.1.x IP and then ALSO changing its subnet mask.

Does this make sense? How do I actually go about doing this? My attempts have just rendered the PC unable to talk to the gateway.

Thanks very much in advance!!
 

jlazzaro

Golden Member
May 6, 2004
1,743
0
0
i have a hard time believing such an expensive device has a hard coded IP address. regardless, changing subnets masks on specific devices to a /23 (255.255.254.0) to include 192.168.0.0 - 192.168.1.255 is pretty kludgy. can you not just route between 192.168.0.0 and 192.168.1.0?

can you elaborate on your existing infrastructure? router, switch, etc?
 

drebo

Diamond Member
Feb 24, 2006
7,034
1
81
Stick another NIC in your PC and set it to an address in the 192.168.0.0/24 network, hook up the controller to that, and forget about it.

Without some much more advanced equipment than you likely have, you will not be able to route between two subnets to accomplish what you want.
 

evilspoons

Senior member
Oct 17, 2005
321
0
76
Yeah, I had a hard time believing it too. The main guts of the robot are a Windows CE-based PC of some sort that has no problem configuring to any IP address. Unfortunately, that Ethernet port is only usable for upgrading the PC, not doing actual remote I/O communication.

The particular board I have to connect to for Modbus/TCP is a separate ethernet card that is indeed hard-coded.

Our network is about as simple as it gets. We have a bunch of PCs that have manually-set IP addresses (don't ask, it's a legacy... apparently the boss is afraid of DHCP) that all eventually make their way back through a single unmanaged switch to a "small business" router appliance. Login authentication and file sharing is done via a Windows server. Everything is in the one subnet because we simply don't have enough devices to require anything fancier (in the range of 20-40 PCs, 3 printers, various things like security cams).

I can't go around reconfiguring all the PCs to accomplish this task, so the 192.168.1.0/24 must stay on the majority of devices.
 

jlazzaro

Golden Member
May 6, 2004
1,743
0
0
does the remote I/O module need to talk robots on both 192.168.0.0 AND 192.168.1.0, or just the former? does it need external connectivity?

as drebo mentioned, adding a second NIC to your PC will be the easiest. your PC NIC2 will be 192.168.0.1, robot will be 192.168.0.2. Set the default gateway (assuming it doesn't need Internet connectivity and doesn't support static routes) of the remote I/O module to the 192.168.1.x address of your PC so it can talk to the Robot through your PC.
 
Last edited:

sactwnguy

Member
Apr 17, 2007
101
0
76
Are you the only one who needs to access it? If so just add a secondary ip address to your local area connection on your pc and be done with it.
 

degibson

Golden Member
Mar 21, 2008
1,389
0
0
changing subnets masks on specific devices to a /23 (255.255.254.0) to include 192.168.0.0 - 192.168.1.255 is pretty kludgy. can you not just route between 192.168.0.0 and 192.168.1.0?

Only kludgy in practice... that's the whole point of an IP subnet in the first place. Too bad more devices don't make the effort to support anything but a /24 subnet.

Anyway... OP: I recommend a small bridge machine on your 192.168.1/24 network that routes to 192.168.0/24, like jlazzaro suggested.
 

her209

No Lifer
Oct 11, 2000
56,336
11
0
If this is a Windows PC, just assign a secondary IP address in the 192.168.0.0/24 network and be done with it.
 

wlee

Senior member
Oct 10, 1999
585
0
71
Buy a cheap 5 port switch ( or VLAN your main switch ) and a good network card for the management PC.

Plug the robot and controller into the 5 port switch.
Plug the second PC network card into the 5 port switch .
Configure second NIC as:

IP: 192.168.0.x
MASK: 255.255.255.0 ( assuming robot uses a class C mask )
Gateway: Leave Blank
DNS: Leave Blank

Leave you primary NIC set to :

IP: 192.168.1.x
MASK: 255.255.255.0
Gateway: 192.168.1.1
DNS: whatever DNS server you use.

If you need to have all PC's on your local LAN talk to the Robot Controller, then you need to use a router or Layer 3 switch to move the traffic between subnets.
 

evilspoons

Senior member
Oct 17, 2005
321
0
76
Thanks for the help, everyone. I am likely going to end up doing something like wlee (& others) suggested and put the robot and remote I/O drop on their own switch.

The PC I am using is an industrial embedded-type (no moving parts) unit whose only expansion slot is PCMCIA, but fortunately it already comes integrated with two gigabit NICs. Never even thought of using the second one.

Only the single PC has any business talking to the remote I/O module and no PCs have any reason to connect to the robot.
 

jlazzaro

Golden Member
May 6, 2004
1,743
0
0
does the remote I/O module only need to talk to the new 192.168.0.x robot, or other existing robots on the 192.168.1.x network?
 

bobdole369

Diamond Member
Dec 15, 2004
4,504
2
0
To those who suggested /23, recall that the other device is hard-coded /24 so it will try to send packets and acks not directly, but to the default gateway. So your packets will go, but the devices will not.

Just FYI: seems evilspoons got it licked with a second network. Easiest solution.
 

bad_monkey

Member
Aug 31, 2010
59
0
0
Am i missing something? Why not just change the gateway IP to 192.168.0.0/24. If it is setup for DHCP it will renew the leases for the other IP's to something in the same subnet. If it is setup statically then one would have to go through and change all the IP's for each pc on the subnet but it is a solution that costs $0 which is always a plus in my book.

EDIT: I'm retarded. Missed the post stating that poster can't change client IP addresses. Ignore!!
 
Last edited:

kevnich2

Platinum Member
Apr 10, 2004
2,465
8
76
Am i missing something? Why not just change the gateway IP to 192.168.0.0/24. If it is setup for DHCP it will renew the leases for the other IP's to something in the same subnet. If it is setup statically then one would have to go through and change all the IP's for each pc on the subnet but it is a solution that costs $0 which is always a plus in my book.

EDIT: I'm retarded. Missed the post stating that poster can't change client IP addresses. Ignore!!

Eh - just blame it on it being friday ;)
 

her209

No Lifer
Oct 11, 2000
56,336
11
0
secondary IP would do nothing...the PC doesn't talk to the robot directly.
I know, it talks to the remote I/O device which talks to the robot. Both the remote I/O and the robot have IP addresses in the 192.168.0.0/24 network as I understand it.

And it will work. To prove it, assign a secondary IP address to your primary PC in a different network (no gateway). Next, assign an IP address to a secondary PC to its NIC. Ping it. You will still be able to go out to the Internet using your primary network, and talk to the secondary PC using the secondary network.