전자부품 데이터시트 검색엔진
  Korean  ▼
ALLDATASHEET.CO.KR

X  

HMS91C8032 데이터시트(PDF) 17 Page - Hynix Semiconductor

부품명 HMS91C8032
상세설명  HYNIX SEMICONDUCTOR INC. 8-BIT SINGLE-CHIP MICROCONTROLLERS
PDF  157 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
제조업체  HYNIX [Hynix Semiconductor]
홈페이지  http://www.skhynix.com/kor/main.do
Logo HYNIX - Hynix Semiconductor

HMS91C8032 데이터시트(HTML) 17 Page - Hynix Semiconductor

Back Button HMS91C8032 Datasheet HTML 13Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 14Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 15Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 16Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 17Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 18Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 19Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 20Page - Hynix Semiconductor HMS91C8032 Datasheet HTML 21Page - Hynix Semiconductor Next Button
Zoom Inzoom in Zoom Outzoom out
 17 / 157 page
background image
HMS91C8032/97C8032
14
NOV., 2001 Ver 1.02
The table lists a single "JMP add" instruction, but in fact there are
three SJMP, LJMP, and AJMP, which differ in the format of the
destination address. JMP is a generic mnemonic which can be
used if the programmer does not care which way the jump is en-
coded.
The SJMP instruction encodes the destination address as a rela-
tive offset, as described above. The instruction is 2 bytes long,
consisting of the opcode and the relative offset byte. The jump
distance is limited to a range of -128 to +127 bytes relative to the
instruction following the SJMP.
The LJMP instruction encodes the destination address as a 16-bit
constant. The instruction is 3 bytes long, consisting of the opcode
and two address bytes. The destination address can be anywhere
in the 64K Program Memory space.
The AJMP instruction encodes the destination address as an
11-bit constant. The instruction is 2 bytes long, consisting of the
opcode, which itself contains 3 of the 11 address bits, followed by
another byte containing the low 8 bits of the destination address.
When the instruction is executed, these 11 bits are simply substi-
tuted for the low 11 bits in the PC. The high 5 bits stay the same.
Hence the destination has to be within the same 2K block as the
instruction following the AJMP.
In all cases the programmer specifies the destination address to
the assembler in the same way: as a label or as a 16-bit constant.
The assembler will put the destination address into the correct
format for the given instruction. If the format required by the in-
struction will not support the distance to the specified destination
address, a "Destination out of range" message is written into the
List file.
The JMP @A+DPTR instruction supports case jumps. The desti-
nation address is computed at execution time as the sum of the
16-bit DPTR register and the Accumulator. Typically. DPTR is
set up with the address of a jump table. In a 5-way branch, for ex-
ample, an integer 0 through 4 is loaded into the Accumulator. The
code to be executed might be as follows:
MOV
DPTR,#JUMP TABLE
MOV
A,INDEX_NUMBER
RL
A
JMP
@A+DPTR
The RL A instruction converts the index number (0 through 4) to
an even number on the range 0 through 8, because each entry in
the jump table is 2 bytes long:
JUMP TABLE:
AJMP
CASE 0
AJMP
CASE 1
AJMP
CASE 2
AJMP
CASE 3
AJMP
CASE 4
Table 3-1 shows a single "CALL addr" instruction, but there are
two of them, LCALL and ACALL, which differ in the format in
which the subroutine address is given to the CPU. CALL is a ge-
neric mnemonic which can be used if the programmer does not
care which way the address is encoded.
The LCALL instruction uses the 16-bit address format, and the
subroutine can be anywhere in the 64K Program Memory space.
The ACALL instruction uses the 11-bit format, and the subrou-
tine must be in the same 2K block as the instruction following the
ACALL.
In any case, the programmer specifies the subroutine address to
the assembler in the same way: as a label or as a 16-bit constant.
The assembler will put the address into the correct format for the
given instructions.
Subroutines should end with a RET instruction, which returns ex-
ecution to the instruction following the CALL.
RETI is used to return from an interrupt service routine. The only
difference between RET and RETI is that RETI tells the interrupt
control system that the interrupt in progress is done. If there is no
interrupt in progress at the time RETI is executed, then the RETI
is functionally identical to RET.
Table 3-7 shows the list of conditional jumps available to the
HMS9XC8032 user. All of these jumps specify the destination
address by the relative offset method, and so are limited to a jump
distance of -128 to +127 bytes from the instruction following the
conditional jump instruction. Important to note, however, the user
specifies to the assembler the actual destination address the same
way as the other jumps: as a label or a 16-bit constant.
There is no Zero bit in the PSW. The JZ and JNZ instructions test
the Accumulator data for that condition.
The DJNZ instruction (Decrement and Jump if Not Zero) is for
loop control. To execute a loop N times, load a counter byte with
N and terminate the loop with a DJNZ to the beginning of the
loop, as shown below for N = 10:
MOV
COUNTER,#10
LOOP:(begin loop)
•
•
•
(end loop)
DJNZ
COUNTER, LOOP
(continue)
.
The CJNE instruction (Compare and Jump if Not Equal) can also
be used for loop control as in Figure 12. Two bytes are specified
in the operand field of the instruction. The jump is executed only
if the two bytes are not equal. In the example of Figure B-3 Shift-
ing a BCD Number One Digits to the Right, the two bytes were
data in R1 and the constant 2AH. The initial data in R1 was 2EH.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


데이터시트 다운로드

Go To PDF Page


링크 URL



ALLDATASHEET 가 귀하에 도움이 되셨나요?  [ DONATE ] 

Alldatasheet는?   |   광고문의   |   운영자에게 연락하기   |   개인정보취급방침   |   링크 투 데이터시트    |   링크교환   |   제조사별 검색
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com