display.py 1.24 KB
Newer Older
Guilhem Saurel's avatar
Guilhem Saurel committed
1
2
#!/usr/bin/env python

3
import sys
Guilhem Saurel's avatar
Guilhem Saurel committed
4
5

import robots_loader
6
7
8
9

DISPLAY_HYQ = 'hyq' in sys.argv
DISPLAY_TALOS = 'talos' in sys.argv
DISPLAY_TALOS_ARM = 'talos_arm' in sys.argv
10
DISPLAY_TALOS_LEGS = 'talos_legs' in sys.argv
11
12
13
14
15
DISPLAY_TIAGO = 'tiago' in sys.argv
DISPLAY_TIAGO_NO_HAND = 'tiago_no_hand' in sys.argv
DISPLAY_ICUB = 'icub' in sys.argv

if DISPLAY_HYQ:
Guilhem Saurel's avatar
Guilhem Saurel committed
16
    hyq = robots_loader.loadHyQ()
17
    hyq.initViewer(loadModel=True)
18
19
20
    hyq.display(hyq.q0)

if DISPLAY_TALOS:
Guilhem Saurel's avatar
Guilhem Saurel committed
21
    talos = robots_loader.loadTalos()
22
    talos.initViewer(loadModel=True)
23
24
25
    talos.display(talos.q0)

if DISPLAY_TALOS_ARM:
Guilhem Saurel's avatar
Guilhem Saurel committed
26
    talos_arm = robots_loader.loadTalosArm()
27
    talos_arm.initViewer(loadModel=True)
28
29
    talos_arm.display(talos_arm.q0)

30
if DISPLAY_TALOS_LEGS:
Guilhem Saurel's avatar
Guilhem Saurel committed
31
    talos_legs = robots_loader.loadTalosLegs()
32
33
34
    talos_legs.initViewer(loadModel=True)
    talos_legs.display(talos_legs.q0)

35
if DISPLAY_TIAGO:
Guilhem Saurel's avatar
Guilhem Saurel committed
36
    tiago = robots_loader.loadTiago()
37
    tiago.initViewer(loadModel=True)
38
39
40
    tiago.display(tiago.q0)

if DISPLAY_TIAGO_NO_HAND:
Guilhem Saurel's avatar
Guilhem Saurel committed
41
    tiago_no_hand = robots_loader.loadTiagoNoHand()
42
    tiago_no_hand.initViewer(loadModel=True)
43
44
45
    tiago_no_hand.display(tiago_no_hand.q0)

if DISPLAY_ICUB:
Guilhem Saurel's avatar
Guilhem Saurel committed
46
    icub = robots_loader.loadICub()
47
    icub.initViewer(loadModel=True)
48
    icub.display(icub.q0)