pub struct EthercatPoulpeController { /* private fields */ }
Expand description
EthercatPoulpeController - wrapper around the three disks motors
Implementations§
Trait Implementations§
Source§impl Debug for EthercatPoulpeController
impl Debug for EthercatPoulpeController
Source§impl MotorsController<3> for EthercatPoulpeController
impl MotorsController<3> for EthercatPoulpeController
fn io(&mut self) -> &mut dyn RawMotorsIO<3>
§fn inverted_axes(&self) -> [Option<bool>; N]
fn inverted_axes(&self) -> [Option<bool>; N]
Get the axes invertion
§fn get_current_position(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_current_position(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current position of the motors (in radians)
§fn get_current_velocity(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_current_velocity(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current velocity of the motors (in radians per second)
§fn get_current_torque(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_current_torque(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current torque of the motors (in Nm)
§fn get_target_position(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_target_position(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current target position of the motors (in radians)
§fn set_target_position(
&mut self,
position: [f64; N],
) -> Result<(), Box<dyn Error>>
fn set_target_position( &mut self, position: [f64; N], ) -> Result<(), Box<dyn Error>>
Set the current target position of the motors (in radians)
§fn set_target_torque(&mut self, torque: [f64; N]) -> Result<(), Box<dyn Error>>
fn set_target_torque(&mut self, torque: [f64; N]) -> Result<(), Box<dyn Error>>
Set the current target torque of the motors (in Nm) TODO: inverted_axes?
§fn set_target_velocity(
&mut self,
velocity: [f64; N],
) -> Result<(), Box<dyn Error>>
fn set_target_velocity( &mut self, velocity: [f64; N], ) -> Result<(), Box<dyn Error>>
Set the current target velocity of the motors (in rad/s) TODO: inverted_axes?
§fn get_target_torque(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_target_torque(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current target torque of the motors (in Nm) TODO: inverted_axes?
§fn get_target_velocity(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_target_velocity(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current target velocity of the motors (in rad/s) TODO: inverted_axes?
§fn set_target_position_fb(
&mut self,
position: [f64; N],
) -> Result<[f64; N], Box<dyn Error>>
fn set_target_position_fb( &mut self, position: [f64; N], ) -> Result<[f64; N], Box<dyn Error>>
Set the current target position and returns the motor feeback (position, velocity, torque)
§fn get_velocity_limit(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_velocity_limit(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the velocity limit of the motors (in radians per second)
§fn set_velocity_limit(
&mut self,
velocity: [f64; N],
) -> Result<(), Box<dyn Error>>
fn set_velocity_limit( &mut self, velocity: [f64; N], ) -> Result<(), Box<dyn Error>>
Set the velocity limit of the motors (in radians per second)
§fn get_torque_limit(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_torque_limit(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the torque limit of the motors (in Nm)
§fn set_torque_limit(&mut self, torque: [f64; N]) -> Result<(), Box<dyn Error>>
fn set_torque_limit(&mut self, torque: [f64; N]) -> Result<(), Box<dyn Error>>
Set the torque limit of the motors (in Nm)
§fn get_pid_gains(&mut self) -> Result<[PID; N], Box<dyn Error>>
fn get_pid_gains(&mut self) -> Result<[PID; N], Box<dyn Error>>
Get the current PID gains of the motors
§fn set_pid_gains(&mut self, pid: [PID; N]) -> Result<(), Box<dyn Error>>
fn set_pid_gains(&mut self, pid: [PID; N]) -> Result<(), Box<dyn Error>>
Set the current PID gains of the motors
§fn get_axis_sensors(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_axis_sensors(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current axis sensors of the articulation TODO: inverted_axes?
§fn get_axis_sensor_zeros(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_axis_sensor_zeros(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the current zeros of the axis sensors of the articulation TODO: inverted_axes?
§fn get_board_state(&mut self) -> Result<u8, Box<dyn Error>>
fn get_board_state(&mut self) -> Result<u8, Box<dyn Error>>
Get the current state of the articulation control board
§fn set_board_state(&mut self, state: u8) -> Result<(), Box<dyn Error>>
fn set_board_state(&mut self, state: u8) -> Result<(), Box<dyn Error>>
Set the current state of the articulation control board (clear error)
§fn get_motor_temperatures(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_motor_temperatures(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the motor temperatures (in Celsius)
§fn get_board_temperatures(&mut self) -> Result<[f64; N], Box<dyn Error>>
fn get_board_temperatures(&mut self) -> Result<[f64; N], Box<dyn Error>>
Get the board H-bridges temperatures (in Celsius)
§fn emergency_stop(&mut self)
fn emergency_stop(&mut self)
Trigger an emergency stop
Source§impl RawMotorsIO<3> for EthercatPoulpeController
impl RawMotorsIO<3> for EthercatPoulpeController
fn name(&self) -> String
Source§fn is_torque_on(&mut self) -> Result<[bool; 3]>
fn is_torque_on(&mut self) -> Result<[bool; 3]>
Check if the motors are ON or OFF
Source§fn get_current_position(&mut self) -> Result<[f64; 3]>
fn get_current_position(&mut self) -> Result<[f64; 3]>
Get the current position of the motors (in radians)
Source§fn get_current_velocity(&mut self) -> Result<[f64; 3]>
fn get_current_velocity(&mut self) -> Result<[f64; 3]>
Get the current velocity of the motors (in radians per second)
Source§fn get_current_torque(&mut self) -> Result<[f64; 3]>
fn get_current_torque(&mut self) -> Result<[f64; 3]>
Get the current torque of the motors (in Nm)
Source§fn get_target_position(&mut self) -> Result<[f64; 3]>
fn get_target_position(&mut self) -> Result<[f64; 3]>
Get the current target position of the motors (in radians)
Source§fn set_target_position(&mut self, position: [f64; 3]) -> Result<()>
fn set_target_position(&mut self, position: [f64; 3]) -> Result<()>
Set the current target position of the motors (in radians)
Source§fn set_target_velocity(&mut self, vel: [f64; 3]) -> Result<()>
fn set_target_velocity(&mut self, vel: [f64; 3]) -> Result<()>
Set the current target velocity of the motors (in rad/s)
Source§fn set_target_torque(&mut self, vel: [f64; 3]) -> Result<()>
fn set_target_torque(&mut self, vel: [f64; 3]) -> Result<()>
Set the current target torque of the motors (in Nm)
Source§fn set_target_position_fb(&mut self, position: [f64; 3]) -> Result<[f64; 3]>
fn set_target_position_fb(&mut self, position: [f64; 3]) -> Result<[f64; 3]>
Set the current target position and returns the motor feeback (position, velocity, torque)
Source§fn get_velocity_limit(&mut self) -> Result<[f64; 3]>
fn get_velocity_limit(&mut self) -> Result<[f64; 3]>
Get the velocity limit of the motors (in radians per second)
Source§fn set_velocity_limit(&mut self, velocity: [f64; 3]) -> Result<()>
fn set_velocity_limit(&mut self, velocity: [f64; 3]) -> Result<()>
Set the velocity limit of the motors (in radians per second)
Source§fn get_torque_limit(&mut self) -> Result<[f64; 3]>
fn get_torque_limit(&mut self) -> Result<[f64; 3]>
Get the torque limit of the motors (in Nm)
Source§fn set_torque_limit(&mut self, torque: [f64; 3]) -> Result<()>
fn set_torque_limit(&mut self, torque: [f64; 3]) -> Result<()>
Set the torque limit of the motors (in Nm)
Source§fn get_pid_gains(&mut self) -> Result<[PID; 3]>
fn get_pid_gains(&mut self) -> Result<[PID; 3]>
Get the current PID gains of the motors
Source§fn set_pid_gains(&mut self, _pid: [PID; 3]) -> Result<()>
fn set_pid_gains(&mut self, _pid: [PID; 3]) -> Result<()>
Set the current PID gains of the motors
Source§fn get_axis_sensors(&mut self) -> Result<[f64; 3]>
fn get_axis_sensors(&mut self) -> Result<[f64; 3]>
Get the current axis sensors
Source§fn get_axis_sensor_zeros(&mut self) -> Result<[f64; 3]>
fn get_axis_sensor_zeros(&mut self) -> Result<[f64; 3]>
Get the zeros of the axis sensors
Source§fn get_board_state(&mut self) -> Result<u8>
fn get_board_state(&mut self) -> Result<u8>
Get the Board State byte
Source§fn get_error_codes(&mut self) -> Result<[i32; 3]>
fn get_error_codes(&mut self) -> Result<[i32; 3]>
Get the motors error codes
Source§fn get_motor_temperatures(&mut self) -> Result<[f64; 3]>
fn get_motor_temperatures(&mut self) -> Result<[f64; 3]>
Get the motor temperatures (in Celsius)
Source§fn get_board_temperatures(&mut self) -> Result<[f64; 3]>
fn get_board_temperatures(&mut self) -> Result<[f64; 3]>
Get the board H-bridges temperatures (in Celsius)
Source§fn set_board_state(&mut self, _state: u8) -> Result<()>
fn set_board_state(&mut self, _state: u8) -> Result<()>
Set the Board State byte
Source§fn get_control_mode(&mut self) -> Result<[u8; 3]>
fn get_control_mode(&mut self) -> Result<[u8; 3]>
Get the control mode
fn emergency_stop(&mut self)
Auto Trait Implementations§
impl !Freeze for EthercatPoulpeController
impl !RefUnwindSafe for EthercatPoulpeController
impl Send for EthercatPoulpeController
impl Sync for EthercatPoulpeController
impl Unpin for EthercatPoulpeController
impl !UnwindSafe for EthercatPoulpeController
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
§impl<T> Conv for T
impl<T> Conv for T
§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
Causes
self
to use its Binary
implementation when Debug
-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
Causes
self
to use its Display
implementation when
Debug
-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
Causes
self
to use its LowerExp
implementation when
Debug
-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
Causes
self
to use its LowerHex
implementation when
Debug
-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
Causes
self
to use its Octal
implementation when Debug
-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
Causes
self
to use its Pointer
implementation when
Debug
-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
Causes
self
to use its UpperExp
implementation when
Debug
-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
Causes
self
to use its UpperHex
implementation when
Debug
-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
Formats each item in a sequence. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Pipes by value. This is generally the method you want to use. Read more
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
Borrows
self
and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
Mutably borrows
self
and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
Borrows
self
, then passes self.as_ref()
into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
Mutably borrows
self
, then passes self.as_mut()
into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
Borrows
self
, then passes self.deref()
into the pipe function.§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Immutable access to the
Borrow<B>
of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
Mutable access to the
BorrowMut<B>
of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
Immutable access to the
AsRef<R>
view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
Mutable access to the
AsMut<R>
view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Immutable access to the
Deref::Target
of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Mutable access to the
Deref::Target
of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
Calls
.tap()
only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
Calls
.tap_mut()
only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
Calls
.tap_borrow()
only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
Calls
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
Calls
.tap_ref()
only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
Calls
.tap_ref_mut()
only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
Calls
.tap_deref()
only in debug builds, and is erased in release
builds.