em78p5842 ELAN Microelectronics Corp, em78p5842 Datasheet - Page 10
![no-image](/images/manufacturer_photos/0/2/215/elan_microelectronics_corp_sml.jpg)
em78p5842
Manufacturer Part Number
em78p5842
Description
8-bit Micro-controller
Manufacturer
ELAN Microelectronics Corp
Datasheet
1.EM78P5842.pdf
(45 pages)
__________________________________________________________________________________________________________________________________________________________________
* This specification is subject to change without notice.
R3 (Status, Page selection)
(Status flag, Page selection bits)
RPAGE1
R/W-0
"MOV R2, A" allows the loading of an address from the A register to the PC, and the ninth and tenth bits are
cleared to "0''.
"ADD R2,A" allows a relative address be added to the current PC, and contents of the ninth and tenth bits are
cleared to "0''.
"TBL" allows a relative address added to the current PC, and contents of the ninth and tenth bits don't change.
The most significant bit (A10~A11) will be loaded with the contents of bit PS0~PS1 in the status register (R5
PAGE0) upon the execution of a "JMP'', "CALL'', "ADD R2, A'', or "MOV R2, A'' instruction.
If an interrupt is triggered, PROGRAM ROM will jump to address 0x08 at page0. The CPU will store ACC,
R3 status and R5 PAGE automatically, and they will be restored after instruction RETI.
Bit 0(C) : Carry flag
Bit 1(DC) : Auxiliary carry flag
Bit 2(Z) : Zero flag
Bit 3(P) : Power down bit
Bit 4(T) : Time-out bit
Bit 5(IOCPAGE) : change IOC5 ~ IOCE to another page
Set to 1 during power on or by a "WDTC" command and reset to 0 by a "SLEP" command.
Set to 1 by the "SLEP" and "WDTC" command, or during power up and reset to 0 by WDT timeout.
Please refer to Fig.4 control register configuration for details.
0/1 Î IOC page0 / IOC page1
EVENT
WDT wake up from sleep mode
WDT time out (not sleep mode)
/RESET wake up from sleep
Power up
Low pulse on /RESET
7
RPAGE0 IOCPAGE
R/W-0
R5(PAGE)
6
A11 A10
R/W-0
0 0
0 1
1 0
1 1
5
Fig.3 Program counter organization
PAGE0 00000~003FF
PAGE1 00400~007FF
PAGE2 00800~00BFF
PAGE3 00C00~00FFF
A9 A8
T
0
0
1
1
x
R
T
4
A7~A0
X
P
0
1
0
1
R
P
3
8
x : don't care
REMARK
R/W
INTERRUPT
CALL
Z
2
and
RETL
RETI
RET
R/W
DC
1
STACK1
STACK4
STACK5
STACK6
STACK7
STACK8
STACK2
STACK3
R/W
C
0
restore
store
EM785840/5841/5842
8-bit Micro-controller
ACC,R3,R5(PAGE)
2004/11/10 V1.2