Renesas M16C Series User Manual page 200

16-bit single-chip microcomputer
Hide thumbs Also See for M16C Series:
Table of Contents

Advertisement

M30245 Group
(4) Interrupt Transfer: Endpoints 1 to 4 Receive
Setting of Transfer Type
When endpoints 1 to 4 OUT are used for interrupt transfer, ISO bit of USB endpoint x(x=1 to 4) OUT
control and status register is set to "0" for interrupt transfer setting.
Also, for initialization of toggle sequence bit in interrupt transfer, set TOGGLE_INIT bit to "1" and
initialize PID to DATA0.
Receive Operation
The endpoint x OUT receive operation in the interrupt transfer is same as the bulk transfer.
www.DataSheet4U.com
Refer to "
Fetch of Receive Data
The fetch procedure of endpoint x OUT receive data in the interrupt transfer is same as the bulk
transfer.
Refer to "
continuous transfer is valid for the bulk transfer only.)
(5) Precautions for Receive
Read from OUT FIFO
Be sure to confirm the OUT_BUF_STS1 and OUT_BUF_STS0 flags states when reading data from
the OUT FIFO. Based on these flags states, judge whether there are receive data in the OUT FIFO.
Be sure to read the byte count of data specified by USB endpoint x OUT write count register value
before setting CLR_OUT_BUF_RDYbitto "1" when reading data from the OUT FIFO. If the
CLR_OUT_BUF_RDY bit is set to "1" during fetching of data from the OUT FIFO, the setting can
cause malfunction of the internal read pointer.
Table 2.8.3. Status on Endpoint 1 to 4 OUT FIFOs
OUT_BUF_STS1
0
0
1
1
*1: Bits 6 to 9 of EPxOFC.
PID Initialization
When TOGGLE_INIT bit is set to "1", the read/write counter inside the FIFO is initialized. To initialize
the PID, set TOGGLE_INIT bit to "1" when the OUT FIFO is empty (the OUT_BUF_STS0 and
OUT_BUF_STS1 flags are "00
Rev.2.00 Oct 16, 2006
REJ09B0340-0200
Receive Operation" of "(2) Bulk Transfer: Endpoints 1 to 4 Receive".
Fetch of Receive Data" of "(2) Bulk Transfer: Endpoints 1 to 4 Receive". (Although
OUT_BUF_STS0
[Specify OUT FIFO size
by the BUF_SIZ
0
No data
Space equal to one buffer
1
Invalid
0
Invalid
1
One data set in the OUT FIFO
No space in the OUT FIFO
").
2
page 191 of 354
Single buffer
*1
]
2. USB function
Double buffer [OUT FIFO size =
(The number of bytes specified
by the BUF_SIZ
*1
)
2]
No data
Space equal to two buffer
Invalid
One data set in the OUT FIFO
Space equal to one buffer
Two data set in the OUT FIFO
No space in the OUT FIFO

Advertisement

Table of Contents
loading

Table of Contents