Starts SCI reception (asynchronous mode).
Remark 1. This API function repeats SCI reception in byte units the number of times specified by the argument rx_num and then stores the received data in the buffer at the location specified by the argument rx_buf.
Remark 2. When performing a SCI reception, R_SCIn_Start must be called before this API function is called.
[Syntax]
#include "r_cg_macrodriver.h"
MD_STATUS R_SCIn_Serial_Receive ( uint8_t * const rx_buf, uint16_t rx_num );
Remark n is the channel number.
[Argument(s)]
I/O |
Argument |
Description |
O |
uint8_t * const rx_buf; |
Pointer to a buffer to store the reception data |
I |
uint16_t rx_num; |
Total amount of data to receive |
[Return value]
Macro |
Description |
MD_OK |
Normal completion |
MD_ARGERROR |
Invalid argument rx_num specification |