Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions robot_modeling/DQ_SerialManipulator.m
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,11 @@
st = get_supported_joint_types();
end

methods (Abstract)
% This method returns the corresponding dual quaternion for a given link's parameters.
get_link_transformation(q, ith);
end

methods (Access = protected)
function check_joint_types(obj)
% CHECK_JOINT_TYPES() throws an exception if the joint types
Expand Down
16 changes: 16 additions & 0 deletions robot_modeling/DQ_SerialManipulatorDH.m
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,22 @@
obj.set_joint_types(A(5,:));
end

function x = get_link_transformation(obj, q, ith)
% This method exposes the protected method get_link2dq(),
% which calculates the corresponding dual quaternion for a
% given link's DH parameters.
% Usage:
% get_link_transformation(q, ith)
% q: The joint value.
% ith: The link number.
%
% Example:
% robot = KukaLwr4Robot.kinematics();
% x = robot.get_link_transformation(pi/2, 3);

x = get_link2dq(obj, q, ith);
end

function ret = get_parameters(obj, parameterType)
% This method returns a vector containing the DH parameters.
% Usage: get_parameters(parameterType)
Expand Down
16 changes: 16 additions & 0 deletions robot_modeling/DQ_SerialManipulatorMDH.m
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,22 @@
obj.set_joint_types(A(5,:));
end

function x = get_link_transformation(obj, q, ith)
% This method exposes the protected method get_link2dq(),
% which calculates the corresponding dual quaternion for a
% given link's MDH parameters.
% Usage:
% get_link_transformation(q, ith)
% q: The joint value.
% ith: The link number.
%
% Example:
% robot = ComauSmartSixRobot.kinematics();
% x = robot.get_link_transformation(pi/2, 3);

x = get_link2dq(obj, q, ith);
end

function ret = get_parameters(obj, parameterType)
% This method returns a vector containing the DH parameters.
% Usage: get_parameters(parameterType)
Expand Down
Loading