#[repr(u8)]pub enum STATTXR {
Disabled = 0,
Stall = 1,
Nak = 2,
Valid = 3,
}
Expand description
Status bits, for transmission transfers Device mode These bits contain the information about the endpoint status, listed in . These bits can be toggled by the software to initialize their value. When the application software writes ’0, the value remains unchanged, while writing ’1 makes the bit value toggle. Hardware sets the STTX bits to NAK, when a correct transfer has occurred (VTTX=1) corresponding to a IN or SETUP (control only) transaction addressed to this channel/endpoint. It then waits for the software to prepare the next set of data to be transmitted. Double-buffered bulk endpoints implement a special transaction flow control, which controls the status based on buffer availability condition (Refer to endpoints). If the endpoint is defined as Isochronous, its status can only be ‘VALID’ or ‘DISABLED’. Therefore, the hardware cannot change the status of the channel/endpoint/channel after a successful transaction. If the software sets the STTX bits to ‘STALL’ or ‘NAK’ for an Isochronous channel/endpoint, the USB peripheral behavior is not defined. These bits are read/write but they can be only toggled by writing ’1. Host mode Same as STRX behaviour but for IN transactions (TBC)
Value on reset: 0
Variants§
Disabled = 0
0: All transmission requests addressed to this endpoint/channel are ignored.
Stall = 1
1: Device mode: the endpoint is stalled and all transmission requests result in a STALL handshake. Host mode: this indicates that the device has STALLed the channel.
Nak = 2
2: Device mode: the endpoint is NAKed and all transmission requests result in a NAK handshake. Host mode: this indicates that the device has NAKed the transmission request.
Valid = 3
3: This endpoint/channel is enabled for transmission.