ESP8266-01 with TPL5111

Nelari
Posts: 4
Joined: Wed Feb 07, 2018 2:37 pm

ESP8266-01 with TPL5111

Postby Nelari » Wed Feb 07, 2018 3:19 pm

I am trying to build a battery-powered data logger with the ESP8266-01. It would do a measurement once every hour, report it by WiFi and then do nothing (sleep) for another 60 minutes. The timing would be handled by the TPL5111 chip that seems tailor-made for an application like this. On TI's data sheet, it looks very simple:

1) The TPL5111 (with its DRV pin) turns on the ENABLE pin of the voltage regulator.
2) The ESP8266-01, powered by the regulator, does its thing and raises the TPL5111's DONE pin.
3) The TPL5111 turns off the ENABLE pin of the voltage regulator (and the ESP loses power.)
4) Repeat after an hour.

So, I have connected GPIO1 to the TPL5111's DONE pin. But it only works once (for me). GPIO1 should be LOW from power-on-reset and then, at the end of the data logging process, be (made) HIGH. But this does not seem to happen with my digitalWrite(1, x); instructions, no matter how I juggle the LOW's and HIGH's (I have a pinMode(1, OUTPUT); at the start.)

Can anyone help? I'm at my wits' end.

Nelari
Posts: 4
Joined: Wed Feb 07, 2018 2:37 pm

Re: ESP8266-01 with TPL5111

Postby Nelari » Wed Feb 07, 2018 11:37 pm

Nelari wrote:2) The ESP8266-01, powered by the regulator, does its thing and raises the TPL5111's DONE pin.

I don't have much measuring equipment, so I added a simple (RC) edge detector at the TPL5111's DONE pin. Judging from its behaviour, the ESP's GPIO1 pin goes HIGH immediately at power-on – even though there has not been time for the data-logging program to run, and there has been no digitalWrite to access the pin. The TPL5111 interprets this rising edge as the DONE signal, and turns off the ESP's power. So the ESP does get power, but loses it right away.

If this is what is going on, I would need a way to make sure the GPIO1 pin stays LOW during the ESP's power-on. Is there such a way?

Nelari
Posts: 4
Joined: Wed Feb 07, 2018 2:37 pm

Re: ESP8266-01 with TPL5111

Postby Nelari » Sun Feb 11, 2018 3:35 am

Never mind. Just use GPIO3 instead of GPIO1. Simple!

Who is online

Users browsing this forum: No registered users and 2 guests