KR20010087887A - Dma having operational function - Google Patents

Dma having operational function Download PDF

Info

Publication number
KR20010087887A
KR20010087887A KR1020000011723A KR20000011723A KR20010087887A KR 20010087887 A KR20010087887 A KR 20010087887A KR 1020000011723 A KR1020000011723 A KR 1020000011723A KR 20000011723 A KR20000011723 A KR 20000011723A KR 20010087887 A KR20010087887 A KR 20010087887A
Authority
KR
South Korea
Prior art keywords
dma
register
data
channel
control
Prior art date
Application number
KR1020000011723A
Other languages
Korean (ko)
Other versions
KR100356810B1 (en
Inventor
고남곤
Original Assignee
박종섭
주식회사 하이닉스반도체
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 박종섭, 주식회사 하이닉스반도체 filed Critical 박종섭
Priority to KR1020000011723A priority Critical patent/KR100356810B1/en
Publication of KR20010087887A publication Critical patent/KR20010087887A/en
Application granted granted Critical
Publication of KR100356810B1 publication Critical patent/KR100356810B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/20Handling requests for interconnection or transfer for access to input/output bus
    • G06F13/28Handling requests for interconnection or transfer for access to input/output bus using burst mode transfer, e.g. direct memory access DMA, cycle steal
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/38Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
    • G06F7/48Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation using non-contact-making devices, e.g. tube, solid state device; using unspecified devices
    • G06F7/57Arithmetic logic units [ALU], i.e. arrangements or devices for performing two or more of the operations covered by groups G06F7/483 – G06F7/556 or for performing logical operations
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2213/00Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F2213/28DMA
    • G06F2213/2804Systems and methods for controlling the DMA frequency on an access bus

Abstract

PURPOSE: A device for the DMA(Direct Memory Access) having a function of an operation is provided to reduce a total operating time by performing the data operation during the data transfer cycle. CONSTITUTION: A DMA register bus I/F(Interface)(602) is the interface for the data I/O(Input/Output) between a MCU(Micro Controller Unit) inner bus(622) and the DMA(600). A data register(604) stores the data inputted from the MCU inner bus. A channel(606) generates a source or destination address according to the operation mode or state of the DMA. A DMA control register(608) stores the control values(START/STOP) necessary to DMA control. A channel control register(610) stores the control values necessary to channel control. A channel·DMA·operating controller(612) control the channel, an address multiplexer(614), DMA operating register(616), DMA operator(618), and operating result register(620). The address multiplexer selectively outputs the source or destination address which is output from each channel. The DMA operating register stores the data which will be operated at the inside of the DMA. The DMA operator performs the operation of the data delivered from the DMA. The operating result register stores the operating result of the DMA operator.

Description

연산 기능을 갖는 다이렉트 메모리 액세스 장치{DMA HAVING OPERATIONAL FUNCTION}Direct memory access device with arithmetic function {DMA HAVING OPERATIONAL FUNCTION}

본 발명은 MCU(Micro Controller Unit)에 관한 것으로, 특히 MCU의 DMA(Direct Memory Access)에 관한 것이다.The present invention relates to a microcontroller unit (MCU), and more particularly to a direct memory access (DMA) of the MCU.

DMA는 제어 장치에 프로세서를 거치지 않고 메모리의 데이터를 인출하거나 메모리에 데이터를 써넣을 수 있도록 하는 장치이다. 도 1은 DMA를 갖는 종래의 MCU의 구성을 나타낸 블록 다이어그램이다. MCU(102) 내부는 CPU(110)와 내부 메모리(112), 내부 I/O(114), DMA(116), 외부 버스 제어부(118), MCU 제어부(120)가 내부 버스(122)로 연결되어 이루어진다. 이 MCU(108)는 외부 버스(108)를 통해 외부 메모리(104)나 외부 I/O(106) 등과 연결된다. 원천 어드레스 리드 사이클(Source Address Read Cycle) 동안에 외부 메모리(104) 또는 외부 I/O(106)를 통해 읽혀진 데이터는 외부 시스템 버스(108)를 통해 DMA(116)의 데이터 레지스터에 저장되고 원천 어드레스 리드 사이클은 종료된다. 원천 어드레스 리드 사이클이 종료된 후 목적지 어드레스 라이트 사이클(Destination Address Write Cycle)이 시작되면, DMA(116) 내부의 데이터 레지스터에 저장되어 있는 데이터가 다시 내부 버스(122)에 실리고, 목적지 어드레스가 내부 I/O(114) 또는 내부 메모리(112)인 경우에는 데이터가 해당 장소에 기록되며 외부 메모리(104)나 외부 I/O(106)인 경우에는 MCU(108) 밖으로 출력되어 해당 장소에 기록되면서 하나의 DMA 사이클이 종료된다.A DMA is a device that allows data to be written to or written out of a memory without passing through a processor to the control device. 1 is a block diagram showing the configuration of a conventional MCU having a DMA. Inside the MCU 102, the CPU 110, the internal memory 112, the internal I / O 114, the DMA 116, the external bus controller 118, and the MCU controller 120 are connected to the internal bus 122. It is done. The MCU 108 is connected to an external memory 104 or an external I / O 106 or the like through an external bus 108. Data read through external memory 104 or external I / O 106 during a Source Address Read Cycle is stored in the data register of DMA 116 via external system bus 108 and read source address read. The cycle ends. When the destination address write cycle starts after the source address read cycle ends, the data stored in the data register inside the DMA 116 is loaded on the internal bus 122 again, and the destination address is internal I. In the case of / O 114 or internal memory 112, data is recorded in the corresponding place, and in case of the external memory 104 or external I / O 106, the data is output out of the MCU 108 and recorded in the corresponding place. The DMA cycle ends.

도 2는 종래의 DMA의 구성을 나타낸 블록 다이어그램이다. DMA 레지스터 버스 인터페이스(202)는 MCU의 내부 버스(122)와 DMA(116) 사이의 데이터 입출력을 위한 인터페이스이다. DMA 레지스터 버스 인터페이스(202)는 MCU의 내부 버스(222)의 어드레스 또는 제어 값을 채널(206)이나 DMA 제어 레지스터(208), 채널 제어 레지스터(210) 등에 전달하고, 반대로 채널(206)이나 DMA 제어 레지스터(208), 채널 제어 레지스터(210)의 어드레스 또는 제어 값을 MCU 내부 버스(122)로 전달한다. 데이터 레지스터(204)는 MCU 내부 버스(122)를 통해 입력되는 데이터를 저장한다. 채널(206)은 DMA(116)의 동작 모드 또는 상태에 따라 원천 어드레스나 목적지 어드레스를 발생시킨다. DMA 제어 레지스터(208)는 START/STOP 등과 같은 DMA 제어에 필요한 제어 값들을 저장한다. 채널제어 레지스터(210)는 채널(206)의 어드레스 출력을 제어하는데 필요한 제어 값들을 저장한다. 채널ㆍDMA 제어기(212)는 DMA 제어 레지스터(208)와 채널 제어 레지스터(210)의 제어 값 등을 이용하여 채널(206)과 어드레스 멀티플렉서(214) 등을 제어한다. 어드레스 멀티플렉서(214)는 각 채널(206)에서 출력되는 원천 어드레스(Source Address)와 목적지 어드레스(Destination Address) 가운데 하나를 DMA 어드레스로서 출력한다. 어드레스 멀티플렉서(214)는 원천 어드레스 리드 사이클 동안에는 원천 어드레스를 출력하고, 목적지 어드레스 리드 사이클 동안에는 목적지 어드레스를 출력한다.2 is a block diagram showing the configuration of a conventional DMA. The DMA register bus interface 202 is an interface for data input and output between the MCU's internal bus 122 and the DMA 116. The DMA register bus interface 202 transfers the address or control value of the MCU's internal bus 222 to the channel 206, the DMA control register 208, the channel control register 210, and the like, and vice versa. The control register 208 and the address or control value of the channel control register 210 are transferred to the MCU internal bus 122. The data register 204 stores data input via the MCU internal bus 122. Channel 206 generates a source address or a destination address depending on the operating mode or state of DMA 116. The DMA control register 208 stores control values necessary for DMA control, such as START / STOP. The channel control register 210 stores control values necessary to control the address output of the channel 206. The channel / DMA controller 212 controls the channel 206 and the address multiplexer 214 and the like using the control values of the DMA control register 208 and the channel control register 210 and the like. The address multiplexer 214 outputs one of a source address and a destination address output from each channel 206 as a DMA address. The address multiplexer 214 outputs the source address during the source address read cycle and outputs the destination address during the destination address read cycle.

도 3은 종래의 DMA의 채널 구성을 나타낸 블록 다이어그램이다. 원천 어드레스 레지스터(302)는 원천 어드레스(Source Address)를 저장한다. 제 1 어드레스 증가부(304)는 원천 어드레스 레지스터(302)의 값을 1씩 증가시킨다. 목적지 어드레스 레지스터(306)는 목적지 어드레스를 저장한다. 어드레스 증가부(308)는 목적지 어드레스 레지스터(306)의 값을 1씩 증가시킨다. 순차 제어기(310)는 원천 어드레스 레지스터(302)에서 출력되는 원천 어드레스와 목적지 어드레스 레지스터(306)에서 출력되는 목적지 어드레스를 어드레스 멀티플렉서(214)로 순차적으로 출력한다. 카운터 레지스터(312)는 계수 값을 저장한다. 제어 레지스터(314)는 채널 인에이블 플래그(EN)나 싱글/듀얼 모드 플래그(S/D MODE), 사이클 스틸/버스트 모드 플래그(CS/B MODE), 상태 플래그(ST) 등을 저장한다.3 is a block diagram showing a channel configuration of a conventional DMA. Source address register 302 stores a source address. The first address increasing unit 304 increases the value of the source address register 302 by one. Destination address register 306 stores the destination address. The address increasing unit 308 increments the value of the destination address register 306 by one. The sequential controller 310 sequentially outputs the source address output from the source address register 302 and the destination address output from the destination address register 306 to the address multiplexer 214. Counter register 312 stores the count value. The control register 314 stores a channel enable flag EN, a single / dual mode flag S / D MODE, a cycle still / burst mode flag CS / B MODE, a status flag ST, and the like.

도 4는 종래의 DMA의 동작을 나타낸 타이밍 다이어그램으로서, 듀얼 어드레스 모드(Dual Address Mode)에서 외부 장치에서 다른 외부 장치로 데이터를 전송하는 경우이다. 원천 어드레스 리드 사이클과 목적지 어드레스 라이트 사이클에 각각 세 개의 클럭이 할당된다. 원천 어드레스 리드 사이클 동안에 DMA가 원천 데이터를 읽기(read) 위하여 원천 어드레스를 발생시키고, 해당 장소로부터 원천 데이터를 읽어와서 DMA(116) 내부의 데이터 레지스터(204)에 저장한다. 목적지 어드레스 라이트 사이클 동안에는 데이터 레지스터(204)에 저장되어 있는 데이터를 해당 목적지 어드레스에 기록(write)한다.4 is a timing diagram illustrating the operation of a conventional DMA, in which data is transmitted from an external device to another external device in a dual address mode. Three clocks are allocated to the source address read cycle and the destination address write cycle. During the source address read cycle, the DMA generates a source address to read the source data, reads the source data from the location and stores it in the data register 204 inside the DMA 116. During the destination address write cycle, the data stored in the data register 204 is written to the corresponding destination address.

도 5는 종래의 DMA의 동작을 나타낸 타이밍 다이어그램으로서, 싱글 어드레스 모드(Single Address Mode)의 경우를 나타낸 것이다. 싱글 어드레스 모드를 필요로하는 입출력 장치는 전송 요청 신호(nREQ)를 발생시켜서 DMA(116)에 전달한다. 전송 요청 신호(nREQ)를 받은 DMA(116)는 CPU(110)로부터 버스 제어 우선권을 넘겨받아 해당 데이터를 전송한다. 이때 입출력 장치의 원천 데이터는 전송 요청 신호(nREQ)에 대한 응답 신호인 전송 허가 신호(nACK)에 동기되어 출력되며, 출력되는 데이터가 저장되는 장소 즉 목적지 어드레스는 DMA(116)에 의해 발생된다. 도 5에 나타낸 바와 같이, n번째 싱글 어드레스 DMA 사이클에서 목적지 어드레스를 발생시키고, 세 클럭 이후에 전송 허가 신호(nACK#N)를 발생시킨다. 이때 입출력 장치는 전송 허가 신호(nACK#N)의 타이밍에 맞추어 데이터를 출력하고, 출력된 데이터는 목적지 어드레스에 직접 기록된다.5 is a timing diagram showing the operation of the conventional DMA, and shows a case of a single address mode. The input / output device requiring the single address mode generates a transfer request signal nREQ and delivers it to the DMA 116. The DMA 116 receiving the transfer request signal nREQ receives the bus control priority from the CPU 110 and transmits the corresponding data. At this time, the source data of the input / output device is output in synchronization with the transmission permission signal nACK, which is a response signal to the transmission request signal nREQ, and a place where the output data is stored, that is, a destination address, is generated by the DMA 116. As shown in Fig. 5, the destination address is generated in the nth single address DMA cycle, and the transfer permission signal nACK # N is generated after three clocks. At this time, the input / output device outputs data in accordance with the timing of the transmission permission signal nACK # N, and the output data is directly written to the destination address.

이와 같은 종래의 DMA는 데이터를 전송하는 기능 이외에는 어떠한 기능도 수행하지 않는다. 따라서 CPU는 데이터의 전송이 이루어진 후에 이미 전송된 데이터를 연산을 위해 다시 인출하여 연산을 수행하고, 연산 결과를 메모리나 입출력 장치에 전송한다. 따라서 데이터 연산 시간에 데이터 전송 시간이 추가되어 전체 동작 시간이 증가하는 문제가 있다.Such a conventional DMA does not perform any function other than the function of transferring data. Therefore, after the data is transferred, the CPU fetches the already transmitted data for calculation and performs the calculation, and transmits the operation result to the memory or the input / output device. Therefore, the data transfer time is added to the data operation time, thereby increasing the overall operation time.

본 발명에 따른 DMA는 데이터 전송 사이클 동안에 데이터 연산이 이루어지도록 하여 전체 동작 시간을 단축시키는데 그 목적이 있다.The DMA according to the present invention aims to shorten the overall operation time by allowing data operation to be performed during a data transfer cycle.

이와 같은 목적의 본 발명은 직접 메모리 액세스 장치를 갖는 마이크로 콘트롤러 유닛을 포함하여 이루어진다.The present invention for this purpose comprises a microcontroller unit having a direct memory access device.

본 발명에 따른 직접 메모리 액세스 장치는 연산 기능을 가지며, 직접 메모리 액세스 장치의 데이터 전송 주기 동안에 전송되는 데이터에 대해 소정의 연산을 수행하도록 이루어진다.The direct memory access device according to the present invention has an arithmetic function, and is configured to perform a predetermined operation on data transmitted during a data transfer period of the direct memory access device.

또 상술한 직접 메모리 액세스 장치는 연산을 수행할 데이터를 저장하는 연산 레지스터(616)와, 연산을 수행하는 연산기(618), 연산의 결과를 저장하는 연산결과 레지스터(620)를 포함하여 이루어진다.The above-described direct memory access device includes an operation register 616 for storing data for performing an operation, an operator 618 for performing an operation, and an operation result register 620 for storing a result of the operation.

도 1은 DMA를 갖는 종래의 MCU의 구성을 나타낸 블록 다이어그램.1 is a block diagram showing the configuration of a conventional MCU having DMA.

도 2는 종래의 DMA의 구성을 나타낸 블록 다이어그램.2 is a block diagram showing a configuration of a conventional DMA.

도 3은 종래의 DMA의 채널 구성을 나타낸 블록 다이어그램.3 is a block diagram showing a channel configuration of a conventional DMA.

도 4와 도 5는 종래의 DMA의 동작을 나타낸 타이밍 다이어그램.4 and 5 are timing diagrams showing the operation of the conventional DMA.

도 6은 본 발명에 따른 DMA의 구성을 나타낸 블록 다이어그램.6 is a block diagram showing a configuration of a DMA according to the present invention;

도 7은 본 발명에 따른 DMA의 채널 구성을 나타낸 블록 다이어그램.7 is a block diagram showing a channel configuration of a DMA according to the present invention.

도 8과 도 9는 본 발명에 따른 연산 기능을 갖는 DMA의 동작 특성을 나타낸 타이밍 다이어그램8 and 9 are timing diagrams showing the operating characteristics of the DMA with arithmetic function according to the present invention.

*도면의 주요 부분에 대한 부호의 설명** Description of the symbols for the main parts of the drawings *

102 : MCU 104 : 외부 메모리102: MCU 104: external memory

106 : 외부 I/O 110 : CPU106: External I / O 110: CPU

112 : 내부 메모리 114 : 내부 I/O112: internal memory 114: internal I / O

116, 600 : DMA 118 : 외부버스 제어부116, 600: DMA 118: external bus control unit

120 : MCU 제어부 602 : DMA 레지스터 버스 I/F120: MCU control unit 602: DMA register bus I / F

604 : 데이터 레지스터 606 : 채널604: data register 606: channel

608 : DMA 제어 레지스터 610 : 채널 제어 레지스터608: DMA control register 610: channel control register

612 : 채널ㆍDMAㆍ연산 제어기 614 : 어드레스 멀티플렉서612: channel DMA operation controller 614: address multiplexer

616 : DMA 연산 레지스터 618 : DMA 연산기616: DMA operation register 618: DMA operator

620 : 연산 결과 레지스터 622 : 외부 버스620: operation result register 622: external bus

IM : DMA 연산 모드 플래그 704, 708 : 어드레스 증가부IM: DMA operation mode flag 704, 708: address increasing part

본 발명의 바람직한 실시예를 도 6 내지 도 9를 참조하여 설명하면 다음과 같다. 먼저 도 6은 본 발명에 따른 DMA의 구성을 나타낸 블록 다이어그램이다. DMA 레지스터 버스 인터페이스(602)는 MCU 내부 버스(622)와 DMA(600) 사이의 데이터 입출력을 위한 인터페이스이다. MCU 내부 버스(622)의 어드레스 또는 제어 값을 채널(606)이나 DMA 제어 레지스터(608), 채널 제어 레지스터(610) 등에 전달하고, 반대로 채널(606)이나 DMA 제어 레지스터(608), 채널 제어 레지스터(610)의 어드레스 또는 제어 값을 MCU 내부 버스(622)로 전달한다. 데이터 레지스터(604)는 MCU 내부 버스(622)를 통해 입력되는 데이터를 저장한다. 채널(606)은 DMA(600)의 동작 모드 또는 상태에 따라 원천 어드레스나 목적지 어드레스를 발생시킨다. DMA 제어 레지스터(608)는 START/STOP 등과 같은 DMA 제어에 필요한 제어 값들을 저장한다. 채널제어 레지스터(610)는 채널 제어에 필요한 제어 값들을 저장한다. 채널ㆍDMAㆍ연산 제어기(612)는 DMA 제어 레지스터(608)와 채널 제어 레지스터(610)의 제어 값 등을 이용하여 채널(606)과 어드레스 멀티플렉서(614) 등을 제어한다. 또 본 발명에 따른 연산 블록, 즉 DMA 연산 레지스터(616)와 DMA 연산기(618), 연산 결과 레지스터(620) 등을 제어하여 소정의 연산이 수행될 수 있도록 한다. 어드레스 멀티플렉서(614)는 각 채널(606)에서 출력되는 원천 어드레스(Source Address) 또는 목적지 어드레스(Destination Address)를 선택적으로 출력한다. DMA 연산 레지스터(616)는 DMA(600) 내부에서 연산을 수행할 데이터를 저장한다. DMA 연산기(618)는 채널ㆍDMAㆍ연산 제어기(612)에 의해 제어되며, DMA(600)를 통해 전달되는 데이터를 대상으로 필요한 연산을 수행한다. 연산결과 레지스터(620)는 DMA 연산기(620)의 연산 결과가 저장된다.Referring to the preferred embodiment of the present invention with reference to Figures 6 to 9 as follows. 6 is a block diagram showing the configuration of a DMA according to the present invention. The DMA register bus interface 602 is an interface for data input and output between the MCU internal bus 622 and the DMA 600. The address or control value of the MCU internal bus 622 is transferred to the channel 606, the DMA control register 608, the channel control register 610, and the like, and conversely, the channel 606, the DMA control register 608, and the channel control register. The address or control value of 610 is transferred to the MCU internal bus 622. The data register 604 stores data input via the MCU internal bus 622. Channel 606 generates a source address or a destination address depending on the operating mode or state of DMA 600. The DMA control register 608 stores control values necessary for DMA control such as START / STOP. The channel control register 610 stores control values necessary for channel control. The channel, DMA, and operation controller 612 controls the channel 606, the address multiplexer 614, and the like using the control values of the DMA control register 608 and the channel control register 610, and the like. In addition, the operation block according to the present invention, that is, the DMA operation register 616, the DMA operator 618, the operation result register 620 and the like are controlled so that a predetermined operation can be performed. The address multiplexer 614 selectively outputs a source address or a destination address output from each channel 606. The DMA operation register 616 stores data for performing an operation inside the DMA 600. The DMA operator 618 is controlled by the channel, DMA, and operation controller 612, and performs necessary operations on the data transferred through the DMA 600. The operation result register 620 stores the operation result of the DMA operator 620.

도 7은 본 발명에 따른 DMA의 채널 구성을 나타낸 블록 다이어그램. 원천 어드레스 레지스터(702)는 원천 어드레스(Source Address)를 저장한다. 어드레스 증가부(704)는 원천 어드레스 레지스터(702)의 값을 1씩 증가시킨다. 목적지 어드레스 레지스터(706)는 목적지 어드레스를 저장한다. 어드레스 증가부(708)는 목적지 어드레스 레지스터(706)의 값을 1씩 증가시킨다. 순차 제어기(710)는 원천 어드레스 레지스터(702)에서 출력되는 원천 어드레스와 목적지 어드레스 레지스터(706)에서 출력되는 목적지 어드레스를 어드레스 멀티플렉서(614)로 순차적으로 출력한다. 카운터 레지스터(712)는 계수 값을 저장한다. 제어 레지스터(714)는 채널 인에이블 플래그(EN)나 , DMA 연산 모드 플래그(IM), 싱글/듀얼 모드 플래그(S/D MODE), 사이클 스틸/버스트 모드 플래그(CS/B MODE), 상태 플래그(ST) 등을 저장한다.7 is a block diagram showing a channel configuration of a DMA according to the present invention. Source address register 702 stores a source address. The address increasing unit 704 increments the value of the source address register 702 by one. Destination address register 706 stores a destination address. The address increasing unit 708 increases the value of the destination address register 706 by one. The sequential controller 710 sequentially outputs the source address output from the source address register 702 and the destination address output from the destination address register 706 to the address multiplexer 614. Counter register 712 stores the count value. The control register 714 includes a channel enable flag (EN), a DMA operation mode flag (IM), a single / dual mode flag (S / D MODE), a cycle still / burst mode flag (CS / B MODE), and a status flag. (ST) and so on.

도 8은 본 발명에 따른 연산 기능을 갖는 DMA의 동작 특성을 나타낸 타이밍 다이어그램으로서, 듀얼 어드레스 모드의 경우를 나타낸 것이다. 원천 데이터를읽어오기(read) 위한 원천 어드레스 리드 사이클 동안에, DMA(600)에서 DMA 어드레스 출력단에서 원천 어드레스가 발생한 뒤 3클럭 뒤에 원천 데이터가 DMA 연산 레지스터(616)에 입력된다. DMA 연산 레지스터(616)에 저장되어 있는 데이터는 필요에 따라 다른 DMA 연산 레지스터(616)의 데이터와 DMA 연산기(618)에서 일련의 연산 과정을 거치게 된다. 이때 연산에 필요한 클럭 수에 따라서 연산 결과가 저장될 버스 사이클은 길어질 수 있다. DMA 연산기(618)의 연산 결과는 연산기 결과 레지스터(620)에 저장되고, 저장된 연산 결과는 내부 버스(622)를 통해 해당 장소에 기록(write)된다. 도 8에서 DMA 연산 입력 데이터(1)는 1 클럭 ALU(Arithmetical Logic Unit) 연산의 경우에 출력되는 연산 결과이며, DMA 연산 입력 데이터(2)는 2 클럭 ALU 연산의 경우에 출력되는 연산 결과이다.8 is a timing diagram showing the operation characteristics of the DMA having a calculation function according to the present invention, showing the case of the dual address mode. During the source address read cycle for reading the source data, the source data is input to the DMA operation register 616 three clocks after the source address is generated at the DMA address output stage in the DMA 600. The data stored in the DMA operation register 616 is subjected to a series of operations in the data of the other DMA operation register 616 and the DMA operator 618 as necessary. In this case, the bus cycle in which the calculation result is stored may be longer depending on the number of clocks required for the calculation. The operation result of the DMA operator 618 is stored in the operator result register 620, and the stored operation result is written to the corresponding place through the internal bus 622. In FIG. 8, DMA arithmetic input data 1 is an arithmetic result that is output in the case of a one-clock ALU (Arithmetical Logic Unit) operation, and DMA arithmetic input data 2 is an arithmetic result that is output in the case of a two-clock ALU operation.

도 9는 본 발명에 따른 연산 기능을 갖는 DMA의 동작 특성을 나타낸 타이밍 다이어그램으로서, 싱글 어드레스 모드의 경우를 나타낸 것이다. 입력 장치로부터 데이터 연산 요구 신호가 발생하여 DMA(600)가 연산 모드로 동작하면 DMA 연산 모드 플래그(IM)가 1이 된다. 이때 입력 장치에서는 논리 0의 전송 요청 신호(nREQ)를 발생시키고, DMA(600)는 논리 0의 전송 허가 신호(nACK)를 발생시킨다. 입력 장치는 전송 허가 신호(nACK)가 논리 0일 때 유효한 데이터를 출력한다. 입력 장치에선 출력되는 데이터는 DMA 연산 레지스터A(616)에 입력된다. 기존의 DMA의 싱글 어드레스 모드 전송 시에는 DMA가 목적지 어드레스를 즉시 발생시켜서 전송 허가 신호(nACK)가 논리 0일 때 데이터를 기록하지만, 본 발명에 따른 DMA(600)에서는 연산 과정을 거친 후에 데이터를 저장해야 하므로 전송 허가 신호(nACK)가 논리 0으로 떨어진다음 클럭에서 DMA 연산기(618)의 출력이 발생한다. 따라서 싱글 어드레스 모드로 DMA 연산을 수행하는 경우에는 기존의 DMA 싱글 어드레스 모드에서보다 1개 많은 전송 개수를 지정해주면 된다.9 is a timing diagram showing the operation characteristics of the DMA having a calculation function according to the present invention, showing the case of the single address mode. When the data operation request signal is generated from the input device and the DMA 600 operates in the operation mode, the DMA operation mode flag IM becomes 1. At this time, the input device generates a logic 0 transmission request signal nREQ, and the DMA 600 generates a logic 0 transmission permission signal nACK. The input device outputs valid data when the transmission permission signal nACK is logical zero. Data output from the input device is input to the DMA operation register A 616. In the conventional single address mode transmission of the DMA, the DMA immediately generates a destination address and records data when the transmission permission signal (nACK) is logical 0.However, in the DMA 600 according to the present invention, the data is processed after the calculation process. Because it must be stored, the transmit permission signal nACK drops to a logic zero, and the output of the DMA operator 618 occurs at the clock. Therefore, when performing a DMA operation in the single address mode, one more transfer number may be specified than in the conventional DMA single address mode.

이와 같은 본 발명에 따른 DMA는 다음과 같은 응용 분야에서 동작 시간을 단축시킬 수 있는 효과를 제공한다. 먼저, 음성 신호를 처리하기 위한 시스템에서 MCU에 연결된 외부 입력 장치인 마이크 등을 통해 음성 신호가 실시간으로 입력되면 아날로그 음성 신호가 디지털 신호로 변환된다. MCU는 변환된 데이터를 여러 가지 필터로 필터링 하여 필터링 계수를 추출한 다음 해당 장소로 필터링 계수를 전송한다. 기존의 MCU에서는 아날로그-디지털 변환기의 출력을 DMA나 CPU를 통해 받아서 메모리에 저장한 다음, 필터 계수 계산을 수행하기 위해 메모리에 저장되어 있는 데이터들을 다시 인출하여 CPU로 보내고, CPU의 연산 결과를 다시 다른 메모리에 저장한다. 그러나 본 발명에 따른 DMA의 DMA 연산기를 필터링 모드로 세팅하면 아날로그-디지털 변환기의 출력이 직접 DMA 연산기에서 필터링 된다. 따라서 연산을 수행할 데이터와 연산 결과를 반복해서 쓰고 읽을 필요가 없다. 또 통신상의 보안을 위하여 많은 데이터가 암호화되어 전송되는데, 데이터의 암호화는 시스템의 성능이 크게 저하됨을 의미한다. 데이터를 암호화하기 위해서는 암호화 알고리듬을 사용하여 데이터를 반복적으로 읽고 써야 하기 때문이다. 그러나 본 발명에 따른 연산 기능을 갖는 DMA를 암호화 모드로 세팅하면 데이터가 전송되는 과정에서 이미 암호화 알고리듬이 자동으로 처리되므로 CPU의 자원을 사용하지 않고도 필요한 연산 결과를 얻을 수 있다.Such DMA according to the present invention provides an effect that can reduce the operation time in the following applications. First, when a voice signal is input in real time through a microphone, which is an external input device connected to an MCU in a system for processing a voice signal, an analog voice signal is converted into a digital signal. The MCU filters the converted data with various filters to extract the filtering coefficients and then sends the filtering coefficients to the corresponding places. In the conventional MCU, the output of the analog-to-digital converter is received through DMA or CPU and stored in the memory. Then, the data stored in the memory is retrieved and sent back to the CPU to perform the filter coefficient calculation. Store in another memory. However, when the DMA operator of the DMA according to the present invention is set to the filtering mode, the output of the analog-to-digital converter is directly filtered by the DMA operator. Therefore, there is no need to repeatedly write and read the data to be operated on and the result of the operation. In addition, a lot of data is encrypted and transmitted for communication security, and data encryption means that the performance of the system is greatly degraded. This is because the data must be repeatedly read and written using encryption algorithms to encrypt the data. However, when the DMA having the arithmetic function according to the present invention is set to the encryption mode, the encryption algorithm is automatically processed in the process of transmitting data, so that the required calculation result can be obtained without using CPU resources.

이와 같은 본 발명에 따른 DMA는 다음과 같은 응용 분야에서 동작 시간을 단축시킬 수 있는 효과를 제공한다. 먼저, 음성 신호를 처리하기 위한 시스템에서 MCU에 연결된 외부 입력 장치인 마이크 등을 통해 음성 신호가 실시간으로 입력되면 아날로그 음성 신호가 디지털 신호로 변환된다. MCU는 변환된 데이터를 여러 가지 필터로 필터링 하여 필터링 계수를 추출한 다음 해당 장소로 필터링 계수를 전송한다. 기존의 MCU에서는 아날로그-디지털 변환기의 출력을 DMA나 CPU를 통해 받아서 메모리에 저장한 다음, 필터 계수 계산을 수행하기 위해 메모리에 저장되어 있는 데이터들을 다시 인출하여 CPU로 보내고, CPU의 연산 결과를 다시 다른 메모리에 저장한다. 그러나 본 발명에 따른 DMA의 DMA 연산기를 필터링 모드로 세팅하면 아날로그-디지털 변환기의 출력이 직접 DMA 연산기에서 필터링 된다. 따라서 연산을 수행할 데이터와 연산 결과를 반복해서 쓰고 읽을 필요가 없다. 또 통신상의 보안을 위하여 많은 데이터가 암호화되어 전송되는데, 데이터의 암호화는 시스템의 성능이 크게 저하됨을 의미한다. 데이터를 암호화하기 위해서는 암호화 알고리듬을 사용하여 데이터를 반복적으로 읽고 써야 하기 때문이다. 그러나 본 발명에 따른 연산 기능을 갖는 DMA를 암호화 모드로 세팅하면 데이터가 전송되는 과정에서 이미 암호화 알고리듬이 자동으로 처리되므로 CPU의 자원을 사용하지 않고도 필요한 연산 결과를 얻을 수 있다.Such DMA according to the present invention provides an effect that can reduce the operation time in the following applications. First, when a voice signal is input in real time through a microphone, which is an external input device connected to an MCU in a system for processing a voice signal, an analog voice signal is converted into a digital signal. The MCU filters the converted data with various filters to extract the filtering coefficients and then sends the filtering coefficients to the corresponding places. In the conventional MCU, the output of the analog-to-digital converter is received through DMA or CPU and stored in the memory. Then, the data stored in the memory is retrieved and sent back to the CPU to perform the filter coefficient calculation. Store in another memory. However, when the DMA operator of the DMA according to the present invention is set to the filtering mode, the output of the analog-to-digital converter is directly filtered by the DMA operator. Therefore, there is no need to repeatedly write and read the data to perform the operation and the operation result. In addition, a lot of data is encrypted and transmitted for communication security, and data encryption means that the performance of the system is greatly degraded. This is because the data must be repeatedly read and written using encryption algorithms to encrypt the data. However, when the DMA having the arithmetic function according to the present invention is set to the encryption mode, the encryption algorithm is automatically processed in the process of transmitting data, so that the required calculation result can be obtained without using CPU resources.

Claims (2)

직접 메모리 액세스 장치를 갖는 마이크로 콘트롤러 유닛에 있어서,A microcontroller unit having a direct memory access device, 상기 직접 메모리 액세스 장치가 연산 장치를 구비하고;The direct memory access device comprises a computing device; 상기 연산 장치가 상기 직접 메모리 액세스 장치의 데이터 전송 주기 동안에 소정의 연산을 수행하도록 이루어지는 마이크로 콘트롤러 유닛.And the computing device is adapted to perform a predetermined operation during a data transfer period of the direct memory access device. 청구항 1에 있어서, 상기 연산 장치는,The method according to claim 1, The computing device, 상기 연산을 수행할 데이터를 저장하는 연산 레지스터와;An operation register for storing data to perform the operation; 상기 연산 레지스터의 데이터를 입력받아 상기 연산을 수행하는 연산기와;An operator configured to receive data of the operation register and perform the operation; 상기 연산의 결과를 저장하는 연산결과 레지스터를 포함하여 이루어지는 마이크로 콘트롤러 유닛.And a calculation result register for storing a result of the calculation.
KR1020000011723A 2000-03-09 2000-03-09 Dma having operational function KR100356810B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020000011723A KR100356810B1 (en) 2000-03-09 2000-03-09 Dma having operational function

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020000011723A KR100356810B1 (en) 2000-03-09 2000-03-09 Dma having operational function

Publications (2)

Publication Number Publication Date
KR20010087887A true KR20010087887A (en) 2001-09-26
KR100356810B1 KR100356810B1 (en) 2002-10-18

Family

ID=19653524

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020000011723A KR100356810B1 (en) 2000-03-09 2000-03-09 Dma having operational function

Country Status (1)

Country Link
KR (1) KR100356810B1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8433829B2 (en) 2009-12-03 2013-04-30 Samsung Electronics Co., Ltd. Direct memory access controller and method of operating the same
CN103744329A (en) * 2013-12-25 2014-04-23 镇江晶鑫电子科技有限公司 High-stable anti-interference circuit system of laser head lens automatic assembly machine

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR0122440B1 (en) * 1994-12-14 1997-11-20 양승택 The audio board which voice capture and play are concurrcutly operating

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8433829B2 (en) 2009-12-03 2013-04-30 Samsung Electronics Co., Ltd. Direct memory access controller and method of operating the same
CN103744329A (en) * 2013-12-25 2014-04-23 镇江晶鑫电子科技有限公司 High-stable anti-interference circuit system of laser head lens automatic assembly machine

Also Published As

Publication number Publication date
KR100356810B1 (en) 2002-10-18

Similar Documents

Publication Publication Date Title
US20030074502A1 (en) Communication between two embedded processors
EP0874320A3 (en) High speed data input-output device which fetches data into internal memory and performs operations on the data before outputting the data
KR100356810B1 (en) Dma having operational function
EP1915696A1 (en) Dma simultaneous transfer to multiple memories
US6032204A (en) Microcontroller with a synchronous serial interface and a two-channel DMA unit configured together for providing DMA requests to the first and second DMA channel
JP2006520956A5 (en)
EP3803610B1 (en) Direct memory access controller
US11789884B2 (en) Bus system and method for operating a bus system
EP2133797B1 (en) Dma transfer device and method
EP1457859B1 (en) Data encryption/decryption device
JP4282390B2 (en) Microcomputer logic development equipment
KR100266963B1 (en) Method and apparatus for reducing latency rime on an interface by overlapping transmitted packets
JP3667556B2 (en) DMA transfer control device and DMA transfer control method
JPS6373289A (en) Cryptographer
JP3096382B2 (en) DMA circuit
JPH06348644A (en) Dma circuit
JP6631370B2 (en) Microcomputer and electronic control unit
JP3146864B2 (en) Unidirectional loop transmission circuit
JP2856709B2 (en) Bus coupling system
JP2552015B2 (en) Data transfer device
US7167997B1 (en) Apparatus and method for limiting data transmission rates
JP2588396B2 (en) Serial receiver with double buffer
KR0152296B1 (en) Data transfering apparatus and processor element using it
KR100427169B1 (en) Communication system and data transmission method thereof
JPS5939051B2 (en) data buffer circuit

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20100920

Year of fee payment: 9

LAPS Lapse due to unpaid annual fee