Wifi not working when network cable is plugged in

Hi Guys
I have a small network of click PLCs
I'm monitoring inputs using Modbus
My PLCc are addressed 192.168.11.---
The Server is addressed 192.168.63.1
I changed my Pie's Wan IP Address to 192.168.11.101
And I left the Pies wifi address as automatic
If I don't have the cat 5 cable plugged in I can get internet over wifi (But cannot communicate with PLCs)
When I plug in the cat 5 cable I can communicate with PLCs but I loose my internet connection
Can anybody assist me with this
Regards
Barry Miller

What is the Pie's address when on wifi?

192.168.11.xxx and 192.168.63.xxx are different class C subnets and devices can't talk to devices on the differnet subnet unless you have a gateway that routes between them. Your Pie should be able to be that router/gateway.

This might get you started:
https://linuxhint.com/raspberry_pi_wired_router/#:~:text=Raspberry%20Pi%20has%20a%20Wi,to%20the%20wired%20network%20interface.

Hi wb666greene
192.168.63.112
Thanks for the link

The Plot thickens
With my cat 5 plugged in I can
I can log into my pie using VNC
But my pie cannot access the internet or send email
So I have internet access
??
I'm confused

I'm confused too, what is the IP of the host running the VNC that is logging into your Pie?
Your Pie has to route from the Ethernet (192.168.11.xxx) to the WiFi (192.168.63.xxx) and vice-versa with the default gateway being your Internet router on 192.168.63 subnet.

Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::556a:ac6:3b4e:a394%21
IPv4 Address. . . . . . . . . . . : 192.168.11.101
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.63.1

Wireless LAN adapter Wi-Fi:

Connection-specific DNS Suffix . : MSI.local
Link-local IPv6 Address . . . . . : fe80::588f:ef4:acb0:5efb%20
IPv4 Address. . . . . . . . . . . : 192.168.63.58
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.63.1

I'm using this PC to program PLCs via network cable
And surfing internet via wifi connection, And both connections work simultaneously

What have you got connected on the ethernet port? Is it just the PLCs or is the 192.168.63.1 router also connected there? If not then you shouldn't have that as the gateway.

The problem is that it is trying to access the internet via that port in preference to the wifi (which is normally a good thing to do). You need to tell the OS that the wifi port should be preferred over the ethernet port, so it will only use ethernet for the PLC connection. I am not sure how to do that without looking it up, and I haven't time at the moment, so you may need to do a bit of googling. You need to use the metric option on the port.

1 Like

The PLCs and the Pie are on the local network
I was getting conflicts with my PLCs while they where addressed 192.168.63.---
So physically they are on the same network but addressed with 192.168.11.---
This eliminated all my conflicts , But I cannot communicate with the Pie.
thanks for you help

You cannot have two subnets on the same wire. So with a subnet mask of 255.255.255.0 you cannot have 192.168.11.x and 192.168.63.x addressed devices connected together. You could do that if you have one subnet on the ethernet and one on the wifi, but you seem to be saying that is not the case.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.