Skip to content

Latest commit

 

History

History
36 lines (26 loc) · 2.56 KB

ReadMe.md

File metadata and controls

36 lines (26 loc) · 2.56 KB

Shutter Controller - WASM Client

Before reading this through make sure you have read the project's ReadMe.

This solution can be used both on desktop and on the web as a WASM module. The latter version is built by the Emscripten sdk and it runs in a HTML canvas element.

Library dependencies

The following dependencies are needed for both versions:

  • DearImGui - an immediate mode GUI library which
  • Protocol buffers - library for creating, parsing and serializing binary messages
  • GLFW - utility used to create OpenGL contexts, and windows

These libraries are only needed for the desktop version:

  • CPP-HTTP-LIB - a library which can be used to send HTTP requests (the WASM version uses Emscripten's fetch library for this)
  • OpenSSL - SSL/TLS handling library which needed for secure requests (the WASM version uses the browser's native solution)
  • STB - library which loads the icon for the desktop window (the WASM version is served with a favicon)

Build instructions

The project uses CMake as the build system. First the protobuf project needs to be built and installed and then its installation location have to be specified in the CmakeLists.txt (which explains the detailed steps for building and installing). The .proto compilation is executed automatically during building.

Apart from this, this module does not need further configuration if it's built as a WASM module. However the resources/built files have to be served with an external server.

The serving HTML page has to be served with the ESP itself just like the HTML+JS client

For the desktop version only the OpenSSL developer tools installation path is need to be set as it cannot be built with CMake.

Using the desktop version

After building the following additional configuration is needed

  • Add your server's (DDNS) URL to the ./resources/connection.txt file
  • Specify your username and password for request authentication in the aforementioned file (see the server's Readme)
  • Copy your certificate file to the ./resources/ directory
  • Install OpenSSL user libraries (if the target system is different from the developing system)

Backlog

  • eliminate STB library