Control transfer, this is a very, very important USB TransFair or endpoint type, because control
TransFair, as we mentioned before, is used to configure the device to be able to work properly.
So the first type of transfers you will be doing at the very early stage when configuring or USB device
and negotiating with the host will be control transfers.
So let's go through control transfer in details.
It has a bit more information in comparison with the other transfers.
However, when you understand this correctly, it will be very easy to control.
Transfer is an unpatriotic transfer so it doesn't happen regularly.
This happens only on need control, transfer guarantees, error-free transfer.
So it has handshaking, in other words.
And control transfer is used to to transfer device enumeration and configuration packets.
And this is what we have just mentioned in the very early stage.
When you connect your USB device to the to the USB port in the host USB enumeration process will start
and the negotiation between the device and the host will happen by sending USB control transfers.
And again, we mention this officially for end point zero and point zero must be configured to be a
control end point.
So it will send and receive control transfers in both directions because.
When you connect your USB device to the USB port in the host, USB enumeration process will start and
the negotiation between the device and the host will happen on the end point zero, which must be control
end point because the host will try to request some data about our device through that endpoint zero,
or it will try to send some data to our device.
Or we can also say it will try to tell our device to change or to set some of its configuration on the
out end point zero.
And because this is configuration related information, it must happen on an control end point and its
end point zero because it's just the default control end point in every USB device and therefore USB
device enumeration happens happens always on end point zero, the maximum data payload in control transfer
is eight, 16, 32 or 64 bytes.
I haven't mentioned the unit here.
This is for full speed devices and it's 64 bytes for high speed devices.
Now we are going to talk about a very, very, very important part of control transfer.
I hope that you noticed that all other transfers we talked about so interrupt, transfer, bulk transfer
and transfer, all of them consist of a single transaction.
So one interrupt transfer consists of only one single transaction, the same for bulk transfer.
It consists only of one bulk transaction and the same for ISO Cronos.
However, control transfer consists of multiple transactions and these transactions are divided into
three stages.
So again, one single control transfer consists of multiple transactions as opposed to the other USPI
transfer types.
So control transfer consists of multiple transactions and these transactions are divided into three
stages.
The first stage of a controlled transfer is called set up stage and set up stage has one transaction.
And here, please notice to not be confused.
Here we are talking about set up stage, which has one transaction in it.
So it has three packets in it, a token packet which is set up, token packet in this case, and then
data packet and then handshake packet.
We will see these packets in details later.
So setup stage is not one packet set up stage is one transaction, which means it has three packets.
The second stage in control transfer is called data stage.
They the stage is optional, which means that the stage can have zero to multiple transactions in it.
So in more details in data stage, we do some data transmitting in the direction from the device to
the whole store.
So in the indirection or in the direction from the horse to the device or in the out direction, but
it's optional.
It depends on the control transfer we want to achieve.
We can have zero to multiple out or end data transactions in data stage.
And again, we will explain this in more detail in the next slide.
And the third USP control transfer stage is called status stage.
Status stage has only one transaction in it.
This is just as same as acknowledging or let's say signaling that a controlled transfer is now finished
and it has one transaction in it.
So let me repeat this last time a controlled transfer consists of multiple transactions, these transactions
are divided into three stages.
Stage one is the set up stage, which has one transaction in it.
Namely, it has three packets in it, the next stage is.
Data stage, it has from zero to multiple data transmitting transactions, either in the direction in
or out doesn't matter.
We have we can have zero to multiple transactions in the data stage.
And the final stage in control transfer is called status stage.
It has one transaction in it.
Hopefully, this theoretical introduction to the control transfer stages was simple.
Don't worry.
Right now, in the next slide, we will explain this in more details on three nice figures.