The EC1 includes a true Real Time Clock and calendar function. This EasyStep will show you how to connect a battery to your EC1 "EasyOne" so the clock can keep the time when the board is not under power
What you will need
- Holder for two AA or AAA batteries with 2-pin female connector. Example
- Two AA batteries, 1.5V each
Alternatively you could use a single 3V button cell in a suitable holder. The AA batteries are readily available, cheap, and will last a very long time.
The picture below shows the wiring. The EC1 battery pins are the two pins at the corner closest to the push button. They are marked 0V and Vbat. Make sure you connect the red (positive) lead to Vbat.
CAUTION: Do not use a battery over 3.3V.
TestingOnce you have a program that can display the time, you should test the battery. Here's a plan:
- Set the time and make sure it is reading out correctly;
- Power down the board;
- Leave it without power for several minutes (make a note of how long). Capacitors on the board can supply the RTC for quite some time;
- Power it up again and check that the time is still correct;
- Repeat the test without the battery connected and verify that it fails with the same amount of time without power (or preferably less time).