smoke detector triggered killswitch based on esp-01 relay

Moderators: Voyager, BertB, rtenklooster, Stuntteam, grovkillen, TD-er

Post Reply
Message
Author
letsDIY4fun
Normal user
Posts: 5
Joined: 10 Jan 2019, 20:20

smoke detector triggered killswitch based on esp-01 relay

#1 Post by letsDIY4fun » 10 Jan 2019, 20:23

Hello community,

i need some help on my project

I have an 3D printer in my basement and for some safety measures I want to setup an automatic killswitch triggered by an smoke detector.
There are two PINs (GND, Signal) on the smoke detector going HIGH 3,3v in case of smoke detection.
I want to connect the smoke detector directly to the esp-relay to cut off the power of the 3d printer in case of smoke or fire.

so i bought some of these esp-01 relays here
https://de.aliexpress.com/item/ESP8266- ... 21218.html

I also soldered an extra wire directly to the GPIO12 on ESP8266EX Chip, to be able to connect the smoke detector as the esp-01 has only two GPIO pins, so now i have 3 in total.
It was a hard piece of solderwork but fortunately i'm not an heavy drinker so i made it :)

Of course i could take another eps-01 and connect it to the smoke detector that griggers the other esp-1 on the relay but in case of an wifi connectionloss or any other problem it will just not work.
I think it would be the best and safest solution.

I have activated the "Rules-Tab" on EasyESP but unfortunately I'm not good at coding at all so i need your help to code the right logic :(

User avatar
grovkillen
Normal user
Posts: 2844
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: smoke detector triggered killswitch based on esp-01 relay

#2 Post by grovkillen » 10 Jan 2019, 20:30

You need to tell us the setup (task names and value names etc).
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 :idea: :idea: :idea:

letsDIY4fun
Normal user
Posts: 5
Joined: 10 Jan 2019, 20:20

Re: smoke detector triggered killswitch based on esp-01 relay

#3 Post by letsDIY4fun » 10 Jan 2019, 20:35

taskname=killswitch
fire as the valuename

User avatar
grovkillen
Normal user
Posts: 2844
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: smoke detector triggered killswitch based on esp-01 relay

#4 Post by grovkillen » 10 Jan 2019, 20:45

And is it 1/0 for smoke detecting or a range value?
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 :idea: :idea: :idea:

letsDIY4fun
Normal user
Posts: 5
Joined: 10 Jan 2019, 20:20

Re: smoke detector triggered killswitch based on esp-01 relay

#5 Post by letsDIY4fun » 10 Jan 2019, 20:48

0=no smoke
1=smoke detected

:)

User avatar
grovkillen
Normal user
Posts: 2844
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: smoke detector triggered killswitch based on esp-01 relay

#6 Post by grovkillen » 10 Jan 2019, 21:37

Code: Select all

On Killswitch#Smoke Do
  If [Killswitch#Smoke]=1
    GPIO,14,0
   Else
    GPIO,14,1
    EndIf
  EndOn
  
Change the GPIO number to whatever your relay is connected to.
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 :idea: :idea: :idea:

letsDIY4fun
Normal user
Posts: 5
Joined: 10 Jan 2019, 20:20

Re: smoke detector triggered killswitch based on esp-01 relay

#7 Post by letsDIY4fun » 11 Jan 2019, 08:15

Thank you grovkillen, i will try it

Has anyone already tried those chinastuff relays? I mean i've already saw such things like weak soldered PCBs, cheapest components and stuff like this. It would be ironic if an safety measure would cause unsafety as its directly connected to 100-220V AC

kimot
Normal user
Posts: 134
Joined: 12 Oct 2017, 20:46

Re: smoke detector triggered killswitch based on esp-01 relay

#8 Post by kimot » 11 Jan 2019, 08:31

letsDIY4fun wrote:
10 Jan 2019, 20:23

I want to connect the smoke detector directly to the esp-relay to cut off the power of the 3d printer in case of smoke or fire.

So why using ESPeasy module?
Standalone relay driven directly by signal from smoke detector will work the same way.

Or your smoke detector is far away from printer?
Or you want report error state somewhere else?
Then using ESPeasy module is nesessery.

letsDIY4fun
Normal user
Posts: 5
Joined: 10 Jan 2019, 20:20

Re: smoke detector triggered killswitch based on esp-01 relay

#9 Post by letsDIY4fun » 11 Jan 2019, 08:48

I want to report in case of any actions so i was thinking about to combine it with IFTT calling an IFTT trigger, what trigger would be the right one in EasyESP rules?

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests