Is it possible for one ESPHome device to talk directly with another ESPHome device?
My use case is I have a switch on a wall (Sonoff T1) and it’s controlling a relay (sonoff basic) located somewhere else in the house.
I currently have an automation in HA to get the status from the switch, and send it as a command to the sonoff basic, but this has some problems.
Namely if the MQTT server is down, or HA is down, it doesn’t work.
I see that ESPHome can subscribe to MQTT topics, which would cut out the middleman of HomeAssistant for this task, but is it possible to do this without MQTT as well, and have true point-to-point communication over WiFi between two ESPHome devices?
EDIT:
It seems that the answer is no, this is not currently possible, but there are two feature requests that would meet these needs, #57 and #52.
B) This forum is listed as the official ESPHOME forum on their website
Maybe you didn’t read closely, but that’s not what I asked.
The device Is still controlled via HomeAssistant, with HA controlling it based on motion and timers.
HomeAssistant is still very much involved in the control of these two devices, and would continue to be.
Hey. Love the response isn’t ESPHome used only with home assistant? At the moment.
Any ways blah blah blah
Try using ble first of all tracker and RSSI component and read the DebUG log, u should see he other esp home device, not entirely sure if this is the way but I watch a good YouTube video where the guy reads sensors from Bluetooth logs and then assigns hem in HA. See intermit.tech channel on YT https://youtu.be/RtJpx8BZvMw
thinking this could be one way to transmit and communicate with the nodes solely
I am working ;his as I would like my wemos d1 to act as a wireless light switch using a battery and deep sleep so that when pushed will tall directly to the other esp and negate ANY need for a server such as HA or other device to also be online ,
ESP devices have a p2p communication channel called ESP-NOW. This allows blazing fast communication between ESP nodes without the need to initialize Wifi. This saves battery life and prolongs the life of battery powered devices.
Unfortunately this is not yet incorporated into ESPHome. There are discussions around it here and I found some documentation on a new component named ‘Wifi Now’ here but this seems to be a preview branch. Looks like we will have to wait some more time for it to be incorporated into the release version.
thank you,
I was just looking for something like this,
Now I use Tasmota device grouping which is easier to setup as you don’t have to cross reference all devices, but this will do,
One question, Do you know if this also would be possible using the API?
For now I have the webserver enabled on all devices, but that’s basically for debugging, once I have ESPHome quirks under control I’m planning to remove the webServer
If I read the documentation the Native API seems to purely made for connecting and integrating with HA.
not sure this is possible,
I think I should go or the webapi as mentioned above.
I did some tests with postman and all works over there.
But I can’t find where/how to put the authentication credentials. I found that auth method is digest auth.
Still I think I need to specify the username and password somewhere.
The problem is,
the documentation suggests auth would mean basic authentication
but giving it a closer look, I looks like digest is uses,
for basic auth, I could just have encoded the credentials and send it in as header.
but Digest, which I’m not familiar with, seems to be a little more complicated and using http_request I can not find if it’s even possible to apply this,
maybe I should add this as a feature request.
a work around would be to remove the authentication, but I was just so happy that there was any.
If it’s using wifi, it should just as well communicate through home assistant. What I need is uart/i2c communication or actually using another esp/beken?? as a port expander, just like arduino port expander component. Using an esp32s2 that you have laying around(stupidly cheap) when you’re out of pins would be awesome.
Any suggestions?
use an i2c gpio expander… they are even cheaper than an esp32, they are smaller and you can chain many of them together to get dozens of additional gpio pins. The problem with using additional MCU boards for something simple like adding gpio pins is now you have to over complicate the project and essentially program 2 boards to communicate and work together to do a task that is easily doable with a single board. There isn’t anything awesome about complicating things that don’t need to be complicated and there. What is awesome though, is when you learn how to use a search box and you can find this stuff out all by your big boy self.
This thread is about esphome to esp communication specifically and found it by…typing in a search box. Guys like you really like to take out the enthusiasm from noob looking users.