Looking for a little guidance on a couple of ESP-01 configurations.
Moderators: grovkillen, Stuntteam, TD-er
Looking for a little guidance on a couple of ESP-01 configurations.
Will someone help with how to configure the following? I am a novice, at best, with electronics and learning as I go with your help of course. There are two different ESP nodes that I would like to create. So far, I can only get an led to work with both GPIO0 and GPIO2. I'm using openhab via MQTT and I know how to interface with openhab. My problem is that I can't get the ESP to load when I attach a pull-up resistor to either GPIO.
Node 1
- Reed switch and push button. The reed switch trips and sends an on/off to openhab via mqtt. The button performs the same command on the other GPIO.
> Do I use pull-up resistors? pull-down? Do I use the Switch hardware via the gui?
Node 2
- push button and relay.
> I'm assuming that I'll use the same design as recommended for Node 1 and the LED config that is already working.
Thank you for your patience and help.
Node 1
- Reed switch and push button. The reed switch trips and sends an on/off to openhab via mqtt. The button performs the same command on the other GPIO.
> Do I use pull-up resistors? pull-down? Do I use the Switch hardware via the gui?
Node 2
- push button and relay.
> I'm assuming that I'll use the same design as recommended for Node 1 and the LED config that is already working.
Thank you for your patience and help.
Re: Looking for a little guidance on a couple of ESP-01 configurations.
Can you explain a little more precise what you mean with
"My problem is that I can't get the ESP to load when I attach a pull-up resistor to either GPIO".
When EASY esp is loaded you do not need any pull up or down resistors on the GPIO-01or 02 on the ESP 8266-01 versions.
Paco
"My problem is that I can't get the ESP to load when I attach a pull-up resistor to either GPIO".
When EASY esp is loaded you do not need any pull up or down resistors on the GPIO-01or 02 on the ESP 8266-01 versions.
Paco
Re: Looking for a little guidance on a couple of ESP-01 configurations.
Trying to install a pull-up/down resistor may be my problem then.
How should I install a push button/reed switch? Does it matter if I use GPIO0 or GPIO2?
Where can I read up this?
Thanks again.
How should I install a push button/reed switch? Does it matter if I use GPIO0 or GPIO2?
Where can I read up this?
When EASY esp is loaded you do not need any pull up or down resistors on the GPIO-01or 02 on the ESP 8266-01 versions.
Thanks again.
-
- Normal user
- Posts: 35
- Joined: 11 Nov 2015, 13:52
Re: Looking for a little guidance on a couple of ESP-01 configurations.
Just connect your button between the gpio (of your choice) and ground.
Then in the device menu of the Web gui . Choose switch. Enter the gpio that u used and tick the box with pull up. If u now push the button it will connect to ground otherwise it is pulled high by the esp.
You can also read this in the wiki:
http://www.esp8266.nu/index.php/Switch
Then in the device menu of the Web gui . Choose switch. Enter the gpio that u used and tick the box with pull up. If u now push the button it will connect to ground otherwise it is pulled high by the esp.
You can also read this in the wiki:
http://www.esp8266.nu/index.php/Switch
Re: Looking for a little guidance on a couple of ESP-01 configurations.
I am sorry that I am still having problems with the switch.
Can you see what may be wrong?
Notes:
- The value in the green area does not change.
- The button is in between the ground and GPIO0. I've tested the button and it is functioning properly and I connected it directly.
- The switch works fine
-I'm not sure what the correct format for openhab is correct. So I've listed many combinations.
- Here's a capture of the config
Thanks again.
Can you see what may be wrong?
Notes:
- The value in the green area does not change.
- The button is in between the ground and GPIO0. I've tested the button and it is functioning properly and I connected it directly.
- The switch works fine
Code: Select all
Switch MQTTLED (test) {mqtt=">[mymosquitto:/ESP01/gpio/2:command:ON:1],>[mymosquitto:/ESP01/gpio/2:command:OFF:0]"}
Code: Select all
Switch MQTTLED (test) {mqtt=">[mymosquitto:/ESP01/gpio/2:command:ON:1],>[mymosquitto:/ESP01/gpio/2:command:OFF:0]"}
Contact MQTTBTN1 (test) {mqtt="<[mymosquitto:/ESP01/gpio/0:state:default]"}
Contact MQTTBTN2 (test) {mqtt="<[mymosquitto:/ESP01/switch1:state:default]"}
Contact MQTTBTN3 (test) {mqtt="<[mymosquitto:/ESP01/MQTTBTN:state:default]"}
Contact MQTTBTN4 (test) {mqtt="<[mymosquitto:/ESP01/switch1/MQTTBTN:state:default]"}
Re: Looking for a little guidance on a couple of ESP-01 configurations.
to see the switch work in the esp easy interface you have to set the IDX/var value to an other value then 0.
Paco
Paco
Re: Looking for a little guidance on a couple of ESP-01 configurations.
The ESP will still not recognize the input on either 00 and 02.
I changed the EDX/var to 123 and tried 100 as well.
Here's a picture of the build.
I changed the EDX/var to 123 and tried 100 as well.
Here's a picture of the build.
Re: Looking for a little guidance on a couple of ESP-01 configurations.
Did you connected the GND to the ESP board?
Picture does not show it.
This is how it works for me with a simple NO Normally Open contact.
Take care that if you press the switch the status in the interface will take some time to refresh.
Or do a manual refesh of the browser.
IDX/VAR is not shown as screenshot is from other version.
Paco
Picture does not show it.
This is how it works for me with a simple NO Normally Open contact.
Take care that if you press the switch the status in the interface will take some time to refresh.
Or do a manual refesh of the browser.
IDX/VAR is not shown as screenshot is from other version.
Paco
Re: Looking for a little guidance on a couple of ESP-01 configurations.
Finally... I've got it working. Please bear with me as I two more requests...
- I can't get Openhab to pick it up.
- Can the switch config maintain a particular state when the circuit is closed? It appears to be in a monetary state (changing from 1 to 0 then to 0 to 1) each time the button it pushed. My idea would be for the state to normally be open (0) then change to (1) when the circuit is closed (button pressed) then back to open (0) when released.
These are the items that do not work.
Here's the log.
- I can't get Openhab to pick it up.
- Can the switch config maintain a particular state when the circuit is closed? It appears to be in a monetary state (changing from 1 to 0 then to 0 to 1) each time the button it pushed. My idea would be for the state to normally be open (0) then change to (1) when the circuit is closed (button pressed) then back to open (0) when released.
These are the items that do not work.
Code: Select all
Contact MQTBTN (test) {mqtt=">[mymosquitto:/esp01/switch/button:state:MAP(switch.map)]"}
Contact MQTBTN1 (test) {mqtt=">[mymosquitto:/esp01/switch/button:state:default)]"}
SW : State 0
HTTP : Delay 1000 ms
MQTT : Topic /esp01/switch/button
SW : State 1
HTTP : Delay 1000 ms
MQTT : Topic /esp01/switch/button
Re: Looking for a little guidance on a couple of ESP-01 configurations.
i do not know how that mqtt stuff works.
it should work as you describe.
What happens in the esp interface is the correct status...........to work from. if they differ with openhab I have no idea.
Paco
it should work as you describe.
What happens in the esp interface is the correct status...........to work from. if they differ with openhab I have no idea.
Paco
Who is online
Users browsing this forum: No registered users and 12 guests