Data Stage Transaction:
1. The data packet to be sent to the host PC is written to the IN endpoint 0 buffer by the MCU. The MCU also
updates the data count value then clears the IN endpoint 0 NACK bit to a 0 to enable the data packet to be
sent to the host PC.
2. The host PC sends an IN token packet addressed to IN endpoint 0. After receiving the IN token, the UBM
transmits the data packet to the host PC. If the data packet is received without an error by the host PC, then
an ACK handshake is returned. The UBM then toggles the TOGGLE bit, sets the NACK bit to 1, and asserts
the endpoint interrupt.
3. The MCU services the interrupt and prepares to send the next data packet to the host PC.
4. If the NACK bit is set to 1 when the IN token packet is received, the UBM simply returns a NAK handshake
to the host PC. If the STALL bit is set to 1 when the IN token packet is received, the UBM simply returns
a STALL handshake to the host PC. If no handshake packet is received from the host PC, then the UBM
prepares to retransmit the same data packet again.
5. MCU continues to send data packets until all data has been sent to the host PC.
Status Stage Transaction:
1. For OUT endpoint 0, the MCU sets the TOGGLE bit to 1, then clears the NACK bit to a 0 to enable a data
packet to be sent by the host PC. Note that for a status stage transaction a null data packet with the DATA1
PID is sent by the host PC.
2. The host PC sends an OUT token packet and the null data packet to OUT endpoint 0. If the data packet
is received without an error the UBM updates the data count value, toggles to the TOGGLE bit, sets the
NACK bit to a 1, returns an ACK handshake to the host PC, and asserts the endpoint interrupt.
3. The MCU services the interrupt. If the status transaction completed successfully, then the MCU clears the
interrupt and clears the NACK bit.
4. If the NACK bit is set to 1 when the OUT token packet is received, the UBM simply returns a NAK handshake
to the host PC. If the STALL bit is set to 1 when the OUT token packet is received, the UBM simply returns
a STALL handshake to the host PC. If a CRC or bit stuff error occurs when the data packet is received, no
handshake is returned to the host PC.
2.2.7.2 Interrupt Transfers
The TAS1020A supports interrupt data transfers both to and from the host PC. Devices that need to send or receive
a small amount of data with a specified service period should use the interrupt transfer type. IN endpoints 1 through
7 and OUT endpoints 1 through 7 can all be configured as interrupt endpoints.
2.2.7.2.1 Interrupt Out Transaction
The steps followed for an interrupt out transaction are:
1. MCU initializes one of the OUT endpoints as an out interrupt endpoint by programming the appropriate USB
endpoint configuration block. This entails programming the buffer size and buffer base address, selecting
the buffer mode, enabling the endpoint interrupt, initializing the toggle bit, enabling the endpoint, and
clearing the NACK bit.
2. The host PC sends an OUT token packet followed by a data packet addressed to the OUT endpoint. If the
data is received without an error then the UBM writes the data to the endpoint buffer, updates the data count
value, toggles the toggle bit, sets the NACK bit to a 1, returns an ACK handshake to the host PC, and asserts
the endpoint interrupt.
3. The MCU services the interrupt and reads the data packet from the buffer. To read the data packet, the MCU
must first obtain the data count value. After reading the data packet, the MCU clears the interrupt and clears
the NACK bit to allow the reception of the next data packet from the host PC.
2鈥?6