
Rev.1.00 May 22 2012
REJ09B0566
4.2.9 40BSerial Communication Interface
Remarks (2/2) • If callback function func1 is specified, callback functions are executed by the interrupt processing
function. This means that no other interrupt can be processed until a callback function has completed.
Program example
/* PDL functions */
#include “r_pdl_sci.h”
/* PDL device-specific definitions */
#include “r_pdl_definitions.h”
volatile uint8_t gSCI1ReceiveBuffer[10];
/* SCI channel 1 receive data handler */
void SCI1RxFunc(void){}
/* SCI channel 1 error handler */
void SCI1ErrFunc(uint8_t error_flags){}
/* SCI channel 1 break signal handler */
void SCI1BreakFunc(void){}
void func( void )
{
uint8_t temp;
/* Put a Null character at the end of the string */
gSCI1ReceiveBuffer[10] = NULL;
R_SCI_Receive(
0,
0,
&c_ gSCI1ReceiveBuffer,
8,
SCI1RxFunc,
SCI1ErrFunc,
SCI1BreakFunc
);
}
Kommentare zu diesen Handbüchern