plcopen
0.22.0
载入中...
搜索中...
未找到
pose.h
浏览该文件的文档.
1
#pragma once
2
3
// Orientation batch (approved matrix: doc/compliance/orientation-semantics.md,
4
// decision #2): the 6-DOF pose plugin contract, parallel to the v1
5
// translational `Kinematics` ABI — the two consume different command
6
// dimensions and are configured mutually exclusively on a group. Same
7
// contract discipline as KB-037/KB-041: analytic solutions, seed-branch
8
// selection with a no-branch-flip gate, singularity margins, no allocation,
9
// no exceptions, bounded time.
10
11
#include <cstddef>
12
13
#include "
rt/error.h
"
14
15
namespace
plcopen::core::kin
16
{
17
18
struct
Pose6
19
{
20
double
position
[3] = {0.0, 0.0, 0.0};
21
// Row-major rotation matrix (must be orthonormal; callers own that).
22
double
rotation
[3][3] = {{1.0, 0.0, 0.0}, {0.0, 1.0, 0.0}, {0.0, 0.0, 1.0}};
23
};
24
25
class
PoseKinematics
26
{
27
public
:
28
virtual
~PoseKinematics
() =
default
;
29
30
virtual
std::size_t
joint_count
()
const
= 0;
31
32
virtual
void
forward
(
const
double
*joints,
Pose6
&pose)
const
= 0;
33
34
// Seed-branch semantics with the max_joint_step no-branch-flip gate
35
// (KB-041 contract carried over): no same-turn candidate inside the step
36
// bound reports `infeasible`, never an implicit branch flip.
37
virtual
rt::ErrorCode
inverse
(
const
Pose6
&pose,
38
const
double
*seed,
39
double
max_joint_step,
40
double
*joints_out)
const
= 0;
41
42
virtual
double
singularity_margin
(
const
double
*joints)
const
= 0;
43
};
44
45
}
// namespace plcopen::core::kin
plcopen::core::kin::PoseKinematics
定义
pose.h:26
plcopen::core::kin::PoseKinematics::singularity_margin
virtual double singularity_margin(const double *joints) const =0
plcopen::core::kin::PoseKinematics::forward
virtual void forward(const double *joints, Pose6 &pose) const =0
plcopen::core::kin::PoseKinematics::joint_count
virtual std::size_t joint_count() const =0
plcopen::core::kin::PoseKinematics::~PoseKinematics
virtual ~PoseKinematics()=default
plcopen::core::kin::PoseKinematics::inverse
virtual rt::ErrorCode inverse(const Pose6 &pose, const double *seed, double max_joint_step, double *joints_out) const =0
error.h
plcopen::core::kin
定义
differential.h:19
plcopen::core::rt::ErrorCode
ErrorCode
定义
error.h:7
plcopen::core::kin::Pose6
定义
pose.h:19
plcopen::core::kin::Pose6::position
double position[3]
定义
pose.h:20
plcopen::core::kin::Pose6::rotation
double rotation[3][3]
定义
pose.h:22
core
kin
pose.h
制作者
1.15.0