Trait autd3_driver::link::Link
source · pub trait Link: Send + Sync {
// Required methods
fn close<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<(), AUTDInternalError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn send<'life0, 'life1, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn receive<'life0, 'life1, 'async_trait>(
&'life0 mut self,
rx: &'life1 mut [RxMessage]
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn is_open(&self) -> bool;
fn timeout(&self) -> Duration;
// Provided methods
fn send_receive<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram,
rx: &'life2 mut [RxMessage],
timeout: Option<Duration>
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
fn wait_msg_processed<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram,
rx: &'life2 mut [RxMessage],
timeout: Duration
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait { ... }
}Expand description
Link is a interface to the AUTD device
Required Methods§
sourcefn close<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<(), AUTDInternalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn close<'life0, 'async_trait>( &'life0 mut self ) -> Pin<Box<dyn Future<Output = Result<(), AUTDInternalError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
Close link
sourcefn send<'life0, 'life1, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn send<'life0, 'life1, 'async_trait>( &'life0 mut self, tx: &'life1 TxDatagram ) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,
Send data to devices
Provided Methods§
sourcefn send_receive<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram,
rx: &'life2 mut [RxMessage],
timeout: Option<Duration>
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn send_receive<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, tx: &'life1 TxDatagram, rx: &'life2 mut [RxMessage], timeout: Option<Duration> ) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,
Send and receive data
sourcefn wait_msg_processed<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
tx: &'life1 TxDatagram,
rx: &'life2 mut [RxMessage],
timeout: Duration
) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn wait_msg_processed<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, tx: &'life1 TxDatagram, rx: &'life2 mut [RxMessage], timeout: Duration ) -> Pin<Box<dyn Future<Output = Result<bool, AUTDInternalError>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,
Wait until message is processed