LW RF Studio 1.2.1 for Linux (x64)
======================================

Install
-------
1. Unpack the archive where the program should stay, for example in ~/opt:

       mkdir -p ~/opt && tar -xzf LWRFStudio-1.2.1-linux-x64.tar.gz -C ~/opt

2. Add it to the application menu (a .desktop file and an icon in ~/.local/share, for this user only).
   Run it as yourself, NOT with sudo (with sudo, the menu entry goes to root's menu):

       ~/opt/LWRFStudio-1.2.1-linux-x64/install.sh

   Or start it directly: ~/opt/LWRFStudio-1.2.1-linux-x64/LWRFStudio
   To remove it: install.sh --uninstall, then delete the folder.

The program is self-contained (no .NET to install). It needs an X11 or XWayland desktop and the usual libraries
of a desktop distribution: fontconfig, libICU (libicu), libX11, libICE, libSM.

openEMS (the simulation engine)
-------------------------------
openEMS (free software, GNU GPL v3) is not part of this package. Build it from source into ~/opt/openEMS, the
folder LW RF Studio looks in first (the openEMS package of Ubuntu is an older version). On Ubuntu:

    sudo apt install git
    git clone --recursive https://github.com/thliebig/openEMS-Project.git
    cd openEMS-Project
    ./scripts/install_deps.sh                         # the packages the build needs (asks for your password)
    ./update_openEMS.sh ~/opt/openEMS --disable-GUI   # 10-30 minutes; NOT with sudo

Then check that LW RF Studio finds it:

    ~/opt/LWRFStudio-1.2.1-linux-x64/LWRFStudioCli engine

It prints the engine (CPU, or GPU with an NVIDIA card and an openEMS built with its GPU engine) and
"openEMS: /home/<you>/opt/openEMS/bin/openEMS". LW RF Studio looks for the program "openEMS" in, in this order:

    ~/opt/openEMS/bin, ~/openEMS/bin, ~/openEMS, /opt/openEMS/bin, /usr/local/bin, /opt/homebrew/bin, /usr/bin, then the PATH

Elsewhere: Tools > Locate openEMS in the program. In a virtual machine (VMware, VirtualBox), give the machine several
CPU cores: openEMS uses one thread per core.

Command line
------------
    ~/opt/LWRFStudio-1.2.1-linux-x64/LWRFStudioCli --help

KiCad plugin
------------
The folder kicad-plugin/lw_antenna_check is the LW Antenna Check plugin. Install it from KiCad's Plugin and Content
Manager, or copy the folder to ~/.local/share/kicad/<version>/scripting/plugins (for example .../kicad/9.0/...) and use
Tools > External Plugins > Refresh Plugins in the PCB editor. It finds the program through the menu entry made by
install.sh, in ~/opt or /opt, or on the PATH; else browse to LWRFStudioCli once.

Also in this folder
-------------------
samples/                 example antennas (File > Open)
EULA.txt                 the licence agreement (you accept it by using the program)
LICENSE.txt              copyright notice
THIRD-PARTY-NOTICES.txt  and third-party-licenses/: the licences of the components the program uses
