Based on the Atmel ATtiny12L-4PI microcontroller -A real Time Clock/Calendar for less than US$1.50 in moderate quantity.
• Low current operation (chip sleeps most of the time)
• Alarm and external event triggered interpreter operation
• Capable of stand-alone timer and alarm use. No additional processor required once programmed.
• One external input pin and one open drain output pin for interpreter
AVRStudio Hex file for clock CV0011.hex
This documentation printed to .PDF format t12clock.pdf
Short form programming and reference guide dscmap.pdf
AVR STudio source 02.11.10 V0011.asm
After programming, you must:
1. Select the Low Frequency Crystal oscillator 67ms + 32k clock, and
2. Disable Reset to free up pin 1 as open drain output.
You might want to enable brownout detection if the EEPROM is important in your application, but be aware that activating brown out detection will increase current drain.
The clock is based on the Atmel ATtiny12 processor which is ideal for this kind of application because of its low current drain when clocked by a 32768 Hz crystal.
A DS interface allows access to a register file, EEPROM, and an instruction interpreter. A separate interpreter interprets instructions stored in the EEPROM. EEPROM interpreter operation can be initiated by a clock/calendar alarm, an external event, or by command via the DS interface. The register set plays a central role in moving information between the DS interface and the clock and EEPROM interpreter. One external input can be sampled by the interpreter and one external open drain output can be driven by the interpreter
The clock’s output can be read from registers 3 through 8, but writing to these registers does not affect the clock unless the “write time buffers to clock” flag is set in the control register (register $0F). See the Register Assignments section for more detail.
For more detail: Real Time Clock/Calendar/Alarm with Interpreter for battery backed-up and battery powered operation with DS interface using ATtiny12