Skip to content
Snippets Groups Projects
Commit 99ff778b authored by Valenza Florian's avatar Valenza Florian Committed by jcarpent
Browse files

[Python] Added example of loading and displaying romeo.

parent 7c5a4978
No related branches found
No related tags found
No related merge requests found
import unittest
import pinocchio as se3
import numpy as np
from pinocchio.robot_wrapper import RobotWrapper
# Warning : the paths are here hard-coded. This file is only here as an example
list_py = ["/local/fvalenza/devel/src/pinocchio/models","titi"]
robot = RobotWrapper("/local/fvalenza/devel/src/pinocchio/models/romeo.urdf",list_py, se3.JointModelFreeFlyer())
robot.initDisplay()
robot.loadDisplayModel("world/pinocchio")
q0 = np.matrix([
0, 0, 0.840252, 0, 0, 0, 1, # Free flyer
0, 0, -0.3490658, 0.6981317, -0.3490658, 0, # left leg
0, 0, -0.3490658, 0.6981317, -0.3490658, 0, # right leg
0, # chest
1.5, 0.6, -0.5, -1.05, -0.4, -0.3, -0.2, # left arm
0, 0, 0, 0, # head
1.5, -0.6, 0.5, 1.05, -0.4, -0.3, -0.2, # right arm
]).T
robot.display(q0)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment