Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: CMake

on:
push:
branches: [main, "v*.x"]
branches: [v1.x]
pull_request:
branches: [main, "v*.x"]
branches: [v1.x]
workflow_dispatch:

env:
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.16.3)
# ===================================================================
# PROJECT SETUP
# ===================================================================
project(flexiv_rdk VERSION 1.9.2 LANGUAGES CXX)
project(flexiv_rdk VERSION 1.9.3 LANGUAGES CXX)

# Configure build type
if(NOT CMAKE_BUILD_TYPE)
Expand Down
9 changes: 1 addition & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,4 @@ Note:

## API Documentation

The complete and detailed API documentation of the **latest release** can be found at [Flexiv RDK APIs](https://www.flexiv.com/software/rdk/api). The API documentation of a previous release can be generated manually using Doxygen. For example, on Linux:

sudo apt install doxygen-latex graphviz
cd flexiv_rdk
git checkout <previous_release_tag>
doxygen doc/Doxyfile.in

Open any html file under `flexiv_rdk/doc/html/` with your browser to view the doc.
The complete and detailed API documentation can be found at [Flexiv RDK APIs](https://www.flexiv.com/software/rdk/api). The page shows the latest release by default. You can view previous releases using the dropdown menu at the top right corner.
2 changes: 1 addition & 1 deletion doc/Doxyfile.in
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ PROJECT_NAME = "Flexiv RDK APIs"
# could be handy for archiving the generated documentation or if some version
# control system is used.

PROJECT_NUMBER = 1.9.2
PROJECT_NUMBER = 1.9.3

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
Expand Down
72 changes: 72 additions & 0 deletions include/flexiv/rdk/data.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -481,6 +481,78 @@ struct Coord
std::string str() const;
};

/**
* @struct NrtCartesianCmd
* @brief Commands data for a single waypoint in non-real-time Cartesian motion-force control.
* @see Robot::SendCartesianMotionForce(), Robot::SendMultiCartesianMotionForce().
Comment thread
pzhu-flexiv marked this conversation as resolved.
*/
struct NrtCartesianCmd
{
/** Default constructor */
NrtCartesianCmd() = default;

/**
* @brief Custom constructor.
* @param[in] pose_d Target TCP pose in world frame.
* @param[in] wrench_d Target TCP wrench in the force control reference frame.
* @param[in] twist_d Target TCP twist in world frame.
* @param[in] max_linear_vel Maximum Cartesian linear velocity when moving to the target pose.
* @param[in] max_angular_vel Maximum Cartesian angular velocity when moving to the target pose.
* @param[in] max_linear_acc Maximum Cartesian linear acceleration when moving to the target
* pose.
* @param[in] max_angular_acc Maximum Cartesian angular acceleration when moving to the target
* pose.
*/
NrtCartesianCmd(const std::array<double, kPoseSize>& pose_d,
const std::array<double, kCartDoF>& wrench_d = {},
const std::array<double, kCartDoF>& twist_d = {}, double max_linear_vel = 0.5,
double max_angular_vel = 1.0, double max_linear_acc = 2.0, double max_angular_acc = 5.0)
: pose_d(pose_d)
, wrench_d(wrench_d)
, twist_d(twist_d)
, max_linear_vel(max_linear_vel)
, max_angular_vel(max_angular_vel)
, max_linear_acc(max_linear_acc)
, max_angular_acc(max_angular_acc)
{
}

/** Target TCP pose in world frame: \f$ {^{O}T_{TCP}}_{d} \in \mathbb{R}^{7 \times 1} \f$.
* Consists of \f$ \mathbb{R}^{3 \times 1} \f$ position and \f$ \mathbb{R}^{4 \times 1} \f$
* quaternion: \f$ [x, y, z, q_w, q_x, q_y, q_z]^T \f$. Unit: \f$ [m]:[] \f$ */
std::array<double, kPoseSize> pose_d = {};

/** Target TCP wrench in the force control reference frame (configured by
* SetForceControlFrame()): \f$ ^{O}F_d \in \mathbb{R}^{6 \times 1} \f$. The robot will track
* the target wrench using an explicit force controller. Consists of \f$ \mathbb{R}^{3 \times 1}
* \f$ force and \f$ \mathbb{R}^{3 \times 1} \f$ moment: \f$ [f_x, f_y, f_z, m_x, m_y, m_z]^T
* \f$. Unit: \f$ [N]:[Nm] \f$ */
std::array<double, kCartDoF> wrench_d = {};

/** Target TCP twist in world frame: \f$ ^{O}\dot{x}_d \in \mathbb{R}^{6 \times 1} \f$.
* Providing properly calculated target twist can improve the robot's overall tracking
* performance at the cost of reduced robustness. Leaving this input 0 can maximize robustness
* at the cost of reduced tracking performance. Consists of \f$ \mathbb{R}^{3 \times 1} \f$
* linear and \f$ \mathbb{R}^{3 \times 1} \f$ angular velocity. Unit: \f$ [m/s]:[rad/s] \f$ */
std::array<double, kCartDoF> twist_d = {};

/** Maximum Cartesian linear velocity when moving to the target pose. A safe value is provided
* as default. Unit: \f$ [m/s] \f$ */
double max_linear_vel = 0.5;

/** Maximum Cartesian angular velocity when moving to the target pose. A safe value is provided
* as default. Unit: \f$ [rad/s] \f$ */
double max_angular_vel = 1.0;

/** Maximum Cartesian linear acceleration when moving to the target pose. A safe value is
* provided as default. Unit: \f$ [m/s^2] \f$ */
double max_linear_acc = 2.0;

/** Maximum Cartesian angular acceleration when moving to the target pose. A safe value is
* provided as default. Unit: \f$ [rad/s^2] \f$ */
double max_angular_acc = 5.0;
};

/** Alias of the variant that holds all possible types of data exchanged with Flexiv robots */
using FlexivDataTypes = std::variant<int, double, std::string, rdk::JPos, rdk::Coord,
std::vector<int>, std::vector<double>, std::vector<std::string>, std::vector<rdk::JPos>,
Expand Down
2 changes: 1 addition & 1 deletion include/flexiv/rdk/mode.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ enum class Mode
* Run non-real-time super primitives, i.e. composite tasks that consist of various components
* like motion, force, vision, planning, etc.
* @note Non-real-time (NRT) mode.
* @see Robot::SendCartesianMotionForce().
* @see Robot::SendCartesianMotionForce(), Robot::SendMultiCartesianMotionForce().
*/
NRT_SUPER_PRIMITIVE,
};
Expand Down
39 changes: 38 additions & 1 deletion include/flexiv/rdk/robot.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -688,13 +688,50 @@ class Robot
* the rest axes motion-controlled, then provide target pose for the motion-controlled axes and
* target wrench for the force-controlled axes.
* @see SetCartesianImpedance(), SetMaxContactWrench(), SetNullSpacePosture(),
* SetForceControlAxis(), SetForceControlFrame(), SetPassiveForceControl().
* SetForceControlAxis(), SetForceControlFrame(), SetPassiveForceControl(),
* SendMultiCartesianMotionForce().
*/
void SendCartesianMotionForce(const std::array<double, kPoseSize>& pose,
const std::array<double, kCartDoF>& wrench = {},
const std::array<double, kCartDoF>& velocity = {}, double max_linear_vel = 0.5,
double max_angular_vel = 1.0, double max_linear_acc = 2.0, double max_angular_acc = 5.0);

