コード例 #1
0
def launchRobotQuestionEndRight(i):
    """To play the movements of the right robot at the end of a question"""
    if d.robots_definition == "2 Keepon":
        a = k.launch("quiz",5,keepon_right,i)
        a.start()
    elif d.robots_definition == "2 Nao":
        a = n.launch("quiz",5,robot_IP_right,port_right,i)
        a.start()
    elif d.robots_definition == "Left Keepon & Right Nao":
        a = n.launch("quiz",5,robot_IP_right,port_right,i)
        a.start()
    elif d.robots_definition == "Left Nao & Right Keepon":
        a = k.launch("quiz",5,keepon_right,i)
        a.start()
    ######################## FOR TESTS DURING DEVELOPMENT #####################
    elif d.robots_definition == "Test only right Keepon ":
        a = k.launch("quiz",5,keepon_right,i)
        a.start()
    elif d.robots_definition == "Test 1 real Nao (left)" or \
         d.robots_definition == "Test 1 movements nao (left) and voices on computer" or \
         d.robots_definition == "Test no voices no movements" or\
         d.robots_definition == "Test only voices Nao on computer" or\
         d.robots_definition == "Test 1 voices Nao (left)" or \
         d.robots_definition == "Test only voices Keepon":
        return
コード例 #2
0
def launchRobotEnd():
    """To play the movements of the robot at the end window"""
    if d.robots_definition == "2 Keepon":
        a = k.launch("End window",3,keepon_right)
        b = k.launch("End window",2,keepon_left)
        a.start()
        b.start()
    elif d.robots_definition == "2 Nao":
        a = n.launch("End window",3,robot_IP_right,port_right)
        b = n.launch("End window",2,robot_IP_left,port_left)
        a.start()
        b.start()
    elif d.robots_definition == "Left Keepon & Right Nao":
        a = n.launch("End window",3,robot_IP_right,port_right)
        b = k.launch("End window",2,keepon_left)
        a.start()
        b.start()
    elif d.robots_definition == "Left Nao & Right Keepon":
        a = k.launch("End window",3,keepon_right)
        b = n.launch("End window",2,robot_IP_left,port_left)
        a.start()
        b.start()
    ######################## FOR TESTS DURING DEVELOPMENT #####################
    elif d.robots_definition == "Test 1 real Nao (left)" or \
         d.robots_definition == "Test 1 movements nao (left) and voices on computer":
        b = n.launch("End window",2,robot_IP_left,port_left)
        b.start()
    elif d.robots_definition == "Test only right Keepon":
        a = k.launch("End window",3,keepon_right)
        a.start()
    elif d.robots_definition == "Test no voices no movements" or \
         d.robots_definition == "Test only voices Nao on computer" or\
         d.robots_definition == "Test 1 voices Nao (left)" or \
         d.robots_definition == "Test only voices Keepon":
        return