1、功能说明

    此例程提供了一种MDMA Mem-to-Mem模式基于地址自动重载的多块传输的用法。

    首先定义一个数组srcBuffer，再配置MDMA，通道0，用于将数据传输数组dstBuffer中（分4个块传输）；

    开启MDMA的传输完成中断，用于指示传输已完成；

    开启块传输完成中断，用于指示每个块传输已完成；

    等待数据传输完成，并按每个块逐一比较dstBuffer中的数据与srcBuffer中的数据是否一致，如一致，打印“MDMA Auto-Reloaded Multi-Block Transfer passed.”，反之，打印“MDMA Auto-Reloaded Multi-Block Transfer failed.”。


2、使用环境

    软件环境：
        KEIL MDK-ARM 5.34.0
        IAR EWARM 8.50.1
    
    芯片支持：
        N32H730  
        N32H735   
        N32H735EC
        N32H760
        N32H762
        N32H765
        N32H765EC
        N32H785
        N32H785EC
        N32H787


3、使用说明
    
    1、时钟源：HSI+PLL

    2、系统时钟：
        M7核：600MHz

    3、MDMA通道：MDMA_CH0
    
    4、USART1配置：
        TX  -->  PA9            AF_PP
        波特率：115200
        数据位：8bit
        停止位：1bit
        无校验

    5、使用方法：
        a，编译下载代码复位运行
        b，通过串口调试助手查看打印信息，验证结果

4、注意事项
    无。
    


1. Function description

    This demo provides a use of the MDMA Mem-to-Mem mode based on address automatic reloading of multi-block transfer.

    Firstly, a array srcBuffer was defined. Then, MDMA and channel 0 were configured to transfer the data to the array dstBuffer (transfer in 4 blocks).

    Enable the MDMA transfer completion interrupt to indicate that the transfer has been completed.

    Enable block transfer completion interrupt to indicate that each block transfer has completed;

    Wait for the data transfer to complete, and compare the data in the dstBuffer with the data in the srcBuffer one by one by block. If it is, print "MDMA Auto-Reloaded Multi-Block Transfer passed." Otherwise, print "MDMA Auto-Reloaded Multi-Block Transfer failed."

    
2. Development environment

    Software environment:
        KEIL MDK-ARM 5.34.0
        IAR EWARM 8.50.1
    
    Supported chips:
        N32H730  
        N32H735   
        N32H735EC
        N32H760
        N32H762
        N32H765
        N32H765EC
        N32H785
        N32H785EC
        N32H787

3. How to use

    1. Clock source: HSI+PLL

    2. System clock:
        M7 core: 600MHz

    3. MDMA channel: MDMA_CH0

    4. USART1 configuration:
        TX --> PA9	AF_PP
        Baud rate: 115200
        Data bit: 8 bits
        Stop bit: 1bit
        No check

    5. Usage:
        a. Compile download code reset run
        b. Check the printed information and verify the results through the serial debugging assistant

4. Attention
    None.

