pub struct Uhd { /* private fields */ }Expand description
Native Rust USRP B2xx RX device. Clones share hardware and configuration.
Implementations§
Source§impl Uhd
impl Uhd
Sourcepub fn probe(args: &Args) -> Result<Vec<Args>, Error>
pub fn probe(args: &Args) -> Result<Vec<Args>, Error>
Discover B2xx devices. index takes precedence over a string serial.
Supports channel-zero RX on B200, B210, B200mini, and B205mini.
Trait Implementations§
Source§impl AgcControl for Uhd
impl AgcControl for Uhd
Source§impl AntennaControl for Uhd
impl AntennaControl for Uhd
Source§impl BandwidthControl for Uhd
impl BandwidthControl for Uhd
Source§impl DcOffsetControl for Uhd
impl DcOffsetControl for Uhd
Source§fn dc_offset_available(
&self,
direction: Direction,
channel: usize,
) -> Result<bool, Error>
fn dc_offset_available( &self, direction: Direction, channel: usize, ) -> Result<bool, Error>
Return whether automatic DC offset correction is available.
Source§impl DeviceInfo for Uhd
impl DeviceInfo for Uhd
Source§impl DynDeviceBackend for Uhd
impl DynDeviceBackend for Uhd
Source§fn rx_device(&self) -> Option<&dyn DynRxDevice>
fn rx_device(&self) -> Option<&dyn DynRxDevice>
Return RX streaming capability, if the backend exposes it.
Source§fn antenna_control(&self) -> Option<&dyn AntennaControl>
fn antenna_control(&self) -> Option<&dyn AntennaControl>
Return antenna control capability, if the backend exposes it.
Source§fn agc_control(&self) -> Option<&dyn AgcControl>
fn agc_control(&self) -> Option<&dyn AgcControl>
Return automatic gain control capability, if the backend exposes it.
Source§fn gain_control(&self) -> Option<&dyn GainControl>
fn gain_control(&self) -> Option<&dyn GainControl>
Return gain control capability, if the backend exposes it.
Source§fn frequency_control(&self) -> Option<&dyn FrequencyControl>
fn frequency_control(&self) -> Option<&dyn FrequencyControl>
Return frequency control capability, if the backend exposes it.
Source§fn sample_rate_control(&self) -> Option<&dyn SampleRateControl>
fn sample_rate_control(&self) -> Option<&dyn SampleRateControl>
Return sample-rate control capability, if the backend exposes it.
Source§fn bandwidth_control(&self) -> Option<&dyn BandwidthControl>
fn bandwidth_control(&self) -> Option<&dyn BandwidthControl>
Return bandwidth control capability, if the backend exposes it.
Source§fn dc_offset_control(&self) -> Option<&dyn DcOffsetControl>
fn dc_offset_control(&self) -> Option<&dyn DcOffsetControl>
Return DC offset control capability, if the backend exposes it.
Source§fn tx_device(&self) -> Option<&dyn DynTxDevice>
fn tx_device(&self) -> Option<&dyn DynTxDevice>
Return TX streaming capability, if the backend exposes it.
Source§impl FrequencyControl for Uhd
impl FrequencyControl for Uhd
Source§fn frequency_range(
&self,
direction: Direction,
channel: usize,
) -> Result<Range, Error>
fn frequency_range( &self, direction: Direction, channel: usize, ) -> Result<Range, Error>
Return supported overall tuning range in Hz.
Source§fn frequency(&self, direction: Direction, channel: usize) -> Result<f64, Error>
fn frequency(&self, direction: Direction, channel: usize) -> Result<f64, Error>
Return current overall channel frequency in Hz.
Source§fn set_frequency(
&self,
direction: Direction,
channel: usize,
frequency: f64,
args: Args,
) -> Result<(), Error>
fn set_frequency( &self, direction: Direction, channel: usize, frequency: f64, args: Args, ) -> Result<(), Error>
Set overall channel frequency in Hz with optional driver arguments.
Source§fn frequency_components(
&self,
direction: Direction,
channel: usize,
) -> Result<Vec<String>, Error>
fn frequency_components( &self, direction: Direction, channel: usize, ) -> Result<Vec<String>, Error>
Return named frequency components for the channel.
Source§fn component_frequency_range(
&self,
direction: Direction,
channel: usize,
name: &str,
) -> Result<Range, Error>
fn component_frequency_range( &self, direction: Direction, channel: usize, name: &str, ) -> Result<Range, Error>
Return supported range in Hz for a named frequency component.
Source§impl GainControl for Uhd
impl GainControl for Uhd
Source§fn gain_elements(
&self,
direction: Direction,
channel: usize,
) -> Result<Vec<String>, Error>
fn gain_elements( &self, direction: Direction, channel: usize, ) -> Result<Vec<String>, Error>
Return named gain elements available for the channel.
Source§fn gain_range(
&self,
direction: Direction,
channel: usize,
) -> Result<Range, Error>
fn gain_range( &self, direction: Direction, channel: usize, ) -> Result<Range, Error>
Return supported overall channel gain range in dB.
Source§fn gain(
&self,
direction: Direction,
channel: usize,
) -> Result<Option<f64>, Error>
fn gain( &self, direction: Direction, channel: usize, ) -> Result<Option<f64>, Error>
Return overall channel gain in dB, if available.
Source§fn set_gain(
&self,
direction: Direction,
channel: usize,
gain: f64,
) -> Result<(), Error>
fn set_gain( &self, direction: Direction, channel: usize, gain: f64, ) -> Result<(), Error>
Set overall channel gain in dB.
Source§fn gain_element_range(
&self,
direction: Direction,
channel: usize,
name: &str,
) -> Result<Range, Error>
fn gain_element_range( &self, direction: Direction, channel: usize, name: &str, ) -> Result<Range, Error>
Return supported range in dB for a named gain element.
Source§impl RxDevice for Uhd
impl RxDevice for Uhd
Source§type RxStreamer = RxStreamer
type RxStreamer = RxStreamer
RX streamer implementation.
Source§fn rx_streamer(
&self,
channels: &[usize],
_args: Args,
) -> Result<Self::RxStreamer, Error>
fn rx_streamer( &self, channels: &[usize], _args: Args, ) -> Result<Self::RxStreamer, Error>
Create an RX streamer.
Source§impl SampleRateControl for Uhd
impl SampleRateControl for Uhd
Auto Trait Implementations§
impl Freeze for Uhd
impl RefUnwindSafe for Uhd
impl Send for Uhd
impl Sync for Uhd
impl Unpin for Uhd
impl UnsafeUnpin for Uhd
impl UnwindSafe for Uhd
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DynRxDevice for T
impl<T> DynRxDevice for T
Source§fn rx_streamer(
&self,
channels: &[usize],
args: Args,
) -> Result<Box<dyn RxStreamer>, Error>
fn rx_streamer( &self, channels: &[usize], args: Args, ) -> Result<Box<dyn RxStreamer>, Error>
Create a type-erased RX streamer.