Everything

Usage example

Start DTC data transfer by UART0 reception. (Repeat reception of 4Bytes data and copying them to the RAM array.)

 

[GUI setting example]

Data transfer controller

Used

DTC

Used

DTCBA

DTC base address

0xffd00

Control data0 (DTCD0)

Used (Chain transfer:Unused; Activation sources:UART0 reception/CSI01/IIC01 transfer end or CSI01 buffer empty)

DTCD0

Transfer mode setting

Repeat mode

Repeat mode interrupt setting

Disable

Repeat area setting

Transfer destination

Source address

0xff12 Address fixed

Destination address

0xfb00

Count

4

Block size

1

 

Serial

Used

SAU0

Used

Channel0

Channel 0

UART0 (Receive)

Data length setting (Receive)

8 bits

Trasfer direction setting (Receive)

LSB

Parity setting (Receive)

None

Stop bit length setting (Receive)

1 bit fixed

Receive data level setting

Normal

Transfer rate setting (Receive)

9600(bps) (error:+0.16% Minimum permissible value:-5.17% Maximum permissible value:+5.16%)

Reception end interrupt priority (INTSR0)

Low

Reception end (Callback function setting)

Used

Reception error (Callback function setting)

Used

 

 

 

[API setting example]

r_main.c

/* Start user code for pragma. Do not edit comment generated here */

#pragma address (g_uart0_buf = 0x0ffb00)

/* End user code. Do not edit comment generated here */

 

/* Start user code for global. Do not edit comment generated here */

volatile uint8_t g_uart0_buf[4];

/* End user code. Do not edit comment generated here */

 

void main(void)

{

       R_MAIN_UserInit();

       /* Start user code. Do not edit comment generated here */

       /* Enable DTCD0 module operation */

       R_DTCD0_Start();

 

       /* Start the UART0 module operation */

       R_UART0_Start();

 

       while (1U)

       {

              NOP();

       }

       /* End user code. Do not edit comment generated here */

}