|
AuboStudio SDK
0.6.3
|
|
|
|
|
动态负载管理 更多...
#include <payload_contribution_model.h>
Public 成员函数 | |
| PayloadContributionModel (PayloadContributionModel &f) | |
| PayloadContributionModel (PayloadContributionModel &&f) | |
| ~PayloadContributionModel () | |
| PayloadPtr | addPayload (const std::string &id_key, const std::string &suggested_name, double mass, const std::vector< double > ¢er_of_gravity) |
| Payload \chinese | |
| PayloadPtr | addPayload (const std::string &id_key, const std::string &suggested_name, double mass, const std::vector< double > ¢er_of_gravity, const std::vector< double > &inertiaMatrix) |
| Payload \chinese | |
| PayloadPtr | getPayload (const std::string &id_key) |
Payload \chinese 返回此前由此AuboCap使用相同idKey标识符添加的负载。使用此方法验证 负载是否存在于当前安装中。 | |
| void | updatePayload (const std::string &id_key, double mass, const std::vector< double > ¢er_of_gravity) |
| Payload \chinese | |
| void | updatePayload (const std::string id_key, double mass, const std::vector< double > ¢er_of_gravity, const std::vector< double > &inertia_matrix) |
| \chinese 更新此AuboCap已添加负载的质量、重心(CoG)和惯性矩阵。 | |
| void | removePayload (const std::string &id_key) |
| \chinese 从此AuboCap中移除已添加的负载。使用该负载的程序节点将变为未定义状态,因为负载 不再可解析。 | |
Private 成员函数 | |
| PayloadContributionModel () | |
Private 属性 | |
| void * | d_ { nullptr } |
友元 | |
| class | DataSwitch |
动态负载管理
在文件 payload_contribution_model.h 第 17 行定义.
| arcs::aubo_scope::PayloadContributionModel::PayloadContributionModel | ( | PayloadContributionModel & | f | ) |
引用了 PayloadContributionModel().
被这些函数引用 PayloadContributionModel() , 以及 PayloadContributionModel().


