-->
Page 1 of 1

ESP8266 + DS3231 + alarms

PostPosted: Sun Jan 06, 2019 2:08 pm
by chlehmann
Hi all
I googled a lot, found a lot but understood only some infos. This is my first project, it might be a bit heavy for a first try :)

I hacked together a ESP, eink-display and DS3231 RTC in order to have a display showing time, next bus and some other infos. I'd like to run it off the grid and - obviously - as long as i can on a load. In order to achive this, i am using the alarm-functions of the RTC. SQW is connected to RST with a capacitor in between to wake up the ESP. Powering this setup from my notebook (usb) was working just fine.

Just before "finishing" it i read that the supplied battery on the RTC is not recharchable and i therefore have to remove a resistor (https://campercontrol.org/step-1-assemb ... tc-module/).
After doing that, the rtc no longer wakes up my esp, no matter what power supply i provide. But time is still working, i can read the RTC just fine!

There are lots of information about removing this or that, or even shorting stuff on the RTC, i really lost track what i should do. The most promising thing might be Adrian writing point 2 here: http://woodsgood.ca/projects/2014/10/21 ... c-battery/ (in the middle of the comments-section), but this is all too high for me.

In short: can somebody help me with operate DS3231 without charging circuit but with working alarms?

Thank you so much!
Chris

Re: ESP8266 + DS3231 + alarms

PostPosted: Mon Jan 07, 2019 7:57 am
by schufti
in general info on both linked pages is correct but should not influence operation of sqw.
So unless you provide more information on your exact module and wiring there will be no further advice possible.

Re: ESP8266 + DS3231 + alarms

PostPosted: Tue Jan 08, 2019 10:28 am
by MamaMia
Not sure if this will help with your problem

From the manufacturers data sheet - see below.
The square wave output requires a pull-up resistor as the SQW output is a open drain FET.
A 470 Ohm resistor to your 5v (or 3.3v) supply line should do.
...........

Active-Low Interrupt or Square-Wave Output. This open-drain pin requires an external pullup resistor connected
to a supply at 5.5V or less. This multifunction pin is determined by the state of the INTCN bit in the Control
Register (0Eh). When INTCN is set to logic 0, this pin outputs a square wave and its frequency is determined by
RS2 and RS1 bits. When INTCN is set to logic 1, then a match between the timekeeping registers and either of
the alarm registers activates the INT/SQW pin (if the alarm is enabled). Because the INTCN bit is set to logic 1
when power is first applied, the pin defaults to an interrupt output with alarms disabled. The pullup voltage can
be up to 5.5V, regardless of the voltage on VCC. If not used, this pin can be left unconnected.