Task #220
Updated by Sanghoon Lee about 1 month ago
This package is std_xela_taxel_viz_ahv4, a marker publisher for an isolated environment for visualizing Allegro hand sensor data.
I plan to develop a visualization app that subscribes to sensor data topics provided by xela_server2_ah and publishes markers in an independent environment for visualization.
Therefore, I plan to develop a standalone Taxel visualization app that operates identically to xela_taxel_viz_ahv4 but publishes separate /robot_description and /joint_states without affecting the robot control environment.
This app publishes data to the Marker topic, allowing RViz and other ROS apps to easily subscribe to this marker topic for visualization.
std_xela_taxel_viz_ahv4 targets the following models:
- uSCuAH (left, right)
Supported models use pre-defined profiles for each model, which can be selected as parameters at startup.
-------------------
!{width:800px}clipboard-202602160020-x68xa.png!
-------------------
h1. std_xela_taxel_viz_ahv4
h2. 1. Goal
Provide standalone Allegro Hand v4 tactile visualization without requiring robot control stack.
h2. 2. System Context
* Input:
** @/x_taxel_ah@
** joint states from @/joint_states@ (global) or @/<ns>/joint_states@ (local)
* Output:
** @/<ns>/markers@
** namespace-local TF topics (@/<ns>/tf@, @/<ns>/tf_static@)
h2. 3. Components
h3. 3.1 std_xela_taxel_viz_ahv4_node
* Handles baseline and marker generation.
* Supports @grid@ and @urdf@ modes.
* Uses mapping/pattern YAML for taxel placement.
h3. 3.2 robot_state_publisher (URDF mode)
* Loads local xacro: @description/xela_uSCuAH_<sequence>_modules.xacro@.
* Runs with @use_ros2_control:=false@ and @use_hand_controllers:=false@.
* Publishes TF on namespace-local remapped topics.
h3. 3.3 std_xela_joint_state_publisher_node (URDF + local mode)
* Publishes namespace-local @joint_states@.
* Loads profile joints by device profile.
* Adds 16 active hand joints (@ah_joint00~ah_joint33@).
h3. 3.4 All-in-one orchestrators
* Sim all-in-one: @sim_xela_server + xela_server2_ah_with_replayer + std viz + RViz@.
* Real all-in-one: @xela_server2_ah + std viz + RViz@.
h2. 4. Model and Hand-Side Selection
@model_name@ drives left/right defaults in all-in-one launch:
* Left default: @XR23AHLCPP@
* Right example: @XR23AHRCPP@
Selector sets:
* @urdf_xacro_path@
* @sequence@
* @pattern_yaml@
* @mapping_yaml@
* @hand_side@
* @joint_states_device_profile@
h2. 5. Configuration Strategy
* Base defaults: @config/base/std_xela_taxel_viz_ahv4.yaml@
* Mapping: @config/maps/taxel_joint_map_new.yaml@
* Patterns: @config/patterns/pattern_lahv4.yaml@, @pattern_rahv4.yaml@
* Joint profiles: @config/joints/joint_state_profiles.yaml@
Resolution order:
# Base config
# Mapping/pattern files
# Launch overrides
h2. 6. TF Isolation Strategy
* Default namespace: @xvizah@.
* Topic-level isolation through TF remapping.
* @frame_prefix@ defaults empty and is optional.
h2. 7. Timing Strategy
* Default @marker_stamp_mode=keep@
* Default @marker_time_offset_sec=-0.1@
* For strict sync issues, @marker_stamp_mode=now@ is available.
h2. 8. Dependencies Boundary
* Reuses URDF/mesh assets from @xela_models@ and @xela_ah_r2c_bringup@.
* No hand control controller runtime required for local URDF visualization.
h2. 9. Acceptance Criteria
* Grid and URDF render correctly with @/x_taxel_ah@.
* URDF local mode works without hand controller.
* Left/right model selection changes URDF and pattern mapping correctly.
* All-in-one launches operate with namespace-local TF and marker topics.
-----------------
h1. README
Standalone visualization package for Allegro Hand v4 tactile sensors.
It runs independently from hand control stack and supports namespace-local TF and local joint-state generation.
h2. Purpose
* Input tactile stream: @/x_taxel_ah@
* Output markers: @/<namespace>/markers@
* Visualization modes: @grid@, @urdf@
* Local URDF mode without hand control controllers
h2. Requirements
* ROS 2 Humble
* @xela_taxel_msgs@
* @xela_models@
* @xela_ah_r2c_bringup@
* @allegro_hand_bringup@
* @xela_server2_ah@ (all-in-one)
* @sim_xela_server@ (sim all-in-one)
h2. Install Dependencies (rosdep)
<pre><code>
WS=~/xela_robotics/02_dev_ws
sudo sh -c "echo 'yaml file://${WS}/src/xela_apps/rosdep/xela_taxel_viz_deps.yaml' > /etc/ros/rosdep/sources.list.d/98-xela-taxel-viz.list"
rosdep update
rosdep install --from-paths ${WS}/src/xela_apps/std_xela_taxel_viz_ahv4 -r -y --ignore-src
</code></pre>
h2. Build
<pre><code>
cd ~/xela_robotics/02_dev_ws
colcon build --packages-select std_xela_taxel_viz_ahv4
source install/setup.bash
</code></pre>
h2. Quick Start
Basic launch (default: grid mode):
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 std_xela_taxel_viz_ahv4.launch.py
</code></pre>
URDF mode with local joint states:
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 std_xela_taxel_viz_ahv4.launch.py viz_mode:=urdf joint_states_mode:=local
</code></pre>
URDF mode with external @/joint_states@:
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 std_xela_taxel_viz_ahv4.launch.py viz_mode:=urdf joint_states_mode:=global
</code></pre>
h2. All-in-One Launch
Sim all-in-one (@sim_xela_server + xela_server2_ah + std_xela_taxel_viz_ahv4 + rviz2@):
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 sim_all_svc_std_xela_taxel_viz_ahv4.launch.py
</code></pre>
Sim all-in-one with right-hand model selection:
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 sim_all_svc_std_xela_taxel_viz_ahv4.launch.py model_name:=XR23AHRCPP viz_mode:=urdf
</code></pre>
Real all-in-one (@xela_server2_ah + std_xela_taxel_viz_ahv4 + rviz2@):
<pre><code>
ros2 launch std_xela_taxel_viz_ahv4 real_all_svc_std_xela_taxel_viz_ahv4.launch.py
</code></pre>
h2. Default Launch Arguments
h3. std_xela_taxel_viz_ahv4.launch.py
* @namespace@: @xvizah@
* @viz_mode@: @grid@
* @joint_states_mode@: @local@
* @frame_id@: @world@
* @frame_prefix@: empty (recommended)
* @overlay_grid_in_urdf@: @false@
* @mapping_yaml@: @config/maps/taxel_joint_map_new.yaml@
* @pattern_yaml@: @config/patterns/pattern_lahv4.yaml@
* @hand_side@: @left@
* @sequence@: @0@
* @tips@: @curved@
* @parent@: @world@
* @marker_stamp_mode@: @keep@
* @marker_time_offset_sec@: @-0.1@
* @joint_states_config_yaml@: @config/joints/joint_state_profiles.yaml@
* @joint_states_device_profile@: auto by hand side
h3. sim_all_svc_std_xela_taxel_viz_ahv4.launch.py
* @namespace@: @xvizah@
* @model_name@: @XR23AHLCPP@
* @viz_mode@: @urdf@
* @joint_states_mode@: @local@
* @frame_prefix@: empty
* @marker_stamp_mode@: @keep@
* @marker_time_offset_sec@: @-0.1@
* @preset@: @normal@
* @integer_z_range@: @10085.0@
* @calib_z_range@: @14.0@
* @z_bias_power@: @1.0@
h3. real_all_svc_std_xela_taxel_viz_ahv4.launch.py
* @namespace@: @xvizah@
* @model_name@: @XR23AHLCPP@
* @viz_mode@: @urdf@
* @joint_states_mode@: @local@
* @frame_prefix@: empty
* @marker_stamp_mode@: @keep@
* @marker_time_offset_sec@: @-0.1@
* @ws_host@: @localhost@
* @ws_port@: @5000@
h2. Local Joint-State Publisher (Controller-Free URDF)
When @viz_mode=urdf@ and @joint_states_mode=local@, @std_xela_joint_state_publisher_node@ starts.
* Publishes @/<namespace>/joint_states@
* Loads profile joints from @config/joints/joint_state_profiles.yaml@
* Adds active hand joints:
** @ah_joint00~ah_joint03@
** @ah_joint10~ah_joint13@
** @ah_joint20~ah_joint23@
** @ah_joint30~ah_joint33@
This avoids dependency on robot-control hand controller for TF visualization.
h2. Hand Model Selection
In all-in-one launch:
* @model_name:=XR23AHLCPP@ selects left defaults
* @model_name:=XR23AHRCPP@ selects right defaults
Selection updates:
* @urdf_xacro_path@
* @pattern_yaml@
* @sequence@
* @hand_side@
* @joint_states_device_profile@
h2. TF Isolation
* @robot_state_publisher@ remaps @/tf@ and @/tf_static@ into namespace-local topics.
* All-in-one RViz remaps to @/<namespace>/tf@ and @/<namespace>/tf_static@.
* Keep @frame_prefix@ empty unless prefixed frame names are required.
h2. Config Layout
* Base: @config/base/std_xela_taxel_viz_ahv4.yaml@
* Mapping: @config/maps/taxel_joint_map_new.yaml@
* Patterns: @config/patterns/pattern_lahv4.yaml@, @pattern_rahv4.yaml@
* Joint profiles: @config/joints/joint_state_profiles.yaml@
* RViz: @config/rviz/@
h2. Troubleshooting
* URDF not visible or RobotModel collapsed:
** Keep @frame_prefix@ empty, or
** Set RViz RobotModel @TF Prefix@ and @Fixed Frame@ to matching prefixed names.
* TF extrapolation warnings:
** Use @marker_stamp_mode:=now@ and keep negative @marker_time_offset_sec@.
* No markers:
** Confirm @/x_taxel_ah@ is publishing and selected @viz_mode@ matches RViz config.
h2. Related Redmine Docs
* @design_std_xela_taxel_viz_ahv4.textile@
* @fsd_std_xela_taxel_viz_ahv4.textile@
---------------
!{width:800px}clipboard-202602230951-dfiqg.png!