RA8900 SA / CE
8.2.2. Calendar counter ( WEEK - YEAR )
Address
Function
03, 13
)
"o" indicates write-protected bits. A zero is always read from these bits.
1) Day of the WEEK counter
The day (of the week) is indicated by 7 bits, bit 0 to bit 6.
The day data values are counted as: Day 01hDay 02hDay 04hDay 08hDay 10hDay
20hDay 40hDay 01hDay 02h, etc.
The correspondence between days and count values is shown below.
WEEK
Write/Read
Write prohibit
Address
04, 14
05, 15
06, 16
)
"o" indicates write-protected bits. A zero is always read from these bits.
The auto calendar function updates all dates, months, and years from January 1, 2001 to December 31, 2099.
The data format is BCD format. For example, a date register value of "0011 0001" indicates the 31st.
Note with caution that writing non-existent date data may interfere with normal operation of the calendar counter.
2) Date counter
Address
04, 14
The updating of dates by the date counter varies according to the month setting.
A leap year is set whenever the year value is a multiple of four (such as 04, 08, 12, 88, 92, or 96). In
February of a leap year, the counter counts dates from "01," "02," "03," to "28," "29," "01," etc.
3) Month counter
Address
05, 15
The month counter counts from 01 (January), 02 (February), and up to 12 (December), then starts again at
01 (January).
4) Year counter
Address
06, 16
The year counter counts from 00, 01, 02 and up to 99, then starts again at 00.
Any year that is a multiple of four (04, 08, 12, 88, 92, 96, etc.) is handled as a leap year.
bit 7
WEEK
bit 7
bit 6
bit 5
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
1
0
Do not set "1" to more than one day at the same time.
Also, note with caution that any setting other than the
seven shown above should not be made as it may
interfere with normal operation.
Function
bit 7
DAY
MONTH
YEAR
80
Function
bit 7
DAY
DAY
1, 3, 5, 7, 8, 10, or 12
4, 6, 9, or 11
Write/Read
February in normal year
February in leap year
Function
bit 7
MONTH
Function
bit 7
YEAR
Y80
bit 6
bit 5
bit 4
6
5
4
bit 4
bit 3
bit 2
bit 1
0
0
0
0
0
0
0
0
1
0
1
0
1
0
0
0
0
0
0
0
0
bit 6
bit 5
bit 4
20
10
10
40
20
10
bit 6
bit 5
bit 4
20
10
Month
bit 6
bit 5
bit 4
10
bit 6
bit 5
bit 4
Y40
Y20
Y10
Page - 9
bit 3
bit 2
bit 1
3
2
1
bit 0
Day
0
1
Sunday
1
0
Monday
0
0
Tuesday
0
0
Wednesday
0
0
Thursday
0
0
Friday
0
0
Saturday
bit 3
bit 2
bit 1
8
4
2
8
4
2
8
4
2
bit 3
bit 2
bit 1
8
4
2
Date update pattern
01, 02, 03 30, 31, 01
01, 02, 03 30, 01, 02
01, 02, 03 28, 01, 02
01, 02, 03 28, 29, 01
bit 3
bit 2
bit 1
8
4
2
bit 3
bit 2
bit 1
Y8
Y4
Y2
ETM44E-01
bit 0
0
Data [h]
01 h
02 h
04 h
08 h
10 h
20 h
40 h
bit 0
1
1
1
bit 0
1
bit 0
1
bit 0
Y1