Skip to content

Commit

Permalink
feat: added support for MuJoCo 2.3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidPL1 committed Feb 8, 2024
1 parent 13489d5 commit 7046778
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion mujoco_ros/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
* replaced `boost::shared_ptr` with `std::shared_ptr` or `std::unique_ptr` wherever possible (ROS 1 fast intra-process message-passing requires boost::shared_ptr).
* replaced `shared_ptr` with `unique_ptr` wherever possible.
* replaced smart pointer constructor initialization with `make_shared` or `make_unique` wherever possible.
* Updated to MuJoCo library version 2.3.7.
* * Added [jointactuatorfrc](https://mujoco.readthedocs.io/en/2.3.7/XMLreference.html#sensor-jointactuatorfrc) support in `mujoco_ros_sensors`.

Contributors: @DavidPL1, @acodeodyssey

Expand Down Expand Up @@ -48,7 +50,7 @@ Contributors: @DavidPL1, @LeroyR, @rhaschke

### Added
* Updated to MuJoCo library version 2.3.6.
* Added a `step(num_steps=1, blocking=true)` public function./
* Added a `step(num_steps=1, blocking=true)` public function.
* Unit tests for plugin loading and resetting and running callbacks correctly.
* Now automatically building with AVX instructions, if possible.
* CMake tooling borrowed from deepminds MuJoCo repo and https://github.com/osjacky430/ros_pkg_template/.
Expand Down
2 changes: 1 addition & 1 deletion mujoco_ros/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ configure_project_option(
)

# Find MuJoCo
find_package(mujoco 2.3.6 REQUIRED)
find_package(mujoco 2.3.7 REQUIRED)
find_library(GLFW libglfw.so.3)

# ###############################################
Expand Down
3 changes: 3 additions & 0 deletions mujoco_ros_sensors/src/mujoco_sensor_handler_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ bool MujocoRosSensorsPlugin::load(const mjModel *model, mjData *data)
SENSOR_STRING[mjSENS_ACTUATORFRC] = "actuatorfrc";
SENSOR_STRING[mjSENS_BALLQUAT] = "ballquat";
SENSOR_STRING[mjSENS_BALLANGVEL] = "ballangvel";
SENSOR_STRING[mjSENS_JOINTACTFRC] = "jointactfrc";
SENSOR_STRING[mjSENS_JOINTLIMITPOS] = "jointlimitpos";
SENSOR_STRING[mjSENS_JOINTLIMITVEL] = "jointlimitvel";
SENSOR_STRING[mjSENS_JOINTLIMITFRC] = "jointlimitfrc";
Expand Down Expand Up @@ -335,6 +336,7 @@ void MujocoRosSensorsPlugin::lastStageCallback(const mjModel *model, mjData *dat
case mjSENS_ACTUATORPOS:
case mjSENS_ACTUATORVEL:
case mjSENS_ACTUATORFRC:
case mjSENS_JOINTACTFRC:
case mjSENS_JOINTLIMITPOS:
case mjSENS_JOINTLIMITVEL:
case mjSENS_JOINTLIMITFRC:
Expand Down Expand Up @@ -572,6 +574,7 @@ void MujocoRosSensorsPlugin::initSensors(const mjModel *model, mjData *data)
case mjSENS_ACTUATORPOS:
case mjSENS_ACTUATORVEL:
case mjSENS_ACTUATORFRC:
case mjSENS_JOINTACTFRC:
case mjSENS_JOINTLIMITPOS:
case mjSENS_JOINTLIMITVEL:
case mjSENS_JOINTLIMITFRC:
Expand Down

0 comments on commit 7046778

Please sign in to comment.