![Cmsemicon BAT32G1 9 Series Скачать руководство пользователя страница 1030](http://html1.mh-extra.com/html/cmsemicon/bat32g1-9-series/bat32g1-9-series_user-manual_26276091030.webp)
BAT32G1x9 user manual | Chapter 24 Enhanced DMA
1030 / 1149
Rev.1.02
(1) Example 1 of the use of normal mode: Continuous A/D conversion results
The DMA is initiated via the A/D conversion end interrupt and the value of the A/D conversion result
register is passed to RAM.
•
Vector address assignment at 2000000AH, control data assignment at 200000E0H~2000000EFH.
• Transfer 2-byte data from the A/D conversion result registers (40045004H, 40045005H) 40 times
to 20000400H of RAM ~80 bytes of ~2000044FH.
Figure 24-18 use of normal mode 1: Continuous A/D conversion results
DMABAR=20000000H
vector address (2000000AH)=0AH
DMACR10(200000E0H)=0048H
DMBLS10(200000E2H)=0001H
DMACT10(200000E4H)=0028H
DMSAR10(200000E8H)=40045004H
DMDAR10(200000ECH)=20000400H
DMAEN1=04H
start A/D conversion
A/D conversion completion interrupt?
Yes
DMACT10=01H
?
No
data transmit
No
generate A/D conversion completion interrupt
request
DMAEN1=00H
data transmit
interrupt handling
Yes
internal handling automatically executed by DMA
RAM
A/D conversion result register
20000400H
2000044EH
Because it is normal mode, the value of the DMRLD10 register is not used. However, when parity error
reset (RPERDIS=0) is allowed to occur via the RAM parity error detection function, the DMRLD10 register
must be initialized (0 000H).