pub struct SerialConfig { /* private fields */ }Available on crate feature
direct-serial only.Expand description
Implementations§
Source§impl SerialConfig
impl SerialConfig
Sourcepub fn new(port_name: String, baud_rate: u32) -> Self
Available on crate feature std only.
pub fn new(port_name: String, baud_rate: u32) -> Self
std only.Creates a serial connection address with port name and baud rate.
Sourcepub fn with_read_buffer_capacity(self, capacity: usize) -> Self
Available on crate feature std only.
pub fn with_read_buffer_capacity(self, capacity: usize) -> Self
std only.Updates the read buffer capacity.
Sourcepub fn buffer_capacity(&self) -> usize
Available on crate feature std only.
pub fn buffer_capacity(&self) -> usize
std only.Returns the configured read buffer capacity.
Trait Implementations§
Source§impl Clone for SerialConfig
Available on crate feature std only.
impl Clone for SerialConfig
Available on crate feature
std only.Source§fn clone(&self) -> SerialConfig
fn clone(&self) -> SerialConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Connectable for SerialConfig
Available on crate feature std only.
impl Connectable for SerialConfig
Available on crate feature
std only.Source§impl Debug for SerialConfig
Available on crate feature std only.
impl Debug for SerialConfig
Available on crate feature
std only.Source§impl Display for SerialConfig
Available on crate feature std only.
impl Display for SerialConfig
Available on crate feature
std only.Source§impl From<SerialConfig> for ConnectionAddress
Available on crate features std or tokio-1 only.
impl From<SerialConfig> for ConnectionAddress
Available on crate features
std or tokio-1 only.Source§fn from(value: SerialConfig) -> Self
fn from(value: SerialConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SerialConfig
impl RefUnwindSafe for SerialConfig
impl Send for SerialConfig
impl Sync for SerialConfig
impl Unpin for SerialConfig
impl UnwindSafe for SerialConfig
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