Esempio n. 1
0
def write_a_word(word, client, hRobot):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    curr_pos[1] = 70
    client.robot_move(hRobot, 2, list_to_string_position(curr_pos),
                      "SPEED=100")

    for c in word:
        write_a_character(c, client, hRobot)
        to_the_next_char(client, hRobot)
Esempio n. 2
0
def move_to_photo_position(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    # curr_pos = [x, y, z, Rx, Ry, Rz]
    curr_pos[0] = 150
    curr_pos[1] = -45
    curr_pos[2] = 235
    curr_pos[3] = 180
    curr_pos[4] = 0
    curr_pos[5] = 180
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 3
0
def replace_the_highlighter(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    curr_pos[0] = 145
    curr_pos[1] = -145
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[2] = 89
    curr_pos[3] = 180
    curr_pos[4] = 0
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 4
0
def write_maiusc_i(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")

    curr_pos[2] = 85
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[0] -= 20
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[2] = 105
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")

    # to allow the subsequent characters to be written on the same line
    curr_pos[0] += 20
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 5
0
def move_to_the_highligther(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    # curr_pos = [x, y, z, Rx, Ry, Rz]
    # first move on y axis to avoid to hit the highlighter
    curr_pos[1] = -145
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[0] = 145
    curr_pos[2] = 86
    curr_pos[3] = 180
    curr_pos[4] = 0
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[5] = 180
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 6
0
def move_to_new_pos(client, hRobot, new_x, new_y, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    curr_pos[0] = new_x
    curr_pos[1] = new_y
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 7
0
def write_three(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")

    curr_pos[0] -= 5
    curr_pos[1] += 5
    curr_pos[2] = 105
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[2] = 85
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[0] += 5
    curr_pos[1] -= 5
    client.robot_move(hRobot, 1, "@P " + list_to_string_position(curr_pos),
                      "SPEED=100")
    curr_pos[0] -= 5
    curr_pos[1] -= 5
    client.robot_move(hRobot, 1, "@P " + list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[0] -= 5
    curr_pos[1] += 5
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")

    # Half of the three
    curr_pos[0] -= 5
    curr_pos[1] -= 5
    client.robot_move(hRobot, 1, "@P " + list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[0] -= 5
    curr_pos[1] += 5
    client.robot_move(hRobot, 1, "@P " + list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[0] += 5
    curr_pos[1] += 5
    client.robot_move(hRobot, 1, "@P " + list_to_string_position(curr_pos),
                      "SPEED=100")

    curr_pos[2] = 105
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")

    # to allow the subsequent characters to be written on the same line
    curr_pos[0] += 15
    curr_pos[1] -= 5
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 8
0
def go_up(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")
    curr_pos[2] = 200
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")
Esempio n. 9
0
def to_the_next_char(client, hRobot, mode=2):
    curr_pos = robot_getvar(client, hRobot, "@CURRENT_POSITION")

    curr_pos[1] -= 15
    client.robot_move(hRobot, mode, list_to_string_position(curr_pos),
                      "SPEED=100")