pub struct Base {
pub robot: Arc<dyn Kinematics>,
pub base: Isometry3<f64>,
}
Expand description
Defines the fixed base that can hold the robot. The base moves the robot to its installed location, providing also rotation if required (physical robots work well and may be installed upside down, or at some angle like 45 degrees). Base itself fully implements the Kinematics, providing both inverse and forward kinematics for the robot on a base.
Fields§
§robot: Arc<dyn Kinematics>
§base: Isometry3<f64>
Transformation from the world origin to the robots base.
Trait Implementations§
Source§impl Kinematics for Base
impl Kinematics for Base
Source§fn inverse(&self, tcp: &Pose) -> Solutions
fn inverse(&self, tcp: &Pose) -> Solutions
Find inverse kinematics (joint position) for this pose
This function is faster but does not handle the singularity J5 = 0 well.
All returned solutions are cross-checked with forward kinematics and
valid.
Source§fn inverse_continuing(&self, tcp: &Pose, previous: &Joints) -> Solutions
fn inverse_continuing(&self, tcp: &Pose, previous: &Joints) -> Solutions
Find inverse kinematics (joint position) for this pose
This function handles the singularity J5 = 0 by keeping the previous values
the values J4 and J6 from the previous solution
Use CONSTRAINT_CENTERED as previous if there is no previous position but we prefer
to be as close to the center of constraints (or zeroes if not set) as
possible.
Source§fn inverse_5dof(&self, tcp: &Pose, j6: f64) -> Solutions
fn inverse_5dof(&self, tcp: &Pose, j6: f64) -> Solutions
Calculates the inverse kinematics for a robot while ignoring the rotation
around joint 6. The position of the tool center point remains precise,
but the rotation is approximate (rotation around the tool axis is ignored).
The return value for joint 6 is set according to the provided parameter.
This method is significantly faster
Source§fn inverse_continuing_5dof(&self, tcp: &Pose, previous: &Joints) -> Solutions
fn inverse_continuing_5dof(&self, tcp: &Pose, previous: &Joints) -> Solutions
Calculates the inverse kinematics for a robot while ignoring the rotation
around joint 6. The position of the tool center point remains precise,
but the rotation is approximate (rotation around the tool axis is ignored).
The return value for joint 6 is set based on the previous joint values.
This method is significantly faster
Source§fn forward(&self, joints: &Joints) -> Pose
fn forward(&self, joints: &Joints) -> Pose
Find forward kinematics (pose from joint positions).
For 5 DOF robot, the rotation of the joint 6 should normally be 0.0
but some other value can be given, meaning the tool is mounted with
fixed rotation offset.
Source§fn forward_with_joint_poses(&self, joints: &Joints) -> [Pose; 6]
fn forward_with_joint_poses(&self, joints: &Joints) -> [Pose; 6]
Computes the forward kinematics for a 6-DOF robotic arm and returns an array of poses
representing the position and orientation of each joint, including the final end-effector. Read more
Source§fn kinematic_singularity(&self, qs: &Joints) -> Option<Singularity>
fn kinematic_singularity(&self, qs: &Joints) -> Option<Singularity>
Detect the singularity. Returns either A type singlularity or None if
no singularity detected.
Source§fn constraints(&self) -> &Option<Constraints>
fn constraints(&self) -> &Option<Constraints>
Returns constraints under what the solver is operating.
Constraints are remembered here and can be used for generating random
joint angles needed by RRT, or say providing limits of sliders in GUI.
Auto Trait Implementations§
impl Freeze for Base
impl !RefUnwindSafe for Base
impl Send for Base
impl Sync for Base
impl Unpin for Base
impl !UnwindSafe for Base
Blanket Implementations§
Source§impl<T, U> AsBindGroupShaderType<U> for T
impl<T, U> AsBindGroupShaderType<U> for T
Source§fn as_bind_group_shader_type(&self, _images: &RenderAssets<Image>) -> U
fn as_bind_group_shader_type(&self, _images: &RenderAssets<Image>) -> U
Return the
T
ShaderType
for self
. When used in AsBindGroup
derives, it is safe to assume that all images in self
exist.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> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§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 moreSource§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).Source§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.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.