Struct ublox_short_range::UbloxClient [−][src]
Implementations
impl<C, N, L> UbloxClient<C, N, L> where
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
pub fn new(client: C, socket_set: &'static mut SocketSet<N, L>) -> Self
[src]
pub fn init(&self) -> Result<(), Error>
[src]
pub fn spin(&self) -> Result<(), Error>
[src]
Not implemented Not in use Not implemented
pub fn send_at<A>(&self, cmd: A) -> Result<A::Response, Error> where
A: AtatCmd,
<A as AtatCmd>::CommandLen: Add<EdmAtCmdOverhead>,
<<A as AtatCmd>::CommandLen as Add<EdmAtCmdOverhead>>::Output: ArrayLength<u8>,
[src]
A: AtatCmd,
<A as AtatCmd>::CommandLen: Add<EdmAtCmdOverhead>,
<<A as AtatCmd>::CommandLen as Add<EdmAtCmdOverhead>>::Output: ArrayLength<u8>,
Send AT command Automaticaly waraps commands in EDM context
Trait Implementations
impl<C, N, L> Dns for UbloxClient<C, N, L> where
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
type Error = Error
The type returned when we have an error
fn gethostbyaddr(&self, _ip_addr: IpAddr) -> Result<String<U256>, Self::Error>
[src]
fn gethostbyname(
&self,
hostname: &str,
_addr_type: AddrType
) -> Result<IpAddr, Self::Error>
[src]
&self,
hostname: &str,
_addr_type: AddrType
) -> Result<IpAddr, Self::Error>
impl<C, N, L> TLS for UbloxClient<C, N, L> where
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
fn import_certificate(
&mut self,
name: &str,
certificate: &[u8]
) -> Result<(), Error>
[src]
&mut self,
name: &str,
certificate: &[u8]
) -> Result<(), Error>
Importing credentials enabeles their use for all further TCP connections
fn import_root_ca(&mut self, name: &str, root_ca: &[u8]) -> Result<(), Error>
[src]
Importing credentials enabeles their use for all further TCP connections
fn import_private_key(
&mut self,
name: &str,
private_key: &[u8],
password: Option<&str>
) -> Result<(), Error>
[src]
&mut self,
name: &str,
private_key: &[u8],
password: Option<&str>
) -> Result<(), Error>
Importing credentials enabeles their use for all further TCP connections
fn enable_tls(
&self,
_socket: SocketHandle,
_ca_cert_name: Option<&str>,
_client_cert_name: Option<&str>,
_priv_key_name: Option<&str>
) -> Result<(), Error>
[src]
&self,
_socket: SocketHandle,
_ca_cert_name: Option<&str>,
_client_cert_name: Option<&str>,
_priv_key_name: Option<&str>
) -> Result<(), Error>
impl<C, N, L> TcpClient for UbloxClient<C, N, L> where
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
type Error = Error
The type returned when we have an error
type TcpSocket = SocketHandle
The type returned when we create a new TCP socket
fn socket(&self) -> Result<Self::TcpSocket, Self::Error>
[src]
Open a new TCP socket to the given address and port. The socket starts in the unconnected state.
fn connect(
&self,
socket: &mut Self::TcpSocket,
remote: SocketAddr
) -> Result<(), Self::Error>
[src]
&self,
socket: &mut Self::TcpSocket,
remote: SocketAddr
) -> Result<(), Self::Error>
Connect to the given remote host and port.
fn is_connected(&self, socket: &Self::TcpSocket) -> Result<bool, Self::Error>
[src]
Check if this socket is still connected
fn send(
&self,
socket: &mut Self::TcpSocket,
buffer: &[u8]
) -> Result<usize, Self::Error>
[src]
&self,
socket: &mut Self::TcpSocket,
buffer: &[u8]
) -> Result<usize, Self::Error>
Write to the stream. Returns the number of bytes written is returned
(which may be less than buffer.len()
), or an error.
fn receive(
&self,
socket: &mut Self::TcpSocket,
buffer: &mut [u8]
) -> Result<usize, Self::Error>
[src]
&self,
socket: &mut Self::TcpSocket,
buffer: &mut [u8]
) -> Result<usize, Self::Error>
fn close(&self, socket: Self::TcpSocket) -> Result<(), Self::Error>
[src]
Close an existing TCP socket.
impl<C, N, L> UdpClient for UbloxClient<C, N, L> where
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
C: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
type Error = Error
The type returned when we have an error
type UdpSocket = SocketHandle
The type returned when we create a new UDP socket
fn socket(&self) -> Result<Self::UdpSocket, Self::Error>
[src]
fn connect(
&self,
socket: &mut Self::UdpSocket,
remote: SocketAddr
) -> Result<(), Self::Error>
[src]
&self,
socket: &mut Self::UdpSocket,
remote: SocketAddr
) -> Result<(), Self::Error>
Connect a UDP socket with a peer using a dynamically selected port. Selects a port number automatically and initializes for read/writing.
fn send(
&self,
socket: &mut Self::UdpSocket,
buffer: &[u8]
) -> Result<(), Self::Error>
[src]
&self,
socket: &mut Self::UdpSocket,
buffer: &[u8]
) -> Result<(), Self::Error>
Send a datagram to the remote host.
fn receive(
&self,
socket: &mut Self::UdpSocket,
buffer: &mut [u8]
) -> Result<(usize, SocketAddr), Self::Error>
[src]
&self,
socket: &mut Self::UdpSocket,
buffer: &mut [u8]
) -> Result<(usize, SocketAddr), Self::Error>
Read a datagram the remote host has sent to us. Returns Ok(n)
, which
means a datagram of size n
has been received and it has been placed
in &buffer[0..n]
, or an error.
fn close(&self, socket: Self::UdpSocket) -> Result<(), Self::Error>
[src]
Close an existing UDP socket.
impl<T, N, L> WifiConnectivity for UbloxClient<T, N, L> where
T: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
T: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
fn connect(&self, options: ConnectionOptions) -> Result<(), WifiConnectionError>
[src]
Attempts to connect to a wireless network with the given connection options.
fn scan(&self) -> Result<Vec<WifiNetwork, U32>, WifiError>
[src]
fn is_connected(&self) -> bool
[src]
fn disconnect(&self) -> Result<(), WifiConnectionError>
[src]
impl<T, N, L> WifiHotspot for UbloxClient<T, N, L> where
T: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
[src]
T: AtatClient,
N: ArrayLength<Option<SocketSetItem<L>>>,
L: ArrayLength<u8>,
fn create_hotspot(
self,
options: ConnectionOptions,
configuration: HotspotOptions
) -> Result<(), WifiHotspotError>
[src]
self,
options: ConnectionOptions,
configuration: HotspotOptions
) -> Result<(), WifiHotspotError>
Creates wireless hotspot service for host machine.
fn stop_hotspot(&mut self) -> Result<bool, WifiHotspotError>
[src]
Stop serving a wireless network.
NOTE: All users connected will automatically be disconnected.
Auto Trait Implementations
impl<C, N, L> Send for UbloxClient<C, N, L> where
C: Send,
C: Send,
impl<C, N, L> !Sync for UbloxClient<C, N, L>
impl<C, N, L> Unpin for UbloxClient<C, N, L> where
C: Unpin,
C: Unpin,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,