/**
* @brief [Non-blocking] Discretely send Cartesian multi-waypoint motion and/or force commands
* for the robot to track using non-real-time super primitives. The robot will execute the
* provided waypoints sequentially using onboard motion generation.
* @param[in] cart_cmds Non-real-time Cartesian motion/force commands for each waypoint. Each
* element uses the same data layout as a single command in SendCartesianMotionForce().
* @param[in] joint_pos Sequence of target joint positions [rad] for each waypoint. Each element
* must contain RobotInfo::DoF values, i.e. the full system degrees of freedom including the
* manipulator and any external axes. Size must match [cart_cmds].
* @throw std::invalid_argument if [cart_cmds] is empty, if [joint_pos] is empty, if
* [cart_cmds] and [joint_pos] do not contain the same number of waypoints, if any waypoint's
* last 4 input parameters is not positive, or if any joint position vector size is not equal
* to RobotInfo::DoF.
Comment thread
pzhu-flexiv marked this conversation as resolved.
* @throw std::logic_error if the robot is not in the correct control mode.
* @throw std::runtime_error if the robot is not operational.
* @note Applicable control modes: NRT_SUPER_PRIMITIVE.
* @warning Same as Flexiv Elements, the target wrench is expressed as wrench sensed at TCP
* instead of wrench exerted by TCP. E.g. commanding f_z = +5 N will make the end-effector move
* towards -Z direction, so that upon contact, the sensed force will be +5 N.
* @par How to achieve pure motion control?
* Use SetForceControlAxis() to disable force control for all Cartesian axes to achieve pure
* motion control. This function does pure motion control by default.
* @par How to achieve pure force control?
* Use SetForceControlAxis() to enable force control for all Cartesian axes to achieve pure
* force control, active or passive.
* @par How to achieve unified motion-force control?
* Use SetForceControlAxis() to enable force control for one or more Cartesian axes and leave
* the rest axes motion-controlled, then provide target pose for the motion-controlled axes and
* target wrench for the force-controlled axes.
* @see SetCartesianImpedance(), SetMaxContactWrench(), SetNullSpacePosture(),
* SetForceControlAxis(), SetForceControlFrame(), SetPassiveForceControl(),
* SendCartesianMotionForce().
*/
void SendMultiCartesianMotionForce(const std::vector<NrtCartesianCmd>& cart_cmds,
const std::vector<std::vector<double>>& joint_pos);

