diff options
Diffstat (limited to 'src/align_detector.c')
-rw-r--r-- | src/align_detector.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/align_detector.c b/src/align_detector.c index 8a1af962..c6e73497 100644 --- a/src/align_detector.c +++ b/src/align_detector.c @@ -69,6 +69,8 @@ int main(int argc, char *argv[]) char *out_geom = NULL; int level = 0; char *rval; + int i; + FILE *fh; /* Long options */ const struct option longopts[] = { @@ -136,5 +138,24 @@ int main(int argc, char *argv[]) return 1; } + fh = fopen("millepede.txt", "w"); + if ( fh == NULL ) { + ERROR("Couldn't open Millepede steering file\n"); + return 1; + } + + for ( i=optind; i<argc; i++ ) { + fprintf(fh, "%s\n", argv[i]); + } + + fprintf(fh, "Parameter\n"); + fprintf(fh, "1 0 0\n"); + fprintf(fh, "2 0 0\n"); + fprintf(fh, "method inversion 5 0.1\n"); + fprintf(fh, "end\n"); + fclose(fh); + + system("pede millepede.txt"); + return 0; } |