Skip to content

CPP API Reference

Types (Classes, Structs & Namespaces)


AudioData (struct)

Audio data structure.
Audio data structure used to encapsulate audio data.

Member Variables

Name Type Description
header Header Message header.
type std::string Audio type.
Audio data type identifier, possible values include:
"waken_up": Wake-up event, format is json, data is json string
"denoise_chunk": Denoised audio data, format is pcm, data is pcm data
"vad_begin": Voice Activity Detection start marker (data is empty)
"vad_chunk": Audio data during voice activity detection, format is pcm, data is pcm data
"vad_end": Voice Activity Detection end marker (data is empty)
format std::string Audio format.
Audio data format description, for example:
"pcm": Sample rate 16000Hz, bit depth 16bit, mono
"json": UTF-8 encoded json text
data std::vector< uint8_t > Data packet.
Binary data packet, the specific format is specified by the format field. For pcm format, the data size for each 80ms is 2560 bytes. For json format, the data size may be the length of json text or empty.

BBox (struct)

None

x1

int BBox::x1() const
Item Description
Function None
Parameters None
Return None

y1

int BBox::y1() const
Item Description
Function None
Parameters None
Return None

x2

int BBox::x2() const
Item Description
Function None
Parameters None
Return None

y2

int BBox::y2() const
Item Description
Function None
Parameters None
Return None

area

float BBox::area() const
Item Description
Function None
Parameters None
Return None

center

cv::Point2f BBox::center() const
Item Description
Function None
Parameters None
Return None

Member Variables

Name Type Description
rect cv::Rect None
cls std::pair< int, float > None

BmsInfo (struct)

Bms information.

Member Variables

Name Type Description
voltage float Voltage (V)
current float Current (A)
battery_level float Battery level (0-100%)
temperature float Temperature (℃)
charging_status bool Charging status:False: not charging, True: charging
health_status bool Health status:False: good, True: bad
capacity float Remaining capacity (Ah)

CameraInfo (struct)

Camera calibration information.
Complete camera calibration data including intrinsic parameters, distortion coefficients, rectification, and projection matrices. Compatible with ROS 2 sensor_msgs/CameraInfo.

Member Variables

