From 4a937e16080be149b47b8d320264d28577bcd33a Mon Sep 17 00:00:00 2001 From: Ferdi Franceschini Date: Fri, 30 May 2008 10:14:56 +1000 Subject: [PATCH] extraconfig.tcl should not be kept on CVS or deployed to ics boxes. We should put commissioning configurations in a config/commissioning directory r2600 | ffr | 2008-05-30 10:14:56 +1000 (Fri, 30 May 2008) | 3 lines --- .../instrument/reflectometer/extraconfig.tcl | 41 ---------- site_ansto/instrument/rsd/extraconfig.tcl | 75 ------------------- 2 files changed, 116 deletions(-) delete mode 100644 site_ansto/instrument/reflectometer/extraconfig.tcl delete mode 100644 site_ansto/instrument/rsd/extraconfig.tcl diff --git a/site_ansto/instrument/reflectometer/extraconfig.tcl b/site_ansto/instrument/reflectometer/extraconfig.tcl deleted file mode 100644 index 587d0bd7..00000000 --- a/site_ansto/instrument/reflectometer/extraconfig.tcl +++ /dev/null @@ -1,41 +0,0 @@ -VarMake detector_distance Float User -VarMake detector_base Float User -VarMake slit4_distance Float User -VarMake slit4_base Float User -VarMake sample_distance Float User -VarMake sample_base Float User -VarMake slit3_distance Float User -VarMake slit3_base Float User - -detector_distance 10000 -detector_base 300 -slit4_distance 6000 -slit4_base 20 -sample_distance 5800 -sample_base 50 -slit3_distance 5600 -slit3_base 20 - -proc set_two_theta { arg } { - set rad [expr ($arg/180.0)*3.1415926535897932384626433832795] - set d1 [expr [SplitReply [detector_distance]] - [SplitReply [sample_distance]]] - set d2 [expr [SplitReply [slit4_distance]] - [SplitReply [sample_distance]]] - set h1 [expr [SplitReply [detector_base]] + $d1 * tan($rad)] - set h2 [expr [SplitReply [slit4_base]] + $d2 * tan($rad)] - return "dz=$h1,st4vt=$h2" -} -publish set_two_theta user - -proc get_two_theta {} { - set d1 [expr [SplitReply [detector_distance]] - [SplitReply [sample_distance]]] - set h1 [expr [SplitReply [dz]] - [SplitReply [detector_base]]] - return [expr (180.0*atan2($h1, $d1))/3.1415926535897932384626433832795] -} -publish get_two_theta user - -MakeConfigurableMotor two_theta -two_theta readscript get_two_theta -two_theta drivescript set_two_theta -sicslist setatt two_theta klass sample -sicslist setatt two_theta long_name two_theta -sicslist setatt two_theta units degrees diff --git a/site_ansto/instrument/rsd/extraconfig.tcl b/site_ansto/instrument/rsd/extraconfig.tcl deleted file mode 100644 index cbc98cdf..00000000 --- a/site_ansto/instrument/rsd/extraconfig.tcl +++ /dev/null @@ -1,75 +0,0 @@ -sz fixed 1 -sz send GRB=0 - -Motor sz1 $motor_driver_type [params \ - asyncqueue mc2\ - axis A\ - units mm\ - hardlowerlim 0\ - hardupperlim 750\ - maxSpeed 5\ - maxAccel 1\ - maxDecel 1\ - stepsPerX [expr -25000.0*(24.0/25.0)*50/11.0]\ - absenc 1\ - absenchome $sz_home\ - cntsPerX -[expr (1<<15)/260.09]] -setHomeandRange -motor sz1 -home 0 -lowrange 0 -uprange 750 -sz1 speed 5 -sz1 part sample -sz1 backlash_offset -1 -sz1 blockage_ratio 5 -sz1 precision 0.025 -sz1 creep_offset 0.1 -sz1 creep_precision 0.01 -sz1 long_name translate_z1 - -Motor sz2 $motor_driver_type [params \ - asyncqueue mc2\ - axis B\ - encoderAxis A\ - units mm\ - hardlowerlim 0\ - hardupperlim 750\ - maxSpeed 5\ - maxAccel 1\ - maxDecel 1\ - stepsPerX [expr -25000.0*(24.0/25.0)*50/11.0]\ - absenc 1\ - absenchome $sz_home\ - cntsPerX -[expr (1<<15)/260.09]] -setHomeandRange -motor sz2 -home 0 -lowrange 0 -uprange 750 -sz2 speed 5 -sz2 part sample -sz2 backlash_offset -1 -sz2 blockage_ratio 5 -sz2 precision 0.025 -sz2 creep_offset 0.1 -sz2 creep_precision 0.01 -sz2 long_name translate_z2 - -fileeval vmotors.tcl - -proc home_z {} { - sz send GRB=0 - sz1 send sh` - sz2 send sh` - sz1 send jg`=-25000 - sz2 send jg`=-25000 - sz1 send bg` - sz2 send bg` - set running 1 - while { $running > 0 } { - set running 0 - set line [sz1 send MG _bg`] - set line [string trimright $line ":"] - set sw [expr int([string trimleft $line " 0"])] - if { $sw > 0 } { set running 1 } - set line [sz2 send MG _bg`] - set line [string trimright $line ":"] - set sw [expr int([string trimleft $line " 0"])] - if { $sw > 0 } { set running 1 } - } - sz1 send mo` - sz2 send mo` -}