pub struct CuJointTrajectoryLimits<const N: usize> {
pub max_velocities: [CuJointVelocity; N],
pub max_accelerations: [CuJointAcceleration; N],
pub max_jerks: Option<[CuJointJerk; N]>,
}Expand description
Per-joint speed, acceleration, and jerk limits for time-parameterization.
Every entry uses the typed joint representation, so revolute (rad/s,
rad/s^2, rad/s^3), prismatic (m/s, m/s^2, m/s^3), and fixed joints
each carry their own unit; the entry kind must match the joint kind of the
parameterized waypoints. max_jerks is only used by
CuTrajectoryProfile::SCurve; None (the default, and an omitted RON
key) means “no jerk bound” and lets the S-curve degrade gracefully to
trapezoidal timing and shape. A single f64::INFINITY entry leaves that
joint unbounded.
{
"max_velocities": [{"revolute": 0.8}, {"prismatic": 0.2}],
"max_accelerations": [{"revolute": 2.0}, {"prismatic": 1.0}],
"max_jerks": [{"revolute": 10.0}, {"prismatic": 5.0}], // optional
}Fields§
§max_velocities: [CuJointVelocity; N]§max_accelerations: [CuJointAcceleration; N]§max_jerks: Option<[CuJointJerk; N]>Per-joint jerk bounds; None means unbounded.
Implementations§
Source§impl<const N: usize> CuJointTrajectoryLimits<N>
impl<const N: usize> CuJointTrajectoryLimits<N>
Sourcepub const fn new(
max_velocities: [CuJointVelocity; N],
max_accelerations: [CuJointAcceleration; N],
) -> Self
pub const fn new( max_velocities: [CuJointVelocity; N], max_accelerations: [CuJointAcceleration; N], ) -> Self
Creates limits from per-joint typed velocities and accelerations with
no jerk bound; add one with CuJointTrajectoryLimits::with_jerks.
Sourcepub const fn with_jerks(self, max_jerks: [CuJointJerk; N]) -> Self
pub const fn with_jerks(self, max_jerks: [CuJointJerk; N]) -> Self
Sets per-joint jerk bounds. Each entry must be positive (finite or
f64::INFINITY) for revolute and prismatic joints; fixed-joint entries
are ignored.
Trait Implementations§
Source§impl<'__de, const N: usize, __Context> BorrowDecode<'__de, __Context> for CuJointTrajectoryLimits<N>
impl<'__de, const N: usize, __Context> BorrowDecode<'__de, __Context> for CuJointTrajectoryLimits<N>
Source§fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>(
decoder: &mut __D,
) -> Result<Self, DecodeError>
fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>
Source§impl<const N: usize> Clone for CuJointTrajectoryLimits<N>
impl<const N: usize> Clone for CuJointTrajectoryLimits<N>
Source§fn clone(&self) -> CuJointTrajectoryLimits<N>
fn clone(&self) -> CuJointTrajectoryLimits<N>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl<const N: usize> Copy for CuJointTrajectoryLimits<N>
Source§impl<const N: usize> Debug for CuJointTrajectoryLimits<N>
impl<const N: usize> Debug for CuJointTrajectoryLimits<N>
Source§impl<const N: usize, __Context> Decode<__Context> for CuJointTrajectoryLimits<N>
impl<const N: usize, __Context> Decode<__Context> for CuJointTrajectoryLimits<N>
Source§impl<const N: usize> Default for CuJointTrajectoryLimits<N>
impl<const N: usize> Default for CuJointTrajectoryLimits<N>
Source§fn default() -> Self
fn default() -> Self
Zero limits: a placeholder that CuJointTrajectoryLimits::validate
rejects, since limits have no sensible default.
Source§impl<'de, const N: usize> Deserialize<'de> for CuJointTrajectoryLimits<N>
impl<'de, const N: usize> Deserialize<'de> for CuJointTrajectoryLimits<N>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl<const N: usize> Encode for CuJointTrajectoryLimits<N>
impl<const N: usize> Encode for CuJointTrajectoryLimits<N>
Source§impl<const N: usize> PartialEq for CuJointTrajectoryLimits<N>
impl<const N: usize> PartialEq for CuJointTrajectoryLimits<N>
Source§impl<const N: usize> Serialize for CuJointTrajectoryLimits<N>
impl<const N: usize> Serialize for CuJointTrajectoryLimits<N>
impl<const N: usize> StructuralPartialEq for CuJointTrajectoryLimits<N>
Source§impl<const N: usize> TypePath for CuJointTrajectoryLimits<N>
impl<const N: usize> TypePath for CuJointTrajectoryLimits<N>
fn type_path() -> &'static str
fn short_type_path() -> &'static str
fn type_ident() -> Option<&'static str>
fn crate_name() -> Option<&'static str>
fn module_path() -> Option<&'static str>
Auto Trait Implementations§
impl<const N: usize> Freeze for CuJointTrajectoryLimits<N>
impl<const N: usize> RefUnwindSafe for CuJointTrajectoryLimits<N>
impl<const N: usize> Send for CuJointTrajectoryLimits<N>
impl<const N: usize> Sync for CuJointTrajectoryLimits<N>
impl<const N: usize> Unpin for CuJointTrajectoryLimits<N>
impl<const N: usize> UnsafeUnpin for CuJointTrajectoryLimits<N>
impl<const N: usize> UnwindSafe for CuJointTrajectoryLimits<N>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CuMsgPayload for T
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<T> ElementType for T
impl<T> ElementType for T
impl<T> GetTypeRegistration for T
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> ⓘ
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> ⓘ
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 more