pub struct PS2000Driver { /* private fields */ }
Implementations§
Trait Implementations§
Source§impl Debug for PS2000Driver
impl Debug for PS2000Driver
Source§impl Drop for PS2000Driver
impl Drop for PS2000Driver
Source§impl PicoDriver for PS2000Driver
impl PicoDriver for PS2000Driver
Source§fn get_driver(&self) -> Driver
fn get_driver(&self) -> Driver
Gets the underlying driver type
Source§fn get_version(&self) -> PicoResult<String>
fn get_version(&self) -> PicoResult<String>
Gets the driver version string
Source§fn enumerate_units(&self) -> PicoResult<Vec<EnumerationResult>>
fn enumerate_units(&self) -> PicoResult<Vec<EnumerationResult>>
Returns a list of discovered serial numbers
Source§fn open_unit(&self, serial: Option<&str>) -> PicoResult<i16>
fn open_unit(&self, serial: Option<&str>) -> PicoResult<i16>
Opens a device, optionally with a specific serial number
Source§fn maximum_value(&self, _: i16) -> PicoResult<i16>
fn maximum_value(&self, _: i16) -> PicoResult<i16>
Get the maximum expected ADC value. This is required to scale to volts
Source§fn get_unit_info(&self, handle: i16, info_type: PicoInfo) -> PicoResult<String>
fn get_unit_info(&self, handle: i16, info_type: PicoInfo) -> PicoResult<String>
Get one of the unit info strings
Source§fn get_channel_ranges(
&self,
handle: i16,
channel: PicoChannel,
) -> PicoResult<Vec<PicoRange>>
fn get_channel_ranges( &self, handle: i16, channel: PicoChannel, ) -> PicoResult<Vec<PicoRange>>
Get valid ranges for the specified channel
Source§fn enable_channel(
&self,
handle: i16,
channel: PicoChannel,
config: &ChannelConfig,
) -> PicoResult<()>
fn enable_channel( &self, handle: i16, channel: PicoChannel, config: &ChannelConfig, ) -> PicoResult<()>
Set up a channel with the supplied config
Source§fn disable_channel(&self, handle: i16, channel: PicoChannel) -> PicoResult<()>
fn disable_channel(&self, handle: i16, channel: PicoChannel) -> PicoResult<()>
Disable a channel
Source§fn set_data_buffer(
&self,
handle: i16,
channel: PicoChannel,
buffer: Arc<RwLock<Pin<Vec<i16>>>>,
_buffer_len: usize,
) -> PicoResult<()>
fn set_data_buffer( &self, handle: i16, channel: PicoChannel, buffer: Arc<RwLock<Pin<Vec<i16>>>>, _buffer_len: usize, ) -> PicoResult<()>
Give the driver a buffer to write data into
Source§fn start_streaming(
&self,
handle: i16,
sample_config: &SampleConfig,
) -> PicoResult<SampleConfig>
fn start_streaming( &self, handle: i16, sample_config: &SampleConfig, ) -> PicoResult<SampleConfig>
Starts the device streaming
Source§fn get_latest_streaming_values<'a>(
&self,
handle: i16,
_channels: &[PicoChannel],
callback: Box<dyn FnMut(usize, usize) + 'a>,
) -> PicoResult<()>
fn get_latest_streaming_values<'a>( &self, handle: i16, _channels: &[PicoChannel], callback: Box<dyn FnMut(usize, usize) + 'a>, ) -> PicoResult<()>
Gets the latest streaming values
Source§fn check_version(&self) -> Result<(), DriverLoadError>
fn check_version(&self) -> Result<(), DriverLoadError>
Check that the driver meets the minimum version tested with these wrappers
Auto Trait Implementations§
impl Freeze for PS2000Driver
impl !RefUnwindSafe for PS2000Driver
impl Send for PS2000Driver
impl Sync for PS2000Driver
impl Unpin for PS2000Driver
impl !UnwindSafe for PS2000Driver
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