During the development of your embedded project, you might need a remote connection to the board. This article will show how you can scan your local network in order to find the IP address of your board.
First, use the ip
command to list the network interfaces available and active on your computer:
$ ip link show up
Warning: Make sure that both your board and your PC are connected to the same LAN.
A relatively big list might be displayed, depending on how many physical and virtual active interfaces you have. Two interfaces will be printed for sure:
lo
, which is a loopback interface.eth
, enp
or wlo
. See from the example below, that the wired interface is enp3s0f1
and the Wi-Fi is wlo1
:After you have identified one interface connected to the same network as your board, use arp-scan
to find the board IP address:
# sudo arp-scan --localnet --interface=<your interface>
See an example below, where the board IP and MAC addresses, found by scanning the LAN from the interface enp3s0f1
on your PC, are 192.168.10.43
and 00:14:2d:63:19:3f
respectively:
In the example above, we could have scanned the LAN from the Wi-Fi wlo1
only if it was it was connected to the same LAN (usually the same router) then the board.
Open the PowerShell, run the ipconfig
command and write down your ipv4 address:
Warning: Make sure that both your board and your PC are connected to the same LAN.
After discovering your ipv4 address, just scan it using the previously installed nmap
program:
# nmap -sn <your-ip>
Note: You can replace the last two numbers of your local ipv4 address with *
, which will make Nmap scan all addresses on your local network.
Please refer to the official Nmap documentation if you need more information.
Now that you have your board's IP address you can Establish an SSH Connection.