Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
sample
simTest2.py
Go to the documentation of this file.
1
#
2
# test script for Simulator and Viewer components
3
#
4
# start SimulatorComp and ViewerComp before running this script
5
#
6
import
rtm
7
import
commands
8
9
openhrp_dir = commands.getoutput(
"pkg-config --variable=prefix openhrp3.1"
)
10
project =
"file://"
+openhrp_dir+
"/share/OpenHRP-3.1/sample/project/SamplePD.xml"
11
sim =
rtm.findRTC
(
"Simulator0"
)
12
print
"sim:"
,sim
13
sim.setProperty(
"project"
, project)
14
vwr =
rtm.findRTC
(
"Viewer0"
)
15
print
"vwr:"
,vwr
16
vwr.setProperty(
"project"
, project)
17
rtm.connectPorts
(sim.port(
"state"
), vwr.port(
"state"
))
18
vwr.start()
19
sim.start()
rtm.findRTC
def findRTC(name, rnc=None)
get RT component
Definition:
jython/rtm.py:341
rtm.connectPorts
def connectPorts(outP, inPs, subscription="flush", dataflow="Push", bufferlength=1, rate=1000)
connect ports
Definition:
jython/rtm.py:433
hrpsys
Author(s): AIST, Fumio Kanehiro
autogenerated on Thu May 6 2021 02:41:51