Name Type Description
header Header Message header.
Contains timestamp and camera coordinate frame ID (e.g., "camera_optical_frame").
height uint32_t Image height (pixels)
Vertical resolution of images produced by this camera at calibration time.
width uint32_t Image width (pixels)
Horizontal resolution of images produced by this camera at calibration time.
distortion_model std::string Distortion model name.
Specifies the lens distortion model used. Common values:
"plumb_bob": Brown-Conrady model with radial (k1,k2,k3) and tangential (p1,p2) distortion
"rational_polynomial": Extended model with additional parameters
"equidistant": Fisheye lens model
d std::vector< double > Distortion coefficients (D)
Vector of distortion parameters, size and interpretation depend on distortion_model. For "plumb_bob": [k1, k2, p1, p2, k3] (5 parameters)
k1, k2, k3: Radial distortion coefficients
p1, p2: Tangential distortion coefficients
k std::array< double, 9 > Intrinsic camera matrix (K)
3×3 matrix in row-major order, maps 3D points in camera frame to 2D pixel coordinates: [fx0cx]
[0fycy]
[001]
fx, fy: Focal lengths in pixel units
cx, cy: Principal point (optical center) in pixels
r std::array< double, 9 > Rectification matrix (R)
3×3 rotation matrix in row-major order. For stereo cameras: rotates left/right camera image planes to be coplanar and row-aligned. For monocular cameras: typically identity matrix (no rectification needed).
p std::array< double, 12 > Projection matrix (P)
3×4 matrix in row-major order, projects 3D points to rectified image coordinates: [fx'0cx'Tx]
[0fy'cy'Ty]
[0010]
fx', fy': Rectified focal lengths
cx', cy': Rectified principal point
Tx, Ty: Stereo baseline (Tx = -fx' × baseline for right camera)
binning_x uint32_t Horizontal binning factor.
Number of camera pixels combined horizontally for each output pixel. Values: 0 or 1 = no binning, 2 = 2×1 binning, etc.
binning_y uint32_t Vertical binning factor.
Number of camera pixels combined vertically for each output pixel. Values: 0 or 1 = no binning, 2 = 1×2 binning, etc.
roi RegionOfInterest Region of interest (ROI)
Specifies a sub-window within the full sensor resolution.
camera_type std::string Camera type identifier.
Optional field specifying camera type or model. Examples: "monocular", "stereo_left", "stereo_right", "depth"
T std::vector< double > Additional transform matrix.
Optional transformation matrix for vendor-specific or extended calibration data. Size and interpretation depend on implementation.

CollisionCheckOption (struct)

Collision detection enable/disable configuration.
This structure provides fine-grained control over collision checking during motion planning and execution. It supports independent toggling of self-collision detection (robot links colliding with each other) and environment collision detection (robot colliding with obstacles or workspace boundaries).
Disabling collision checks improves computational performance but may result in unsafe trajectories. Use with caution in controlled environments.

set_disable_self_collision_check

void galbot::sdk::g1::CollisionCheckOption::set_disable_self_collision_check(bool disable)
Item Description
Function Enable or disable self-collision detection.
Parameters disable: true to disable self-collision checking, false to enable
Return None

set_disable_env_collision_check

void galbot::sdk::g1::CollisionCheckOption::set_disable_env_collision_check(bool disable)
Item Description
Function Enable or disable environment collision detection.
Parameters disable: true to disable environment collision checking, false to enable
Return None

get_disable_self_collision_check

bool galbot::sdk::g1::CollisionCheckOption::get_disable_self_collision_check() const
Item Description
Function Check if self-collision detection is disabled.
Parameters None
Return true if self-collision detection is currently disabled, false if enabled

get_disable_env_collision_check

bool galbot::sdk::g1::CollisionCheckOption::get_disable_env_collision_check() const
Item Description
Function Check if environment collision detection is disabled.
Parameters None
Return true if environment collision detection is currently disabled, false if enabled

print

void galbot::sdk::g1::CollisionCheckOption::print() const
Item Description
Function Print collision detection configuration to standard output.
Parameters None
Return None

DepthData (struct)

Depth image data structure.
Contains compressed depth image data from depth cameras or RGB-D sensors. Compatible with ROS 2 sensor_msgs/CompressedImage format with depth extensions.

convert_to_cv2_mat

std::shared_ptr<cv::Mat> galbot::sdk::g1::DepthData::convert_to_cv2_mat()
Item Description
Function Convert depth data to OpenCV Mat.
Parameters None
Return std::shared_ptr Smart pointer to decoded depth image on success, nullptr on failure

Member Variables

Name Type Description
header Header Message header.
Contains acquisition timestamp and camera coordinate frame ID.
height uint32_t Image height (pixels)
Number of rows in the depth image.
width uint32_t Image width (pixels)
Number of columns in the depth image.
format std::string Image format descriptor.
Specifies depth encoding and compression format. Example: "16UC1; compressedDepth png" (16-bit unsigned, 1 channel, PNG compressed)
data std::vector< uint8_t > Depth image data.
Binary blob containing raw or compressed depth image data.
depth_scale uint32_t Depth scale factor.
Quantization factor for converting pixel values to metric depth. True depth (meters) = pixel_value / depth_scale Example: depth_scale = 1000 means pixel values are in millimeters

DetectionAndSegmentationResult (struct)

None

SENSORDATA_POINTER_TYPEDEFS

DetectionAndSegmentationResult::SENSORDATA_POINTER_TYPEDEFS(DetectionAndSegmentationResult)
Item Description
Function None
Parameters None
Return None

DetectionAndSegmentationResult

DetectionAndSegmentationResult::DetectionAndSegmentationResult()
Item Description
Function None
Parameters None
Return None

DetectionAndSegmentationResult

DetectionAndSegmentationResult::DetectionAndSegmentationResult(const cv::Rect &box, const std::string &name, const int index, const float conf, const std::vector< cv::Point2f > &kps=std::vector< cv::Point2f >(), const std::vector< cv::Point > &poly=std::vector< cv::Point >())
Item Description
Function None
Parameters None
Return None

printInfo

void DetectionAndSegmentationResult::printInfo(std::ostream &os, bool showPolygon=false) const
Item Description
Function None
Parameters None
Return None

Member Variables

Name Type Description
bbox cv::Rect None
className std::string None
classIndex int None
confidence float None
keypoints std::vector< cv::Point2f > None
polygon std::vector< cv::Point > None

DetectionResult (struct)

None

SENSORDATA_POINTER_TYPEDEFS

DetectionResult::SENSORDATA_POINTER_TYPEDEFS(DetectionResult)
Item Description
Function None
Parameters None
Return None

addResult

void DetectionResult::addResult(const cv::Rect &box, const std::string &className, int classIndex, float confidence)
Item Description
Function None
Parameters None
Return None

addResult

void DetectionResult::addResult(const cv::Rect &box, const std::vector< cv::Point2f > &kps, const std::string &className, int classIndex, float confidence)
Item Description
Function None
Parameters None
Return None

addPose

void DetectionResult::addPose(const Eigen::Matrix4f &pose)
Item Description
Function None
Parameters None
Return None

addKeypoints

void DetectionResult::addKeypoints(const std::vector< cv::Point2f > &kps)
Item Description
Function None
Parameters None
Return None

addPointCloud

void DetectionResult::addPointCloud(const PointCloudPtr &cloud)
Item Description
Function None
Parameters None
Return None

setRunningInfo

void DetectionResult::setRunningInfo(const std::string &info)
Item Description
Function None
Parameters None
Return None

addClassMask

void DetectionResult::addClassMask(const cv::Mat &mask)
Item Description
Function None
Parameters None
Return None

addInstanceMask

void DetectionResult::addInstanceMask(const cv::Mat &mask)
Item Description
Function None
Parameters None
Return None

clear

void DetectionResult::clear()
Item Description
Function None
Parameters None
Return None

getResultInfo

std::string DetectionResult::getResultInfo()
Item Description
Function None
Parameters None
Return None

copyFrom

void DetectionResult::copyFrom(const DetectionResult &other)
Item Description
Function None
Parameters None
Return None

DetectionResult

DetectionResult::DetectionResult()
Item Description
Function None
Parameters None
Return None

Member Variables

Name Type Description
timestamp_ns EIGEN_MAKE_ALIGNED_OPERATOR_NEW int64_t None
sensorName std::string None
resultImage cv::Mat None
resultPointCloud std::vector< PointCloudPtr > None
detectionAndSegmentationResults std::vector< DetectionAndSegmentationResult > None
boundingBoxes std::vector< cv::Rect > None
classNames std::vector< std::string > None
classIndices std::vector< int > None
confidences std::vector< float > None
ocrString std::vector< std::string > None
targetPoses std::vector< Eigen::Matrix4f > None
keypoints std::vector< std::vector< cv::Point2f > > None
runningInfo std::string None
classMask cv::Mat None
instanceMask cv::Mat None
garbage_result GarbageResult::Ptr None
object6DPoses std::map< std::string, std::vector< Eigen::Matrix4f > > None
grasp_pose_result std::vector< std::vector< float > > None
targetPointPoses std::vector< Eigen::Matrix4f > None
preTargetPointPoses std::vector< Eigen::Matrix4f > None
ocrPointPoses std::vector< Eigen::Matrix4f > None
ocrLabelImage std::map< std::string, std::vector< cv::Mat > > None
ocrResults std::map< std::string, Eigen::Matrix4f > None

DeviceInfo (struct)

Device information structure.
Describes basic information about the robot or module, used for device management, logging, diagnostics, and maintenance tracking.

Member Variables

Name Type Description
model std::string Device model name or identifier
serial_number std::string Unique serial number for device identification
firmware_version std::string System firmware version string (e.g., "1.2.3")
hardware_version std::string Hardware version or revision number
manufacturer std::string Manufacturer name or company identifier

EffortInfo (struct)

6D wrench information (force + torque)
Represents a 6-DOF wrench (force and torque) typically measured by a force/torque sensor. Also known as a spatial force or generalized force.

Member Variables

Name Type Description
timestamp_ns int64_t Measurement timestamp (nanoseconds since epoch)
force Vector3 Force vector (Newtons): [fx, fy, fz]
torque Vector3 Torque vector (Newton-meters): [tx, ty, tz]

Error (struct)

Error information.
Describes an error from a single module or component, including error code and human-readable description for debugging and diagnostics.

Error

galbot::sdk::g1::Error::Error(std::string commpent_input, int error_code_input, std::string description_input)
Item Description
Function Constructor.
Parameters commpent_input: Fault module or component name
error_code_input: Numerical error code
description_input: Human-readable error description
Return None

Member Variables

Name Type Description
commpent std::string Fault module or component name (note: field name contains typo but preserved for API compatibility)
error_code uint64_t Numerical error code for programmatic error handling
description std::string Human-readable error description

ErrorInfo (struct)

Error information collection.
Contains a timestamped collection of error messages from multiple modules or components.

Member Variables

Name Type Description
timestamp_ns int64_t Timestamp when errors were collected (nanoseconds since epoch)
error_vec std::vector< Error > Vector of error messages from various system components

ForceData (struct)

Force sensor data.
Contains timestamped force and torque measurements from a 6-axis force/torque sensor, typically mounted at robot wrists or tool interfaces.

Member Variables

Name Type Description
timestamp_ns int64_t Measurement timestamp (nanoseconds since epoch)
force Vector3 Force vector (Newtons): [fx, fy, fz]
torque Vector3 Torque vector (Newton-meters): [tx, ty, tz]

g1 (namespace)

Namespace for Galbot G1 humanoid robot.

Member Variables

Name Type Description
g_actuate_type_map const std::unordered_map< std::string, ActuateType > Whole-body planning actuation type mapping table.
This static map provides a string-to-enum conversion for ActuateType enumeration values, enabling actuation type selection from configuration files or function parameters:
"with_chain_only" -> ACTUATE_WITH_CHAIN_ONLY : Execute kinematic chain actions only (arms only)
"with_torso" -> ACTUATE_WITH_TORSO : Include torso joint actuation
"with_leg" -> ACTUATE_WITH_LEG : Include leg joint actuation
"type_num" -> ACTUATE_TYPE_NUM : Total number of actuation types (for iteration)
This map is used for runtime string-based actuation type resolution.
ActuateType
status_string_map_ std::unordered_map< MotionStatus, std::string > MotionStatus enumeration to human-readable string mapping table.
This static map converts MotionStatus enumeration values to descriptive strings for logging, debugging, and user interface display purposes.
Status mappings:
MotionStatus::SUCCESS -> "SUCCESS: Execution succeeded"
MotionStatus::TIMEOUT -> "TIMEOUT: Execution timeout"
MotionStatus::FAULT -> "FAULT: Fault occurred, unable to continue execution"
MotionStatus::INVALID_INPUT -> "INVALID_INPUT: Input parameters do not meet requirements"
MotionStatus::INIT_FAILED -> "INIT_FAILED: Internal communication component creation failed"
MotionStatus::IN_PROGRESS -> "IN_PROGRESS: In motion but target not yet reached"
MotionStatus::STOPPED_UNREACHED -> "STOPPED_UNREACHED: Motion stopped before reaching target"
MotionStatus::DATA_FETCH_FAILED -> "DATA_FETCH_FAILED: Failed to retrieve required data"
MotionStatus::PUBLISH_FAIL -> "PUBLISH_FAIL: Failed to transmit command/data"
MotionStatus::COMM_DISCONNECTED -> "COMM_DISCONNECTED: Communication link disconnected"
MotionStatus::STATUS_NUM -> "STATUS_NUM: Total number of status enumerations"
MotionStatus::UNSUPPORTED_FUNCRION -> "UNSUPPORTED_FUNCRION: Function not supported yet"
The map is primarily used by status_to_string() method.
MotionStatus
status_to_string()
default_param std::shared_ptr< Parameter > Default parameter object for motion planning.
Provides a shared default Parameter instance with standard configuration values. Can be used when custom parameters are not required.
Parameter

Enums

Navigation task execution status enumeration.
Defines the possible outcomes when executing navigation commands such as moving to a goal position or following a path.

Enum Value Description
SUCCESS Execution succeeded, navigation task completed as expected
FAIL Execution failed due to unspecified error
TIMEOUT Execution timeout, task did not complete within allowed time
INVALID_INPUT Input parameters do not meet requirements or are out of valid range
MODE_ERR Current mode does not support this operation
COMM_ERR Communication error occurred during execution
WAIT_INITIALIZED Waiting for system initialization, navigation system not ready

Navigation task current state enumeration.
Represents the current state of an active or completed navigation task, as reported by the navigation system. Used for polling during non-blocking navigation to detect RUNNING, SUCCESS, or FAILED and exit error logic in time.

Enum Value Description
UNKNOWN Task state unknown or not yet reported
RUNNING Navigation task is in progress
SUCCESS Navigation task completed successfully
FAILED Navigation task failed

ControlStatus

Control command execution status enumeration.
Represents the execution status of robot control commands, including joint control, end-effector control, and other motion control operations.

Enum Value Description
SUCCESS Execution succeeded, command completed with valid result
TIMEOUT Execution timeout, task not completed within specified time limit
FAULT Fault occurred, system detected anomaly and aborted execution
INVALID_INPUT Input parameters invalid or not meeting interface requirements
INIT_FAILED Initialization failed, internal communication or dependent component creation failed
IN_PROGRESS Command is executing but has not reached target state
STOPPED_UNREACHED Stopped during execution without reaching target position or state
DATA_FETCH_FAILED Data retrieval failed during operation, unable to read required state
PUBLISH_FAIL Control or state data publication failed, command may not be transmitted
COMM_DISCONNECTED Communication connection lost, cannot continue execution
STATUS_NUM Total number of status enumerations (for boundary checking or array sizing)

SensorStatus

Sensor execution status enumeration.
Represents the status of sensor data acquisition and processing operations, applicable to cameras, lidar, IMU, force sensors, and other sensor types.

Enum Value Description
SUCCESS Execution succeeded, sensor data valid and operation completed
TIMEOUT Execution timeout, data acquisition or operation not completed within specified time limit
FAULT Fault occurred, sensor detected anomaly and cannot continue normal operation
INVALID_INPUT Input parameters invalid or not meeting interface requirements
INIT_FAILED Initialization failed, internal communication or dependent component creation failed
IN_PROGRESS Operation in progress but not yet completed
STOPPED_UNREACHED Stopped during execution without completing expected operation
DATA_FETCH_FAILED Data acquisition or reading failed, sensor may be disconnected or malfunctioning
PUBLISH_FAIL Data transmission or reporting failed, unable to publish sensor data
COMM_DISCONNECTED Sensor communication connection lost, no data available
STATUS_NUM Total number of status enumerations (for boundary checking or array sizing)

MotionStatus

Robot motion execution status enumeration.
Represents the execution status of robot motion commands, including trajectory following, pose reaching, and other motion planning operations.

Enum Value Description
SUCCESS Execution succeeded, motion reached expected target position/pose
TIMEOUT Execution timeout, motion not completed within specified time limit
FAULT Fault occurred, motion cannot continue due to hardware or safety issue
INVALID_INPUT Input parameters invalid or not meeting interface requirements
INIT_FAILED Internal initialization failed, communication component or resource creation failed
IN_PROGRESS Motion in progress but has not reached target yet
STOPPED_UNREACHED Stopped during motion without reaching target position/pose
DATA_FETCH_FAILED Data retrieval failed, e.g., sensor or state reading failure
PUBLISH_FAIL Data transmission or command delivery failed, motion command may not be executed
COMM_DISCONNECTED Communication disconnected or control node unavailable
STATUS_NUM Total number of status enumerations (for boundary checking or array sizing)
UNSUPPORTED_FUNCRION Function not yet supported, called interface or operation not implemented (note: typo in enum name preserved for API compatibility)

LogLevel

Log level enumeration.
Represents the severity level of log messages.

Enum Value Description
TRACE Trace level, detailed information for debugging
DEBUG Debug level, diagnostic information for developers
INFO Info level, general operational messages
WARN Warn level, potentially harmful situations
ERROR Error level, error events that might still allow the application to continue running
CRITICAL Critical level, severe error events that lead to application termination

TrajectoryControlStatus

Robot trajectory execution status enumeration.
Represents the real-time execution status when the robot follows a pre-planned trajectory consisting of multiple waypoints.

Enum Value Description
INVALID_INPUT Input parameters do not meet requirements, trajectory cannot be executed
RUNNING Trajectory is currently executing, not yet completed
COMPLETED Trajectory execution completed successfully, reached final target point
STOPPED_UNREACHED Stopped during trajectory execution without reaching endpoint
ERROR Error occurred, trajectory execution cannot continue
DATA_FETCH_FAILED Execution data retrieval failed, e.g., joint state or sensor feedback unavailable
STATUS_NUM Total number of status enumerations (for boundary checking or array sizing)

JointGroup

Joint group enumeration describing different functional modules of the robot.
Groups robot joints into functional units for coordinated control and motion planning. Each group typically represents a kinematic chain or end-effector subsystem.

Enum Value Description
HEAD Head joint group, typically for pan-tilt or vision orientation
LEFT_ARM Left arm joint group, multi-DOF manipulator chain
RIGHT_ARM Right arm joint group, multi-DOF manipulator chain
LEG Leg joint group, for humanoid or legged robots
CHASSIS Chassis joint group, mobile base or lower platform
LEFT_GRIPPER Left gripper joint group, typically 1-2 DOF parallel jaw gripper
RIGHT_GRIPPER Right gripper joint group, typically 1-2 DOF parallel jaw gripper
LEFT_SUCTION_CUP Left suction cup joint group, vacuum-based end-effector
RIGHT_SUCTION_CUP Right suction cup joint group, vacuum-based end-effector
LEFT_DEXHAND Left dexhand joint group, dexterous hand end-effector
RIGHT_DEXHAND Right dexhand joint group, dexterous hand end-effector
JOINT_GROUP_NUM Total number of joint group enumerations (for boundary checking or array sizing)

SensorType

Sensor type enumeration describing various sensors on the robot.
Identifies different sensor types available on the robot for perception, localization, and manipulation tasks.

Enum Value Description
HEAD_LEFT_CAMERA Head left camera, typically RGB camera for stereo vision
HEAD_RIGHT_CAMERA Head right camera, typically RGB camera for stereo vision
LEFT_ARM_CAMERA Left arm camera, mounted on left manipulator for visual servoing
RIGHT_ARM_CAMERA Right arm camera, mounted on right manipulator for visual servoing
LEFT_ARM_DEPTH_CAMERA Left arm depth camera, provides RGB-D data for left arm workspace
RIGHT_ARM_DEPTH_CAMERA Right arm depth camera, provides RGB-D data for right arm workspace
BASE_LIDAR Base lidar, laser scanner for 2D/3D environment mapping and obstacle detection
TORSO_IMU Torso IMU (Inertial Measurement Unit), measures acceleration and angular velocity
BASE_ULTRASONIC Base ultrasonic sensor array, for proximity detection and collision avoidance
SENSOR_NUM Total number of sensor enumerations (for boundary checking or array sizing)

UltrasonicType

Chassis ultrasonic sensor probe enumeration (8 directions)
Identifies individual ultrasonic sensors arranged around the mobile base chassis for omnidirectional obstacle detection and proximity sensing.

Enum Value Description
FRONT_LEFT Front left ultrasonic sensor
FRONT_RIGHT Front right ultrasonic sensor
RIGHT_LEFT Right side front ultrasonic sensor
RIGHT_RIGHT Right side rear ultrasonic sensor
BACK_LEFT Back left ultrasonic sensor
BACK_RIGHT Back right ultrasonic sensor
LEFT_LEFT Left side front ultrasonic sensor
LEFT_RIGHT Left side rear ultrasonic sensor
ULTRASONIC_NUM Total number of ultrasonic sensors (for boundary checking or array sizing)

GalbotOneFoxtrotSensor

Force sensor enumeration describing robot wrist force sensors.
Identifies force/torque sensors mounted at the robot's wrist joints for force-controlled manipulation and contact detection.

Enum Value Description
LEFT_WRIST_FORCE Left wrist force/torque sensor, typically 6-axis (3 forces + 3 torques)
RIGHT_WRIST_FORCE Right wrist force/torque sensor, typically 6-axis (3 forces + 3 torques)
FORCE_NUM Total number of force sensor enumerations (for boundary checking or array sizing)

ControllerName

Controller name enumeration.
Identifies the available controllers for different robot parts. Used for switching active controllers.

Enum Value Description
CHASSIS_POSE_CTRL Chassis pose controller
CHASSIS_TWIST_CTRL Chassis twist controller
LEG_PVT_BYPASS_CTRL Leg PVT bypass controller
LEG_PVT_CTRL Leg PVT controller
HEAD_PVT_BYPASS_CTRL Head PVT bypass controller
HEAD_PVT_CTRL Head PVT controller
LEFT_ARM_PVT_BYPASS_CTRL Left arm PVT bypass controller
LEFT_ARM_PVT_CTRL Left arm PVT controller
RIGHT_ARM_PVT_BYPASS_CTRL Right arm PVT bypass controller
RIGHT_ARM_PVT_CTRL Right arm PVT controller
LEFT_GRIPPER_CTRL Left gripper controller
RIGHT_GRIPPER_CTRL Right gripper controller
LEFT_DEXHAND_CTRL Left dexhand controller
RIGHT_DEXHAND_CTRL Right dexhand controller
CONTROLLER_NAME_NUM Total number of controller names

ChainType

Robot kinematic chain type enumeration.
Identifies different kinematic chains in the robot structure for forward/inverse kinematics calculations and motion planning.

Enum Value Description
HEAD Head kinematic chain, from base/torso to head end-effector
LEFT_ARM Left arm kinematic chain, from base/torso to left end-effector
RIGHT_ARM Right arm kinematic chain, from base/torso to right end-effector
LEG Leg kinematic chain, for legged locomotion
TORSO Torso kinematic chain, connects base to upper body
CHAIN_NUM Total number of kinematic chains (for boundary checking or array sizing)

ActuateType

Actuation type enumeration.
Specifies which kinematic chains should be actuated during motion planning and execution. This controls whether the robot uses only the target arm, or also involves torso or leg motion.

Enum Value Description
ACTUATE_WITH_CHAIN_ONLY Actuate only the target joint chain (e.g., arm only), base remains fixed
ACTUATE_WITH_TORSO Actuate target joint chain and torso for extended workspace
ACTUATE_WITH_LEG Actuate target joint chain and legs for mobile manipulation
ACTUATE_TYPE_NUM Total number of actuation types (for boundary checking or array sizing)

SeedType

IK solver seed type enumeration.
Specifies the initialization strategy for inverse kinematics (IK) solvers. Different seed types affect convergence speed and solution quality.

Enum Value Description
RANDOM_SEED Random seed, generates random initial joint configurations
RANDOM_PROGRESSIVE_SEED Random progressive seed, tries multiple random seeds iteratively (recommended for robustness)
USER_DEFINED_SEED User-defined seed, uses explicitly provided initial joint configuration
SEED_TYPE_NUM Total number of seed types (for boundary checking or array sizing)

ReferenceFrame

Reference frame enumeration.
Specifies the coordinate frame in which poses, positions, or trajectories are expressed. Note: This is a plain enum (not enum class) for C-style compatibility.

Enum Value Description
FRAME_WORLD World/global coordinate frame, fixed reference frame
FRAME_BASE Robot base coordinate frame, attached to mobile base

SUCTION_ACTION_STATE

Suction cup action state enumeration.
Represents the operational state of a vacuum suction cup end-effector, tracking the suction process from idle to success or failure.

Enum Value Description
suction_action_idle Idle state, vacuum not activated
suction_action_sucking Suction in progress, attempting to grasp object
suction_action_success Suction successful, pressure decreased indicating secure grasp
suction_action_failed Suction failed, pressure did not decrease (no object or seal failure)

galbot_perception_types.hpp (file)

None

Enums

PerceptionModule

None

Enum Value Description
FOUNDATION_STEREO None
LIGHT_STEREO None
STATUS_NUM None

GalbotMotion (class)

Unified motion planning and control interface for Galbot robots.
This class provides a comprehensive API for robot motion control, including:
Forward and inverse kinematics computation
Single-chain and multi-chain trajectory planning
Collision detection (self-collision and environment)
Tool and obstacle management
Whole-body coordinated motion planning
GalbotMotion follows the Singleton design pattern to ensure a single instance manages all motion-related operations and robot state. Thread-safety is not guaranteed; external synchronization required for multi-threaded access.
All angular units are radians, linear units are meters (SI standard).
Quaternions must be unit-normalized: sqrt(x² + y² + z² + w²) = 1.
Usage Example:GalbotMotion&motion=GalbotMotion::get_instance();
if(!motion.init()){
//Handleinitializationfailure
}

get_instance

static GalbotMotion& galbot::sdk::g1::GalbotMotion::get_instance()
Item Description
Function Get the singleton instance of GalbotMotion.
Parameters None
Return Reference to the unique GalbotMotion instance

init

bool galbot::sdk::g1::GalbotMotion::init()
Item Description
Function Initialize motion planning system and communication interfaces.
Parameters None
Return true if initialization succeeds
false if initialization fails (check logs for details)

is_valid

bool galbot::sdk::g1::GalbotMotion::is_valid()
Item Description
Function Check if the motion interface is properly initialized and operational.
Parameters None
Return true if object is valid and ready for use
false if initialization failed or object is in invalid state

forward_kinematics

std::tuple<MotionStatus, std::vector<double> > galbot::sdk::g1::GalbotMotion::forward_kinematics(const std::string &target_frame, const std::string &reference_frame="base_link", const std::unordered_map< std::string, std::vector< double >> &joint_state={}, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Compute forward kinematics for a target link.
Parameters target_frame: Name of the link whose pose is to be computed (e.g., "left_ee_link", "camera_link")
reference_frame: Coordinate frame for pose expression (default: "base_link")
joint_state: Joint configurations by chain: {chain_name -> joint_angles}. Empty map uses current robot joint state.
params: Planning parameters (collision checking, timeout, etc.)
Return Tuple of (status, pose_vector): status: MotionStatus::SUCCESS on success, error code otherwise pose_vector: [x, y, z, qx, qy, qz, qw] (meters, quaternion) or empty on failure

forward_kinematics_by_state

std::tuple<MotionStatus, std::vector<double> > galbot::sdk::g1::GalbotMotion::forward_kinematics_by_state(const std::string &target_frame, const std::shared_ptr< RobotStates > &reference_robot_states=nullptr, const std::string &reference_frame="base_link", std::shared_ptr< Parameter > params=default_param)
Item Description
Function Compute forward kinematics using complete robot state.
Parameters target_frame: Link name for pose computation
reference_robot_states: Complete robot state; nullptr uses current robot state
reference_frame: Coordinate frame for pose expression (default: "base_link")
params: Planning parameters
Return Tuple of (status, pose_vector): status: MotionStatus::SUCCESS on success, error code otherwise pose_vector: [x, y, z, qx, qy, qz, qw] (meters, quaternion) or empty on failure

inverse_kinematics

std::tuple<MotionStatus, std::unordered_map<std::string, std::vector<double> > > galbot::sdk::g1::GalbotMotion::inverse_kinematics(const std::vector< double > &target_pose, const std::vector< std::string > &chain_names, const std::string &target_frame="EndEffector", const std::string &reference_frame="base_link", const std::unordered_map< std::string, std::vector< double >> &initial_joint_positions={}, const bool &enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Compute inverse kinematics for target Cartesian pose.
Parameters target_pose: Target Cartesian pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion)
chain_names: Kinematic chains to coordinate (e.g., {"left_arm"}, {"right_arm", "torso"})
target_frame: Frame on chain for pose target (e.g., "EndEffector", "Tool")
reference_frame: Coordinate frame for pose specification (default: "base_link")
initial_joint_positions: Seed configurations by chain: {chain_name -> joint_angles}. Empty map uses current robot state as seed.
enable_collision_check: If true, only returns collision-free solutions
params: Planning parameters (timeout, actuation type, etc.)
Return Tuple of (status, solution_map): status: MotionStatus::SUCCESS if solvable, error code otherwise solution_map: {chain_name -> joint_angles} (radians) for each chain, empty on failure

inverse_kinematics_by_state

std::tuple<MotionStatus, std::unordered_map<std::string, std::vector<double> > > galbot::sdk::g1::GalbotMotion::inverse_kinematics_by_state(const std::vector< double > &target_pose, const std::vector< std::string > &chain_names, const std::string &target_frame="EndEffector", const std::string &reference_frame="base_link", const std::shared_ptr< RobotStates > &reference_robot_states=nullptr, const bool &enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Compute inverse kinematics using complete robot state as seed.
Parameters target_pose: Target Cartesian pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion)
chain_names: Kinematic chains to coordinate
target_frame: Frame on chain for pose target (e.g., "EndEffector", "Tool")
reference_frame: Coordinate frame for pose specification (default: "base_link")
reference_robot_states: Complete robot state as IK seed; nullptr uses current state
enable_collision_check: If true, only returns collision-free solutions
params: Planning parameters
Return Tuple of (status, solution_map): status: MotionStatus::SUCCESS if solvable, error code otherwise solution_map: {chain_name -> joint_angles} (radians), empty on failure

get_end_effector_pose

std::tuple<MotionStatus, std::vector<double> > galbot::sdk::g1::GalbotMotion::get_end_effector_pose(const std::string &end_effector_frame, const std::string &reference_frame="base_link")
Item Description
Function Get current end-effector pose from robot state.
Parameters end_effector_frame: Name of end-effector link (must exist in URDF, e.g., "left_ee_link")
reference_frame: Coordinate frame for pose expression (default: "base_link")
Return Tuple of (status, pose_vector): status: MotionStatus::SUCCESS on success, error codes: DATA_FETCH_FAILED: TF lookup failed INVALID_INPUT: Invalid frame names pose_vector: [x, y, z, qx, qy, qz, qw] (meters, quaternion) or empty on failure

get_end_effector_pose_on_chain

std::tuple<MotionStatus, std::vector<double> > galbot::sdk::g1::GalbotMotion::get_end_effector_pose_on_chain(const std::string &chain_name, const std::string frame_id="EndEffector", const std::string &reference_frame="base_link")
Item Description
Function Get current end-effector pose for a specific kinematic chain.
Parameters chain_name: Kinematic chain identifier (e.g., "left_arm", "right_arm")
frame_id: End-effector frame type: "EndEffector" (flange), "Camera", etc.
reference_frame: Coordinate frame for pose expression (default: "base_link")
Return Tuple of (status, pose_vector): status: MotionStatus::SUCCESS on success, error code otherwise pose_vector: [x, y, z, qx, qy, qz, qw] (meters, quaternion) or empty on failure

set_end_effector_pose

MotionStatus galbot::sdk::g1::GalbotMotion::set_end_effector_pose(const std::vector< double > &target_pose, const std::string &end_effector_frame, const std::string &reference_frame="base_link", std::shared_ptr< RobotStates > reference_robot_states=nullptr, const bool &enable_collision_check=true, const bool &is_blocking=true, const double &timeout=-1.0, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Command end-effector to move to target Cartesian pose.
Parameters target_pose: Target Cartesian pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion)
end_effector_frame: Kinematic chain identifier (e.g., "left_arm", "right_arm")
reference_frame: Coordinate frame for pose specification (default: "base_link")
reference_robot_states: Planning seed state; nullptr uses current state. Warning: For direct execution, typically leave as nullptr to avoid conflicts between seed and actual robot state.
enable_collision_check: If true, only executes collision-free trajectories
is_blocking: If true, blocks until motion completes or times out; if false, returns immediately
timeout: Blocking timeout (seconds). If < 0 and is_blocking=true, uses params->timeout_second
params: Motion planning parameters (linear motion, actuation type, etc.)
Return MotionStatus: SUCCESS: Motion completed successfully (blocking) or command sent (non-blocking) TIMEOUT: Motion exceeded timeout duration INVALID_INPUT: Invalid pose or parameters FAULT: Planning or execution failure

motion_plan

std::tuple<MotionStatus, std::unordered_map<std::string, std::vector<std::vector<double> > > > galbot::sdk::g1::GalbotMotion::motion_plan(std::shared_ptr< RobotStates > target, std::shared_ptr< RobotStates > start=nullptr, std::shared_ptr< RobotStates > reference_robot_states=nullptr, bool enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Plan trajectory for a single kinematic chain.
Parameters target: Target state (must be PoseState or JointStates, not base RobotStates). Specifies the goal configuration for planning.
start: Optional start state (typically JointStates). nullptr uses current robot state as start. Warning: For direct execution, leave as nullptr to avoid conflicts.
reference_robot_states: Whole-body reference state for planning context. nullptr uses current robot state. If start is provided, its joint values overwrite the corresponding chain in reference_robot_states. Warning: For direct execution, leave as nullptr.
enable_collision_check: If true, only returns collision-free trajectories
params: Planning parameters (timeout, actuation type, linear motion, etc.)
Return Tuple of (status, trajectory_map): status: MotionStatus::SUCCESS if planning succeeds, error code otherwise trajectory_map: {chain_name -> waypoint_list}, where waypoint_list is a sequence of joint configurations (radians) along the trajectory. Empty on failure.

motion_plan_multi_waypoints

std::tuple<MotionStatus, std::unordered_map<std::string, std::vector<std::vector<double> > > > galbot::sdk::g1::GalbotMotion::motion_plan_multi_waypoints(std::shared_ptr< RobotStates > target, std::vector< std::vector< double >> targets, std::shared_ptr< RobotStates > start=nullptr, std::shared_ptr< RobotStates > reference_robot_states=nullptr, bool enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Plan trajectory through multiple waypoints for a single chain.
Parameters target: Template state defining waypoint type (PoseState or JointStates) and specifying chain_name. The state values in target are not used; only the type and chain_name are referenced.
targets: Sequence of waypoint values. Format depends on target type: PoseState: each waypoint is [x, y, z, qx, qy, qz, qw] (meters, quaternion) JointStates: each waypoint is joint configuration (radians)
start: Optional start state (JointStates). nullptr uses current robot state. Warning: For direct execution, leave as nullptr.
reference_robot_states: Whole-body reference state for planning context. nullptr uses current state. Warning: For direct execution, leave as nullptr.
enable_collision_check: If true, only returns collision-free trajectories
params: Planning parameters
Return Tuple of (status, trajectory_map): status: MotionStatus::SUCCESS if planning succeeds, error code otherwise trajectory_map: {chain_name -> waypoint_list}, smooth trajectory through all waypoints

motion_plan_multi_waypoints

std::tuple<MotionStatus, std::unordered_map<std::string, std::vector<std::vector<double> > > > galbot::sdk::g1::GalbotMotion::motion_plan_multi_waypoints(std::unordered_map< std::shared_ptr< RobotStates >, std::vector< std::vector< double >>> targets, std::vector< std::shared_ptr< RobotStates >> start={}, std::shared_ptr< RobotStates > reference_robot_states=nullptr, bool enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Plan coordinated trajectories through waypoints for multiple chains.
Parameters targets: Map of {state_template -> waypoint_list} for each chain. Keys are RobotStates (with chain_name set) defining waypoint type; values are waypoint sequences in same format as single-chain version.
start: Optional start states (JointStates) for each chain. Empty uses current state. Warning: For direct execution, leave empty.
reference_robot_states: Whole-body reference state for planning context. nullptr uses current state. Warning: For direct execution, leave as nullptr.
enable_collision_check: If true, only returns collision-free trajectories
params: Planning parameters
Return Tuple of (status, trajectory_map): status: MotionStatus::SUCCESS if planning succeeds, error code otherwise trajectory_map: {chain_name -> waypoint_list} for all chains

move_whole_body_joint_zero

MotionStatus galbot::sdk::g1::GalbotMotion::move_whole_body_joint_zero(bool is_blocking=true, double leg_head_speed_rad_s=0.2, double leg_head_timeout_s=15.0, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Move the whole-body joints to the predefined zero (home) configuration.
Parameters is_blocking: Whether to block on leg/head execution and arm planning/execution.
leg_head_speed_rad_s: Max joint speed for leg/head direct control (rad/s).
leg_head_timeout_s: Timeout for leg/head direct control (seconds).
params: Motion planning parameters for arm planning (collision is forced enabled).
Return MotionStatus Overall execution status.

check_collision

std::tuple<MotionStatus, std::vector<bool> > galbot::sdk::g1::GalbotMotion::check_collision(const std::vector< std::shared_ptr< RobotStates >> &start, bool enable_collision_check=true, std::shared_ptr< Parameter > params=default_param)
Item Description
Function Check robot states for collisions.
Parameters start: Vector of robot states to check. Each state can be: RobotStates: complete whole-body configuration JointStates: single-chain configuration (other joints use current state)
enable_collision_check: If true, checks both self and environment collisions; if false, only checks self-collisions
params: Optional parameters
Return Tuple of (status, collision_results): status: MotionStatus::SUCCESS if check completes, error code otherwise collision_results: Boolean vector (same size as start): true = collision detected, false = collision-free

attach_tool

MotionStatus galbot::sdk::g1::GalbotMotion::attach_tool(const std::string &chain, const std::string &tool)
Item Description
Function Attach a tool to an end-effector.
Parameters chain: Kinematic chain for tool attachment (e.g., "left_arm", "right_arm")
tool: Tool identifier (must be predefined in tool library, see getSupportToolList())
Return MotionStatus: SUCCESS: Tool attached successfully INVALID_INPUT: Invalid chain or tool name FAULT: Tool attachment failed

detach_tool

MotionStatus galbot::sdk::g1::GalbotMotion::detach_tool(const std::string &chain)
Item Description
Function Detach the current tool from an end-effector.
Parameters chain: Kinematic chain to detach tool from (e.g., "left_arm", "right_arm")
Return MotionStatus: SUCCESS: Tool detached successfully INVALID_INPUT: Invalid chain name or no tool attached FAULT: Tool detachment failed

add_obstacle

MotionStatus galbot::sdk::g1::GalbotMotion::add_obstacle(const std::string &obstacle_id, const std::string &obstacle_type, const std::vector< double > &pose, const std::array< double, 3 > &scale={}, const std::string &key="", const std::string &target_frame="world", const std::string &ee_frame="ee_base", const std::vector< double > &reference_joint_positions={}, const std::vector< double > &reference_base_pose={}, const std::vector< std::string > &ignore_collision_link_names={}, const double &safe_margin=0, const double &resolution=0.01)
Item Description
Function Load collision object into environment.
Parameters obstacle_id: Unique obstacle identifier (must not exist in scene). Used for later removal/updates.
obstacle_type: Obstacle geometry type (e.g., "box", "sphere", "cylinder", "mesh", "point_cloud", "depth_image"). See getSupportObstacleType() for valid types.
pose: Obstacle pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion) relative to target_frame.
scale: Geometry dimensions (meters): box: [length, width, height] sphere: [radius, -, -] cylinder: [radius, height, -] mesh/point_cloud: scaling factors [sx, sy, sz]
key: Type-specific data: mesh/point_cloud: file path (e.g., "/path/to/model.stl") depth_image: camera source ("front_head", "left_arm", "right_arm") primitives: unused, leave empty
target_frame: Reference frame for pose (default: "world"). Can be "world", "base_link", or chain name (e.g., "left_arm").
ee_frame: If target_frame is a chain, specifies frame on chain: "ee_base" (end-effector), "camera_base", "camera_object".
reference_joint_positions: Robot joint state for computing frame transforms (radians). Empty uses current robot state.
reference_base_pose: Robot base pose in map frame: [x, y, z, qx, qy, qz, qw]. Empty uses current localization.
ignore_collision_link_names: Robot links to exclude from collision with this obstacle. Useful for carried objects or mounting surfaces.
safe_margin: Safety distance buffer (meters). Collision reported if distance < safe_margin. Default: 0 (contact-based).
resolution: Discretization resolution (meters) for complex geometries (mesh, point cloud, depth image). Default: 0.01m.
Return MotionStatus: SUCCESS: Obstacle added successfully INVALID_INPUT: Invalid obstacle_id (duplicate), type, or parameters FAULT: Failed to process geometry or add to scene

remove_obstacle

MotionStatus galbot::sdk::g1::GalbotMotion::remove_obstacle(const std::string &obstacle_id)
Item Description
Function Remove a collision obstacle from the planning scene.
Parameters obstacle_id: Unique identifier of obstacle to remove (must exist in scene)
Return MotionStatus: SUCCESS: Obstacle removed successfully INVALID_INPUT: obstacle_id not found in scene FAULT: Removal operation failed

clear_obstacle

MotionStatus galbot::sdk::g1::GalbotMotion::clear_obstacle()
Item Description
Function Remove all collision obstacles from the planning scene.
Parameters None
Return MotionStatus: SUCCESS: All obstacles cleared successfully FAULT: Clear operation failed

attach_target_object

MotionStatus galbot::sdk::g1::GalbotMotion::attach_target_object(const std::string &obstacle_id, const std::string &obstacle_type, const std::vector< double > &pose, const std::array< double, 3 > &scale={}, const std::string &key="", const std::string &target_frame="world", const std::string &ee_frame="ee_base", const std::vector< double > &reference_joint_positions={}, const std::vector< double > &reference_base_pose={}, const std::vector< std::string > &ignore_collision_link_names={}, const double &safe_margin=0, const double &resolution=0.01)
Item Description
Function Attach a collision object to the robot (e.g., grasped object).
Parameters obstacle_id: Unique object identifier (must not exist in scene).
obstacle_type: Object geometry type (e.g., "box", "sphere", "mesh"). See getSupportObstacleType() for valid types.
pose: Object pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion) relative to target_frame at attachment time.
scale: Geometry dimensions (meters): box: [length, width, height] sphere: [radius, -, -] cylinder: [radius, height, -]
key: Type-specific data (e.g., mesh file path for "mesh" type).
target_frame: Attachment frame (default: "world"). Typically a chain name (e.g., "left_arm") for grasped objects.
ee_frame: If target_frame is a chain, specifies frame on chain ("ee_base", "camera_base", etc.).
reference_joint_positions: Robot joint state for computing attachment transform (radians). Empty uses current robot state.
reference_base_pose: Robot base pose in map: [x, y, z, qx, qy, qz, qw]. Empty uses current localization.
ignore_collision_link_names: Robot links to exclude from collision with this object. Typically includes the grasping end-effector links.
safe_margin: Safety distance buffer (meters). Default: 0.
resolution: Discretization resolution for complex geometries (meters). Default: 0.01m.
Return MotionStatus: SUCCESS: Object attached successfully INVALID_INPUT: Invalid parameters or duplicate obstacle_id FAULT: Attachment operation failed

detach_target_object

MotionStatus galbot::sdk::g1::GalbotMotion::detach_target_object(const std::string &obstacle_id)
Item Description
Function Detach an object from the robot (e.g., after release).
Parameters obstacle_id: Unique identifier of attached object to remove
Return MotionStatus: SUCCESS: Object detached successfully INVALID_INPUT: obstacle_id not found in attached objects FAULT: Detachment operation failed

set_motion_plan_config

MotionStatus galbot::sdk::g1::GalbotMotion::set_motion_plan_config(std::shared_ptr< MotionPlanConfig > config)
Item Description
Function Set global motion planning configuration.
Parameters config: Shared pointer to MotionPlanConfig with desired settings
Return MotionStatus: SUCCESS: Configuration applied successfully INVALID_INPUT: Invalid configuration parameters FAULT: Configuration update failed

get_motion_plan_config

std::tuple<MotionStatus, MotionPlanConfig> galbot::sdk::g1::GalbotMotion::get_motion_plan_config()
Item Description
Function Get current motion planning configuration.
Parameters None
Return Tuple of (status, config): status: MotionStatus::SUCCESS on success, error code otherwise config: Current MotionPlanConfig object (default-constructed on failure)
std::vector<std::string> galbot::sdk::g1::GalbotMotion::get_link_names(bool only_end_effector=false)
Item Description
Function Get robot link names from kinematic model.
Parameters only_end_effector: If true, returns only end-effector/tool links; if false, returns all links including base, intermediate, and end-effector links. Default: false (all links).
Return Vector of link name strings (empty if retrieval fails)
const std::set<std::string>& galbot::sdk::g1::GalbotMotion::getSupportLinks()
Item Description
Function Get set of valid link names in robot model.
Parameters None
Return Const reference to set of supported link name strings

getSupportChains

const std::set<std::string>& galbot::sdk::g1::GalbotMotion::getSupportChains()
Item Description
Function Get set of valid kinematic chain names.
Parameters None
Return Const reference to set of supported chain name strings

getSupportFrame

const std::set<std::string>& galbot::sdk::g1::GalbotMotion::getSupportFrame()
Item Description
Function Get set of valid reference frame names.
Parameters None
Return Const reference to set of supported reference frame name strings

getSupportEEFrame

const std::set<std::string>& galbot::sdk::g1::GalbotMotion::getSupportEEFrame()
Item Description
Function Get set of valid end-effector frame types.
Parameters None
Return Const reference to set of supported end-effector frame type strings

getSupportToolList

const std::set<std::string>& galbot::sdk::g1::GalbotMotion::getSupportToolList()
Item Description
Function Get list of available tools that can be attached.
Parameters None
Return Const reference to set of tool name strings

getSupportObstacleType

std::set<std::string> galbot::sdk::g1::GalbotMotion::getSupportObstacleType()
Item Description
Function Get list of supported collision obstacle geometry types.
Parameters None
Return Set of supported obstacle type strings

getBuiltObjectList

std::vector<std::string> galbot::sdk::g1::GalbotMotion::getBuiltObjectList()
Item Description
Function Get list of currently added obstacles in planning scene.
Parameters None
Return Vector of obstacle ID strings (empty if no obstacles)

getAttachedObjectList

std::vector<std::string> galbot::sdk::g1::GalbotMotion::getAttachedObjectList()
Item Description
Function Get list of currently attached objects on the robot.
Parameters None
Return Vector of attached object ID strings (empty if none attached)

isLinkNameValid

bool galbot::sdk::g1::GalbotMotion::isLinkNameValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate link name against robot model.
Parameters value: Link name to validate
throw_exception: If true, throws std::invalid_argument on validation failure; if false, returns false silently. Default: false.
Return true if link name is valid, false otherwise

isChainNameValid

bool galbot::sdk::g1::GalbotMotion::isChainNameValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate kinematic chain name.
Parameters value: Chain name to validate (e.g., "left_arm", "right_arm")
throw_exception: If true, throws exception on failure. Default: false.
Return true if chain name is valid, false otherwise

isFrameNameValid

bool galbot::sdk::g1::GalbotMotion::isFrameNameValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate reference frame name.
Parameters value: Frame name to validate (e.g., "base_link", "world")
throw_exception: If true, throws exception on failure. Default: false.
Return true if frame name is valid, false otherwise

isEEFrameValid

bool galbot::sdk::g1::GalbotMotion::isEEFrameValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate end-effector frame type.
Parameters value: Frame type to validate (e.g., "EndEffector", "Camera", "TCP")
throw_exception: If true, throws exception on failure. Default: false.
Return true if frame type is valid, false otherwise

isToolNameValid

bool galbot::sdk::g1::GalbotMotion::isToolNameValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate tool name.
Parameters value: Tool name to validate
throw_exception: If true, throws exception on failure. Default: false.
Return true if tool name is valid, false otherwise

isObstacleTypeValid

bool galbot::sdk::g1::GalbotMotion::isObstacleTypeValid(const std::string &value, bool throw_exception=false)
Item Description
Function Validate obstacle geometry type.
Parameters value: Obstacle type to validate (e.g., "box", "sphere", "mesh")
throw_exception: If true, throws exception on failure. Default: false.
Return true if obstacle type is valid, false otherwise

isWholeBodyStateValid

bool galbot::sdk::g1::GalbotMotion::isWholeBodyStateValid(const std::vector< double > &value, bool throw_exception=false)
Item Description
Function Validate whole-body joint configuration vector.
Parameters value: Joint configuration vector (radians) to validate
throw_exception: If true, throws exception on failure. Default: false.
Return true if vector size matches robot DOF, false otherwise

isPose7dValid

bool galbot::sdk::g1::GalbotMotion::isPose7dValid(const std::vector< double > &value, bool throw_exception=false)
Item Description
Function Validate 7D pose vector (position + quaternion).
Parameters value: Pose vector to validate
throw_exception: If true, throws exception on failure. Default: false.
Return true if vector size is 7, false otherwise

isChainJointStateValid

bool galbot::sdk::g1::GalbotMotion::isChainJointStateValid(const std::unordered_map< std::string, std::vector< double >> &value, bool throw_exception=false)
Item Description
Function Validate chain-indexed joint configuration map.
Parameters value: Map of {chain_name -> joint_configuration} to validate
throw_exception: If true, throws exception on failure. Default: false.
Return true if all chain names and vector sizes are valid, false otherwise

getRobotDof

int galbot::sdk::g1::GalbotMotion::getRobotDof()
Item Description
Function Get robot total degrees of freedom (DOF).
Parameters None
Return Number of robot DOF (actuated joints)

getRobotStates

RobotStates galbot::sdk::g1::GalbotMotion::getRobotStates()
Item Description
Function Get current complete robot state.
Parameters None
Return RobotStates object containing: whole_body_joint: complete joint configuration (radians) base_state: mobile base pose [x, y, z, qx, qy, qz, qw] (meters, quaternion)

getWholeBodyState

std::vector<double> galbot::sdk::g1::GalbotMotion::getWholeBodyState()
Item Description
Function Get current whole-body joint configuration.
Parameters None
Return Vector of joint angles (radians), size = getRobotDof()

getChassisState

std::vector<double> galbot::sdk::g1::GalbotMotion::getChassisState()
Item Description
Function Get current mobile base pose.
Parameters None
Return Base pose vector: [x, y, z, qx, qy, qz, qw] (meters, unit quaternion)

getChainJointState

std::unordered_map<std::string, std::vector<double> > galbot::sdk::g1::GalbotMotion::getChainJointState()
Item Description
Function Get current joint configurations for all kinematic chains.
Parameters None
Return Map of {chain_name -> joint_configuration} (radians) for each chain (e.g., {"left_arm" -> [7 joint angles], "right_arm" -> [7 joint angles]})

getChainPoseState

std::unordered_map<std::string, std::vector<double> > galbot::sdk::g1::GalbotMotion::getChainPoseState(const std::string &frame="base_link")
Item Description
Function Get current Cartesian poses for all kinematic chains.
Parameters frame: Reference frame for pose expression (default: "base_link")
Return Map of {chain_name -> pose_vector}, where pose_vector is [x, y, z, qx, qy, qz, qw] (meters, quaternion) for each chain's end-effector

replace_joint_state

bool galbot::sdk::g1::GalbotMotion::replace_joint_state(const std::string &chain_name, const std::vector< double > &chain_joint, std::vector< double > &whole_body_joint)
Item Description
Function Update a specific chain's joints in a whole-body configuration.
Parameters chain_name: Chain identifier whose joints to replace
chain_joint: New joint configuration for the chain (radians)
whole_body_joint: Whole-body joint vector to modify (in/out parameter)
Return true if replacement succeeds, false if chain_name invalid or size mismatch

status_to_string

std::string galbot::sdk::g1::GalbotMotion::status_to_string(MotionStatus status)
Item Description
Function Convert MotionStatus enum to human-readable string.
Parameters status: MotionStatus enumeration value
Return Descriptive status string (e.g., "SUCCESS: Execution succeeded", "TIMEOUT: Execution timeout")

GalbotNavigation (class)

Navigation interface for mobile robot chassis motion planning and localization.
This class provides a thread-safe singleton interface for controlling the mobile base navigation system. It supports 2D pose estimation, relocalization, goal-directed navigation with dynamic obstacle avoidance, and path planning capabilities.
The navigation system operates in a global map frame and provides both blocking and non-blocking navigation modes. It supports both differential drive and omnidirectional motion planning strategies.
This class uses the singleton pattern with thread-safe initialization.
All pose coordinates are specified in the map frame unless explicitly stated otherwise.
Typical usage: auto&nav=GalbotNavigation::get_instance();
if(nav.init()){
Posegoal;
goal.x=1.0;//meters
goal.y=2.0;//meters
goal.theta=0.0;//radians
nav.navigate_to_goal(goal,true,false,30.0,true);
}

get_instance

static GalbotNavigation& galbot::sdk::g1::GalbotNavigation::get_instance()
Item Description
Function Get the thread-safe singleton instance of GalbotNavigation.
Parameters None
Return Reference to the GalbotNavigation singleton instance.

init

bool galbot::sdk::g1::GalbotNavigation::init()
Item Description
Function Initialize the navigation subsystem and its dependencies.
Parameters None
Return true if initialization succeeded, false otherwise.

relocalize

NavigationStatus galbot::sdk::g1::GalbotNavigation::relocalize(const Pose &init_pose)
Item Description
Function Perform relocalization to re-estimate the robot's pose in the map frame.
Parameters init_pose: Initial pose estimate in the map frame (x, y in meters, theta in radians). This serves as the starting point for the relocalization algorithm.
Return NavigationStatus indicating the result of the relocalization request. See NavigationStatus enumeration for possible values.

is_localized

bool galbot::sdk::g1::GalbotNavigation::is_localized()
Item Description
Function Check whether the robot is currently localized in the map.
Parameters None
Return true if the robot is localized with acceptable confidence, false if localization is lost or uncertain.

get_current_pose

Pose galbot::sdk::g1::GalbotNavigation::get_current_pose()
Item Description
Function Get the current estimated pose of the robot chassis in the map frame.
Parameters None
Return Pose structure containing: x: X-coordinate in meters (map frame) y: Y-coordinate in meters (map frame) theta: Orientation in radians (map frame, counter-clockwise from x-axis)
NavigationStatus galbot::sdk::g1::GalbotNavigation::navigate_to_goal(const Pose &goal_pose, bool enable_collision_check=true, bool is_blocking=false, float timeout=8, bool omni_plan=true)
Item Description
Function Navigate the robot to a target goal pose in the map frame.
Parameters goal_pose: Target goal pose in the map frame. Contains: x: Target x-coordinate in meters y: Target y-coordinate in meters theta: Target orientation in radians
enable_collision_check: If true, enables dynamic obstacle detection and avoidance during navigation. If false, only static map obstacles are considered. Default: true.
is_blocking: Execution mode flag. Default: false. false (non-blocking): Returns immediately after sending the navigation command. The return status indicates whether the command was successfully sent, not whether the goal was reached. true (blocking): Blocks until the goal is reached, navigation fails, or timeout occurs. The return status reflects the final navigation outcome.
timeout: Maximum wait time in seconds for blocking mode. Default: 8.0 seconds. Only relevant when is_blocking is true. If the goal is not reached within this time, the method returns with a timeout status.
omni_plan: Motion planning mode flag. Default: true. true: Enables omnidirectional motion planning (holonomic drive), allowing the robot to move in any direction and rotate independently. false: Uses differential drive planning with kinematic constraints.
Return NavigationStatus indicating the result: In non-blocking mode: Command acceptance status In blocking mode: Final navigation outcome (success, failure, timeout)

move_straight_to

NavigationStatus galbot::sdk::g1::GalbotNavigation::move_straight_to(const Pose &goal_pose, bool is_blocking=true, float timeout=8)
Item Description
Function Move the robot to a relative target pose in the odometry frame.
Parameters goal_pose: Target pose relative to the current robot base_link frame. Contains: x: Forward/backward displacement in meters (+ forward, - backward) y: Left/right displacement in meters (+ left, - right) theta: Relative rotation in radians (counter-clockwise positive)
is_blocking: Execution mode flag. Default: true. true (blocking): Blocks until the motion is complete, fails, or timeout occurs. The return status reflects the final outcome. false (non-blocking): Returns immediately after sending the motion command. The return status indicates command acceptance.
timeout: Maximum wait time in seconds for blocking mode. Default: 8.0 seconds. Only relevant when is_blocking is true.
Return NavigationStatus indicating the result: In non-blocking mode: Command acceptance status In blocking mode: Final motion outcome (success, failure, timeout)

stop_navigation

NavigationStatus galbot::sdk::g1::GalbotNavigation::stop_navigation()
Item Description
Function Stop the current navigation task and bring the robot to a halt.
Parameters None
Return NavigationStatus indicating whether the stop command was successfully sent to the navigation system.

check_path_reachability

bool galbot::sdk::g1::GalbotNavigation::check_path_reachability(const Pose &goal_pose, const Pose &start_pose)
Item Description
Function Check if a collision-free path exists from start to goal in the map.
Parameters goal_pose: Goal pose in the map frame. Contains: x: Goal x-coordinate in meters y: Goal y-coordinate in meters theta: Goal orientation in radians
start_pose: Start pose in the map frame. Contains: x: Start x-coordinate in meters y: Start y-coordinate in meters theta: Start orientation in radians
Return true if a collision-free path exists from start to goal, false if no valid path can be found.

check_goal_arrival

bool galbot::sdk::g1::GalbotNavigation::check_goal_arrival()
Item Description
Function Check if the robot has successfully reached the current goal.
Parameters None
Return true if the robot has reached the goal within tolerance thresholds, false if still navigating, no active goal, or goal not yet reached.

get_navigation_status

NavigationTaskStatus galbot::sdk::g1::GalbotNavigation::get_navigation_status()
Item Description
Function Get the current navigation task state.
Parameters None
Return NavigationTaskStatus Current task state. UNKNOWN if no status yet; RUNNING while navigating; SUCCESS or FAILED when task has finished.

GalbotPerception (class)

None

get_instance

static GalbotPerception& galbot::sdk::g1::GalbotPerception::get_instance()
Item Description
Function Get the singleton instance of GalbotPerception.
Parameters None
Return Reference to the singleton instance.

init

bool galbot::sdk::g1::GalbotPerception::init(const std::set< PerceptionModule > &enabled_modules)
Item Description
Function Initialize perception and load models for the selected modules.
Parameters enabled_modules: Set of perception modules to enable.
Return True if every requested module loaded successfully.

run_once

bool galbot::sdk::g1::GalbotPerception::run_once(PerceptionModule module)
Item Description
Function Run a single inference for the given module.
Parameters module: Perception module to run.
Return None

wait_for_new_result

bool galbot::sdk::g1::GalbotPerception::wait_for_new_result(PerceptionModule module, double timeout_s=5.0)
Item Description
Function Block until the module produces a new result, or timeout. Use with run_once to fetch the latest output.
Parameters module: Perception module.
timeout_s: Timeout in seconds.
Return None

get_latest_result

bool galbot::sdk::g1::GalbotPerception::get_latest_result(PerceptionModule module, DetectionResult &result)
Item Description
Function Return the latest cached result for the module without blocking.
Parameters module: Perception module.
result: Output detection result.
Return True if a result is available, false if none.

GalbotRobot (class)

Main robot control interface for Galbot G1 humanoid robot.
This class provides a singleton interface for controlling the Galbot G1 robot. It supports:
Joint position and trajectory control
End-effector control (grippers and suction cups)
Mobile base velocity control
Sensor data acquisition (IMU, cameras, LiDAR, ultrasonic)
Coordinate frame transformations
System lifecycle management
The class follows the singleton pattern to ensure a single instance controls the robot hardware throughout the application lifecycle.
All angles are in radians unless otherwise specified.
All linear distances are in meters unless otherwise specified.
All timestamps are in nanoseconds unless otherwise specified.

get_instance

static GalbotRobot& galbot::sdk::g1::GalbotRobot::get_instance()
Item Description
Function Get the singleton instance of GalbotRobot.
Parameters None
Return Reference to the singleton instance

init

bool galbot::sdk::g1::GalbotRobot::init(const std::unordered_set< SensorType > &enable_sensor_set={})
Item Description
Function Initialize the robot control system.
Parameters enable_sensor_set: Set of sensors to enable. If empty, a default set of sensors will be enabled. Specify only required sensors to reduce computational overhead and memory consumption.
Return true if initialization succeeded
false if initialization failed

set_joint_commands

ControlStatus galbot::sdk::g1::GalbotRobot::set_joint_commands(const std::vector< JointCommand > &joint_commands, const std::vector< std::string > &joint_groups={}, const std::vector< std::string > &joint_names={}, const double time_from_start_s=10)
Item Description
Function Set low-level joint commands for specified joints.
Parameters joint_commands: Vector of joint commands containing control parameters for each joint
joint_groups: Joint groups to control. Supported groups: legs, head, left_arm, right_arm, gripper, suction_cup. Empty vector defaults to all body joints (legs, head, left_arm, right_arm).
joint_names: Specific joint names to control. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
time_from_start_s: Time in seconds from the start of the motion to execute the command.
Return ControlStatus indicating success or failure of command transmission

set_joint_commands

ControlStatus galbot::sdk::g1::GalbotRobot::set_joint_commands(const std::vector< JointCommand > &joint_commands, const std::vector< JointGroup > &joint_groups={}, const std::vector< std::string > &joint_names={}, const double time_from_start_s=10)
Item Description
Function Set low-level joint commands for specified joint groups.
Parameters joint_commands: Vector of joint commands containing control parameters for each joint.
joint_groups: Joint groups to control using JointGroup enumerations. Supported groups: legs, head, left_arm, right_arm, gripper, suction_cup. Empty vector defaults to all body joints (legs, head, left_arm, right_arm).
joint_names: Specific joint names to control. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
time_from_start_s: Time in seconds from the start of the motion to execute the command.
Return ControlStatus indicating success or failure of command transmission.

set_joint_positions

ControlStatus galbot::sdk::g1::GalbotRobot::set_joint_positions(const std::vector< double > &joint_positions, const std::vector< JointGroup > &joint_groups={}, const std::vector< std::string > &joint_names={}, const bool is_blocking=true, const double speed_rad_s=0.2, const double timeout_s=15)
Item Description
Function Set target joint positions for specified joint groups.
Parameters joint_positions: Vector of target joint angles in radians. The order must match the joint ordering returned by get_joint_names() for the specified joint_groups or joint_names.
joint_groups: Joint groups to control using JointGroup enumerations. Supported groups: legs, head, left_arm, right_arm. Empty vector defaults to all body joints (legs, head, left_arm, right_arm).
joint_names: Specific joint names to control. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
is_blocking: If true, blocks until motion completes or timeout occurs. If false, returns immediately after command is sent.
speed_rad_s: Maximum joint angular velocity in radians per second (rad/s). Default: 0.2 rad/s.
timeout_s: Maximum blocking wait time in seconds. Returns immediately upon timeout regardless of execution completion. Default: 15 seconds.
Return ControlStatus indicating success or failure of the motion command

set_joint_positions

ControlStatus galbot::sdk::g1::GalbotRobot::set_joint_positions(const std::vector< double > &joint_positions, const std::vector< std::string > &joint_groups={}, const std::vector< std::string > &joint_names={}, const bool is_blocking=true, const double speed_rad_s=0.2, const double timeout_s=15)
Item Description
Function Set target joint positions for specified joint groups by name.
Parameters joint_positions: Vector of target joint angles in radians. The order must match the joint ordering returned by get_joint_names() for the specified joint_groups or joint_names.
joint_groups: Joint group names to control. Supported groups: "legs", "head", "left_arm", "right_arm". Empty vector defaults to all body joints (legs, head, left_arm, right_arm).
joint_names: Specific joint names to control. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
is_blocking: If true, blocks until motion completes or timeout occurs. If false, returns immediately after command is sent.
speed_rad_s: Maximum joint angular velocity in radians per second (rad/s). Default: 0.2 rad/s.
timeout_s: Maximum blocking wait time in seconds. Returns immediately upon timeout regardless of execution completion. Default: 15 seconds.
Return ControlStatus indicating success or failure of the motion command

check_trajectory_execution_status

std::vector<TrajectoryControlStatus> galbot::sdk::g1::GalbotRobot::check_trajectory_execution_status(std::vector< std::string > joint_groups)
Item Description
Function Get trajectory execution status for specified joint groups.
Parameters joint_groups: Vector of joint group names to query
Return Vector of TrajectoryControlStatus indicating execution state for each group

check_trajectory_execution_status

std::vector<TrajectoryControlStatus> galbot::sdk::g1::GalbotRobot::check_trajectory_execution_status(std::vector< JointGroup > joint_groups)
Item Description
Function Get trajectory execution status for specified joint groups.
Parameters joint_groups: Vector of JointGroup enumerations to query
Return Vector of TrajectoryControlStatus indicating execution state for each group

execute_joint_trajectory

ControlStatus galbot::sdk::g1::GalbotRobot::execute_joint_trajectory(const Trajectory &trajectory, bool is_blocking=true)
Item Description
Function Execute a pre-planned joint trajectory.
Parameters trajectory: Trajectory data structure containing waypoints and timing
is_blocking: If true, blocks until trajectory execution completes. If false, returns immediately after trajectory is submitted.
Return ControlStatus indicating success or failure of trajectory execution/submission

set_joint_commands_batch

ControlStatus galbot::sdk::g1::GalbotRobot::set_joint_commands_batch(const Trajectory &trajectory)
Item Description
Function Set joint commands in batch mode (non-blocking)
Parameters trajectory: Trajectory data structure containing waypoints with joint commands. Each TrajectoryPoint contains time_from_start and a list of JointCommand. JointCommand includes position (rad), velocity (rad/s), acceleration (rad/s²), effort (N·m), Kp (position gain), and Kd (velocity gain).
Return ControlStatus indicating success or failure of command submission. Returns immediately without waiting for execution completion (non-blocking).

set_suction_cup_command

ControlStatus galbot::sdk::g1::GalbotRobot::set_suction_cup_command(JointGroup end_effector, bool activate)
Item Description
Function Control suction cup activation state.
Parameters end_effector: JointGroup enumeration specifying which suction cup to control
activate: If true, activates vacuum suction. If false, releases suction.
Return ControlStatus indicating success or failure of command transmission

set_gripper_command

ControlStatus galbot::sdk::g1::GalbotRobot::set_gripper_command(JointGroup end_effector, double width_m, double velocity_mps=0.03, double effort=30, bool is_blocking=true)
Item Description
Function Control gripper opening width and force.
Parameters end_effector: JointGroup enumeration specifying which gripper to control
width_m: Target gripper opening width in meters (m), measured between the inner surfaces of the gripper fingers.
velocity_mps: Gripper closing/opening velocity in meters per second (m/s). Default: 0.03 m/s.
effort: Maximum gripping force in Newton-meters (N·m). This limits the torque applied to prevent damage to grasped objects. Default: 30 N·m.
is_blocking: If true, blocks until gripper reaches target position or times out. If false, returns immediately after command is sent.
Return ControlStatus indicating success or failure of gripper command

get_dexterous_hand_state

ControlStatus galbot::sdk::g1::GalbotRobot::get_dexterous_hand_state(const JointGroup end_effector, JointStateMessage &joint_state)
Item Description
Function None
Parameters None
Return None

set_dexhand_command

ControlStatus galbot::sdk::g1::GalbotRobot::set_dexhand_command(JointGroup end_effector, const std::vector< JointCommand > &dexhand_command, bool is_blocking=true)
Item Description
Function Control dexhand opening width and force.
Parameters end_effector: JointGroup enumeration specifying which dexhand to control
dexhand_command: Vector of dexhand commands containing control parameters for each joint inspire: [position, velocity, acceleration, effort] range [0-1000, 0-1000, , 0-1000] brainco:[position, velocity, acceleration, effort] range [0-100, -100-100, , ]
is_blocking: If true, blocks until dexhand reaches target position or times out.
Return ControlStatus indicating success or failure of dexhand command

get_gripper_state

std::shared_ptr<GripperState> galbot::sdk::g1::GalbotRobot::get_gripper_state(const JointGroup end_effector)
Item Description
Function Get current gripper state.
Parameters end_effector: JointGroup enumeration specifying which gripper to query
Return Shared pointer to GripperState, or nullptr if retrieval fails

get_suction_cup_state

std::shared_ptr<SuctionCupState> galbot::sdk::g1::GalbotRobot::get_suction_cup_state(const JointGroup end_effector)
Item Description
Function Get current suction cup state.
Parameters end_effector: JointGroup enumeration specifying which suction cup to query
Return Shared pointer to SuctionCupState, or nullptr if retrieval fails

get_joint_positions

std::vector<double> galbot::sdk::g1::GalbotRobot::get_joint_positions(const std::vector< std::string > &joint_groups, const std::vector< std::string > &joint_names)
Item Description
Function Get current joint positions by group name.
Parameters joint_groups: Joint group names to query. Empty vector retrieves all body joints.
joint_names: Specific joint names to query. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
Return Vector of current joint angles in radians

get_joint_positions

std::vector<double> galbot::sdk::g1::GalbotRobot::get_joint_positions(const std::vector< JointGroup > &joint_groups, const std::vector< std::string > &joint_names={})
Item Description
Function Get current joint positions by group enumeration.
Parameters joint_groups: JointGroup enumerations to query. Empty vector retrieves all body joints.
joint_names: Specific joint names to query. This parameter takes precedence over joint_groups. When provided, joint_groups is ignored.
Return Vector of current joint angles in radians

get_joint_group_names

std::vector<std::string> galbot::sdk::g1::GalbotRobot::get_joint_group_names()
Item Description
Function Get available joint group names for the robot.
Parameters None
Return Vector of joint group names, or empty vector if retrieval fails

get_joint_names

std::vector<std::string> galbot::sdk::g1::GalbotRobot::get_joint_names(bool only_active_joint=true, const std::vector< std::string > &joint_groups={})
Item Description
Function Get robot joint names by group name.
Parameters only_active_joint: If true, returns only actuated joints (excludes passive/fixed joints). If false, returns all joints including passive ones.
joint_groups: Joint group names to query. Empty vector retrieves joints from all groups.
Return Vector of joint names in kinematic chain order

get_joint_names

std::vector<std::string> galbot::sdk::g1::GalbotRobot::get_joint_names(bool only_active_joint=true, const std::vector< JointGroup > &joint_groups={})
Item Description
Function Get robot joint names by group enumeration.
Parameters only_active_joint: If true, returns only actuated joints (excludes passive/fixed joints). If false, returns all joints including passive ones.
joint_groups: JointGroup enumerations to query. Empty vector retrieves joints from all groups.
Return Vector of joint names in kinematic chain order

get_joint_states

std::vector<JointState> galbot::sdk::g1::GalbotRobot::get_joint_states(const std::vector< std::string > &joint_group_vec, const std::vector< std::string > &joint_names_vec={})
Item Description
Function Get real-time joint states by group name.
Parameters joint_group_vec: Joint group names to query. Empty vector defaults to all body joints.
joint_names_vec: Specific joint names to query. This parameter takes precedence over joint_group_vec. When provided, joint_group_vec is ignored.
Return Vector of JointState structures containing current state for each joint

get_joint_states

std::vector<JointState> galbot::sdk::g1::GalbotRobot::get_joint_states(const std::vector< JointGroup > &joint_group, const std::vector< std::string > &joint_names={})
Item Description
Function Get real-time joint states by group enumeration.
Parameters joint_group: JointGroup enumerations to query. Empty vector defaults to all body joints.
joint_names: Specific joint names to query. This parameter takes precedence over joint_group. When provided, joint_group is ignored.
Return Vector of JointState structures containing current state for each joint

set_base_velocity

ControlStatus galbot::sdk::g1::GalbotRobot::set_base_velocity(const std::array< double, 3 > &linear_velocity, const std::array< double, 3 > &angular_velocity, double duration_s=0.0)
Item Description
Function Set mobile base velocity command.
Parameters linear_velocity: Linear velocity in meters per second (m/s), expressed in base frame. Order: {vx, vy, vz} where: vx: forward/backward velocity (positive forward) vy: left/right velocity (positive left) vz: up/down velocity (typically 0 for ground robots)
angular_velocity: Angular velocity in radians per second (rad/s), expressed in base frame. Order: {wx, wy, wz} where: wx: roll rate (rotation about x-axis) wy: pitch rate (rotation about y-axis) wz: yaw rate (rotation about z-axis, positive counter-clockwise)
duration_s: Duration in seconds to maintain the velocity command before auto-stop. If <= 0, the command behaves as legacy mode (no automatic stop).
Return ControlStatus indicating success or failure of command transmission

set_base_pose

ControlStatus galbot::sdk::g1::GalbotRobot::set_base_pose(const Pose &base_pose, bool is_blocking=true, double timeout_s=15.0)
Item Description
Function Set mobile base pose command.
Parameters base_pose: Target base pose [x, y, z, qx, qy, qz, qw]
is_blocking: If true, waits for controller response; if false, returns immediately after request
timeout_s: Timeout for blocking request (seconds)
Return ControlStatus indicating success or failure of command transmission

set_base_pose

ControlStatus galbot::sdk::g1::GalbotRobot::set_base_pose(double x, double y, double yaw, const std::string &frame_id="odom", const std::string &reference_frame_id="odom", bool is_blocking=true, double timeout_s=15.0)
Item Description
Function Set mobile base pose (x, y, yaw) with selectable frames.
Parameters x: Target x position (meters)
y: Target y position (meters)
yaw: Target yaw (radians)
frame_id: Frame id of target. Options: "base_link" / "odom" / "map". Default: "odom"
reference_frame_id: Reference frame id. Options: "odom" / "map"
is_blocking: If true, waits for controller response; if false, returns immediately after request
timeout_s: Timeout for blocking request (seconds)
Return ControlStatus indicating success or failure of command transmission

set_base_pose

ControlStatus galbot::sdk::g1::GalbotRobot::set_base_pose(double x, double y, double yaw, const std::string &frame_id, const std::string &reference_frame_id, double time_from_start_s, bool is_blocking=true, double timeout_s=15.0)
Item Description
Function Set mobile base pose (x, y, yaw) with explicit interpolation time.
Parameters x: Target x position (meters)
y: Target y position (meters)
yaw: Target yaw (radians)
frame_id: Frame id of target. Options: "base_link" / "odom" / "map"
reference_frame_id: Reference frame id. Options: "odom" / "map"
time_from_start_s: Chassis pose interpolation time (seconds)
is_blocking: If true, waits for controller response; if false, returns immediately after request
timeout_s: Request timeout (seconds)
Return ControlStatus indicating success or failure of command transmission

execute_whole_body_target

ControlStatus galbot::sdk::g1::GalbotRobot::execute_whole_body_target(const std::vector< double > &joint_positions, const std::array< double, 3 > &linear_velocity, const std::array< double, 3 > &angular_velocity, bool is_blocking=true, double speed_rad_s=0.2, double timeout_s=15.0)
Item Description
Function Execute a whole-body target with base velocity.
Parameters joint_positions: Whole-body joint positions: leg(5) + head(2) + left_arm(7) + right_arm(7)
linear_velocity: Base linear velocity [vx, vy, vz] in base frame (m/s)
angular_velocity: Base angular velocity [wx, wy, wz] in base frame (rad/s)
is_blocking: If true, waits for joint execution to complete or timeout
speed_rad_s: Max joint speed for the joint target (rad/s)
timeout_s: Timeout for blocking wait (seconds)
Return ControlStatus indicating success or failure of the command

execute_whole_body_target

ControlStatus galbot::sdk::g1::GalbotRobot::execute_whole_body_target(const std::vector< double > &joint_positions, const Pose &base_pose, bool is_blocking=true, double speed_rad_s=0.2, double timeout_s=15.0)
Item Description
Function Execute a whole-body target with base pose.
Parameters joint_positions: Whole-body joint positions: leg(5) + head(2) + left_arm(7) + right_arm(7)
base_pose: Target base pose [x, y, z, qx, qy, qz, qw]
is_blocking: If true, waits for joint execution to complete or timeout
speed_rad_s: Max joint speed for the joint target (rad/s)
timeout_s: Timeout for blocking wait (seconds)
Return ControlStatus indicating success or failure of the command

execute_whole_body_target

ControlStatus galbot::sdk::g1::GalbotRobot::execute_whole_body_target(const std::vector< double > &joint_positions, double x, double y, double yaw, const std::string &frame_id="odom", const std::string &reference_frame_id="odom", bool is_blocking=true, double speed_rad_s=0.2, double time_from_start_s=10.0, double timeout_s=15.0)
Item Description
Function Execute a whole-body target with base pose (x, y, yaw) and selectable frames.
Parameters joint_positions: Whole-body joint positions: leg(5) + head(2) + left_arm(7) + right_arm(7)
x: Target x position (meters)
y: Target y position (meters)
yaw: Target yaw (radians)
frame_id: Frame id of target. Options: "base_link" / "odom" / "map". Default: "odom"
reference_frame_id: Reference frame id. Options: "odom" / "map"
is_blocking: If true, waits for joint execution to complete or timeout
speed_rad_s: Max joint speed for the joint target (rad/s)
time_from_start_s: Chassis pose interpolation duration (seconds)
timeout_s: Timeout for blocking wait (seconds)
Return ControlStatus indicating success or failure of the command

stop_base

ControlStatus galbot::sdk::g1::GalbotRobot::stop_base()
Item Description
Function Emergency stop mobile base movement.
Parameters None
Return ControlStatus indicating success or failure of command transmission

zero_whole_body_and_base

std::pair<MotionStatus, ControlStatus> galbot::sdk::g1::GalbotRobot::zero_whole_body_and_base(const Pose &base_zero_pose, bool is_blocking=true, double leg_head_speed_rad_s=0.2, double leg_head_timeout_s=15.0, std::shared_ptr< Parameter > params=nullptr)
Item Description
Function One-key zero: move whole-body joints to zero and base to zero pose.
Parameters base_zero_pose: Target base zero pose [x, y, z, qx, qy, qz, qw]
is_blocking: Whether to block on joint zeroing
leg_head_speed_rad_s: Max joint speed for leg/head direct control (rad/s)
leg_head_timeout_s: Timeout for leg/head direct control (seconds)
params: Motion planning parameters (nullptr uses default_param)
Return Pair of (MotionStatus for joints, ControlStatus for base)

zero_whole_body_and_base

std::pair<MotionStatus, ControlStatus> galbot::sdk::g1::GalbotRobot::zero_whole_body_and_base(const std::string &frame_id="odom", const std::string &reference_frame_id="odom", bool is_blocking=true, double leg_head_speed_rad_s=0.2, double leg_head_timeout_s=15.0, std::shared_ptr< Parameter > params=nullptr)
Item Description
Function One-key zero: move whole-body joints to zero and base (x,y,yaw) to zero with selectable frames.
Parameters frame_id: Frame id of target. Options: "base_link" / "odom" / "map". Default: "odom"
reference_frame_id: Reference frame id. Options: "odom" / "map"
is_blocking: Whether to block on joint zeroing
leg_head_speed_rad_s: Max joint speed for leg/head direct control (rad/s)
leg_head_timeout_s: Timeout for leg/head direct control (seconds)
params: Motion planning parameters (nullptr uses default_param)
Return Pair of (MotionStatus for joints, ControlStatus for base)

stop_trajectory_execution

ControlStatus galbot::sdk::g1::GalbotRobot::stop_trajectory_execution()
Item Description
Function Stop all currently executing joint trajectories.
Parameters None
Return ControlStatus indicating success or failure of command transmission

reload_controller

ControlStatus galbot::sdk::g1::GalbotRobot::reload_controller(const std::string &group_name="all")
Item Description
Function Reload a controller.
Parameters group_name: Name of the joint group to reload. Supported groups: chassis, legs, head, left_arm, right_arm, gripper, or "all" to reload all controllers (default).
Return ControlStatus indicating success or failure of the reload operation

reload_controller

ControlStatus galbot::sdk::g1::GalbotRobot::reload_controller(const JointGroup joint_group)
Item Description
Function Reload a controller.
Parameters joint_group: JointGroup enumeration of the joint group to reload.
Return ControlStatus indicating success or failure of the reload operation

switch_controller

ControlStatus galbot::sdk::g1::GalbotRobot::switch_controller(ControllerName controller_name)
Item Description
Function Switch active controller strategy.
Parameters controller_name: Name of the controller to switch to.
Return ControlStatus indicating success or failure of the switch operation.

get_active_controller

ControllerName galbot::sdk::g1::GalbotRobot::get_active_controller(const std::string &group_name)
Item Description
Function Get active controller name for specified joint group.
Parameters group_name: Name of the joint group to query.
Return ControllerName Name of the active controller.

get_active_controller

ControllerName galbot::sdk::g1::GalbotRobot::get_active_controller(const JointGroup joint_group)
Item Description
Function Get active controller name for specified joint group.
Parameters joint_group: JointGroup enumeration of the joint group to query.
Return ControllerName Name of the active controller.

acquire_controller

ControlStatus galbot::sdk::g1::GalbotRobot::acquire_controller(ControllerName controller_name)
Item Description
Function Acquire hardware authority.
Parameters controller_name: Name of the controller to acquire.
Return ControlStatus indicating success or failure of the acquire operation.

release_controller

ControlStatus galbot::sdk::g1::GalbotRobot::release_controller(const std::string &group_name="all")
Item Description
Function Release hardware authority.
Parameters group_name: Name of the joint group to release. Supported groups: chassis, legs, head, left_arm, right_arm, gripper, or "all" to release all controllers (default).
Return ControlStatus indicating success or failure of the release operation

release_controller

ControlStatus galbot::sdk::g1::GalbotRobot::release_controller(const JointGroup joint_group)
Item Description
Function Release hardware authority.
Parameters joint_group: JointGroup enumeration of the joint group to release.
Return ControlStatus indicating success or failure of the release operation

start_controller

ControlStatus galbot::sdk::g1::GalbotRobot::start_controller(const std::string &group_name="all")
Item Description
Function Start controller execution.
Parameters group_name: Name of the joint group to start. Supported groups: chassis, legs, head, left_arm, right_arm, gripper, or "all" to start all controllers (default).
Return ControlStatus indicating success or failure of the start operation

start_controller

ControlStatus galbot::sdk::g1::GalbotRobot::start_controller(const JointGroup joint_group)
Item Description
Function Start controller execution.
Parameters joint_group: JointGroup enumeration of the joint group to start.
Return ControlStatus indicating success or failure of the start operation

stop_controller

ControlStatus galbot::sdk::g1::GalbotRobot::stop_controller(const std::string &group_name="all")
Item Description
Function Stop controller execution.
Parameters group_name: Name of the joint group to stop. Supported groups: chassis, legs, head, left_arm, right_arm, gripper, or "all" to stop all controllers (default).
Return ControlStatus indicating success or failure of the stop operation

stop_controller

ControlStatus galbot::sdk::g1::GalbotRobot::stop_controller(const JointGroup joint_group)
Item Description
Function Stop controller execution.
Parameters joint_group: JointGroup enumeration of the joint group to stop.
Return ControlStatus indicating success or failure of the stop operation

get_imu_data

std::shared_ptr<ImuData> galbot::sdk::g1::GalbotRobot::get_imu_data(SensorType imu_type)
Item Description
Function Get IMU (Inertial Measurement Unit) sensor data.
Parameters imu_type: SensorType enumeration specifying which IMU to query
Return Shared pointer to ImuData structure, or nullptr if sensor is not enabled or data retrieval fails

get_odom

std::shared_ptr<OdomData> galbot::sdk::g1::GalbotRobot::get_odom()
Item Description
Function Get robot odometry information.
Parameters None
Return Shared pointer to OdomData containing: Position in meters (m) relative to odometry frame origin Orientation as quaternion Linear velocity in meters per second (m/s) Angular velocity in radians per second (rad/s) Timestamp in nanoseconds Returns nullptr if odometry is unavailable.

get_device_information

std::shared_ptr<DeviceInfo> galbot::sdk::g1::GalbotRobot::get_device_information()
Item Description
Function Get device information.
Parameters None
Return Shared pointer to DeviceInfo structure containing: model: Device model name or identifier serial_number: Unique serial number for device identification firmware_version: System firmware version string hardware_version: Hardware version or revision number manufacturer: Manufacturer name or company identifier Returns nullptr if device information retrieval fails.

get_rgb_data

std::shared_ptr<RgbData> galbot::sdk::g1::GalbotRobot::get_rgb_data(const SensorType rgb_camera)
Item Description
Function Get latest RGB image from specified camera.
Parameters rgb_camera: SensorType enumeration specifying which RGB camera to query
Return Shared pointer to RgbData containing image buffer, dimensions, encoding, and timestamp. Returns nullptr if camera is not enabled or data retrieval fails.

get_depth_data

std::shared_ptr<DepthData> galbot::sdk::g1::GalbotRobot::get_depth_data(const SensorType depth_camera)
Item Description
Function Get latest depth image from specified camera.
Parameters depth_camera: SensorType enumeration specifying which depth camera to query
Return Shared pointer to DepthData containing depth image buffer, dimensions, encoding, and timestamp. Returns nullptr if camera is not enabled or data retrieval fails.

get_lidar_data

std::shared_ptr<LidarData> galbot::sdk::g1::GalbotRobot::get_lidar_data(const SensorType lidar)
Item Description
Function Get latest LiDAR point cloud data.
Parameters lidar: SensorType enumeration specifying which LiDAR to query
Return Shared pointer to LidarData (PointCloud2 format) containing point cloud with coordinates in meters (m) relative to the LiDAR frame. Returns nullptr if LiDAR is not enabled or data retrieval fails.

get_ultrasonic_data

std::shared_ptr<UltrasonicData> galbot::sdk::g1::GalbotRobot::get_ultrasonic_data(const UltrasonicType ultrasonic_type)
Item Description
Function Get distance measurement from specified ultrasonic sensor.
Parameters ultrasonic_type: UltrasonicType enumeration specifying which ultrasonic sensor to query (one of 8 directional sensors)
Return Shared pointer to UltrasonicData containing distance in meters (m), or nullptr if sensor is not enabled or data retrieval fails

get_camera_intrinsic

std::shared_ptr<CameraInfo> galbot::sdk::g1::GalbotRobot::get_camera_intrinsic(const SensorType camera)
Item Description
Function Get camera intrinsic parameters.
Parameters camera: SensorType enumeration specifying which camera to query
Return Shared pointer to CameraInfo containing: focal_length_x, focal_length_y: Focal lengths in pixels principal_point_x, principal_point_y: Principal point coordinates in pixels distortion_coeffs: Vector of distortion coefficients (e.g., k1, k2, p1, p2, k3) more camera-specific parameters as needed Returns nullptr if camera is not enabled or data retrieval fails.

get_transform

std::pair<std::vector<double>, int64_t> galbot::sdk::g1::GalbotRobot::get_transform(const std::string &target_frame, const std::string &source_frame, int64_t timestamp_ns=0, int64_t timeout_ms=100)
Item Description
Function Query coordinate frame transformation (TF)
Parameters target_frame: Name of the target coordinate frame (frame to transform into). Examples: map, base_link, imu_base_link. The actual list is determined by get_frame_names().
source_frame: Name of the source coordinate frame (frame to transform from). Examples: map, base_link, imu_base_link. The actual list is determined by get_frame_names().
timestamp_ns: Desired transform timestamp in nanoseconds. Pass 0 to get the most recent available transformation.
timeout_ms: Maximum time to wait for the transform in milliseconds. Default: 100 milliseconds.
Return Pair containing: Vector of 7 doubles representing the transform [x, y, z, qx, qy, qz, qw] where (x, y, z) is translation in meters and (qx, qy, qz, qw) is orientation quaternion Timestamp in nanoseconds when the transform was valid Returns empty vector and timestamp 0 if retrieval fails or times out.

get_frame_names

std::vector<std::string> galbot::sdk::g1::GalbotRobot::get_frame_names()
Item Description
Function Get all frame names.
Parameters None
Return std::vector All frame names

get_sensor_extrinsic

std::pair<std::vector<double>, int64_t> galbot::sdk::g1::GalbotRobot::get_sensor_extrinsic(const SensorType sensor_id, const std::string &reference_frame="base_link")
Item Description
Function Get sensor extrinsic parameters.
Parameters sensor: SensorType enumeration specifying which sensor to query
reference_frame: Name of the reference coordinate frame (frame to transform from) Default is "base_link".
Return Pair containing: Vector of 7 doubles representing the transform [x, y, z, qx, qy, qz, qw] where (x, y, z) is translation in meters and (qx, qy, qz, qw) is orientation quaternion Timestamp in nanoseconds when the transform was valid Returns empty vector and timestamp 0 if retrieval fails.

get_force_sensor_data

std::shared_ptr<ForceData> galbot::sdk::g1::GalbotRobot::get_force_sensor_data(const GalbotOneFoxtrotSensor sensor_type)
Item Description
Function Get force/torque sensor data.
Parameters sensor_type: GalbotOneFoxtrotSensor enumeration specifying which force sensor to query
Return Shared pointer to ForceData containing: Force vector in Newtons (N): [fx, fy, fz] Torque vector in Newton-meters (N·m): [tx, ty, tz] Timestamp in nanoseconds Returns nullptr if sensor is not enabled or data retrieval fails.

start_microphone_stream_input

std::string galbot::sdk::g1::GalbotRobot::start_microphone_stream_input(std::function< void(const std::shared_ptr< AudioData >)> callback, int chunk_size=2560, bool use_raw_audio=false)
Item Description
Function Start microphone streaming audio input.
Parameters callback: Audio data callback function with signature: void(const std::shared_ptr)
chunk_size: Audio data chunk size in bytes, default value 2560. Dynamic configuration not supported yet
use_raw_audio: Whether to use raw audio, default false. Dynamic configuration not supported yet. true means output raw audio directly, false means output processed audio
Return std::string Stream ID used to identify this audio input stream

stop_microphone_stream_input

void galbot::sdk::g1::GalbotRobot::stop_microphone_stream_input(const std::string &stream_id="")
Item Description
Function Stop the specified microphone streaming audio input.
Parameters stream_id: Audio input stream ID to stop. If empty string, stops all active streams
Return None

write_audio_stream_output

bool galbot::sdk::g1::GalbotRobot::write_audio_stream_output(const std::string &audio_chunk, const std::string &stream_id="")
Item Description
Function Write PCM format audio data chunk to audio output stream for real-time playback.
Parameters audio_chunk: Audio data chunk in PCM format (16000 Hz, 16-bit little-endian), single channel
stream_id: Audio stream ID to distinguish different audio sources. Empty string means use default stream
Return bool Returns operation result. True means audio data has been successfully written and playback task issued, False means write failed

stop_audio_stream_output

void galbot::sdk::g1::GalbotRobot::stop_audio_stream_output(const std::string &stream_id="")
Item Description
Function Stop the specified audio output stream or all active audio output streams playback.
Parameters stream_id: Audio output stream ID to stop. Empty string means stop all active audio output streams
Return None

get_volume

float galbot::sdk::g1::GalbotRobot::get_volume()
Item Description
Function Get current system global volume value.
Parameters None
Return float Returns current volume value, range 0.0 to 100.0

set_volume

bool galbot::sdk::g1::GalbotRobot::set_volume(float volume)
Item Description
Function Set system global volume value.
Parameters volume: Target volume value, range 0.0 to 100.0
Return bool Returns the volume setting result. True indicates the volume was set successfully, False indicates the volume setting failed.

is_running

bool galbot::sdk::g1::GalbotRobot::is_running()
Item Description
Function Check if the robot control system is running.
Parameters None
Return true if system is running normally
false if shutdown signal has been received and system is preparing to exit

request_shutdown

void galbot::sdk::g1::GalbotRobot::request_shutdown()
Item Description
Function Request system shutdown.
Parameters None
Return None

wait_for_shutdown

void galbot::sdk::g1::GalbotRobot::wait_for_shutdown()
Item Description
Function Block until shutdown signal is received.
Parameters None
Return None

destroy

void galbot::sdk::g1::GalbotRobot::destroy()
Item Description
Function Clean up system resources.
Parameters None
Return None

register_exit_callback

void galbot::sdk::g1::GalbotRobot::register_exit_callback(std::function< void()> exit_function)
Item Description
Function Register callback function for shutdown event.
Parameters exit_function: Callback function with signature void() to be executed during shutdown. Use this to perform application-specific cleanup (e.g., saving data, stopping threads).
Return None

get_bms_information

std::shared_ptr<BmsInfo> galbot::sdk::g1::GalbotRobot::get_bms_information()
Item Description
Function Get BMS (Battery Management System) information.
Parameters None
Return Shared pointer to BmsInfo containing battery information

get_log_information

std::shared_ptr<LogInfo> galbot::sdk::g1::GalbotRobot::get_log_information(uint64 timewindow_s, LogLevel log_level)
Item Description
Function Get log information.
Parameters None
Return Shared pointer to LogInfo containing log information

GalbotSdkLogStream (class)

None

GalbotSdkLogStream

galbot::sdk::g1::GalbotSdkLogStream::GalbotSdkLogStream(LogLevel level, const char *file, const char *func, int line)
Item Description
Function None
Parameters None
Return None

operator<<

GalbotSdkLogStream& galbot::sdk::g1::GalbotSdkLogStream::operator<<(const T &v)
Item Description
Function None
Parameters None
Return None

operator<<

GalbotSdkLogStream& galbot::sdk::g1::GalbotSdkLogStream::operator<<(std::ostream &(*manip)(std::ostream &))
Item Description
Function None
Parameters None
Return None

~GalbotSdkLogStream

galbot::sdk::g1::GalbotSdkLogStream::~GalbotSdkLogStream() noexcept
Item Description
Function None
Parameters None
Return None

GarbageResult (struct)

None

SENSORDATA_POINTER_TYPEDEFS

GarbageResult::SENSORDATA_POINTER_TYPEDEFS(GarbageResult)
Item Description
Function None
Parameters None
Return None

addResult

void GarbageResult::addResult(const std::string &uuid, Eigen::Vector3f box_shape, const Eigen::Vector3f &box_center_pos, const cv::Rect &box)
Item Description
Function None
Parameters None
Return None

addPointCloud

void GarbageResult::addPointCloud(const std::string &uuid, const PointCloudPtr &bbox_pointcloud)
Item Description
Function None
Parameters None
Return None

Member Variables

Name Type Description
boxes_shape EIGEN_MAKE_ALIGNED_OPERATOR_NEW std::map< std::string, Eigen::Vector3f > None
boxes_center_pos std::map< std::string, Eigen::Vector3f > None
bboxes std::map< std::string, cv::Rect > None
bboxes_pointcloud std::map< std::string, PointCloudPtr > None

GripperState (struct)

Gripper state.
Represents the current state of a parallel-jaw gripper, including opening width, motion status, and grasping force.

Member Variables

Name Type Description
timestamp_ns int64_t State timestamp (nanoseconds since epoch)
width double Gripper opening width (meters), distance between fingers
velocity double Gripper closing/opening velocity (meters/second), positive = opening
effort double Gripper grasping force (Newtons), force applied by fingers
is_moving bool Motion flag: true if gripper is currently moving, false if stationary
joint_positions std::vector< double > Gripper joint positions (radians), typically 1-2 joints for finger actuators

Header (struct)

Message header structure.
Standard message header containing timestamp and coordinate frame information. Timestamp is stored as nanoseconds since epoch (unified with other sensor types).

Member Variables

Name Type Description
timestamp_ns int64_t Timestamp of data acquisition (nanoseconds since epoch)
Records when the data was captured or generated.
frame_id std::string Frame ID.
Identifies the coordinate frame in which the data is expressed. Examples: "base_link", "world", "camera_optical_frame", "lidar_link", "map"

IKSolverConfig (struct)

Inverse kinematics (IK) solver configuration parameters.
This structure configures the numerical inverse kinematics solver used to compute joint configurations that achieve desired end-effector poses. It supports collision-aware IK with configurable seed strategies, convergence tolerances, joint limit handling, and timeout parameters.
IK solving is an iterative numerical optimization process that may benefit from multiple random initializations to find feasible collision-free solutions.

set_col_aware_ik_timeout

void galbot::sdk::g1::IKSolverConfig::set_col_aware_ik_timeout(double timeout)
Item Description
Function Set timeout for collision-aware IK solver.
Parameters timeout: Maximum solver iteration time (units: ms)
Return None

set_seed_type

void galbot::sdk::g1::IKSolverConfig::set_seed_type(SeedType type)
Item Description
Function Set initial configuration seed generation strategy.
Parameters type: Seed generation method for IK optimization initialization
Return None

set_col_aware_ik_joint_limit_bias

void galbot::sdk::g1::IKSolverConfig::set_col_aware_ik_joint_limit_bias(double bias)
Item Description
Function Set safety margin from joint position limits.
Parameters bias: Distance from joint limits to treat as forbidden region (units: rad)
Return None

set_translation_eps

void galbot::sdk::g1::IKSolverConfig::set_translation_eps(const std::array< double, 3 > &eps)
Item Description
Function Set Cartesian position error tolerance for IK convergence.
Parameters eps: Per-axis position error tolerance {x, y, z} (units: m)
Return None

set_rotation_eps

void galbot::sdk::g1::IKSolverConfig::set_rotation_eps(const std::array< double, 3 > &eps)
Item Description
Function Set orientation error tolerance for IK convergence.
Parameters eps: Per-axis orientation error tolerance {roll, pitch, yaw} (units: rad)
Return None

set_enable_collision_check_log

void galbot::sdk::g1::IKSolverConfig::set_enable_collision_check_log(bool enable)
Item Description
Function Enable or disable detailed collision checking diagnostic logs.
Parameters enable: true to output collision detection logs, false to suppress
Return None

get_col_aware_ik_timeout

double galbot::sdk::g1::IKSolverConfig::get_col_aware_ik_timeout() const
Item Description
Function Get collision-aware IK solver timeout.
Parameters None
Return Timeout duration (units: ms)

get_seed_type

SeedType galbot::sdk::g1::IKSolverConfig::get_seed_type() const
Item Description
Function Get IK solver seed generation strategy.
Parameters None
Return Current seed type

get_col_aware_ik_joint_limit_bias

double galbot::sdk::g1::IKSolverConfig::get_col_aware_ik_joint_limit_bias() const
Item Description
Function Get joint limit safety margin.
Parameters None
Return Joint limit bias distance (units: rad)

get_translation_eps

const std::array<double, 3>& galbot::sdk::g1::IKSolverConfig::get_translation_eps() const
Item Description
Function Get Cartesian position error tolerance.
Parameters None
Return Per-axis position tolerance {x, y, z} (units: m)

get_rotation_eps

const std::array<double, 3>& galbot::sdk::g1::IKSolverConfig::get_rotation_eps() const
Item Description
Function Get orientation error tolerance.
Parameters None
Return Per-axis orientation tolerance {roll, pitch, yaw} (units: rad)

get_enable_collision_check_log

bool galbot::sdk::g1::IKSolverConfig::get_enable_collision_check_log() const
Item Description
Function Check if collision check logging is enabled.
Parameters None
Return true if logging is enabled, false otherwise
void galbot::sdk::g1::IKSolverConfig::print() const
Item Description
Function Print IK solver configuration to standard output.
Parameters None
Return None

Enums

SeedType

Initial guess generation strategy for IK optimization.

Enum Value Description
RANDOM_SEED Uniformly random joint configurations within limits
RANDOM_PROGRESSIVE_SEED Progressive random sampling with increasing coverage
USER_DEFINED_SEED User-provided initial joint configurations

ImuData (struct)

IMU data structure.
Contains timestamped data from an Inertial Measurement Unit (IMU), including accelerometer, gyroscope, and magnetometer measurements.

Member Variables

Name Type Description
timestamp_ns int64_t Measurement timestamp (nanoseconds since epoch)
accel Vector3 Linear acceleration (meters/second²): [ax, ay, az]
gyro Vector3 Angular velocity (radians/second): [ωx, ωy, ωz]
magnet Vector3 Magnetic field strength (micro-Tesla): [mx, my, mz]

JointCommand (struct)

Single joint control command.
Specifies desired motion parameters for a single robot joint in a trajectory or control command.

Member Variables

Name Type Description
position double Desired joint position (radians)
velocity double Desired joint velocity (radians/second)
acceleration double Desired joint acceleration (radians/second²)
effort double Desired joint torque/effort (Newton-meters)

JointState (struct)

Single joint state structure.
Represents the complete real-time state of a single robot joint, including kinematic quantities (position, velocity, acceleration) and dynamic quantities (torque/effort and motor current).

JointState

galbot::sdk::g1::JointState::JointState()=default
Item Description
Function Default constructor.
Parameters None
Return None

JointState

galbot::sdk::g1::JointState::JointState(double position_input, double velocity_input, double acceleration_input, double effort_input, double current_input)
Item Description
Function Parameterized constructor.
Parameters position_input: Joint angular position (radians)
velocity_input: Joint angular velocity (radians/second)
acceleration_input: Joint angular acceleration (radians/second²)
effort_input: Joint torque/effort (Newton-meters)
current_input: Motor current (amperes)
Return None

Member Variables

Name Type Description
position double Joint angular position (radians)
velocity double Joint angular velocity (radians/second)
acceleration double Joint angular acceleration (radians/second²)
effort double Joint torque/effort (Newton-meters)
current double Motor current (amperes)

JointStateMessage (struct)

Joint state message structure.
Timestamped collection of joint states for multiple joints, typically representing a snapshot of the robot's complete joint configuration at one instant.

Member Variables

Name Type Description
timestamp_ns int64_t Acquisition timestamp (nanoseconds since epoch)
joint_state_vec std::vector< JointState > Vector of individual joint states

JointStates (class)

Joint-space target specification.
Represents target joint configuration for a kinematic chain. Extends RobotStates to specify joint-based motion goals. Used in joint trajectory planning and forward kinematics computation.
All joint angles must be in radians.
Vector size must match the DOF of the specified kinematic chain.

getType

Type galbot::sdk::g1::JointStates::getType() const override
Item Description
Function Get runtime type identifier.
Parameters None
Return Type::JOINT, indicating this is a joint-space target

set_joint_positions

void galbot::sdk::g1::JointStates::set_joint_positions(const std::vector< double > &joints)
Item Description
Function Set complete joint configuration for the kinematic chain.
Parameters joints: Vector of joint angles (radians), must match chain DOF
Return None

set_joint

void galbot::sdk::g1::JointStates::set_joint(int index, int val)
Item Description
Function Set individual joint angle by index.
Parameters index: Zero-based joint index within the chain
val: Joint angle value (radians)
Return None

Member Variables

Name Type Description
joint_positions std::vector< double > Target joint configuration for the chain (radians), ordered by joint index.

KinematicsBoundary (struct)

Kinematic boundary parameters for robot kinematic chain joints.
This structure defines the kinematic constraints for a robot kinematic chain (e.g., manipulator arms, mobile base, or leg chains). It specifies position, velocity, acceleration, and jerk limits for each joint in the chain.
These boundaries are critical for ensuring safe and physically feasible motion during trajectory planning and execution. Each vector should contain one value per joint in the kinematic chain.
All joint space quantities are specified in radians or radians per unit time.

set_chain_name

void galbot::sdk::g1::KinematicsBoundary::set_chain_name(const std::string &name)
Item Description
Function Set the name identifier for this kinematic chain.
Parameters name: Chain name identifier, e.g., "left_arm", "right_arm", "mobile_base"
Return None

set_lower_limit

void galbot::sdk::g1::KinematicsBoundary::set_lower_limit(const std::vector< double > &limits)
Item Description
Function Set joint position lower bounds.
Parameters limits: Vector of lower position limits for each joint (units: rad)
Return None

set_upper_limit

void galbot::sdk::g1::KinematicsBoundary::set_upper_limit(const std::vector< double > &limits)
Item Description
Function Set joint position upper bounds.
Parameters limits: Vector of upper position limits for each joint (units: rad)
Return None

set_vel_lower_limit

void galbot::sdk::g1::KinematicsBoundary::set_vel_lower_limit(const std::vector< double > &limits)
Item Description
Function Set joint velocity lower bounds.
Parameters limits: Vector of lower velocity limits for each joint (units: rad/s)
Return None

set_vel_upper_limit

void galbot::sdk::g1::KinematicsBoundary::set_vel_upper_limit(const std::vector< double > &limits)
Item Description
Function Set joint velocity upper bounds.
Parameters limits: Vector of upper velocity limits for each joint (units: rad/s)
Return None

set_acc_lower_limit

void galbot::sdk::g1::KinematicsBoundary::set_acc_lower_limit(const std::vector< double > &limits)
Item Description
Function Set joint acceleration lower bounds.
Parameters limits: Vector of lower acceleration limits for each joint (units: rad/s²)
Return None

set_acc_upper_limit

void galbot::sdk::g1::KinematicsBoundary::set_acc_upper_limit(const std::vector< double > &limits)
Item Description
Function Set joint acceleration upper bounds.
Parameters limits: Vector of upper acceleration limits for each joint (units: rad/s²)
Return None

set_jerk_lower_limit

void galbot::sdk::g1::KinematicsBoundary::set_jerk_lower_limit(const std::vector< double > &limits)
Item Description
Function Set joint jerk lower bounds.
Parameters limits: Vector of lower jerk limits for each joint (units: rad/s³)
Return None

set_jerk_upper_limit

void galbot::sdk::g1::KinematicsBoundary::set_jerk_upper_limit(const std::vector< double > &limits)
Item Description
Function Set joint jerk upper bounds.
Parameters limits: Vector of upper jerk limits for each joint (units: rad/s³)
Return None

get_chain_name

const std::string& galbot::sdk::g1::KinematicsBoundary::get_chain_name() const
Item Description
Function Get the kinematic chain name identifier.
Parameters None
Return Const reference to chain name string

get_lower_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_lower_limit() const
Item Description
Function Get joint position lower bounds.
Parameters None
Return Const reference to vector of lower position limits (units: rad)

get_upper_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_upper_limit() const
Item Description
Function Get joint position upper bounds.
Parameters None
Return Const reference to vector of upper position limits (units: rad)

get_vel_lower_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_vel_lower_limit() const
Item Description
Function Get joint velocity lower bounds.
Parameters None
Return Const reference to vector of lower velocity limits (units: rad/s)

get_vel_upper_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_vel_upper_limit() const
Item Description
Function Get joint velocity upper bounds.
Parameters None
Return Const reference to vector of upper velocity limits (units: rad/s)

get_acc_lower_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_acc_lower_limit() const
Item Description
Function Get joint acceleration lower bounds.
Parameters None
Return Const reference to vector of lower acceleration limits (units: rad/s²)

get_acc_upper_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_acc_upper_limit() const
Item Description
Function Get joint acceleration upper bounds.
Parameters None
Return Const reference to vector of upper acceleration limits (units: rad/s²)

get_jerk_lower_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_jerk_lower_limit() const
Item Description
Function Get joint jerk lower bounds.
Parameters None
Return Const reference to vector of lower jerk limits (units: rad/s³)

get_jerk_upper_limit

const std::vector<double>& galbot::sdk::g1::KinematicsBoundary::get_jerk_upper_limit() const
Item Description
Function Get joint jerk upper bounds.
Parameters None
Return Const reference to vector of upper jerk limits (units: rad/s³)
void galbot::sdk::g1::KinematicsBoundary::print() const
Item Description
Function Print kinematic boundary information to standard output.
Parameters None
Return None

LidarData (struct)

Lidar data structure.
Generic N-dimensional point cloud structure compatible with ROS 2 sensor_msgs/PointCloud2. Stores point data as a binary blob with field descriptors defining the data layout. Supports both ordered (structured) and unordered (unstructured) point clouds.

Member Variables

Name Type Description
header Header Message header.
Contains acquisition timestamp and coordinate frame for temporal and spatial reference.
height uint32_t Point cloud height (rows)
Unordered point cloud: height = 1 (single row)
Ordered point cloud: height = number of rows (e.g., from spinning lidar or depth camera)
width uint32_t Point cloud width (points per row)
Unordered point cloud: width = total number of points
Ordered point cloud: width = number of points per row (columns) Total points = height × width
fields std::vector< PointField > Field descriptors.
Describes the data channels (x, y, z, intensity, rgb, etc.) present in each point and their binary layout (offset, type, count).
is_bigendian bool Endianness flag.
true: Data is Big Endian byte order
false: Data is Little Endian byte order (typical for x86/ARM systems)
point_step uint32_t Point step (bytes per point)
Total byte size of a single point structure, including all fields and padding. Must be ≥ sum of all field sizes, may include alignment padding.
row_step uint32_t Row step (bytes per row)
Total byte size of one row of points. Formula: row_step = point_step × width
data std::vector< uint8_t > Point cloud binary data.
Binary blob containing all point data in row-major order. Size should equal: row_step × height bytes Each point occupies point_step bytes, laid out according to fields descriptors.
is_dense bool Dense cloud flag.
true: All points are valid, no NaN or Inf values present
false: Cloud may contain invalid points (NaN/Inf coordinates or fields)

LineTrajCheckPrimitive (struct)

Geometric primitive configuration for Cartesian linear trajectory validation.
This structure configures the collision detection geometric representation for linear end-effector trajectories in Cartesian space. It supports two primitive types: infinitesimally thin lines and swept-volume cylinders.
Choosing the appropriate primitive affects collision detection conservativeness and computational cost. Cylinder primitives model the robot's actual swept volume more accurately but require more expensive geometric queries.

set_line_check_primitive_type

void galbot::sdk::g1::LineTrajCheckPrimitive::set_line_check_primitive_type(PrimitiveType type)
Item Description
Function Set geometric primitive type for linear trajectory validation.
Parameters type: Primitive representation (LINE or CYLINDER)
Return None

set_cylinder_prim_radius

void galbot::sdk::g1::LineTrajCheckPrimitive::set_cylinder_prim_radius(double radius)
Item Description
Function Set swept-volume cylinder radius for trajectory collision checking.
Parameters radius: Cylinder radius representing robot swept volume (units: m)
Return None

set_line_prim_curvature

void galbot::sdk::g1::LineTrajCheckPrimitive::set_line_prim_curvature(double curvature)
Item Description
Function Set curvature approximation tolerance for line primitive.
Parameters curvature: Maximum deviation tolerance for piecewise-linear approximation (units: m)
Return None

get_line_check_primitive_type

PrimitiveType galbot::sdk::g1::LineTrajCheckPrimitive::get_line_check_primitive_type() const
Item Description
Function Get the geometric primitive type for trajectory checking.
Parameters None
Return Current primitive type (LINE or CYLINDER)

get_cylinder_prim_radius

double galbot::sdk::g1::LineTrajCheckPrimitive::get_cylinder_prim_radius() const
Item Description
Function Get the cylinder primitive swept-volume radius.
Parameters None
Return Cylinder radius (units: m)

get_line_prim_curvature

double galbot::sdk::g1::LineTrajCheckPrimitive::get_line_prim_curvature() const
Item Description
Function Get the line primitive curvature approximation tolerance.
Parameters None
Return Curvature tolerance (units: m)
void galbot::sdk::g1::LineTrajCheckPrimitive::print() const
Item Description
Function Print line trajectory check primitive configuration to standard output.
Parameters None
Return None

Enums

PrimitiveType

Geometric representation for linear trajectory collision checking.

Enum Value Description
LINE Zero-thickness line segment (fast but less conservative)
CYLINDER Swept-volume cylinder with configurable radius (accurate but slower)

LoggerConfig (struct)

Logger configuration structure.
Defines the configuration parameters for the logging system, including file settings, log levels, and output options.

Member Variables

Name Type Description
path std::string Directory path for log files. Default: ~/galbot_sdk_log/user_log
file_name std::string Log file name. Default: _.log
file_max_size uint64_t Maximum size of a single log file (bytes)
file_max_num uint64_t Number of log files to retain in rotation
level LogLevel Minimum log level to record
console_output bool Flag to enable or disable console output

LogInfo (struct)

Log information.

Member Variables

Name Type Description
level std::string None
message std::string "error" "warning"

MotionPlanConfig (class)

Comprehensive motion planning configuration management.
MotionPlanConfig serves as a centralized configuration container for all motion planning subsystems. It aggregates sampling strategies, trajectory generation parameters, inverse kinematics solver settings, collision detection options, feasibility validation criteria, and kinematic constraint boundaries.
This class provides a unified interface for configuring complex motion planning pipelines, supporting both simple manipulator planning and whole-body humanoid motion generation with multiple kinematic chains.
Configuration objects are lazily initialized and managed through shared pointers to optimize memory usage and support optional feature configuration.

MotionPlanConfig

galbot::sdk::g1::MotionPlanConfig::MotionPlanConfig()=default
Item Description
Function Default constructor.
Parameters None
Return None

set_update_time

void galbot::sdk::g1::MotionPlanConfig::set_update_time(int64_t t)
Item Description
Function Set configuration update timestamp.
Parameters t: Timestamp of last configuration modification (units: ns, typically CLOCK_MONOTONIC)
Return None

get_update_time

int64_t galbot::sdk::g1::MotionPlanConfig::get_update_time()
Item Description
Function Get configuration update timestamp.
Parameters None
Return Timestamp of last configuration modification (units: ns)

create_sampler_config

std::shared_ptr<SamplerConfig> galbot::sdk::g1::MotionPlanConfig::create_sampler_config()
Item Description
Function Create or retrieve sampler configuration.
Parameters None
Return Shared pointer to sampler configuration with default settings

create_trajectory_plan_config

std::shared_ptr<TrajectoryPlanConfig> galbot::sdk::g1::MotionPlanConfig::create_trajectory_plan_config()
Item Description
Function Create or retrieve trajectory planning configuration.
Parameters None
Return Shared pointer to trajectory planning configuration with default settings

create_ik_solver_config

std::shared_ptr<IKSolverConfig> galbot::sdk::g1::MotionPlanConfig::create_ik_solver_config()
Item Description
Function Create or retrieve inverse kinematics solver configuration.
Parameters None
Return Shared pointer to IK solver configuration with default settings

create_collision_check_option

std::shared_ptr<CollisionCheckOption> galbot::sdk::g1::MotionPlanConfig::create_collision_check_option()
Item Description
Function Create or retrieve collision check option configuration.
Parameters None
Return Shared pointer to collision check options with default settings

create_trajectory_feasibility_check_option

std::shared_ptr<TrajectoryFeasibilityCheckOption> galbot::sdk::g1::MotionPlanConfig::create_trajectory_feasibility_check_option()
Item Description
Function Create or retrieve trajectory feasibility check option configuration.
Parameters None
Return Shared pointer to trajectory feasibility check options with default settings

create_line_traj_check_primitive

std::shared_ptr<LineTrajCheckPrimitive> galbot::sdk::g1::MotionPlanConfig::create_line_traj_check_primitive()
Item Description
Function Create or retrieve line trajectory check primitive configuration.
Parameters None
Return Shared pointer to line trajectory check primitive with default settings

set_sampler_config

void galbot::sdk::g1::MotionPlanConfig::set_sampler_config(const std::shared_ptr< SamplerConfig > &config)
Item Description
Function Set or replace sampler configuration.
Parameters config: Shared pointer to sampler configuration; nullptr clears the configuration
Return None

set_trajectory_plan_config

void galbot::sdk::g1::MotionPlanConfig::set_trajectory_plan_config(const std::shared_ptr< TrajectoryPlanConfig > &config)
Item Description
Function Set or replace trajectory planning configuration.
Parameters config: Shared pointer to trajectory planning configuration; nullptr clears the configuration
Return None

set_ik_solver_config

void galbot::sdk::g1::MotionPlanConfig::set_ik_solver_config(const std::shared_ptr< IKSolverConfig > &config)
Item Description
Function Set or replace inverse kinematics solver configuration.
Parameters config: Shared pointer to IK solver configuration; nullptr clears the configuration
Return None

set_collision_check_option

void galbot::sdk::g1::MotionPlanConfig::set_collision_check_option(const std::shared_ptr< CollisionCheckOption > &option)
Item Description
Function Set or replace collision check option configuration.
Parameters option: Shared pointer to collision check options; nullptr clears the configuration
Return None

set_trajectory_feasibility_check_option

void galbot::sdk::g1::MotionPlanConfig::set_trajectory_feasibility_check_option(const std::shared_ptr< TrajectoryFeasibilityCheckOption > &option)
Item Description
Function Set or replace trajectory feasibility check option configuration.
Parameters option: Shared pointer to trajectory feasibility check options; nullptr clears the configuration
Return None

set_feasibility_boundary

void galbot::sdk::g1::MotionPlanConfig::set_feasibility_boundary(const std::vector< KinematicsBoundary > &boundary)
Item Description
Function Set kinematic feasibility boundaries for all chains.
Parameters boundary: Vector of kinematic boundaries, one per chain
Return None

set_line_traj_check_primitive

void galbot::sdk::g1::MotionPlanConfig::set_line_traj_check_primitive(const std::shared_ptr< LineTrajCheckPrimitive > &primitive)
Item Description
Function Set or replace line trajectory check primitive configuration.
Parameters primitive: Shared pointer to line trajectory check primitive; nullptr clears the configuration
Return None

set_ik_joint_limit

void galbot::sdk::g1::MotionPlanConfig::set_ik_joint_limit(const std::vector< KinematicsBoundary > &boundary)
Item Description
Function Set joint limits used during IK solving phase.
Parameters boundary: Vector of kinematic boundaries for IK solver joint constraints
Return None

set_sampler_joint_limit

void galbot::sdk::g1::MotionPlanConfig::set_sampler_joint_limit(const std::vector< KinematicsBoundary > &boundary)
Item Description
Function Set joint limits used during sampling-based planning phase.
Parameters boundary: Vector of kinematic boundaries for sampling algorithms
Return None

set_hard_joint_limit

void galbot::sdk::g1::MotionPlanConfig::set_hard_joint_limit(const std::vector< KinematicsBoundary > &boundary)
Item Description
Function Set absolute hard joint limits (safety-critical boundaries)
Parameters boundary: Vector of kinematic boundaries representing mechanical/safety limits
Return None

set_revert_ik_joint_limit

void galbot::sdk::g1::MotionPlanConfig::set_revert_ik_joint_limit(bool flag)
Item Description
Function Enable or disable IK joint limit reversion to hard limits.
Parameters flag: true to revert IK joint limits to hard limits, false to use configured IK limits
Return None

set_revert_ik_joint_limit_chains

void galbot::sdk::g1::MotionPlanConfig::set_revert_ik_joint_limit_chains(const std::vector< std::string > &chains)
Item Description
Function Set specific kinematic chains for IK joint limit reversion.
Parameters chains: Vector of chain names to apply IK limit reversion (e.g., {"left_arm", "torso"})
Return None

get_sampler_config

std::shared_ptr<SamplerConfig> galbot::sdk::g1::MotionPlanConfig::get_sampler_config() const
Item Description
Function Get sampler configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to sampler configuration, or nullptr if not set

get_trajectory_plan_config

std::shared_ptr<TrajectoryPlanConfig> galbot::sdk::g1::MotionPlanConfig::get_trajectory_plan_config() const
Item Description
Function Get trajectory planning configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to trajectory planning configuration, or nullptr if not set

get_ik_solver_config

std::shared_ptr<IKSolverConfig> galbot::sdk::g1::MotionPlanConfig::get_ik_solver_config() const
Item Description
Function Get inverse kinematics solver configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to IK solver configuration, or nullptr if not set

get_collision_check_option

std::shared_ptr<CollisionCheckOption> galbot::sdk::g1::MotionPlanConfig::get_collision_check_option() const
Item Description
Function Get collision check option configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to collision check options, or nullptr if not set

get_trajectory_feasibility_check_option

std::shared_ptr<TrajectoryFeasibilityCheckOption> galbot::sdk::g1::MotionPlanConfig::get_trajectory_feasibility_check_option() const
Item Description
Function Get trajectory feasibility check option configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to trajectory feasibility check options, or nullptr if not set

get_line_traj_check_primitive

std::shared_ptr<LineTrajCheckPrimitive> galbot::sdk::g1::MotionPlanConfig::get_line_traj_check_primitive() const
Item Description
Function Get line trajectory check primitive configuration (may be nullptr if not initialized)
Parameters None
Return Shared pointer to line trajectory check primitive, or nullptr if not set

get_sampler_config_ref

SamplerConfig& galbot::sdk::g1::MotionPlanConfig::get_sampler_config_ref()
Item Description
Function Get mutable reference to sampler configuration.
Parameters None
Return Mutable reference to sampler configuration (guaranteed non-null)

get_trajectory_plan_config_ref

TrajectoryPlanConfig& galbot::sdk::g1::MotionPlanConfig::get_trajectory_plan_config_ref()
Item Description
Function Get mutable reference to trajectory planning configuration.
Parameters None
Return Mutable reference to trajectory planning configuration (guaranteed non-null)

get_ik_solver_config_ref

IKSolverConfig& galbot::sdk::g1::MotionPlanConfig::get_ik_solver_config_ref()
Item Description
Function Get mutable reference to inverse kinematics solver configuration.
Parameters None
Return Mutable reference to IK solver configuration (guaranteed non-null)

get_collision_check_option_ref

CollisionCheckOption& galbot::sdk::g1::MotionPlanConfig::get_collision_check_option_ref()
Item Description
Function Get mutable reference to collision check option configuration.
Parameters None
Return Mutable reference to collision check options (guaranteed non-null)

get_trajectory_feasibility_check_option_ref

TrajectoryFeasibilityCheckOption& galbot::sdk::g1::MotionPlanConfig::get_trajectory_feasibility_check_option_ref()
Item Description
Function Get mutable reference to trajectory feasibility check option configuration.
Parameters None
Return Mutable reference to trajectory feasibility check options (guaranteed non-null)

get_line_traj_check_primitive_ref

LineTrajCheckPrimitive& galbot::sdk::g1::MotionPlanConfig::get_line_traj_check_primitive_ref()
Item Description
Function Get mutable reference to line trajectory check primitive configuration.
Parameters None
Return Mutable reference to line trajectory check primitive (guaranteed non-null)

get_feasibility_boundary

const std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_feasibility_boundary() const
Item Description
Function Get kinematic feasibility boundaries for all chains (read-only)
Parameters None
Return Const reference to vector of kinematic feasibility boundaries

get_feasibility_boundary

std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_feasibility_boundary()
Item Description
Function Get kinematic feasibility boundaries for all chains (mutable)
Parameters None
Return Mutable reference to vector of kinematic feasibility boundaries

get_ik_joint_limit

const std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_ik_joint_limit() const
Item Description
Function Get IK phase joint limits (read-only)
Parameters None
Return Const reference to vector of IK joint limit boundaries

get_ik_joint_limit

std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_ik_joint_limit()
Item Description
Function Get IK phase joint limits (mutable)
Parameters None
Return Mutable reference to vector of IK joint limit boundaries

get_sampler_joint_limit

const std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_sampler_joint_limit() const
Item Description
Function Get sampling phase joint limits (read-only)
Parameters None
Return Const reference to vector of sampling joint limit boundaries

get_sampler_joint_limit

std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_sampler_joint_limit()
Item Description
Function Get sampling phase joint limits (mutable)
Parameters None
Return Mutable reference to vector of sampling joint limit boundaries

get_hard_joint_limit

const std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_hard_joint_limit() const
Item Description
Function Get hard joint limits (read-only)
Parameters None
Return Const reference to vector of hard joint limit boundaries

get_hard_joint_limit

std::vector<KinematicsBoundary>& galbot::sdk::g1::MotionPlanConfig::get_hard_joint_limit()
Item Description
Function Get hard joint limits (mutable)
Parameters None
Return Mutable reference to vector of hard joint limit boundaries

get_revert_ik_joint_limit_chains

const std::vector<std::string>& galbot::sdk::g1::MotionPlanConfig::get_revert_ik_joint_limit_chains() const
Item Description
Function Get kinematic chains for selective IK joint limit reversion (read-only)
Parameters None
Return Const reference to vector of chain names for IK limit reversion

get_revert_ik_joint_limit_chains

std::vector<std::string>& galbot::sdk::g1::MotionPlanConfig::get_revert_ik_joint_limit_chains()
Item Description
Function Get kinematic chains for selective IK joint limit reversion (mutable)
Parameters None
Return Mutable reference to vector of chain names for IK limit reversion

get_revert_ik_joint_limit

bool galbot::sdk::g1::MotionPlanConfig::get_revert_ik_joint_limit()
Item Description
Function Check if IK joint limit reversion is enabled.
Parameters None
Return true if IK limits should revert to hard limits, false otherwise
void galbot::sdk::g1::MotionPlanConfig::print() const
Item Description
Function Print comprehensive motion planning configuration to standard output.
Parameters None
Return None

OdomData (struct)

Odometry data.
Contains robot pose estimate from odometry sources (wheel encoders, visual odometry, etc.). Used for robot localization and navigation.

Member Variables

Name Type Description
timestamp_ns int64_t Odometry timestamp (nanoseconds since epoch)
position std::array< double, 3 > Position [x, y, z] (meters)
orientation std::array< double, 4 > Orientation as quaternion [qx, qy, qz, qw]

Parameter (class)

Motion planning parameter configuration class.
This class extends PlannerConfig to provide comprehensive configuration options for whole-body motion planning and execution. It encapsulates execution mode, actuation type, tool frame handling, collision checking, and coordinate frame specifications.
All angular parameters are expected in radians, linear parameters in meters (SI units).

Parameter

galbot::sdk::g1::Parameter::Parameter()=default
Item Description
Function Default constructor.
Parameters None
Return None

Parameter

galbot::sdk::g1::Parameter::Parameter(bool direct_execute, bool blocking, double timeout, std::string actuate, bool tool_pose, bool check_collision, const std::string &frame="base_link")
Item Description
Function Parameterized constructor for whole-body motion planning configuration.
Parameters direct_execute: If true, immediately executes the planned motion; if false, only computes the plan
blocking: If true, blocks until motion completes or times out; if false, returns immediately
timeout: Maximum allowed time for motion execution (in seconds)
actuate: Actuation type string key (see g_actuate_type_map): "with_chain_only", "with_torso", or "with_leg"
tool_pose: If true, target pose is relative to tool frame; if false, relative to end-effector flange
check_collision: If true, enables collision checking during planning; if false, skips collision detection
frame: Reference frame for pose specifications, defaults to "base_link" (robot base frame)
Return None

setDirectExecute

void galbot::sdk::g1::Parameter::setDirectExecute(bool direct_execute)
Item Description
Function Set direct execution mode.
Parameters direct_execute: If true, planned motion is immediately executed on the robot; if false, only computes the trajectory without execution
Return None

setBlocking

void galbot::sdk::g1::Parameter::setBlocking(bool blocking)
Item Description
Function Set blocking execution mode.
Parameters blocking: If true, function blocks until motion completes or times out; if false, returns immediately after sending motion command
Return None

setTimeout

void galbot::sdk::g1::Parameter::setTimeout(double timeout)
Item Description
Function Set motion execution timeout.
Parameters timeout: Maximum allowed time for motion execution (in seconds, must be positive)
Return None

setActuate

void galbot::sdk::g1::Parameter::setActuate(const std::string &actuate)
Item Description
Function Set actuation type for whole-body coordination.
Parameters actuate: Actuation type string key: "with_chain_only" (arms only), "with_torso" (arms + torso), or "with_leg" (arms + legs)
Return None

setToolPose

void galbot::sdk::g1::Parameter::setToolPose(bool tool_pose)
Item Description
Function Set tool coordinate frame usage.
Parameters tool_pose: If true, target poses are interpreted relative to the tool frame (TCP); if false, relative to the end-effector flange frame
Return None

setCheckCollision

void galbot::sdk::g1::Parameter::setCheckCollision(bool check_collision)
Item Description
Function Enable or disable collision checking.
Parameters check_collision: If true, planner performs collision detection against self-collisions and environment obstacles; if false, skips collision checking
Return None

setReferenceFrame

void galbot::sdk::g1::Parameter::setReferenceFrame(const std::string &frame)
Item Description
Function Set the reference frame for pose specifications.
Parameters frame: Reference frame name (e.g., "base_link", "world", "odom")
Return None

setMoveLine

void galbot::sdk::g1::Parameter::setMoveLine(bool flag)
Item Description
Function Set Cartesian linear motion mode.
Parameters flag: If true, uses linear (straight-line) Cartesian motion; if false, uses joint-space interpolation (may result in curved end-effector paths)
Return None

getDirectExecute

bool galbot::sdk::g1::Parameter::getDirectExecute() const
Item Description
Function Get direct execution mode status.
Parameters None
Return true if direct execution is enabled, false otherwise

getBlocking

bool galbot::sdk::g1::Parameter::getBlocking() const
Item Description
Function Get blocking execution mode status.
Parameters None
Return true if blocking mode is enabled, false otherwise

getTimeout

double galbot::sdk::g1::Parameter::getTimeout() const
Item Description
Function Get motion execution timeout value.
Parameters None
Return Timeout duration in seconds (positive value)

getActuateType

std::string galbot::sdk::g1::Parameter::getActuateType() const
Item Description
Function Get actuation type as string.
Parameters None
Return Actuation type string ("with_chain_only", "with_torso", "with_leg", or "unknown" if not found)

getToolPose

bool galbot::sdk::g1::Parameter::getToolPose() const
Item Description
Function Get tool coordinate frame usage status.
Parameters None
Return true if using tool frame (TCP), false if using end-effector flange frame

getCheckCollision

bool galbot::sdk::g1::Parameter::getCheckCollision() const
Item Description
Function Get collision checking status.
Parameters None
Return true if collision checking is enabled, false otherwise

getReferenceFrame

std::string galbot::sdk::g1::Parameter::getReferenceFrame() const
Item Description
Function Get reference frame name.
Parameters None
Return Reference frame identifier string (e.g., "base_link", "world")

isMoveLine

bool galbot::sdk::g1::Parameter::isMoveLine()
Item Description
Function Check if Cartesian linear motion mode is enabled.
Parameters None
Return true if using linear Cartesian interpolation, false if using joint-space interpolation

PlannerConfig (struct)

Motion planning configuration structure.
Comprehensive configuration for robot motion planning and execution, controlling behavior such as planning mode, collision checking, reference frames, and execution parameters.

Member Variables

Name Type Description
is_direct_execute bool Whether to execute trajectory immediately after planning.
true: Plan and execute the trajectory in one operation
false: Only plan the trajectory without executing (for preview or validation)
is_blocking bool Whether to wait synchronously for operation completion.
true: Block until planning/execution completes or timeout occurs
false: Return immediately after initiating operation (asynchronous mode)
timeout_second double Timeout duration for blocking operations (seconds)
Maximum time to wait for planning or execution completion when is_blocking = true. Default: 20 seconds
actuate_type ActuateType Actuation mode specifying which kinematic chains to use.
Determines whether to use only the target arm, or also involve torso/leg motion for extended workspace or mobile manipulation.
is_tool_pose bool Whether target is specified as tool center point (TCP) pose.
true: Target is end-effector TCP pose (Cartesian space)
false: Target is joint space configuration
is_relative_pose bool Whether target pose is relative to current pose.
true: Target pose is relative displacement from current end-effector pose
false: Target pose is absolute in the specified reference frame
is_check_collision bool Whether to enable collision checking during planning.
true: Check collisions with obstacles and self-collisions
false: Disable collision checking (use with caution)
reference_frame std::string Reference coordinate frame for target pose.
Specifies the coordinate frame in which target poses are expressed. Common values: "base_link", "world", "odom"
joint_state std::unordered_map< JointGroup, std::vector< double > > Initial joint state for planning.
Specifies starting joint configuration for planning. If empty, uses current robot state. Key: Joint group identifier Value: Vector of joint angles (radians) for that group
move_line bool Whether to plan Cartesian linear path.
true: Plan straight-line motion in Cartesian space (end-effector moves in straight line)
false: Plan standard joint-space or task-space trajectory (may not be Cartesian linear)

PlanTaskResult (struct)

Planning task result structure.
Contains the complete result of a motion planning operation, including success status, generated trajectory, kinematics solutions, and collision information.

Member Variables

Name Type Description
task_id std::string Unique task identifier.
Used to track and distinguish different planning tasks, especially in asynchronous operations.
success bool Success flag.
true: Planning completed successfully
false: Planning failed (check error_code and error_message for details)
error_code int Numerical error code.
Used for programmatic error handling. Zero typically indicates success, non-zero values indicate specific error conditions.
error_message std::string Human-readable error message.
Provides detailed description of failure reason or exception information when success = false.
trajectory struct galbot::sdk::g1::PlanTaskResult::Trajectory None
ik_result std::unordered_map< std::string, std::vector< double > > Inverse kinematics solution.
Maps kinematic chain name to solved joint configuration (radians). Key: Joint chain name (e.g., "left_arm", "right_arm") Value: Vector of joint angles (radians)
fk_result std::unordered_map< std::string, Pose > Forward kinematics solution.
Maps link or end-effector name to computed pose. Key: Link or end-effector name (e.g., "left_gripper", "right_hand") Value: Computed pose (position + orientation)
collision_result std::vector< double > Collision detection result.
Optional field containing collision distances or penetration depths. Empty vector typically means no collision check was performed. Non-empty values may represent minimum distances to obstacles or collision severity.

Point (struct)

3D point
Represents a position in three-dimensional Cartesian space.

Member Variables

Name Type Description
x double X coordinate (meters)
y double Y coordinate (meters)
z double Z coordinate (meters)

PointField (struct)

Point cloud field descriptor.
Describes one data field in a PointCloud2 point structure, defining its name, type, offset, and count. Compatible with ROS 2 sensor_msgs/PointField.

Member Variables

Name Type Description
name std::string Field name.
Identifier for this data channel. Standard field names include:
"x", "y", "z": 3D Cartesian coordinates (meters)
"intensity": Reflection intensity (unitless or sensor-specific)
"rgb" or "rgba": Color information (packed RGB or RGBA)
"ring": Lidar ring/laser index (integer)
"timestamp": Per-point timestamp (seconds or nanoseconds)
offset uint32_t Byte offset from point start.
Byte offset of this field from the beginning of a point's data structure. Example: For point layout {x:float32, y:float32, z:float32}, offsets are: x=0, y=4, z=8
datatype DataType Data type of this field.
Specifies the primitive data type using the DataType enumeration.
count uint32_t Number of elements in this field.
Array length for this field. Typically 1 for scalar fields (x, y, z, intensity). May be > 1 for array fields (e.g., count=3 for a 3-element vector).

Enums

DataType

Data type enumeration.
Defines primitive data types for point cloud fields, determining byte size and interpretation method for each field value.

Enum Value Description
UNKNOWN Unknown or unspecified type
INT8 8-bit signed integer (1 byte)
UINT8 8-bit unsigned integer (1 byte)
INT16 16-bit signed integer (2 bytes)
UINT16 16-bit unsigned integer (2 bytes)
INT32 32-bit signed integer (4 bytes)
UINT32 32-bit unsigned integer (4 bytes)
FLOAT32 32-bit IEEE 754 floating point (4 bytes)
FLOAT64 64-bit IEEE 754 floating point (8 bytes)

Pose (struct)

Pose (position + orientation) structure.
Represents a full 6-DOF (Degrees of Freedom) pose in 3D space, combining position (translation) and orientation (rotation) information. Commonly used for robot end-effector poses, object poses, and coordinate frame transforms.

Pose

galbot::sdk::g1::Pose::Pose()=default
Item Description
Function Default constructor.
Parameters None
Return None

Pose

galbot::sdk::g1::Pose::Pose(const T &pos, const T &quat)
Item Description
Function Initialize Pose using separate position and quaternion containers.
Parameters pos: 3D position vector [x, y, z] in meters, must have size 3
quat: Quaternion vector [x, y, z, w], must have size 4
Return None

Pose

galbot::sdk::g1::Pose::Pose(const T &vec)
Item Description
Function Initialize Pose using a single 7-dimensional vector.
Parameters vec: 7D vector: [x, y, z, qx, qy, qz, qw] where first 3 elements are position (meters) and last 4 elements are quaternion
Return None

Member Variables

Name Type Description
position Point Position in 3D space (x, y, z) in meters
orientation Quaternion Orientation as unit quaternion (x, y, z, w)

PoseState (class)

Cartesian pose target specification.
Represents a target end-effector pose in Cartesian space (SE(3)). Extends RobotStates to specify pose-based motion goals for kinematic chains. Used in inverse kinematics and Cartesian trajectory planning.
Pose values: position in meters, orientation as unit quaternion.
Coordinate frames must exist in the robot's TF tree.

getType

Type galbot::sdk::g1::PoseState::getType() const override
Item Description
Function Get runtime type identifier.
Parameters None
Return Type::POSE, indicating this is a Cartesian pose target

Member Variables

Name Type Description
frame_id std::string Target frame on the kinematic chain (e.g., "EndEffector", "Camera", "TCP")
reference_frame std::string Reference coordinate frame (e.g., "base_link", "world", "odom")
pose Pose Target Cartesian pose: position (meters) + orientation (unit quaternion)

Quaternion (struct)

Quaternion.
Represents a 3D rotation using quaternion representation (x, y, z, w). A unit quaternion has magnitude 1 and represents a valid rotation.

Member Variables

Name Type Description
x double X component of the quaternion vector part
y double Y component of the quaternion vector part
z double Z component of the quaternion vector part
w double W component, scalar part (for identity rotation, w=1 and x=y=z=0)

RegionOfInterest (struct)

Region of interest (ROI)
Defines a rectangular sub-region within an image for selective processing. Compatible with ROS 2 sensor_msgs/RegionOfInterest.

Member Variables

Name Type Description
x_offset uint32_t X offset (left edge)
Horizontal pixel coordinate of the ROI's left edge. 0 means ROI starts at the image's left edge.
y_offset uint32_t Y offset (top edge)
Vertical pixel coordinate of the ROI's top edge. 0 means ROI starts at the image's top edge.
height uint32_t ROI height (pixels)
Number of pixel rows in the region of interest.
width uint32_t ROI width (pixels)
Number of pixel columns in the region of interest.
do_rectify bool Rectification flag.
true: Apply camera rectification to this ROI before processing
false: Use raw image data without rectification, or capture full resolution

RgbData (struct)

RGB/color image data structure.
Contains compressed color image data from RGB cameras. Compatible with ROS 2 sensor_msgs/CompressedImage format.

convert_to_cv2_mat

std::shared_ptr<cv::Mat> galbot::sdk::g1::RgbData::convert_to_cv2_mat()
Item Description
Function Decode compressed image data to OpenCV Mat.
Parameters None
Return std::shared_ptr Smart pointer to decoded image on success, nullptr on failure

Member Variables

Name Type Description
header Header Message header.
Contains acquisition timestamp and camera coordinate frame ID.
format std::string Image format descriptor.
Specifies compression format and encoding. Examples: "jpeg", "png", "bgr8; jpeg compressed bgr8"
data std::vector< uint8_t > Compressed image data.
Binary blob containing the compressed image (JPEG, PNG, etc.).

RobotStates (class)

Robot kinematic state representation.
Encapsulates the complete kinematic state of the robot, including whole-body joint configuration and mobile base pose. This class serves as a base for more specialized state representations (PoseState, JointStates) and is used throughout the planning and control pipeline for state specification and feedback.
All angular values are in radians, linear values in meters (SI units).
Base pose uses quaternion representation for orientation (x, y, z, qx, qy, qz, qw).

getType

virtual Type galbot::sdk::g1::RobotStates::getType() const
Item Description
Function Get the runtime type of this state object.
Parameters None
Return Type enumeration value, ROBOT_STATES for base class

RobotStates

galbot::sdk::g1::RobotStates::RobotStates()=default
Item Description
Function Default constructor.
Parameters None
Return None

setWholeBodyJoint

void galbot::sdk::g1::RobotStates::setWholeBodyJoint(const std::vector< double > &joint_positions)
Item Description
Function Set complete whole-body joint configuration.
Parameters joint_positions: Vector of joint angles (in radians), must match robot DOF
Return None

setBaseState

void galbot::sdk::g1::RobotStates::setBaseState(const Pose &base_pose)
Item Description
Function Set mobile base pose.
Parameters base_pose: Base pose in SE(3): position (meters) and orientation (quaternion)
Return None

RobotStates

galbot::sdk::g1::RobotStates::RobotStates(const std::string &chain, const std::vector< double > &whole_joint, const Pose &base_pose)
Item Description
Function Parameterized constructor for complete robot state initialization.
Parameters chain: Kinematic chain name (e.g., "left_arm", "right_arm")
whole_joint: Complete joint configuration vector (radians)
base_pose: Mobile base pose: position (meters) + orientation (unit quaternion)
Return None

Member Variables

Name Type Description
chain_name std::string Kinematic chain identifier (e.g., "left_arm", "right_arm")
whole_body_joint std::vector< double > Complete robot joint configuration (radians), ordered by joint index.
base_state std::vector< double > Mobile base pose: [x, y, z, qx, qy, qz, qw] (meters, quaternion)

Enums

Type

Enumeration for distinguishing derived state types.
Used for runtime type identification of RobotStates-derived classes.

Enum Value Description
POSE PoseState: Cartesian pose target.
JOINT JointStates: Joint space target.
ROBOT_STATES RobotStates: Generic whole-body state.

SamplerConfig (struct)

Configuration parameters for sampling-based motion planners.
This structure configures sampling-based planning algorithms (e.g., RRT, RRT*). It controls state space sampling resolution, interpolation settings, path simplification, and planning termination conditions.
Sampling-based planners explore the configuration space by randomly sampling states and connecting them to build a motion plan graph.

set_state_check_type

void galbot::sdk::g1::SamplerConfig::set_state_check_type(StateCheckType type)
Item Description
Function Set the distance metric for state comparison.
Parameters type: Distance metric type for evaluating state similarity
Return None

set_state_check_resolution

void galbot::sdk::g1::SamplerConfig::set_state_check_resolution(double resolution)
Item Description
Function Set state comparison resolution threshold.
Parameters resolution: Minimum distance threshold to consider two states as distinct (units: rad or dimensionless)
Return None

set_interpolate

void galbot::sdk::g1::SamplerConfig::set_interpolate(bool enable)
Item Description
Function Enable or disable path interpolation between sampled states.
Parameters enable: true to enable interpolation, false to use only sampled waypoints
Return None

set_interpolation_cnt

void galbot::sdk::g1::SamplerConfig::set_interpolation_cnt(int cnt)
Item Description
Function Set the number of interpolation waypoints between consecutive samples.
Parameters cnt: Number of intermediate waypoints to insert (0 = use automatic calculation)
Return None

set_simplify

void galbot::sdk::g1::SamplerConfig::set_simplify(bool enable)
Item Description
Function Enable or disable path simplification post-processing.
Parameters enable: true to enable path shortcutting and smoothing, false to use raw planned path
Return None

set_max_simplification_time

void galbot::sdk::g1::SamplerConfig::set_max_simplification_time(double time)
Item Description
Function Set maximum time budget for path simplification.
Parameters time: Maximum simplification duration (units: s); negative values indicate no time limit
Return None

set_termination_condition_type

void galbot::sdk::g1::SamplerConfig::set_termination_condition_type(TerminationConditionType type)
Item Description
Function Set planning termination condition.
Parameters type: Termination criterion (timeout only vs. timeout or exact solution)
Return None

set_max_planning_time

void galbot::sdk::g1::SamplerConfig::set_max_planning_time(double time)
Item Description
Function Set maximum time budget for motion planning.
Parameters time: Maximum planning duration (units: s)
Return None

get_state_check_type

StateCheckType galbot::sdk::g1::SamplerConfig::get_state_check_type() const
Item Description
Function Get the configured distance metric for state comparison.
Parameters None
Return Current state check type

get_state_check_resolution

double galbot::sdk::g1::SamplerConfig::get_state_check_resolution() const
Item Description
Function Get state comparison resolution threshold.
Parameters None
Return Resolution value (units: rad or dimensionless, depending on state check type)

get_interpolate

bool galbot::sdk::g1::SamplerConfig::get_interpolate() const
Item Description
Function Check if path interpolation is enabled.
Parameters None
Return true if interpolation is enabled, false otherwise

get_interpolation_cnt

int galbot::sdk::g1::SamplerConfig::get_interpolation_cnt() const
Item Description
Function Get the number of interpolation waypoints.
Parameters None
Return Number of intermediate waypoints between samples

get_simplify

bool galbot::sdk::g1::SamplerConfig::get_simplify() const
Item Description
Function Check if path simplification is enabled.
Parameters None
Return true if path simplification is enabled, false otherwise

get_max_simplification_time

double galbot::sdk::g1::SamplerConfig::get_max_simplification_time() const
Item Description
Function Get maximum path simplification time budget.
Parameters None
Return Maximum simplification time (units: s); negative values indicate no limit

get_termination_condition_type

TerminationConditionType galbot::sdk::g1::SamplerConfig::get_termination_condition_type() const
Item Description
Function Get planning termination condition.
Parameters None
Return Current termination condition type

get_max_planning_time

double galbot::sdk::g1::SamplerConfig::get_max_planning_time() const
Item Description
Function Get maximum planning time budget.
Parameters None
Return Maximum planning time (units: s)
void galbot::sdk::g1::SamplerConfig::print() const
Item Description
Function Print sampler configuration to standard output.
Parameters None
Return None

Enums

StateCheckType

Distance metric for comparing states in configuration space.

Enum Value Description
EUCLIDEAN_DISTANCE Cartesian Euclidean distance in joint space (treats joint angles as Cartesian coordinates)
RADIAN_DISTANCE Angular distance metric accounting for joint angle wraparound and weighting

TerminationConditionType

Planning termination criteria.

Enum Value Description
TIMEOUT Terminate only when maximum planning time is exceeded
TIMEOUT_AND_EXACT_SOLUTION Terminate when timeout occurs OR exact goal solution is found

SuctionCupState (struct)

Suction cup state.
Contains the current state of a vacuum suction cup gripper, including activation status, pressure reading, and action state.

Member Variables

Name Type Description
timestamp_ns int64_t State timestamp (nanoseconds since epoch)
activation bool Activation flag: true if vacuum is on, false if off
pressure double Current vacuum pressure (Pascals), typically negative for suction
action_state SUCTION_ACTION_STATE Current suction action state

Timestamp (struct)

Timestamp structure.
Represents high-precision time points with second and nanosecond components. Compatible with ROS 2 builtin_interfaces/Time and std_msgs/Header timestamp format.

Member Variables

Name Type Description
sec int64_t Seconds component.
Number of seconds since UNIX Epoch (1970-01-01 00:00:00 UTC).
nanosec uint32_t Nanoseconds component.
Nanosecond portion within the current second. Valid range: [0, 999,999,999] (< 1 second)

Trajectory (struct)

Joint trajectory.
Represents a complete robot trajectory consisting of multiple waypoints over time.

Member Variables

Name Type Description
points std::vector< TrajectoryPoint > Ordered list of trajectory waypoints
joint_groups std::vector< std::string > Names of joint groups involved in this trajectory
joint_names std::vector< std::string > Names of individual joints controlled by this trajectory

Trajectory (struct)

Trajectory result.
Contains the complete planned trajectory with joint positions and timing information.

Member Variables

Name Type Description
joint_positions std::vector< std::vector< double > > Joint positions at each waypoint.
Each element is a vector of joint angles (radians) representing robot configuration at one waypoint. Inner vector size = number of joints, outer vector size = number of waypoints.
timestamps std::vector< double > Timestamps for each waypoint (seconds)
Cumulative time from trajectory start. Size must match joint_positions size.

TrajectoryFeasibilityCheckOption (struct)

Trajectory validation and feasibility checking configuration.
This structure provides fine-grained control over which feasibility constraints are enforced during trajectory validation. It supports independent toggling of collision detection, joint limit compliance, and velocity profile feasibility.
Selectively disabling checks can improve computational performance for debugging, simulation, or scenarios where certain constraints are guaranteed to be satisfied.
Disabling feasibility checks may produce trajectories that are unsafe or physically unrealizable. Use with caution and only when constraints are verified through other means.

set_disable_collision_check

void galbot::sdk::g1::TrajectoryFeasibilityCheckOption::set_disable_collision_check(bool disable)
Item Description
Function Enable or disable collision detection during trajectory validation.
Parameters disable: true to skip collision checking, false to enforce collision-free trajectories
Return None

set_disable_joint_limit_check

void galbot::sdk::g1::TrajectoryFeasibilityCheckOption::set_disable_joint_limit_check(bool disable)
Item Description
Function Enable or disable joint limit compliance checking.
Parameters disable: true to skip joint limit validation, false to enforce position limits
Return None

set_disable_velocity_feasibility_check

void galbot::sdk::g1::TrajectoryFeasibilityCheckOption::set_disable_velocity_feasibility_check(bool disable)
Item Description
Function Enable or disable velocity profile feasibility checking.
Parameters disable: true to skip velocity limit validation, false to enforce velocity constraints
Return None

get_disable_collision_check

bool galbot::sdk::g1::TrajectoryFeasibilityCheckOption::get_disable_collision_check() const
Item Description
Function Check if collision detection is disabled.
Parameters None
Return true if collision checking is currently disabled, false if enabled

get_disable_joint_limit_check

bool galbot::sdk::g1::TrajectoryFeasibilityCheckOption::get_disable_joint_limit_check() const
Item Description
Function Check if joint limit checking is disabled.
Parameters None
Return true if joint limit validation is currently disabled, false if enabled

get_disable_velocity_feasibility_check

bool galbot::sdk::g1::TrajectoryFeasibilityCheckOption::get_disable_velocity_feasibility_check() const
Item Description
Function Check if velocity feasibility checking is disabled.
Parameters None
Return true if velocity validation is currently disabled, false if enabled
void galbot::sdk::g1::TrajectoryFeasibilityCheckOption::print() const
Item Description
Function Print trajectory feasibility check configuration to standard output.
Parameters None
Return None

TrajectoryPlanConfig (struct)

Trajectory planning and parameterization configuration.
This structure configures trajectory generation parameters for converting discrete motion plans into smooth, time-parameterized trajectories. It supports both single-segment and multi-waypoint trajectory planning.
Trajectory planning involves computing velocity and acceleration profiles along a geometric path while respecting kinematic constraints.

set_min_move_time

void galbot::sdk::g1::TrajectoryPlanConfig::set_min_move_time(double time)
Item Description
Function Set minimum duration for any motion segment.
Parameters time: Minimum trajectory execution time (units: s)
Return None

set_move_line_intermediate_point

void galbot::sdk::g1::TrajectoryPlanConfig::set_move_line_intermediate_point(double value)
Item Description
Function Set waypoint density for Cartesian linear motion interpolation.
Parameters value: Number of intermediate waypoints for linear path segments (dimensionless)
Return None

set_way_point_plan_expected_time

void galbot::sdk::g1::TrajectoryPlanConfig::set_way_point_plan_expected_time(double time)
Item Description
Function Set expected total duration for multi-waypoint trajectory planning.
Parameters time: Expected trajectory execution time for waypoint sequences (units: s)
Return None

get_min_move_time

double galbot::sdk::g1::TrajectoryPlanConfig::get_min_move_time() const
Item Description
Function Get minimum motion segment duration.
Parameters None
Return Minimum movement time (units: s)

get_move_line_intermediate_point

double galbot::sdk::g1::TrajectoryPlanConfig::get_move_line_intermediate_point() const
Item Description
Function Get waypoint density for linear motion interpolation.
Parameters None
Return Number of intermediate waypoints (dimensionless)

get_way_point_plan_expected_time

double galbot::sdk::g1::TrajectoryPlanConfig::get_way_point_plan_expected_time() const
Item Description
Function Get expected multi-waypoint trajectory duration.
Parameters None
Return Expected planning time (units: s)
void galbot::sdk::g1::TrajectoryPlanConfig::print() const
Item Description
Function Print trajectory planning configuration to standard output.
Parameters None
Return None

TrajectoryPoint (struct)

Single trajectory point.
Represents a waypoint in a robot trajectory, specifying joint states at a particular time.

Member Variables

Name Type Description
time_from_start_second double Time from trajectory start (seconds)
joint_command_vec std::vector< JointCommand > List of joint commands for all joints at this waypoint

TransformMessage (struct)

Transform message structure.
Represents a timestamped coordinate frame transformation, consisting of translation and rotation. Commonly used for TF (Transform) trees in robotics.

Member Variables

Name Type Description
timestamp_ns int64_t Transform timestamp (nanoseconds since epoch)
translation Point Translation vector (meters)
rotation Quaternion Rotation as unit quaternion (x, y, z, w)

UltrasonicData (struct)

Ultrasonic sensor data structure.
Contains a single ultrasonic distance measurement with timestamp.

Member Variables

Name Type Description
timestamp_ns int64_t Measurement timestamp in nanoseconds since epoch
distance double Measured distance to nearest obstacle (meters)

Vector3 (struct)

3D vector structure
Represents a three-dimensional vector, used for forces, torques, velocities, accelerations, and other vectorial quantities.

Member Variables

Name Type Description
x double X component
y double Y component
z double Z component