Page 1 of 1

SendTo

Posted: 15 Apr 2016, 17:20
by BertB
@Martinus

Hi,
Can you explain in short, how we can use the SendTo command?

Re: SendTo

Posted: 15 Apr 2016, 17:48
by Martinus
BertB wrote:@Martinus

Hi,
Can you explain in short, how we can use the SendTo command?
You can send commands to a remote ESP unit. This can be useful for standalone ESP units without any MQTT brokers, HA controllers and such.
Build just simple basic Home automation with just two ESP modules.

Assume two ESP's, set as Unit 1 and Unit 2.
Enter this command on unit 1, will turn on GPIO 2 on unit 2:

Code: Select all

sendTo 2,GPIO,2,1
You can use this in the rules tab as an action.

Suppose an event on unit 1 needs to set an output on unit 2:

rules tab on unit 1:

Code: Select all

on demoEvent do
  sendTo 2,GPIO,2,1
endon
Or you could create an event on the remote unit:

Code: Select all

on demoEvent do
  sendTo 2,event,givemesomewater
endon
The rules tab on the remote unit needs to be configured to do something based on this event.

All inspired by the good old Nodo...

Re: SendTo

Posted: 15 Apr 2016, 23:24
by BertB
Thanks. Works very fine.

Re: SendTo

Posted: 19 Apr 2016, 12:44
by tozett
Very cool,
the Wiki should Show this fantasic function... 8-)

Re: SendTo

Posted: 19 Apr 2016, 13:11
by tozett
That arise s another question:
Can I have a minimal Setup with two ESP units, where one is an AP, the others a client.
Anybody knows this?
That would be cooool

Re: SendTo

Posted: 19 Apr 2016, 14:12
by BertB
It shall Be done.