Created
July 26, 2016 03:21
-
-
Save jakewins/12e5143d8adb76157b659bc0a6ea9904 to your computer and use it in GitHub Desktop.
Revisions
-
jakewins created this gist
Jul 26, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,25 @@ from morse.builder import * class Sickle(GroundRobot): """ A template robot model for kuka, with a motion controller and a pose sensor. """ def __init__(self, name = None, debug = True): # kuka.blend is located in the data/robots directory GroundRobot.__init__(self, 'mysim/data/mysim/robots/sickle.blend', name) self.properties(classpath = "mysim.robots.sickle.Sickle") # head self.arm = Armature(armature_name = "Armature") self.arm_pose = ArmaturePose() self.arm_pose.name = "pose" self.arm.append(self.arm_pose) self.append(self.arm) def add_interface(self, interface): if interface == "socket": self.arm.add_service('socket') # TODO Use a joint state publisher thing that PR2 uses? self.arm_pose.add_service('socket')