Replies: 4 comments
-
Would you like to control via mesh a GPIO that HA has access to, or the other way around and control a GPIO on a meshtastic node via HA? Currently I mostly use text messages and HA automation that match the text to trigger action inside HA (not the most efficient way to do it, but kind of works). In terms of ability to send remote hardware messages from HA to the meshtastic node, that is something that is not yet implemented. I really like the quite remote relay / sensor idea, and this is one of my use cases. I even had already some ideas around using ESPHome Native API over Meshtastic, would be nice way to integrate some remote devices into HA where I don't have IP connectivity. |
Beta Was this translation helpful? Give feedback.
-
Offering a action/service to send remote hardware message (where you would provide the GPIO values) should be pretty easy. Representing a meshstatic node with the remote hardware module enabled as a device with GPIO in Home Assistant might be tricky, as the integration can't really discover the GPIOs the mehstatic node supports. The only way would be when you as the user create / configure the representation in home assistant. For such a use case the ESPHome Native API over Meshtastic would be better suited. But one bigger roadblock there is that you can't easily embed meshtastic radio capabiltites into a ESP Home Device, as currently the whole meshtastic radio implementation is a big chunk in the firmware and the radio part itself can't be used standalone |
Beta Was this translation helpful? Give feedback.
-
In my use-case I am trying to add nodes further away from WiFi network in remote locations on solar+battery power. They have both ways of communication - some have a button attached and others have relays attached or both at the same time. Current and voltage sensor could be sent as telemetry already. Everything is super easy with ESPHome and I use a lot near WiFI. In perfect world you could just add Lora pins to ESPHome config and relay everything over that. I guess the problem is that ESPHome API is pretty chatty and might not be best for Lora. Maybe it's something possible to change (verbose flag?). The HA devs mentioned this in one of the release party videos. There was a thought that something similar to BTHome could be developed. Some small footprint protocol. But they said Lora and remote nodes is a special case and needed for "general home use", so probably not top priority for a while. At the moment, the button from node->HA could be done with the "External notification" module, but it does limit it just with one GPIO input. Not the best, but possible. If there was an action to send GPIO states you could create a helper and automation for the change. And also automation to read the GPIO messages back. If you know your GPIOs then I guess you could just config it with the automation. ESPHome API would be way better, yes! Other idea could be to create a Meshtastic<->ESPHome<->HA gateway, but no idea if it's possible. Also then you would have to have static config for ESPHome with all remote sensors and GPIOs. Gateway would keep the state correct. If you add more nodes then you would need to recompile. Also not the best. I have no ability to help with coding, but I do have a setup I could test stuff on. I have 4 nodes (Heltec's Wireless Stick Lite v3) with some inputs and outputs and a 5th in high position as gateway. We have tried using OpenMQTTGateway, but with sub-optimal results, LoRa part was not really stable. |
Beta Was this translation helpful? Give feedback.
-
Currently the only possible way to get Meshtastic on your nodes is when you install the full firmware on it. But in that case when you already have meshtastic on those remote devices, you should be able to control the GPIO once this integration has implemented Remote hardware module support. There would probably be also a possibility to create a home assistant module inside the meshtastic firmware that would allow for some discovery functionality by home assistant and offering similar functionality as external notification and GPIO module (for ease of usage with home assistant). Maybe you could configure it on how it should expose HA entities, in a similar way how you configure your device with ESPHome. I reopened that discussion at #5739 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Thank you for this initiative. Seems like a good path to get some Lora magic in HA.
Is it possible to use this integration for remote GPIO as well? Like a really remote relay or sensor?
This document says that it is possible only through Python API. So in principal it should also work though this integration?
https://meshtastic.org/docs/configuration/module/remote-hardware/
Beta Was this translation helpful? Give feedback.
All reactions