So you're a Noob? Post your questions here until you graduate! Don't be shy.

User avatar
By jpoppinmoneyunit
#75078 I've done a few searches so bear with me if it's been covered already.

I have a circuit mapped out on a breadboard for adding wifi to an espresso machine via esp8266-01 and using the st_anything GitHub repos.

My problem is that the espresso machine uses a momentary button to trigger the machine on with a 5V pulse, which is easy enough. But the esp8266-01 module (or maybe other versions too) give off a short pulse on the gpio pins right when you first power up the module. This would be ok too but I don't want the machine to power up every time I plug it in or have a power outage when i'm not at home.

Is there a way to cut out that first little blip of power using a hardware solution? Some sort of filter that only gives an output if the gpio is on for 3 seconds or so? Or some other solution?

Thanks in advance.
User avatar
By rudy
#75082 Use GPIO4 or GPIO5. They do not have any action when the ESP8266 turns on. There are other hardware methods but this would be easiest. You should have a pull-down resistor included to give the line a defined state before it is initialized.

Other options is to use one of the port pins that have internal pull-up enabled on turn on to drive a p-channel mosfet. Low being On. The mosfet inverts the signal and you get a high out. (3.3v)

Opto-couplers can be used.
User avatar
By btidey
#75089 Are you intending to use the esp-01 module (8 pin header)? They have very limited access to the GPIO pins just GPIO00 and GPIO02, compared with either dev boards or esp-12 modules. I don't use esp-01 for that reason.

I think as Rudy suggested if you make the trigger active low by inverting with a buffer (mosfet or bjt) which you will probably need to get 5V pulse anyway then you can avoid the problem by using a pull up to 3.3V on the pin and ensuring you set the data output high before you set the pinMode.
User avatar
By rudy
btidey wrote:.. set the data output high before you set the pinMode.

Yes, always set the output state before enabling the port for output.