Minimig RTC

From OpenCircuits
Revision as of 19:49, 29 August 2007 by Freqmax (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Real time clock that keeps the time over power cycling.
Advantages:

  • Disc files get correct date
  • Any software dependent on date will work correctly (astronomy/satellite?)

Commodore: A501 Rev5, 512k + RTC

RAM organised as 16 x (Sanyo LM33256G-12 DIP16) 1 x 256kbit Dynamic RAM
RTC 5 Volt "OKI M6242B" U9 DIP18 clocked with a 32768 Hz crystal, backed up by a 3,6V NiCd battery
M6242B datasheet
Register table:
Address Input Register name Data Count value Description
D3 D2 D1 D0
0 S1 S8 S4 S2 S1 0-9 1-second digit register
1 S10 * S40 S20 S10 0-5 10-second digit register
2 MI1 mi8 mi4 mi2 mi1 0-9 1-minute digit register
3 MI10 * mi40 mi20 mi10 0-5 10-minute digit register
4 H1 h8 h4 h2 h1 0-9 1-hour digit register
5 H10 * PM/AM h20 h10 0-2 or 0-1 PM/AM 10-hour digit register
6 D1 d8 d4 d2 d1 0-9 1-day digit register
7 D10 * * d20 d10 0-3 10-day digit register
8 MO1 mo8 mo4 mo2 mo1 0-9 1-month digit register
9 MO10 * * * MO10 0-1 10-month digit register
A Y1 y8 y4 y2 y1 0-9 1-year digit register
B Y10 y80 y40 y20 y10 0-9 10-year digit register
C W * w4 w2 w1 0-6 Week register (0=Sunday)
D CD 30 sec. ADJ IRQ FLAG BUSY HOLD - Control Register D
E CE t1 t0 ITRPT /STND MASK - Control Register E
F CF TEST 24/12 STOP REST - Control Register F
REST = RESET
ITRPT/STND = INTERRUPT/STANDARD
Note 1) Bit * does not exist (unrecognized during a write and held at "0" during a read).
Note 2) Be sure to mask the AM/PM bit when processing 10's of hour's data.
Note 3) BUSY bit is read only. The IRQ FLAG bit can only be set to a "0". Setting the IRQ FLAG to a "1" is done by hardware.
Note 4) PM at 1 and AM at 0 for PM / AM bit.


Micronik: Realtime Clock for Clockport, RTC

Pin maps:

MCU pins
FPGA pins
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox