EasyManuals Logo

Holtek HT48R30A-1 User Manual

Default Icon
174 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #31 background imageLoading...
Page #31 background image
·
Location 010H
This vector is used by the external interrupt INT1
. If the external interrupt pin on the device goes
low, the program will jump to this location and begin execution if the external interrupt is enabled
and the stack is not full. This vector is available for the HT48RU80/HT48CU80 only. For the
other devices, this interrupt is not used.
·
Location 014H
For the HT48RU80/HT48CU80 devices, this internal vector is reserved for the UART Bus inter
-
rupt service routine. When a UART Bus interrupt resulting from a transmission flag or reception
is completed, the program will jump to this location and begin execution if the interrupt is en
-
abled and the stack is not full.
·
Location 018H
For the HT48RU80/HT48CU80 devices, this internal vector is reserved for the Timer/Event
Counter 2 interrupt service routine. If a timer interrupt results from a Timer/Event Counter 2
overflow, the program will jump to this location and begin execution if the interrupt is enabled
and the stack is not full.
Managing Multiple Banks
For the HT48RU80/HT48CU80 devices, which have multiple Program Memory banks, there are
some special considerations that have to be taken into account. First, the sections of program
which are to be located into different banks are placed using the ROMBANK directive. When using
the ²CALL² instruction to call routines located in a different bank, or when using the ²JMP² instruc
-
tions to directly jump to a location in a different bank, the target bank must be first selected by cor
-
rectly setting up the Bank Pointer prior to executing the ²CALL² or ²JMP² instruction. This of
course can be achieved by directly controlling Bit 5 of the Bank Pointer, BP, but can also be done
by using the BANK directive as shown in the example. Then, when a ²CALL² or ²JMP² instruction
is executed, the Bank Pointer value stored in the BP register will be automatically loaded into the
Program Counter. When the ²RET² instruction is encountered in a subroutine called from a differ-
ent bank, the program will automatically return to the original bank, however, the BP value will not
be changed and will remain at the value where the subroutine is located. For this reason the BP
must be carefully managed when moving between banks. The following example for the
HT48RU80/HT48CU80 devices illustrates how to use the ²CALL² and ²JMP² instructions be-
tween different banks:
include HT48RU80.inc
:
:
rombank 0 codesec0 ; define rombank 0
rombank 1 codesec1 ; define rombank 1
:
:
codesec0 .section at 000h ¢code¢ ; locates the following program section
; into Bank 0
clr bp ; re-initializing the BP
jmp start
:
:
start:
:
:
lab0:
:
:
22
I/O Type MCU

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Holtek HT48R30A-1 and is the answer not in the manual?

Holtek HT48R30A-1 Specifications

General IconGeneral
BrandHoltek
ModelHT48R30A-1
CategoryMicrocontrollers
LanguageEnglish

Related product manuals