-
Notifications
You must be signed in to change notification settings - Fork 7
Home
generate JointTrajectory messages from Actions stored in Blender .blend files
Welcome to ros_blender_bridge, the open-source bridge between ROS and Blender.
ros_blender_bridge allows you to:
- Use kinematic robot models created in Blender to power ROS based robots
- Create Blender based inverse kinematic joint controllers
- Create keyframe animations in Blender and run them on robots running ROS
Add bones...
Inverse kinematics: *Edit mode *
The last step toward using Blender to control your robot is to define the joint controller and axes yaml configuration files (described below).
The joint controller yaml file specifies what joints are in each controller, the default speed and acceleration of the joints in the joint controller and the type of motor each joint uses. Joint names should be the same names used in the Blender armature and the actual motors used on the robot.
zoidstein_bge_neck_controller:
default_speed: 0.5
default_acceleration: 0.1
joints:
neck_yaw_joint:
motor: pololu
neck_pitch_joint:
motor: pololu
The last step is to combine everything in a ROS launch file.
<launch>
<param name="robot_name" value="zoidstein" />
<param name="armature_name" value="Armature" />
<param name="joint_axes_yaml" value="$(find ros_bge_bridge)/launch/zoidstein_joint_axes.yaml" />
<node pkg="ros_bge_bridge" type="run_bge_controllers.py" name="bge_controllers" output="screen">
<param name="bge_controllers_yaml" value="$(find ros_bge_bridge)/launch/zoidstein_bge_controllers.yaml" />
</node>
<node pkg="ros_bge_bridge" type="launch_blender" name="launch_blender" output="screen">
<param name="blend_file" value="$(find ros_bge_bridge)/launch/zoidstein.blend" />
<param name="use_game_engine" value="true" />
</node>
</launch>
A couple of global parameters need to be defined: the name of your armature in Blender (armature_name) and the location of the joint axes yaml configuration file (joint_axes_yaml).
Start the bge_controllers node and pass it the location of your joint controller yaml configuration (bge_controllers_yaml).
Lastly, start a blender instance with launch_blender. You need to specify the Blender file to use (blend_file) and whether you are using the game engine runtime (use_game_engine) - which is true for joint controllers for now.
TODO: remove game engine dependencies because Blender can be launched without a gui