DatasheetQ Logo
Electronic component search and free download site. Transistors,MosFET ,Diode,Integrated circuits

HMS97C8032 데이터 시트보기 (PDF) - Hynix Semiconductor

부품명
상세내역
제조사
HMS97C8032 Datasheet PDF : 157 Pages
First Prev 11 12 13 14 15 16 17 18 19 20 Next Last
HMS91C8032/97C8032
MOV
MOV
MOV
MOV
MOV
A,2EH
2EH,2DH
2DH,2CH
2CH,2BH
2BH,#0
2A 2B 2C 2D 2E ACC
00 12 34 56 78 78
00 12 34 56 56 78
00 12 34 34 56 78
00 12 12 34 56 78
00 00 12 34 56 78
A. Using direct MOVs: 14 bytes, 9us
CLR
XCH
XCH
XCH
XCH
A
A,2BH
A,2CH
A,2DH
A,2EH
2A 2B 2C 2D 2E ACC
00 12 34 56 78 00
00 00 34 56 78 12
00 00 12 56 78 34
00 00 12 34 78 56
00 00 12 34 56 78
B. Using XCHs: 9 bytes, 5us
Figure 3-2 Shifting a BCD Number Two Digits to the
Right
MOV R1,#2EH
MOV R0,#2DH
2A 2B 2C 2D 2E ACC
00 12 34 56 78 XX
00 12 34 56 78 XX
loop for R1 = 2EH
LOOP: MOV A,@R1
00 12
XCHD A,@R0
00 12
SWAP A
00 12
MOV @R1,A
00 12
DEC R1
00 12
DEC R0
00 12
CJNE R1,#2AH,LOOP
34 56
34 58
34 58
34 58
34 58
34 58
78 78
78 76
78 67
67 67
67 67
67 67
loop for R1 = 2DH:
loop for R1 = 2CH:
loop for R1 = 2BH:
00 12 38 45 67 45
00 18 23 45 67 23
08 01 23 45 67 01
CLR
XCH
A
A,2AH
00 01 23 45 67 00
08 01 23 45 67 08
Figure 3-3 Shifting a BCD Number One Digits to the
Right
First, pointers R1 and R0 are set up to point to the two bytes con-
taining the last four BCD digits. Then a loop is executed which
leaves the last byte, location 2EH, holding the last two digits of
the shifted number. The pointers are decremented, and the loop is
repeated for location 2DH. The CJNE instruction (Compare and
Jump if Not equal) is a loop control that will be described later.
The loop executed from LOOP to CJNE for R1 = 2EH, 2DH,
2CH, and 2BH. At that point the digit that was originally shifted
out on the right has propagated to location 2AH. Since that loca-
tion should be left with 0s, the lost digit is moved to the Accumu-
lator.
External RAM
HMC9XC8032 series do NOT support external RAM access
mode.
3.6 Lookup Tables
Table 3-4 shows the two instructions that are available for read-
ing lookup tables in Program Memory. Since these instructions
access only Program Memory, the lookup tables can only be read,
not updated.
The mnemonic is MOVC for "move constant." The first MOVC
instruction in Table 3-1 can accommodate a table of up to 256 en-
tries numbered 0 through 255. The number of the desired entry is
loaded into the Accumulator, and the Data Pointer is set up to
point to the beginning of the table. Then:
MOVC A, @A+DPTR
copies the desired table entry into the Accumulator.
The other MOVC instruction works the same way, except the
Program Counter (PC) is used as the table base, and the table is
accessed through a subroutine. First the number of the desired en-
try is loaded into the Accumulator, and the subroutine is called:
MOV A , ENTRY NUMBER
CALL TABLE
The subroutine "TABLE" would look like this:
TABLE: MOVC A , @A+PC
RET
The table itself immediately follows the RET (return) instruction
is Program Memory. This type of table can have up to 255 entries,
numbered 1 through 255. Number 0 cannot be used, because at
the time the MOVC instruction is executed, the PC contains the
address of the RET instruction. An entry numbered 0 would be
the RET opcode itself.
MNEMONIC
MOVC A, @A+DPTR
MOVC A, @A+PC
OPERATION
Read program memory at (A + DPTR)
Read program memory at (A + PC)
Table 3-4 Table B-4 HMS9XC8032 Data Transfer Instruction that Access Internal Data Memory Spcace
12
NOV., 2001 Ver 1.02

Share Link: 

datasheetq.com  [ Privacy Policy ]Request Datasheet ] [ Contact Us ]