| arcs::aubo_scope::PayloadContributionModel::PayloadContributionModel | ( | PayloadContributionModel && | f | ) |
| arcs::aubo_scope::PayloadContributionModel::~PayloadContributionModel | ( | ) |
|
private |
| PayloadPtr arcs::aubo_scope::PayloadContributionModel::addPayload | ( | const std::string & | id_key, |
| const std::string & | suggested_name, | ||
| double | mass, | ||
| const std::vector< double > & | center_of_gravity ) |
Payload \chinese
向AuboScope的当前安装中添加一个负载。
添加后终端用户可选择该负载,其他AuboCap贡献(通过PayloadModel接口)也可 使用。该负载不可被终端用户或其他aubo_studio插件修改。
系统将根据指定的负载质量和重心自动计算惯性矩阵的默认估算值。如果有负载惯性矩阵 的实际数据,可以使用addPayload(String, String, Mass, Position,
InertiaMatrix)方法替代(可获得更好的机器人手臂性能)。
注意:指定的负载质量必须是连接到机器人工具输出法兰的负载总质量。
负载质量和重心坐标(CoG)的有效范围可通过RobotLimits接口获取,该接口 可通过RobotModel#getRobotLimits()访问。
| idKey | 用于标识此负载的键,不可为null或空字符串。该键仅对 此AuboCap有效,只需在此AuboCap中唯一,无需对其他aubo_studio插件"全局"唯一。 |
| suggestedName | 建议的负载名称,不可为null或空字符串。有效 名称必须匹配正则表达式[a-zA-Z][a-zA-Z0-9_]{0,14},总共15个字符。最终名称可 从返回的负载实例获取。 |
| mass | 连接到机器人工具输出法兰的负载总质量,不可为null。使 用SimpleValueFactory#createMass(double, Mass.Unit)创建。 |
| centerOfGravity | 负载的重心(CoG),也称为质心。定义为工具输出法兰中心与 所连接负载重心之间的偏移量。不可为null。使用PositionFactory 接口创建。 |
| PayloadAlreadyAddedException | 如果之前已使用相同的idKey标 识符添加过负载。使用getPayload(String)检查负载是否已添加到当前安装中。 使用updatePayload(String, Mass, Position)或 updatePayload(String, Mass, Position, InertiaMatrix)来更新负载。 |
| IllegalPayloadNameException | 如果建议的名称不匹配所需的正则表达式。 |
| IllegalMassException | 如果指定的质量不在AuboScope定义的有效范围内。 |
| IllegalCenterOfGravityException | 如果指定重心的任何值不在AuboScope定义 的有效范围内。 \endchinese \english |
Add a payload to the current installation in AuboScope.
This makes the payload selectable by the end user as well as available to other AuboCap contributions (through the PayloadModel interface). The payload is not modifiable by the end user or other aubo_studio plugins.
A default guess for the inertia matrix for the payload will be computed based on the specified payload mass and center of gravity. If data for the payload's inertia matrix is available, the method addPayload(String, String, Mass, Position, InertiaMatrix) can used instead (this might give better performance of the robot arm).
Note: The specified payload mass must be the total mass of the payload attached to the tool output flange of the robot.
The valid range for the payload mass and the coordinates of the center of gravity (CoG) are available through the RobotLimits interface which can be accessed with RobotModel#getRobotLimits() (an instance of the RobotModel interface can be retrieved through SystemAPI#getRobotModel()).
| idKey | The key to identify this payload by, not null nor an empty string. The key is for this AuboCap only, i.e. it only has to be unique for this AuboCap and not "globally" for other aubo_studio plugins. |
| suggestedName | Suggested name for the payload, not null nor an empty string. Valid names must match regex [a-zA-Z][a-zA-Z0-9_]{0,14} for a total of 15 characters. The final name can be retrieved from the returned payload instance. |
| mass | The total mass of the payload attached to the tool output flange of the robot, not null. Create it using SimpleValueFactory#createMass(double, Mass.Unit). |
| centerOfGravity | The center of gravity (CoG), also referred to as center of mass, for the payload. It is defined as the offset between the center of the tool output flange and the center of gravity of the attached payload. Cannot be null. Create it using the PositionFactory interface. |
| PayloadAlreadyAddedException | If a payload has previously been added using the same idKey identifier. Use getPayload(String) to check if the payload has already been added to the current installation. Use updatePayload(String, Mass,
Position) or updatePayload(String, Mass,
Position, InertiaMatrix) to update the payload if the payload parameters have changed. |
| IllegalPayloadNameException | If the suggested name does not match required regex. |
| IllegalMassException | If the specified mass is not inside the valid range as defined by AuboScope. |
| IllegalCenterOfGravityException | If any of the values of the specified center of gravity are not inside the valid range as defined by AuboScope. \endenglish |
| PayloadPtr arcs::aubo_scope::PayloadContributionModel::addPayload | ( | const std::string & | id_key, |
| const std::string & | suggested_name, | ||
| double | mass, | ||
| const std::vector< double > & | center_of_gravity, | ||
| const std::vector< double > & | inertiaMatrix ) |
Payload \chinese
向AuboScope的当前安装中添加一个包含惯性矩阵的负载。
添加后终端用户可选择该负载,其他AuboCap贡献(通过PayloadModel接口)也可 使用。该负载不可被终端用户或其他aubo_studio插件修改。
如果没有负载惯性矩阵的数据,请改用addPayload(String, String, Mass,
Position, InertiaMatrix)方法。
注意:指定的负载质量必须是连接到机器人工具输出法兰的负载总质量。
负载质量和重心坐标(CoG)的有效范围可通过RobotLimits接口获取,该接口 可通过RobotModel#getRobotLimits()访问。
| idKey | 用于标识此负载的键,不可为null或空字符串。该键仅对 此AuboCap有效。 |
| suggestedName | 建议的负载名称,不可为null或空字符串。 |
| mass | 负载总质量,不可为null。 |
| centerOfGravity | 负载的重心(CoG),不可为null。 |
| inertiaMatrix | 负载的惯性矩阵,定义在以负载重心为中心的坐标系中,坐标轴与 工具输出法兰坐标系对齐。不可为null。 |
| PayloadAlreadyAddedException | 如果之前已使用相同的idKey标 识符添加过负载。 |
| IllegalPayloadNameException | 如果建议的名称不匹配所需的正则表达式。 |
| IllegalMassException | 如果指定的质量不在有效范围内。 |
| IllegalCenterOfGravityException | 如果指定重心的任何值不在有效范围内。 |
| IllegalInertiaMatrixException | 如果指定惯性矩阵的任何值不在有效范围内。 \endchinese \english |
Add a payload to the current installation in AuboScope.
This makes the payload selectable by the end user as well as available to other AuboCap contributions (through the PayloadModel interface). The payload is not modifiable by the end user or other aubo_studio plugins.
Use the addPayload(String, String, Mass, Position,
InertiaMatrix) method instead if data for the payload's inertia matrix is not available.
Note: The specified payload mass must be the total mass of the payload attached to the tool output flange of the robot.
The valid range for the payload mass and the coordinates of the center of gravity (CoG) are available through the RobotLimits interface which can be accessed with RobotModel#getRobotLimits() (an instance of the RobotModel interface can be retrieved through SystemAPI#getRobotModel()).
| idKey | The key to identify this payload by, not null nor an empty string. The key is for this AuboCap only, i.e. it only has to be unique for this AuboCap and not "globally" for other aubo_studio plugins. |
| suggestedName | Suggested name for the payload, not null nor an empty string. Valid names must match regex [a-zA-Z][a-zA-Z0-9_]{0,14} for a total of 15 characters. The final name can be retrieved from the returned payload instance. |
| mass | The total mass of the payload attached to the tool output flange of the robot, not null. Create it using SimpleValueFactory#createMass(double, Mass.Unit). |
| centerOfGravity | The center of gravity (CoG), also referred to as center of mass, for the payload. It is defined as the offset between the center of the tool output flange and the center of gravity of the attached payload. Cannot be null. Create it using the PositionFactory interface. |
| inertiaMatrix | The inertia matrix of the payload, defined in a coordinate system with center at the payload's center of gravity and the axes aligned with the tool output flange coordinate system (axes). Cannot be null. Create it using double, double,
double, double, double, MomentOfInertia.Unit). |
| PayloadAlreadyAddedException | If a payload has previously been added using the same idKey identifier. Use getPayload(String) to check if the payload has already been added to the current installation. Use updatePayload(String, Mass,
Position) or updatePayload(String, Mass,
Position, InertiaMatrix) to update the payload if the payload parameters have changed. |
| IllegalPayloadNameException | If the suggested name does not match required regex. |
| IllegalMassException | If the specified mass is not inside the valid range as defined by AuboScope. |
| IllegalCenterOfGravityException | If any of the values of the specified center of gravity are not inside the valid range as defined by AuboScope. |
| IllegalInertiaMatrixException | If any of the values of the specified inertia matrix are not inside the valid range as defined by AuboScope. \endenglish |
| PayloadPtr arcs::aubo_scope::PayloadContributionModel::getPayload | ( | const std::string & | id_key | ) |
Payload \chinese 返回此前由此AuboCap使用相同idKey标识符添加的负载。使用此方法验证 负载是否存在于当前安装中。
| idKey | 用于标识此负载的键,不可为null或空字符串。 |
idKey 标识符的)负载,则返回null。 \endchinese \english Returns the payload previously added by this AuboCap using the same idKey identifier. Use this to verify if the payload is present in the current installation.| idKey | The key to identify this payload by, not null nor an empty string. |
null if no payload exists in current installation (with the specified idKey identifier). \endenglish | void arcs::aubo_scope::PayloadContributionModel::removePayload | ( | const std::string & | id_key | ) |
\chinese 从此AuboCap中移除已添加的负载。使用该负载的程序节点将变为未定义状态,因为负载 不再可解析。
| idKey | 添加负载时使用的标识符键,不可为null或空字符串。 |
| PayloadNotFoundException | 如果当前安装中不存在对应idKey 标识符的负载。 \endchinese \english Remove a payload added by this AuboCap from AuboScope. Program nodes using the payload will be become undefined because the payload is no longer resolvable. |
| idKey | The identifier key used to add the payload with, not nor an empty string. |
| PayloadNotFoundException | If no payload exists with the provided idKey identifier in the current installation. \endenglish |
| void arcs::aubo_scope::PayloadContributionModel::updatePayload | ( | const std::string & | id_key, |
| double | mass, | ||
| const std::vector< double > & | center_of_gravity ) |
Payload \chinese
更新此AuboCap已添加负载的质量和重心(CoG)。
注意:如果已为负载指定了惯性矩阵,调用此方法将用基于新的负载质量和重心 计算的默认估算值替换(覆盖)它。为避免覆盖现有惯性矩阵(或更新现有惯性矩阵), 请改用updatePayload(String, Mass, Position, InertiaMatrix)方法。
| idKey | 用于标识负载的键,不可为null或空字符串。调用此方法 前必须已使用相同的键添加过负载。 |
| mass | 负载总质量,不可为null。使用 SimpleValueFactory#createMass(double, Mass.Unit)创建。 |
| centerOfGravity | 负载的重心,不可为null。使用 PositionFactory接口创建。 |
| PayloadNotFoundException | 如果当前安装中不存在对应idKey 标识符的负载。 |
| IllegalMassException | 如果指定的质量不在AuboScope定义的有效范围内。 |
| IllegalCenterOfGravityException | 如果指定重心的任何值不在有效范围内。 \endchinese \english |
Update the mass and center of gravity (CoG) of an existing payload added by this AuboCap.
Note: If an inertia matrix has been specified for the payload, calling this method will replace (overwrite) it with a computed default guess based the new specified payload mass and center of gravity. To avoid overwriting an existing inertia matrix (or to update an existing inertia matrix), instead use the method updatePayload(String, Mass, Position, InertiaMatrix).
| idKey | The key to identify the payload, not null nor an empty string. A payload must have been added using the same key prior to calling this method. |
| mass | The total mass of the payload attached to the tool output flange of the robot, not null. Create it using SimpleValueFactory#createMass(double, Mass.Unit). |
| centerOfGravity | The center of gravity of the payload, not . Create it using the PositionFactory interface. |
| PayloadNotFoundException | If no payload exists with the provided idKey identifier in the current installation. |
| IllegalMassException | If the specified mass is not inside the valid range as defined by AuboScope. |
| IllegalCenterOfGravityException | If any of the values of the specified center of gravity are not inside the valid range as defined by AuboScope. \endenglish |
| void arcs::aubo_scope::PayloadContributionModel::updatePayload | ( | const std::string | id_key, |
| double | mass, | ||
| const std::vector< double > & | center_of_gravity, | ||
| const std::vector< double > & | inertia_matrix ) |
\chinese 更新此AuboCap已添加负载的质量、重心(CoG)和惯性矩阵。
| idKey | 用于标识负载的键,不可为null或空字符串。调用此方法 前必须已使用相同的键添加过负载。 |
| mass | 负载总质量,不可为null。使用 SimpleValueFactory#createMass(double, Mass.Unit)创建。 |
| centerOfGravity | 负载的重心,不可为null。使用 PositionFactory接口创建。 |
| inertiaMatrix | 负载的惯性矩阵,不可为null。 |
| PayloadNotFoundException | 如果当前安装中不存在对应idKey 标识符的负载。 |
| IllegalMassException | 如果指定的质量不在有效范围内。 |
| IllegalCenterOfGravityException | 如果指定重心的任何值不在有效范围内。 |
| IllegalInertiaMatrixException | 如果指定惯性矩阵的任何值不在有效范围内。 \endchinese \english Update the mass, center of gravity (CoG) and inertia matrix of an existing payload added by this AuboCap. |
| idKey | The key to identify the payload, not null nor an empty string. A payload must have been added using the same key prior to calling this method. |
| mass | The total mass of the payload attached to the tool output flange of the robot, not null. Create it using SimpleValueFactory#createMass(double, Mass.Unit). |
| centerOfGravity | The center of gravity of the payload, not . Create it using the PositionFactory interface. |
| inertiaMatrix | The inertia matrix of the payload, not null. Create it using double, double,
double, double, double, MomentOfInertia.Unit) |
| PayloadNotFoundException | If no payload exists with the provided idKey identifier in the current installation. |
| IllegalMassException | If the specified mass is not inside the valid range as defined by AuboScope. |
| IllegalCenterOfGravityException | If any of the values of the specified center of gravity are not inside the valid range as defined by AuboScope. |
| IllegalInertiaMatrixException | If any of the values of the specified inertia matrix are not inside the valid range as defined by AuboScope. \endenglish |
|
friend |
|
private |
在文件 payload_contribution_model.h 第 414 行定义.