Changeset 8862 for trunk/MagicSoft/Cosy/cosy.cc
- Timestamp:
- 02/13/08 19:44:39 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Cosy/cosy.cc
r8860 r8862 10 10 #include "vmodican.h" 11 11 12 #include "MEnv.h" 12 13 #include "MArgs.h" 13 14 #include "MCosy.h" … … 50 51 gLog << " Options:" << endl; 51 52 gLog.Usage(); 53 gLog << " --debug-env=0 Disable debugging setting resources <default>" << endl; 54 gLog << " --debug-env[=1] Display untouched resources after program execution" << endl; 55 gLog << " --debug-env=2 Display untouched resources after eventloop setup" << endl; 56 gLog << " --debug-env=3 Debug setting resources from resource file and command line" << endl; 57 gLog << " --debug-mem Debug memory usage" << endl << endl; 52 58 gLog << " --debug-threads Debug threads" << endl << endl; 59 gLog << " --rc=Name:option Set or overwrite a resource of the resource file." << endl << endl; 53 60 gLog << " --version, -V Show startup message with version number" << endl; 54 61 gLog << " -?, -h, --help This help" << endl << endl; … … 80 87 } 81 88 82 const Int_t channel = arg.GetIntAndRemove("--channel=", 0); 83 const Bool_t kDebugMem = arg.HasOnlyAndRemove("--debug-mem"); 84 const Bool_t kDebugThreads = arg.HasOnlyAndRemove("--debug-threads"); 89 const Int_t channel = arg.GetIntAndRemove("--channel=", 0); 90 const Bool_t kDebugMem = arg.HasOnlyAndRemove("--debug-mem"); 91 const Bool_t kDebugThreads = arg.HasOnlyAndRemove("--debug-threads"); 92 const TString sps = arg.GetStringAndRemove("--sps=", "127.0.0.1"); 93 const TString ceco = arg.GetStringAndRemove("--cc=", "ceco"); // ceco 94 const TString pointing = arg.GetStringAndRemove("--pointing-model=", "bending2.txt"); // ceco 95 const TString kConfig = arg.GetStringAndRemove("--config=", ".cosyrc"); // ceco 96 Int_t kDebugEnv = arg.HasOnlyAndRemove("--debug-env") ? 1 : 0; 97 kDebugEnv = arg.GetIntAndRemove("--debug-env=", kDebugEnv); 85 98 86 99 // … … 93 106 return 2; 94 107 } 95 /* 108 96 109 // 97 110 // Now we access/read the resource file. This will remove all … … 108 121 if (!env.TakeEnv(arg, kDebugEnv>2)) 109 122 return 0xfd; 110 */ 123 111 124 // 112 125 // check for the right usage of the program (number of options) … … 178 191 } 179 192 */ 180 MCosy *cosy = new MCosy( );181 182 Interface *interface = new Ethernet( "127.0.0.1", 5357, 5358, cosy);193 MCosy *cosy = new MCosy(env, ceco, pointing); 194 195 Interface *interface = new Ethernet(sps, 5357, 5358, cosy); 183 196 // Interface *interface = new VmodIcan(cosy, "/dev/dpm_00", 125); 184 197 185 198 gLog << all << "- Starting MCosy." << endl; 186 199 187 cosy->Start(); 200 cosy->Start(env); 201 202 // FIXME: Is this the right position? 203 if (kDebugEnv>0) 204 env.PrintUntouched(); 205 188 206 189 207 MStarguider *client=0;
Note:
See TracChangeset
for help on using the changeset viewer.