ht82j30r Holtek Semiconductor Inc., ht82j30r Datasheet - Page 11

no-image

ht82j30r

Manufacturer Part Number
ht82j30r
Description
Ht82j30r/ht82j30a -- 16 Channel A/d Mcu With Spi Interface
Manufacturer
Holtek Semiconductor Inc.
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
HT82J30R
Manufacturer:
HOLTEK
Quantity:
155
Special Function Registers
To ensure successful operation of the microcontroller,
certain internal registers are implemented in the Data
Memory area. These registers ensure correct operation
of internal functions such as timers, interrupts, etc., as
well as external functions such as I/O data control. The
location of these registers within the Data Memory be-
gins at the address 00H. Any unused Data Memory lo-
cations between these special function registers and the
point where the General Purpose Memory begins is re-
served and attempting to read data from these locations
will return a value of 00H.
Indirect Addressing Register - IAR
The IAR register, located at Data Memory address
ter allows what is known as indirect addressing, which
permits data manipulation using Memory Pointers in-
stead of the usual direct memory addressing method
data .section
adres1
adres2
adres3
adres4
block
code .section at 0 code
org
start:
loop:
continue:
The important point to note here is that in the example shown above, no reference is made to specific Data Memory ad-
dresses.
Rev. 1.10
00H , is not physically implemented. This special regis-
mov a,04h
mov block,a
mov a,offset adres1; Accumulator loaded with first RAM address
mov mp,a
clr IAR
inc mp
sdz block
jmp loop
00h
db ?
db ?
db ?
db ?
db ?
data
; setup size of block
; setup memory pointer with first RAM address
; check if last memory location has been cleared
; clear the data at address defined by MP
; increment memory pointer
11
where the actual memory address is defined. Any ac-
tions on the IAR register will result in corresponding
read/write operations to the memory location specified
by the Memory Pointer MP. Reading the IAR register in-
directly will return a result of 00H and writing to the
register indirectly will result in no operation.
Memory Pointer - MP
One Memory Pointer, known as MP, is physically imple-
mented in the Data Memory. The Memory Pointer can
be written to and manipulated in the same way as nor-
mal registers providing an easy way of addressing and
tracking data. When using any operation on the indirect
addressing register IAR, it is actually the address speci-
fied by the Memory Pointer that the microcontroller will
be directed to.
HT82J30R/HT82J30A
March 13, 2008

Related parts for ht82j30r