diff --git a/CHANGELOG.md b/CHANGELOG.md index 3efcef6..6b8b4f4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ Loading and reset times are reported in the server debug log. All plugin stats c ### Fixed * Added missing call to render callbacks in viewer. While the callbacks were still being run for offscreen rendering, the viewer did not render additional geoms added by plugins. * *mujoco_ros_control*: fixed sometimes using wrong joint id in default hardware interface (would only be correct, if the joints appear first and in the same order in the compiled MuJoCo model). +* *mujoco_ros_sensors*: now skipping user sensors, as they should be handled in separate, dedicated plugins. ### Changed * Moved `mujoco_ros::Viewer::Clock` definition to `mujoco_ros::Clock` (into common_types.h). diff --git a/mujoco_ros_sensors/src/mujoco_sensor_handler_plugin.cpp b/mujoco_ros_sensors/src/mujoco_sensor_handler_plugin.cpp index 1b94a90..bb61404 100644 --- a/mujoco_ros_sensors/src/mujoco_sensor_handler_plugin.cpp +++ b/mujoco_ros_sensors/src/mujoco_sensor_handler_plugin.cpp @@ -444,6 +444,12 @@ void MujocoRosSensorsPlugin::initSensors(const mjModel *model, mjData *data) int parent_id = model->site_bodyid[site_id]; int type = model->sensor_type[n]; + // Skip user sensors because handling is unknown and should be done in extra plugin + if (type == mjSENS_USER) { + ROS_INFO_STREAM_NAMED("sensors", "Skipping USER sensor"); + continue; + } + site = mj_id2name(const_cast(model), model->sensor_objtype[n], site_id); if (model->names[model->name_sensoradr[n]]) {