Hello!
How can I send simple text to controller after change gpio status. What i want? see the status of my door key. When door are closed- switch is pushed on (i want to see locked) when door are open switch is pushed off (i want to se unlocked)
what funktion should I use? switch?
do i need for this rules?
Regards
nobody@all
Simple text after change gpio status
Moderators: grovkillen, Stuntteam, TD-er
-
- Normal user
- Posts: 30
- Joined: 09 Apr 2017, 23:27
-
- Normal user
- Posts: 30
- Joined: 09 Apr 2017, 23:27
Re: Simple text after change gpio status
ok. I spent all day trying to do something by my self and I am one step ahead.
Using switch input and some rules:
i can send via mqtt door status 0/1 (0-unlocked, 1-locked)
now the hardest thing for me - how can i send no 0/1 but locked/unlocked
My I please someone for help?
Using switch input and some rules:
Code: Select all
on wlacznik#status do
if [wlacznik#status]=0
gpio,12,0
endif
endon
on wlacznik#status do
if [wlacznik#status]=1
gpio,12,1
endif
endon
i can send via mqtt door status 0/1 (0-unlocked, 1-locked)
now the hardest thing for me - how can i send no 0/1 but locked/unlocked
My I please someone for help?
-
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
Re: Simple text after change gpio status
You'll have to use the publish command. Please study the wiki on rules.nobody@all wrote: ↑01 Jan 2018, 19:47 ok. I spent all day trying to do something by my self and I am one step ahead.
Using switch input and some rules:Code: Select all
on wlacznik#status do if [wlacznik#status]=0 gpio,12,0 endif endon on wlacznik#status do if [wlacznik#status]=1 gpio,12,1 endif endon
i can send via mqtt door status 0/1 (0-unlocked, 1-locked)
now the hardest thing for me - how can i send no 0/1 but locked/unlocked
My I please someone for help?
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you

ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you



-
- Normal user
- Posts: 30
- Joined: 09 Apr 2017, 23:27
Re: Simple text after change gpio status [SOLVED]
I did not think it is so simple
my all rules
Thank You very very much 
Regards

my all rules
Code: Select all
on switch#status do
if [switch#status]=0
gpio,12,0
endif
endon
on switch#status do
if [switch#status]=1
gpio,12,1
endif
endon
on switch#status do
if [switch#status]=0
Publish door,open
endif
endon
on switch#status do
if [switch#status]=1
Publish door,closed
endif
endon

Regards
-
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
Re: Simple text after change gpio status
Happy to have helped. 

ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you

ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you



-
- Normal user
- Posts: 30
- Joined: 09 Apr 2017, 23:27
Re: Simple text after change gpio status
last question.
When door change status locked/unlocked controller send two informations
from controller publish /%sysname%/%tskname%/%valname% /ESP_Easy/switch/status 0
and
door unlocked
How to set up to see only door unlocked?
edit
my bad
i just erase topic and everything is ok.
When door change status locked/unlocked controller send two informations
from controller publish /%sysname%/%tskname%/%valname% /ESP_Easy/switch/status 0
and
door unlocked
How to set up to see only door unlocked?
edit
my bad

i just erase topic and everything is ok.
-
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
Re: Simple text after change gpio status
Just uncheck the "send to controller" in the settings for that device.nobody@all wrote: ↑01 Jan 2018, 20:54 last question.
When door change status locked/unlocked controller send two informations
from controller publish /%sysname%/%tskname%/%valname% /ESP_Easy/switch/status 0
and
door unlocked
How to set up to see only door unlocked?
edit
my bad![]()
i just erase topic and everything is ok.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you

ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you



Who is online
Users browsing this forum: Anthropic Claude Bot [bot] and 19 guests