Bit Stuffing And Nrzi Coding; Bulk Transactions - Samsung S3C2500B User Manual

Table of Contents

Advertisement

S3C2500B
8 bits
PID
8 bits
PID
8 bits
PID
8 bits
PID

10.3.4 BIT STUFFING AND NRZI CODING

The USB employs NRZI data encoding when transmitting packets. In NRZI encoding, a "1" is represented by no
change in level and a "0" is represented by a change in level. The high level represents the J state on the data
lines in NRZI encoding and J state means that D+ is 5V and D- is 0V. A string of zeros causes the NRZI data to
toggle each bit time. A string of ones causes long periods with no transitions in the data.
In order to ensure adequate signal transitions, the transmitting device employs bit stuffing when sending a packet
on USB. A zero is inserted after every six consecutive ones in the data stream before the data is NRZI encoded,
to force a transition in the NRZI data stream. This gives the receiver logic a data transition at least once every
seven bit times to guarantee the data and clock lock. Bit stuffing is enabled beginning with the Sync Pattern and
throughout the entire transmission. The data "one" that ends the Sync Pattern is counted as the first one in a
sequence. Bit stuffing by the transmitter is always enforced, without exception. If required by the bit stuffing rules,
a zero bit will be inserted even if it is the last bit before the end-of-packet (EOP) signal.

10.3.5 BULK TRANSACTIONS

The bulk transfer type is designed to support devices that need to communicate relatively large amounts of data
at highly variable times where the transfer can use any available bandwidth. Requesting a pipe with a bulk
transfer type provides the requester with the following:
— Access to the USB on a bandwidth-available basis
— Retry of transfers, in the case of occasional delivery failure due to errors on the bus
— Guaranteed delivery of data, but no guarantee of bandwidth or latency.
Bulk transfers occur only on a bandwidth-available basis. For a USB with large amounts of free bandwidth, bulk
transfers may happen relatively quickly; for a USB with little bandwidth available, bulk transfers may trickle out
over a relatively long period of time.
A bulk pipe is a stream pipe and, therefore, always has communication flowing either into or out of the host for a
given pipe. If a device requires bi-directional bulk communication flow, two bulk pipes must be used, one in each
direction.
7 bits
4 bits
ADDR
ENDP
0-1023 bytes
DATA
Handshake/Low Speed Preamble
11 bits
Frame Number
CRC5
Figure 10-3. USB Frame Format
5 bits
CRC5
Token (In/Out)
16 bits
CRC16
5 bits
Start of Frame
USB CONTROLLER
Data (Toggle)
10-5

Advertisement

Table of Contents
loading

Table of Contents