pub trait Endpoint {
    fn address(&self) -> u8;
    fn endpoint_num(&self) -> u8;
    fn transfer_type(&self) -> TransferType;
    fn direction(&self) -> Direction;
    fn max_packet_size(&self) -> u16;
    fn in_toggle(&self) -> bool;
    fn set_in_toggle(&mut self, toggle: bool);
    fn out_toggle(&self) -> bool;
    fn set_out_toggle(&mut self, toggle: bool);
}
Expand description

Endpoint defines the USB endpoint for various transfers.

Required Methods

Address of the device owning this endpoint. Must be between 0 and 127.

Endpoint number, irrespective of direction. (e.g., for both endpoint addresses, 0x81 and 0x01, this function would return 0x01).

The type of transfer this endpoint uses.

The direction of transfer this endpoint accepts.

The maximum packet size for this endpoint.

The data toggle sequence bit for the next transfer from the device to the host.

The USBHost will, when required, update the data toggle sequence bit for the next device to host transfer.

The data toggle sequence bit for the next transfer from the host to the device.

The USBHost will, when required, update the data toggle sequence bit for the next host to device transfer.

Implementors