23.04.2013 Views

TMPM330 - Keil

TMPM330 - Keil

TMPM330 - Keil

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

9.3.6 Receive FIFO Buffer<br />

Under development<br />

<strong>TMPM330</strong> (rev 0.4) 9-16<br />

<strong>TMPM330</strong><br />

In addition to the double buffer function already described, data may be stored using the<br />

receive FIFO buffer. By setting of the SC0FCNF register and of the<br />

SC0MOD1 register, the 4-byte receive buffer can be enabled. Also, in the UART mode or<br />

I/O interface mode, data may be stored up to a predefined fill level. When the receive FIFO<br />

buffer is to be used, be sure to enable the double buffer function.<br />

If data with parity bit is to be received in the UART mode, parity check must be performed<br />

each time a data frame is received.<br />

9.3.7 Receive FIFO Operation<br />

I/O interface mode with SCLK output:<br />

The following example describes the case a 4-byte data stream is received in the half duplex<br />

mode:<br />

SC0RFC=01: Clears receive FIFO and sets the condition of interrupt generation.<br />

SC0RFC=00: Sets the interrupt to be generated at fill level 4.<br />

SC0FCNF =10111: Automatically inhibits continued reception after reaching the fill level.<br />

The number of bytes to be used in the receive FIFO is the same as the interrupt generation fill<br />

level.<br />

In this condition, 4-byte data reception may be initiated by setting the half duplex transmission<br />

mode and writing “1” to the RXE bit. After receiving 4 bytes, the RXE bit is automatically<br />

cleared and the receive operation is stopped (SCLK is stopped).<br />

Receive buffer 1<br />

Receive buffer 2<br />

RX FIFO<br />

RBFLL<br />

Receive interrupt<br />

RXE<br />

1 byte<br />

2 byte<br />

1 byte<br />

1 byte<br />

3 byte<br />

2 byte<br />

Fig. 9-3 Receive FIFO Operation<br />

4 byte<br />

3 byte<br />

2 byte 3 byte<br />

1 byte 2 byte<br />

1 byte<br />

4 byte<br />

4 byte<br />

3 byte<br />

2 byte<br />

1 byte<br />

Serial Channel (SIO)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!