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