diff --git a/Shell/run_cave.py b/Shell/run_cave.py
index e0805b2531f478bec5d3b337e1318dd092aa2c2d..f8528960291068ec1a8ef9212d08843e79464433 100644
--- a/Shell/run_cave.py
+++ b/Shell/run_cave.py
@@ -8,8 +8,7 @@ dtrack_filepath = "/home/vrsw/DTrack/DTrack2_v2.13.0/bin/DTrack2.bin"
vrpn_filepath = "/home/vrsw/vrpn/vrpn_git/build_clang/server_src/vrpn_server"
vrpn_config_filepath = "/home/vrsw/vrpn/vrpn_git/build_clang/server_src/vrpn.cfg"
-hostname_lookup_table =
-{
+hostname_lookup_table = {
"10.0.1.1" : "ngs01",
"10.0.1.2" : "ngs02",
"10.0.1.3" : "ngs03",
@@ -54,14 +53,16 @@ def main():
lines = configuration_file.readlines()
for line in lines:
- name = "temp"
- ip = "temp"
- is_left = (name.find("eye_left") != -1)
- # TODO: Fill.
+ if line.startsWith("#") or ("[cluster_node]" not in line) or ("master" in line):
+ continue
+
+ split_line = line.split()
+ name = split_line[1][3:]
+ ip = split_line[2][5:]
processes.append(subprocess.Popen([
"ssh " + hostname_lookup_table[ip] +
- " export XAUTHORITY=/var/run/Xauthority-vr; export DISPLAY=:0." + ("1" if is_left else "0") + ";"
+ " export XAUTHORITY=/var/run/Xauthority-vr; export DISPLAY=:0." + ("1" if ("eye_left" in name) else "0") + ";"
" /bin/nice_av00 -n -15 " + application_filepath +
" ResX=1920 ResY=1200 WinX=0 WinY=0 -fixedseed -nosplash -opengl4 -fullscreen" +
" dc_cfg=" + configuration_filepath + " dc_node=" + name + " -dc_cluster -dc_dev_mono"