Skip to content

๐Ÿ–ฅ [Software] GUI application that uses the MakAir telemetry protocol to offer rich on-screen information.

License

Notifications You must be signed in to change notification settings

lasmafedotova/makair-control-ui

ย 
ย 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

MakAir Control UI

Normal Respiratory Cycle

Versions

Version Last Changelog Ready?
V1.1.x Operational initial release โœ…
V1.2.x Crashes fixed + smoother graph + implemented medical staff feedbacks โœ…
V1.3.x Improve text readability, by increasing font sizes โœ…

How To Build?

In order to setup your environment and build the code, please follow the following commands (for MacOS):

  1. Install Rustup
  2. รˆnsure you are using the Rust stable toolchain: rustup default stable
  3. On Linux, make sure you have cmake installed and those libraries (debian): libxcb-shape0 libxcb-shape0-dev libxcb-xfixes0 libxcb-xfixes0-dev libfontconfig libfontconfig1-dev
  4. Build the project: cargo build

Wayland support may be available but it hasn't been tested. You need a working X11 server.

Tested at Rust version: rustc 1.43.0 (4fb7144ed 2020-04-20)

How To Run?

To run the Control UI, please ensure that your device first has an open serial connection with the motherboard.

Note that the Control UI relies on the MakAir Telemetry library, which gets pulled from the makair-telemetry repository.

Take note of the serial port used as an input on your Control UI board, and call:

  1. Run: ./makair-control --port=0 (where --port is your serial port ID, maybe /dev/ttyUSB0)

You may also play a pre-recorded file, by passing it as an input (this is handy while developing; example records are available in the telemetry library repository):

  1. Pull the telemetry library (in the parent directory): git pull https://github.com/makers-for-life/makair-telemetry.git
  2. Run an example (from the Control UI directory): ./makair-control --input=../makair-telemetry/records/few_cycles (where --input is an UNIX file path)

Supported Translations

As MakAir was designed to be used internationally, we have made sure that the Control UI was fully translated in major languages.

You can pass the desired locale code when running the makair-control binary, using the --translation argument. Make sure to pass the locale ISO code, eg. for French: --translation=fr.

โžก๏ธ You can find the list of supported languages, with their ISO language codes below:

  • ๐Ÿ‡ฌ๐Ÿ‡ง English: en
  • ๐Ÿ‡ซ๐Ÿ‡ท French: fr
  • ๐Ÿ‡ฉ๐Ÿ‡ช German: de โ€” (WIP)
  • ๐Ÿ‡ฎ๐Ÿ‡น Italian: it โ€” (WIP)
  • ๐Ÿ‡ช๐Ÿ‡ธ Spanish: es โ€” (WIP)
  • ๐Ÿ‡ต๐Ÿ‡น Portuguese: pt
  • ๐Ÿ‡ต๐Ÿ‡ฑ Polish: pl โ€” (WIP)
  • ๐Ÿ‡ฑ๐Ÿ‡ป Latvian: lv โ€” (WIP)
  • ๐Ÿ‡ท๐Ÿ‡บ Russian: ru โ€” (WIP)
  • ๐Ÿ‡บ๐Ÿ‡ฆ Ukrainian: uk โ€” (WIP)
  • ๐Ÿ‡น๐Ÿ‡ท Turkish: tr โ€” (WIP)
  • ๐Ÿ‡ฆ๐Ÿ‡ฟ Azerbaijani: az โ€” (WIP)
  • ๐Ÿ‡จ๐Ÿ‡ณ Chinese (Simplified): zh

โ„น๏ธ If your language does not appear in the list above, you may translate the base English file, then open a Pull Request.

How To Build A Release? (Cross-Compile For ARM)

To cross-compile a new release for an ARM target (using MUSL; statically-linked libraries), you can call the release_binaries.sh script:

  1. Run: ./scripts/release_binaries.sh --version=1.0.0

Make sure to replace the version script argument with the current release version. This is used for file naming purposes only.

โš ๏ธ Important note: this is still a work in progress. We are near cross-compiling capabilities, though some work still needs to be done due to non-MUSL C-based dependencies.

Optional Features

The Control UI behavior can be tuned at compile time, by enabling some optional features while building the binary:

  • Automatic graph scaler:
    • Feature name: graph-scaler
    • Build command: cargo build --features=graph-scaler
    • Purpose: enables automatic graph maximum calculation, and re-adjustments as the target peak pressure is adjusted by an operator, or the largest point pressure value on screen overflows the graph. This overrides the default static maximum pressure value, that is based on the theoretical saturation maximum in an human subject. While the dynamic graph scaler system was previously the default, based on medical staff feedback it has been made static in order to improve machine usability in real-world scenarios. The auto-scaler feature was confusing for them, as traditional respirator systems use an hardcoded maximum.

Troubleshooting

In case of an issue, please review the following points and check if any could help:

  • If you are on Linux, you need to be a member of the dialout group for your user to be able to use the device created by the serial port;

About

๐Ÿ–ฅ [Software] GUI application that uses the MakAir telemetry protocol to offer rich on-screen information.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Rust 94.7%
  • FreeMarker 3.1%
  • Shell 2.2%