pub struct RevPiControl { /* private fields */ }
Expand description
RevPiControl is an object representing an open file handle to the piControl driver file descriptor.
Implementations§
Source§impl RevPiControl
impl RevPiControl
pub fn new() -> Self
pub fn new_at(path: &str) -> Self
pub fn read(&mut self, offset: u64, length: usize) -> Result<Vec<u8>>
Sourcepub fn write(&mut self, offset: u64, data: &Vec<u8>) -> Result<bool>
pub fn write(&mut self, offset: u64, data: &Vec<u8>) -> Result<bool>
Writes process data at a specific position and a returns a boolean result.
Sourcepub fn get_variable_info(&self, name: &str) -> Result<SPIVariable>
pub fn get_variable_info(&self, name: &str) -> Result<SPIVariable>
Get the info for a variable.
Sourcepub fn get_device_info_list(&self) -> Result<Vec<SDeviceInfo>>
pub fn get_device_info_list(&self) -> Result<Vec<SDeviceInfo>>
Gets a description of connected devices.
Sourcepub fn get_bit_value(&self, pSpiValue: &mut SPIValue) -> Result<bool>
pub fn get_bit_value(&self, pSpiValue: &mut SPIValue) -> Result<bool>
Gets the value of one bit in the process image.
Sourcepub fn set_bit_value(&self, pSpiValue: &mut SPIValue) -> Result<bool>
pub fn set_bit_value(&self, pSpiValue: &mut SPIValue) -> Result<bool>
Sets the value of one bit in the process image.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RevPiControl
impl RefUnwindSafe for RevPiControl
impl Send for RevPiControl
impl Sync for RevPiControl
impl Unpin for RevPiControl
impl UnwindSafe for RevPiControl
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