def __init__(self,language): self.path2webi = roslib.packages.get_pkg_dir("qbo_webi") self.camera="left" self.language = language self.templatelookup = TemplateLookup(directories=['./']) self.htmlTemplate = Template(filename='teleoperation/templates/teleoperationTemplate.html',lookup=self.templatelookup) self.jsTemplate = Template(filename='teleoperation/templates/teleoperationTemplate.js') #self.variablesTemplate = Template(filename='static/js/generalVariables.js') self.cmd_vel_pub=rospy.Publisher('/cmd_vel', Twist) self.cmd_joints_pub=rospy.Publisher('/cmd_joints', JointState) self.client_speak = rospy.ServiceProxy("/qbo_talk/festival_say", Text2Speach) self.mjpegServer = MjpegServerFunctions() self.image_size=[640,480] self.head_velocity_factor = 2.0 self.head_move_type = 1 #self.qbo_mouth_control=mouth() self.mouth_pub=rospy.Publisher('/cmd_mouth', Mouth_msg) self.vMouths=[] self.vMouths.append(Mouth(0,"Happy",476160,)); self.vMouths.append(Mouth(1,"Sad",571392)); self.vMouths.append(Mouth(2,"Ooh",476718)); self.vMouths.append(Mouth(3,"Pucker the mouth to the right",17376)); self.vMouths.append(Mouth(4,"Pucker the mouth to the left",2016)); self.vMouths.append(Mouth(5,"Straight face",31744)); self.vMouths.append(Mouth(6,"Small mouth",141636)); self.vMouths.append(Mouth(7,"Speak 1",31)); self.vMouths.append(Mouth(8,"Speak 2",479)); self.vMouths.append(Mouth(9,"Speak 3",14911)); self.vMouths.append(Mouth(10,"Speak 4",15359)); self.vMouths.append(Mouth(11,"Speak 5",476735)); self.vMouths.append(Mouth(12,"Speak 6",491519)); self.vMouths.append(Mouth(13,"None",0)); self.vMouths.append(Mouth(14,"surprise",476718)); self.vMouths.append(Mouth(15,"regular",69904)); self.vMouths.append(Mouth(16,"tongue",283616)); self.command = RunCmd() self.chars = string.ascii_letters + string.digits #Variables for android functions comming from Tornado(qbo_http_api_login) self.linphoneRunning = False self.auth = "notDefined" self.authBot = "notDefined" self.envi = "" self.processSipd = "" self.processSiprtmp = "" self.processLinphone = "" self.processAudioControl = "" self.ecoCancelationId = "notDefined"