Lidar configuration - RealCabot/lidar_map GitHub Wiki

sudo vim /etc/network/interfaces

So that the file looks similar to the follows:

If using Ethernet to USB adapter

# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback

allow-hotplug enxa0cec808aa14
iface enxa0cec808aa14 inet static
address 192.168.0.15
netmask 255.255.255.0 

Note that enxa0cec808aa14 is the name of the Ethernet to USB adapter's id, you may need to check ifconfig with adapter plugged in to get your id.

If using Ethernet directly

auto eth0:0
iface eth0:0 inet static
address 192.168.0.15
netmask 255.255.255.0

May need to restart computer after changing interfaces file