pub struct WakingPipeDev {
pub pipe: WakingPipe,
pub medium: Medium,
pub mtu: usize,
}Expand description
Wrapper around WakingPipe to implement smoltcp::phy::Device.
Like netcore::PipeDev except that it implements
AsyncWakeDevice.
Fields§
§pipe: WakingPipeEnd of a pipe that will be directly connected to the netstack, receiving packets to be sent and supplying packets to be received.
medium: MediumThe type of network frame the pipe will carry.
For our purposes, this will typically be Medium::Ip.
mtu: usizeThe maximum packet size to be transmitted through the pipe.
The implementation does not check or limit the actual size of packets flowing
through it, this field is just informational for
smoltcp::phy::Device::capabilities.
Trait Implementations§
Source§impl AsyncWakeDevice for WakingPipeDev
impl AsyncWakeDevice for WakingPipeDev
Source§impl Device for WakingPipeDev
impl Device for WakingPipeDev
type RxToken<'a> = RxToken where Self: 'a
type TxToken<'a> = WakingPipeSender where Self: 'a
Source§fn receive(
&mut self,
timestamp: Instant,
) -> Option<(Self::RxToken<'_>, Self::TxToken<'_>)>
fn receive( &mut self, timestamp: Instant, ) -> Option<(Self::RxToken<'_>, Self::TxToken<'_>)>
Construct a token pair consisting of one receive token and one transmit token. Read more
Source§fn transmit(&mut self, _timestamp: Instant) -> Option<Self::TxToken<'_>>
fn transmit(&mut self, _timestamp: Instant) -> Option<Self::TxToken<'_>>
Construct a transmit token. Read more
Source§fn capabilities(&self) -> DeviceCapabilities
fn capabilities(&self) -> DeviceCapabilities
Get a description of device capabilities.
Auto Trait Implementations§
impl !Freeze for WakingPipeDev
impl !RefUnwindSafe for WakingPipeDev
impl !UnwindSafe for WakingPipeDev
impl Send for WakingPipeDev
impl Sync for WakingPipeDev
impl Unpin for WakingPipeDev
impl UnsafeUnpin for WakingPipeDev
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more