Skip to main content

Network Setup

Connect the Modalix DevKit to your network or directly to your host computer. By default, the DevKit uses DHCP to get an IP address.

Keep serial access available

A serial connection lets you check the IP address and fix network settings when you cannot connect over the network.

1. Connect the DevKit​

Choose the connection that fits your setup:

  • Network with DHCP: Connect the DevKit to your router or network switch. It gets an IP address automatically.
  • Direct connection to a host: Connect the DevKit's Ethernet port to the host. Use a USB-to-Ethernet adapter if needed. On firmware 3.0, you can usually connect without setting static IP addresses; see the tip below.
  • Internet access through a host: Connect the DevKit to the host and enable Internet sharing. See Share the Host's Internet Connection.
Direct connections on firmware 3.0

If no DHCP server is available at boot, firmware 3.0 assigns the DevKit a link-local address in the 169.254.x.x range (169.254.0.0/16).

A directly connected host using DHCP will usually assign itself an address in the same range, if IPv4 link-local fallback is enabled. The host and DevKit can then communicate without static IP configuration.

This connection provides local access only. For Internet access, use a network with Internet access or enable host Internet sharing.

Direct connections on firmware 2.1.3

If DHCP is unavailable, the DevKit defaults to 192.168.1.20. Set the host's connected Ethernet interface to a different static address in the same subnet, such as 192.168.1.10/24, to connect to the DevKit over the local network.

2. Find the DevKit's IP Address​

If you know the DevKit runs firmware 3.0, run this command on the host, on the same local network:

sima-user@sima-user-machine:~$ sima-cli device discover

The command prints the IP addresses of discovered Modalix DevKits.

For other firmware versions, or if discovery does not find the DevKit, open the serial console and run this command on the DevKit:

modalix:~$ ip -4 addr

Find the address after inet on the connected Ethernet interface, such as end0. For example, 192.168.91.181/22 means the IP address is 192.168.91.181. Do not use the loopback address 127.0.0.1.

3. Test the Connection​

Run these commands on the host, replacing <devkit-ip> with the address you found:

sima-user@sima-user-machine:~$ ping <devkit-ip>
sima-user@sima-user-machine:~$ ssh sima@<devkit-ip>
If the connection fails

Check the Ethernet cable and the IP addresses on both devices. For a direct connection, both addresses must be in the same subnet. If the host does not support link-local fallback, enable it or configure static addresses on both devices.

Use the serial console to check or change the DevKit's network settings.

Change DHCP or Static IP Settings​

Run this command on the DevKit to open the network configuration menu:

modalix:~$ sima-cli network

Use the menu to switch between DHCP and a static IP without rebooting.

Configure with NetworkManager​

If sima-cli is not available, use the commands below on eLxr 2.1 or later. They use the preconfigured end0-dhcp and end0-static profiles.

To enable DHCP:

modalix:~$ sudo nmcli connection up end0-dhcp

To set a static address and activate it:

modalix:~$ sudo nmcli connection modify end0-static ipv4.addresses 192.168.1.20/24
modalix:~$ sudo nmcli connection up end0-static

Replace 192.168.1.20/24 with the address and network prefix for your setup. Configure the host with a different address in the same subnet.

To check the active connection and IP address:

modalix:~$ nmcli -f NAME,DEVICE,STATE connection show --active
modalix:~$ ip -4 addr
Changing network settings

Changing the IP address can disconnect your SSH session. Use the serial console or reconnect with the new address.

Share the Host's Internet Connection​

Use this option when the DevKit needs Internet access through an Ubuntu host.

  1. Connect the DevKit's Ethernet port to the host. Make sure the host has Internet access.
  2. On the host, open Settings → Network → Wired and create or edit the connection for that Ethernet port.
  3. In the IPv4 tab, choose Shared to other computers and apply the change.
  4. Turn the connection off and on to apply the settings.
  5. Make sure the DevKit uses DHCP, then find its IP address and test the connection.

Ubuntu normally uses 10.42.0.0/24 for the shared network. Your host may use a different subnet. If needed, check the host's Ethernet address with ip -4 addr, then scan that subnet:

sima-user@sima-user-machine:~$ nmap -sn 10.42.0.0/24

Use discovery or the serial console to confirm which address belongs to the DevKit.

Older Firmware: U-Boot Network Settings​

Firmware 2.0 or earlier

These steps apply only to firmware 2.0 or earlier. On firmware 2.1 or later, use the Linux commands above. For more information about older releases, see the v2.0.0 documentation.

  1. Connect to the DevKit through a serial terminal.

  2. Reboot the DevKit. When you see Hit any key to stop autoboot, press a key to enter U-Boot.

  3. To enable static IP settings, run:

    sima:~$ env set forcenetcfg static; saveenv
    sima:~$ boot

    The first and second Ethernet ports use 192.168.1.20 and 192.168.2.20.

  4. To change the static address after Linux starts, edit the Network section in this file:

    modalix:~$ sudo vi /etc/systemd/network/20-end0-static.network

    This file is used only on firmware 2.0 or earlier. Firmware 2.1 and later use NetworkManager profiles.

  5. To enable DHCP instead, run these commands in U-Boot:

    sima:~$ env set forcenetcfg dhcp; saveenv
    sima:~$ boot