homieiot / homie-esp8266

💡 ESP8266 framework for Homie, a lightweight MQTT convention for the IoT
http://homieiot.github.io/homie-esp8266
MIT License
1.36k stars 308 forks source link

ESP-01 and GPIO0 not working #105

Closed mikecay closed 8 years ago

mikecay commented 8 years ago

Hi

I have a sketch to control 2 relays, for some reason the sketch cannot set GPIO0 HIGH, GPIO2 is fine. I know the ESP-01 is working because if I use a sketch without homie I can set GPIO0 HIGH. Does homie do something on GPIO0?

Thank you,

Mike

marvinroger commented 8 years ago

See Reset : http://marvinroger.viewdocs.io/homie-esp8266~v1.5.0/3.-Advanced-usage

GPIO0 is indeed used as a trigger to reset the homie-esp8266 config. Before Homie.setup(), just do Homie.disableResetTrigger() to disable this behavior.

mikecay commented 8 years ago

Thank you for the quick response. In doing so will I still be able to do ota updates?

Mike

marvinroger commented 8 years ago

Yes you will. Resetting means, in Homie, press a button to erase the internal configuration of the board, OTA is another thing, and will still work. :)