What is WSL

The Windows Subsystem for Linux, or WSL, is an optional feature available on Windows 10 that allows Linux programs to run natively on Windows (in a Windows 10 version of the Bash shell). WSL was designed by Microsoft in partnership with Canonical, the creators of Ubuntu. Together, they created a kernel compatibility layer based on Ubuntu. To run WSL you need Windows 10 64-bit version 1607 (the Anniversary update) or above (32-bit versions are not supported). You can check your Windows version here.

BEFORE CONTINUING: please be aware that at present WSL can’t access the integrated or USB cameras connected to the Windows machine. This means that Dragonfly will be able to access ONLY H.264 or MJPEG video stream made available by network cameras through a local or Internet connection (e.g. the CSI/USB camera connected to a Raspberry Pi or the integrated camera of a smartphone/tablet etc..).

Why Dragonfly with WSL

Using WSL is different from installing a virtual machine (with VMware or Virtual Box), as with WSL the Linux system runs natively on Windows. There is no third party involved and this means that the level of performances is much higher than when using a virtual machine. Despite this it must be said that even with WSL the performances are about 20% slower than a native Ubuntu installation.

Step 1 – Enable WSL in Windows 10

  1. Open PowerShell as Administrator and run:
    ​Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
  2. Restart your computer when prompted.

Step 2 – Install Ubuntu inside WSL

Click the following link to automatically install the current Ubuntu LTS release from the Microsoft store: Ubuntu 18.04 LTS (Bionic).

Step 3 – Install Dragonfly

  1. Launch the Ubuntu Terminal via one of the following methods:
    • Searching for UBUNTU inside the Windows Start menu
    • or from the Windows command line using the wsl command.
    • or from the Windows command line launching the command: ubuntu1804
  2. Install Unzip with this command:
    sudo apt install unzip
  3. Close the Ubuntu Terminal and launch it again.
  4. Download the latest version of Dragonfly with this command:
    wget https://s3.amazonaws.com/navizon.indoors.camera/dragonfly/dragonfly_installation_linux_20200316.zip
  5. Launch these commands to install Dragonfly:
    unzip dragonfly_installation_linux_20200316.zip
    cd dragonfly_linux
    # At this stage, you will be asked for superuser credentials for installation. The installation of the Dragonfly Java App, Web UI and all the dependencies could take a bit. Be patient.

Step 4 – Launch Dragonfly

Do you have already a set of credentials? If not already done please generate a set of Accuware credentials (usernamepassword and Site ID) filling the form at this link.

  1. Go the directory where the start.sh script is located (cd dragonfly_linux/application/) and enter the following command to launch the Dragonfly Java App:
    # Replace 'my_site_id', 'my_email' and 'my_password' with Accuware credentials (quotes must remain)
    java -jar -DsiteId="my_site_id" -Dlogin="my_email" -Dpassword="my_password" dfja-1.6-dist.jar
  2. Open a tab inside your favorite browser and type the following URL to launch the Dragonfly Web UI:
  3. You have now to configure Dragonfly following the instructions inside this page.

PLEASE READ: during the configuration of Dragonfly you will have to compute the calibration of your camera and you will have to make available the JSON calibration file to the Dragonfly installation running on Ubuntu inside WSL. To do so please read use these commands:

# To access the Windows directory with the calibration file
​cd​​ /mnt/c/Users/{username}/Downloads/

# To copy the file {filename}.json to the correct Dragonfly directory inside Ubuntu
sudo cp {filename}.json ~/dragonfly_linux/application/data/config

Creating/changing Linux files in your Appdata folder from Windows will likely result in data corruption and/or damage your Linux environment requiring you to uninstall & reinstall your distro!