pub struct Cam { /* private fields */ }
Expand description
The structure of the camera allows you to communicate with it at a high level
Implementations§
Source§impl Cam
impl Cam
Sourcepub async fn new<S>(
addr: S,
port: usize,
user_passwd: Option<(S, S)>,
movment_speed_ms: usize,
) -> Result<Self, Box<dyn Error>>
pub async fn new<S>( addr: S, port: usize, user_passwd: Option<(S, S)>, movment_speed_ms: usize, ) -> Result<Self, Box<dyn Error>>
Creating an object to connect to the camera. If there is no login and password, then the user_passwd
field should have the value None
Sourcepub async fn rotate_cam(&mut self, rot: i8) -> Result<Response, Box<dyn Error>>
pub async fn rotate_cam(&mut self, rot: i8) -> Result<Response, Box<dyn Error>>
Rotate the camera, rot
can vary -100..=100
Sourcepub async fn zoom_cam(&mut self, zoom: i8) -> Result<Response, Box<dyn Error>>
pub async fn zoom_cam(&mut self, zoom: i8) -> Result<Response, Box<dyn Error>>
Zoom the camera lens, zoom
can vary from -100..=100
Sourcepub async fn tilt_cam(&mut self, til: i8) -> Result<Response, Box<dyn Error>>
pub async fn tilt_cam(&mut self, til: i8) -> Result<Response, Box<dyn Error>>
Tilt the camera, til
can vary from -100..=100
pub async fn change_movement_speed(&mut self, ms: usize)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Cam
impl !RefUnwindSafe for Cam
impl Send for Cam
impl Sync for Cam
impl Unpin for Cam
impl !UnwindSafe for Cam
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