/**
* @brief [Blocking] Set impedance properties of the robot's Cartesian motion controller
* used in the Cartesian motion-force control modes.
Expand Down
2 changes: 1 addition & 1 deletion lib/flexiv_rdk.win_amd64.lib.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
d1bedfc79b3b14ba896924f82cbe5fec8cddbf69b680c722a58e456d7c2deb50
16f1bc197a6795cac7a233e4710ec2fceba556819c90d429dcec027d35e1ac79
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.aarch64-linux-gnu.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
83b76d2264113bf76ae2b514e15c8dea4f9b2e45c39720654db80b73f422248c
eb21a49805b99d6d41519075836553cadd287b58bf575d386de12aa9579596a3
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.aarch64-linux-gnu.ros2-jazzy.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
02b2779df7e98aa91a1b2f41236d201c7e242837fc285c3a1e80cf504d44b752
d96cff2e4fc19ea47327964f12c837b0141e9a60f5b945dc7ec615a9fcfa45d5
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.aarch64-qnx.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
76dbf2b676c18911078101c59760382eb5174e94272c213c22ca1b690c99ef89
5a43cde38c9e553f55435f353fa0979b16ca73bc0295d6279260b10e946354b7
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.arm64-darwin.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7786efb7b3ff6d96005f598420e6929658091279664dcd9923ad16094003dcaf
3bd587126846c2724258749e16b1789fa2e96574cdfd5fe5925dacdba9624635
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.x86_64-linux-gnu.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3b1c923b4bed6c1cc94ce774d57071906c5808a30302a5d7d7be40b349c69b58
b3314d3095dd4615391448ea5e471ee2414696fea92e1232accafa54f2a39cfc
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.x86_64-linux-gnu.ros2-jazzy.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
49e8a20adec9b56b6263cdf94954cf3414b7a507521f42640208dd5efaf8276d
901c883df2647cb199aaf622aa3fd1955cb70c84023d4b0218ec32730873f15a
2 changes: 1 addition & 1 deletion lib/libflexiv_rdk.x86_64-qnx.a.sha256
Original file line number Diff line number Diff line change
@@ -1 +1 @@
e6b1538f3ec3e6a7bae22c849c48ed33ac3ee348d5fcad4526f3ad79949d3ad9
ae3fa7f1f8df84282d1df0cb1c82d85e3a50fdf6f8aa29108b1d00c715ce99c8