Static IP adress Configuration Issue

Assign your computer a static IP address

  • trying to assign your computer a static IP address that match the one of your PYNQ Z1 board in order to connect it via ethernet cable may not work sometimes if you follow the instructions given in the readthedocs page of PYNQ for Linux users, which are as the following:

    • editing the interface file sudo gedit /etc/network/interfaces, by adding the static IP address with:
      auto lo eth0
      iface lo inet loopback
      iface eth0 inet static
      address 192.168.2.1
      netmask 255.255.255.0
  • if so, then you would not be able to start your interface, by running sudo ifup eth0, and you get: No networking: Failed to bring up eth0,
    this is due to the wrong network device logical name you have written in the interface config.

  • to solve this, find your network device logical name by installing the lshw package: sudo apt-get install lshw ,and running: sudo lshw -C network, copy the logical name and write it in the interface file instead of eth0
    auto lo logical name
    iface lo inet loopback
    iface logical name inet static
    address 192.168.2.1
    netmask 255.255.255.0

  • then you should restart your interface with the new configuration by going to sbin directory: cd /sbin , and running: sudo ifdown logical name && sudo ifup -v logical name

  • at this point restart or logout and login to your system

  • after restarting your device you might see Unmanaged network showing on your wired network status to solve this:
    1- sudo gedit /etc/NetworkManager/NetworkManager.conf
    2- change [ifupdown] managed=false – to – [ifupdown] managed=true
    and here you go! write http://192.168.2.99 on your browser and the jupyter notebook on PYNQ will be welcoming you!

1 Like

I faced similar issue. Thanks for mentioning the list of steps that you took.

As a workaround, I just converted the notebooks to python files using nbconvert. And then ran them in native python on pynq by just doing

python filename.py

and debugging using pdb.

1 Like

Happy to know that you found that useful, and I do like the creative approach you took in your trick