Management UI

You should have cloned the root project and it's sub-modules (which includes this project directory).

That-way the parent directory contains the HIDAPI and teensy_fan_controller projects.

Windows

Prerequisites:

  1. Qt Installer

  2. MSVC 2017 64-bit

  3. Recent Qt release (Qt 5.13.2 at time of writing) for MSVC 2017 64-bit

  4. Qt Charts component

The application is NOT compatible with MinGW builds due to the use of hidapi. HIDAPI will compile with mingw32 (NOT mingw64-32bit), however Qt must be built from source to use this stack.

Note:

First, build the static HIDAPI library:

  1. Launch x64 Native Tools Command Prompt for VS 2017

  2. Add Qt5 to PATH, fe.:

     SET PATH=%PATH%;c:\share\Qt\5.13.2\msvc2017_64\bin
  3. Change directory to HIDAPI

  4. Run qmake:

     qmake
  5. Run nmake:

     nmake
  6. Verify HIDAPI.lib was created:

         dir windows\HIDAPI.lib
    
         ...
         12/30/2019  11:03 AM            27,960 HIDAPI.lib

Building the Fan Controller UI:

Until the Fan Controller UI's installer is published, it is easiest to run the application using Qt Creator.

You may build using the CLI with qmake and nmake, but will have to copy all Qt runtime dependencies (qml, plugins, dlls) into the release directory to start the application.

Linux (Ubuntu 18.04)

Prerequisites:

  1. Qt Installer

  2. Recent Qt release (Qt 5.13.2 at time of writing) for GCC 64-bit

  3. Qt Charts component

  4. apt install build-essential libxkbcommon-x11-0 libhidapi-dev libhidapi-hidraw0 libgl1 libgl1-mesa-dev libx11-xcb1

I experienced issues launching the application using X11 forwarding and ended up installing and launching xfce (apt install xfce4).

First, build the static HIDAPI library:

  1. In non-root Shell, add Qt5 to PATH, fe.:

     PATH=$PATH:~/Qt/5.13.2/gcc_64/bin
     QT_QPA_PLATFORM_PLUGIN_PATH=~/Qt/5.13.2/gcc_64/plugins
  2. Change directory to HIDAPI, fe.:

     cd ~/TeensyFanController/HIDAPI
  3. Run qmake:

     qmake
  4. Run make:

     make
  5. Verify libHIDAPI.a was created:

     ls linux/libHIDAPI.a

Build the Fan Controller UI:

  1. Change directory to HIDAPI, fe.:

     cd ~/TeensyFanController/teensy_fan_controller
  2. Run qmake:

     qmake
  3. Run make:

     make
  4. Launch using sudo (note: replace /home/username/Qt/5.13.2 with path to Qt release):

     sudo bash -c 'QT_BASE=/home/username/Qt/5.13.2 QML2_IMPORT_PATH="$QT_BASE/gcc_64/qml" QML_IMPORT_PATH="$QT_BASE/gcc_64/qml" QT_QPA_PLATFORM_PLUGIN_PATH="$QT_BASE/gcc_64/plugins"  ./tfctrl'

Last updated