A device with direct LAN connection to a PC -  and getting an IP address - Page 1
Forum section: electronics / general

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 06:34:34 pm
content: Hi, I have in my lab a PC wired to a router (router is off the lab) via a single LAN cable (1Gb).The PC has got two ethernet ports (two IP addresses).I have an oscilloscope, I want to wire the scope to the second ethernet port in the PC, and I want the scope gets an IP address.Is there perhaps a trick how to do it (except to run a DHCP server on the PC)?

author: m k
author_rank: Super Contributor
timestamp: January 16, 2025, 06:43:26 pm
content: A device can have a static address or not.If not then something must provide it and scope must support that something.

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 06:48:29 pm
content: DHO-804 scope - it can have a static address, afaik (at least I see it in the menu).

author: tunk
author_rank: Super Contributor
timestamp: January 16, 2025, 06:56:45 pm
content: Try to e.g. set your pc to 192.168.3.2 and your scope to 192.168.3.3(assuming this subnet isn't in use for your other PC port).

author: m k
author_rank: Super Contributor
timestamp: January 16, 2025, 07:11:53 pm
content: Your PC has one address space, don't use that for your static addresses.tunk's offer is fine, regular routers don't use that.Maybe better use 33 for 3rd octet, if you're in a bigger facility.Last octets as 2 and 3 are also fine.If default gateway is required you can use basically any value, for unknown address there is a timeout, but it shouldn't be a real problem.Using PC's address as gateway address for scope is probably also fine, but you never know if M$ is your PC OS provider.

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 07:21:05 pm
content: The scope allows to set Static IP, let my PC be 192.168.0.99for example:Scope settings:DHCP Auto IP X Static IPIP address 192.168.0.150Subnet 255.255.255.0Gateway 192.168.0.77DNS 0.0.0.0mDNS OFF (ON/OFF)The scope is connected (green light). Scope shows Netw status INVALID IP after I apply it.

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 07:34:28 pm
content: Tried "Auto IP" and after some time it connected toIP address 169.254.xxx.yyy who is it?? "local-link"Gateway 169.254.1.1.And I can see it in the browser

author: nfmax
author_rank: Super Contributor
timestamp: January 16, 2025, 07:38:38 pm
content: That is link-local addressing. If all else fails, it allows the two endpoints of the link to communicate with each other, but nowhere else

author: Sorama
author_rank: Frequent Contributor
timestamp: January 16, 2025, 07:43:20 pm
content: It means your device did not get an ip address from the dhcp server.SYour pc is not a router nor a switch.So this won’t work, unless you configure 2 subnets an a routing on this pc.Just buy a simple switch and put the network cable of the pc into that switch and also cables from pc and scope into that switch.

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 07:44:37 pm
content: Quote from: nfmax on January 16, 2025, 07:38:38 pmI see, hopefully it is not connected somewhere elseThanks!

author: iMo
author_rank: Super Contributor
timestamp: January 16, 2025, 07:47:28 pm
content: It takes some time it connects to the 169.254... via the "Auto IP", so I thought it does not work when I tried couple of times before..And it works..

author: Sorama
author_rank: Frequent Contributor
timestamp: January 16, 2025, 07:50:17 pm
content: Quote from: iMo on January 16, 2025, 07:47:28 pmReread my post please. I wasn’t finished yet :-)

author: David Hess
author_rank: Super Contributor
timestamp: January 16, 2025, 11:37:20 pm
content: I do that all of the time with static addresses, although the switch I am using can operate as a DHCP server if I wanted.

author: macboy
author_rank: Super Contributor
timestamp: January 17, 2025, 02:18:20 am
content: Do you want the scope on the same network? Just bridge the two network cards on the PC. Then it actress almost exactly like an Ethernet switch. The scope will see the LANs DHCP server. I've done this on Linux and on Windows.