Skip to main content

A Python client that connects Meshtastic radios via MQTT to Home Assistant (Hass).

Project description

Meshtastic to Home Assistant (Hass)

A Python client for use with Meshtastic devices. The client connects to a mesh radio via USB serial port. Telemetry and position messages from the mesh are published to an MQTT broker and further into Home Assistant. All MQTT entities will by auto discovered in Home Assistant.

Usage

usage: meshtastic2hass [-h] --dev DEV --mqtt-host MQTT_HOST [--mqtt-port MQTT_PORT] --mqtt-user MQTT_USER --mqtt-password
                       MQTT_PASSWORD [--mqtt-topic-prefix MQTT_TOPIC_PREFIX] [--version]

Connects Meshtastic radios via MQTT to Home Assistant (Hass).

options:
  -h, --help            show this help message and exit
  --config CONFIG       Path to configuration file in TOML format.
  --dev DEV             The device the Meshtastic device is connected to, i.e. /dev/ttyUSB0
  --mqtt-host MQTT_HOST
                        The MQTT broker host name or IP.
  --mqtt-port MQTT_PORT
                        The MQTT broker port.
  --mqtt-user MQTT_USER
                        The MQTT broker user name.
  --mqtt-password MQTT_PASSWORD
                        The MQTT broker password.
  --mqtt-topic-prefix MQTT_TOPIC_PREFIX
                        The MQTT topic prefix.
  --version             show program's version number and exit

Node Filter

By default all received Meshtastic nodes will create entities in Home Assistant.

This might be an undesired behavior when only some nodes are of interest. A node filter can be defined in config.toml.

filter_nodes = [] takes a set of Meshtastic nodes short names to be includes in filter. Only these nodes will be forwarded to home assistant via MQTT topic, hence creating entities. Keep empty to forward all nodes.

Receiving channels text from nodes is not filtered at all.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

meshtastic2hass-1.0.11.tar.gz (24.2 kB view details)

Uploaded Source

Built Distribution

meshtastic2hass-1.0.11-py3-none-any.whl (22.2 kB view details)

Uploaded Python 3

File details

Details for the file meshtastic2hass-1.0.11.tar.gz.

File metadata

  • Download URL: meshtastic2hass-1.0.11.tar.gz
  • Upload date:
  • Size: 24.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for meshtastic2hass-1.0.11.tar.gz
Algorithm Hash digest
SHA256 8d15aa93941e324bf7721c2c452d1496a1173261c07f8acfadf6321dd05737d7
MD5 f090033f1bfc221444efd930568fae93
BLAKE2b-256 b3a1f9cfc2ff1a5796ef10af9f5c0c5641d681b7df9d656460a5af8cb55903b8

See more details on using hashes here.

File details

Details for the file meshtastic2hass-1.0.11-py3-none-any.whl.

File metadata

File hashes

Hashes for meshtastic2hass-1.0.11-py3-none-any.whl
Algorithm Hash digest
SHA256 84ff0141482e7c293d01d87f4a5d0f996840393cab61dd9ca3dd32a5c29672e7
MD5 23f37733b89ca7d66992d8dc4f0c8062
BLAKE2b-256 ae9af3dd32f650eb8268232f038c9a4f82218de22c41fd40754c9de2aa6419c1

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page