[][src]Enum esp_idf_bindgen::pbuf_type

#[repr(u32)]pub enum pbuf_type {
    PBUF_RAM,
    PBUF_ROM,
    PBUF_REF,
    PBUF_POOL,
}

@ingroup pbuf Enumeration of pbuf types

Variants

PBUF_RAM

pbuf data is stored in RAM, used for TX mostly, struct pbuf and its payload are allocated in one piece of contiguous memory (so the first payload byte can be calculated from struct pbuf). pbuf_alloc() allocates PBUF_RAM pbufs as unchained pbufs (although that might change in future versions). This should be used for all OUTGOING packets (TX).

PBUF_ROM

pbuf data is stored in ROM, i.e. struct pbuf and its payload are located in totally different memory areas. Since it points to ROM, payload does not have to be copied when queued for transmission.

PBUF_REF

pbuf comes from the pbuf pool. Much like PBUF_ROM but payload might change so it has to be duplicated when queued before transmitting, depending on who has a 'ref' to it.

PBUF_POOL

pbuf payload refers to RAM. This one comes from a pool and should be used for RX. Payload can be chained (scatter-gather RX) but like PBUF_RAM, struct pbuf and its payload are allocated in one piece of contiguous memory (so the first payload byte can be calculated from struct pbuf). Don't use this for TX, if the pool becomes empty e.g. because of TCP queuing, you are unable to receive TCP acks!

Trait Implementations

impl Clone for pbuf_type[src]

impl Copy for pbuf_type[src]

impl Debug for pbuf_type[src]

impl Eq for pbuf_type[src]

impl Hash for pbuf_type[src]

impl PartialEq<pbuf_type> for pbuf_type[src]

impl StructuralEq for pbuf_type[src]

impl StructuralPartialEq for pbuf_type[src]

Auto Trait Implementations

impl Send for pbuf_type

impl Sync for pbuf_type

impl Unpin for pbuf_type

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.