Skip to content

A Meshtastic desktop client, allowing simple, offline deployment and administration of an ad-hoc mesh communication network. Built in Rust and TypeScript.

License

Notifications You must be signed in to change notification settings

meshtastic/network-management-client

Repository files navigation

image

Meshtastic Emergency Response Client

An unofficial Meshtastic desktop client, allowing simple, offline deployment and administration of a mesh communication network.

GitHub last commit GitHub GitHub issues GitHub top language Open Collective backers

Introduction

This application is an unofficial desktop client for the Meshtastic Project, with the goal of allowing emergency response workers to deploy and manage an off-grid mesh network. Currently, many emergency response teams utilize UHF/VHF analog radios, and while reliable, cannot reliably transmit vital data over long distances (GPS waypoints, regions of interest, etc). Our goal is to allow response coordinators to purchase cheap, off-shelf radio hardware and quickly and reliably use that hardware to communicate this vital response information.

This application is built using the Tauri Framework, a modern, secure successor to the Electron Framework. This allows us to natively support Linux, macOS, and Windows within the same codebase without the performance or memory overhead of a Chromium browser. Our core application infrastructure is written in Rust, and UI and client functionality is written in React TypeScript and bundled using Vite. This project is in early stages of development, and as such is not yet suitable for production use.

image

Features

This project is in early stages of development, but here's a rough roadmap of functionality we're working on.

  • 🌎 Node in-map viewing
    • Mapping service integration
    • Node positioning on map
    • Offline map usage
  • 🔌 Rust serial management of base node
    • Rust serialport integration
    • Rust protobuf decoding/encoding
    • Tauri event management
    • Redux saga event integration
  • 📡 Messaging and channel management
    • Redux store + saga setup
    • Channel management flows + UI
    • Messaging UI
    • Local message backup
  • 📝 Network onboarding and configuration flow
  • 💻 Algorithmic network management
    • Tauri command infrastructure
    • Graph initialization and management
    • Algorithm implementations
    • Insight utility UI
  • 💾 Response summary and export flow

Development

Prerequisites

This project is built in Rust and React TypeScript, and managed using the PNPM package manager. As such, this project requires the following programs to be installed on your development machine:

Additionally, this project uses Git submodules to include the meshtastic/protobufs repository. To install this submodule, run git submodule update --init after cloning this repository.

Recommended IDE Setup

While this project can be developed within any text editor, we recommend the Visual Studio Code editor. If using VSCode, we strongly recommend that you install the following Visual Studio Code extensions. These extensions both enforce code style and enable language and framework support for our tech stack.

Commands

To standardise and simplify our development flow, we utilize PNPM commands (defined in package.json). We have created commands which allow for the development of the client only, or development of the client embeddeded in a desktop application window. We support running the application UI in a browser in the event that a contributor wants to make UI changes but is unable to install the required project dependences, although we strongly recommend developing using the rust:* commands. You will be unable to connect to a serial device when developing in-browser. Project dependencies can be installed with pnpm i.

Reminder: When using any rust:* command, you will need to have the src-tauri/protobufs git submodule initialized. To do so, run git submodule update --init in the root of the project.

  • pnpm run ui:dev - Starts the UI development server, allowing for UI development in a browser environment. Note that any code that interfaces with the Rust backend will not function within this browser environment, meaning you will be unable to connect to serial devices in this context
  • pnpm run ui:build: - Runs a production build on the UI code into the dist directory
  • pnpm run ui:preview - Runs the built UI from the dist directory. This command must be run after ui:build
  • pnpm run ui:format - Formats the UI codebase using Prettier and ESLint
  • pnpm run ui:test - Runs UI test suite using Jest
  • pnpm run rust:dev - Starts the desktop application in development mode, allowing for hot reloading of UI and Rust code
  • pnpm run rust:test - Runs backend tests on the Rust codebase directory (/src-tauri). This command also generates TypeScript client bindings in the /src-tauri/bindings directory. Add -- --show-output to show Rust println! macro calls within test suites.

Note: On Linux, your user may not have permission to access a given serial port. If this happens, you will likely need to add your user to the group that controls the serial port you want to access. You can find the group that controls a serial port via the ls -ld PATH_TO_PORT_HERE command. You can add your user to this group via the usermod -a -G GROUP_NAME_HERE $USER command.

Contributing

As we are still very early in development, we don't yet have a standardized framework for accepting contributions. This being said, we are very open to suggestions and/or code changes! If you're interested in contributing to this repository, we would ask that you first check our issue board to ensure your work isn't duplicating the work of others. Then, please make an issue on our board so we know what you're interested in working on. If you have any questions about the project, we would love to hear from you!