diff --git a/site_ansto/instrument/config/commands/hvcommands.tcl b/site_ansto/instrument/config/commands/hvcommands.tcl index e1b8456c..50da9008 100644 --- a/site_ansto/instrument/config/commands/hvcommands.tcl +++ b/site_ansto/instrument/config/commands/hvcommands.tcl @@ -1,5 +1,9 @@ -set scaleval 1000.0 +set scaleval 2000.0 +set rampstep 100 +set rampdelay 3 +set motdir 1 +set pulserstate 0 proc SetVoltScale {newscaleval} { global scaleval @@ -11,17 +15,58 @@ proc VoltScale {involt} { return [expr {($involt*1.0)/$scaleval}] } +proc SetRampParms {_rampstep _rampdelay} { + global rampstep rampdelay + set rampstep $_rampstep + set rampdelay $_rampdelay +} + proc SetVolt {volt} { + global pulserstate if {$volt== 0} { PulserOff + set pulserstate 0 } else { set pulservolt [VoltScale $volt] - sct_pulser send "VOLT:OFFS $pulservolt; OFFS?" - PulserDC $pulservolt - PulserOn +# sct_pulser send "VOLT:OFFS $pulservolt; OFFS?" +# PulserDC $pulservolt + if {$pulserstate==0} { + PulserDC $pulservolt + PulserOn + set pulserstate 1 + } else { + sct_pulser send "VOLT:OFFS $pulservolt; OFFS?" + PulserOn + } } } +proc VoltSetStep {start step fin delay} { + set i [expr {$start*1.0}] + set loopvar 1 + SetVolt $i + if {($start == $fin) || ($step == 0)} {break} + while {$loopvar} { + wait $delay + if {($start < $fin)} { + set i [expr {$i + abs($step)}] + if {$i >= $fin} { + set i $fin + set loopvar 0 + } + } + if {($start > $fin)} { + set i [expr {$i - abs($step)}] + if {$i <= $fin} { + set i $fin + set loopvar 0 + } + } + SetVolt $i + } +} + + proc GetVolt {} { sct_pulser transact VOLT:OFFS? } @@ -29,25 +74,18 @@ proc GetVolt {} { proc SingleVolt {volt oscno} { histmem mode unlimited newfile HISTOGRAM_XY - if {$volt== 0} { - PulserOff - } else { - set pulservolt [VoltScale $volt] - sct_pulser send "VOLT:OFFS $pulservolt; OFFS?" - pulserDC $pulservolt - PulserOn - } - oscmd start $oscno - hmm countblock + SetVolt $volt + oct oscillate_count $oscno + oct oscillate start save 0 - oscmd stop + } proc SetDC {} { pulseroff #NOTE: Setting FUNC DC generates a remote ctrl error if the # burst mode happens to be on - set resp [sct_pulser transact "BURS:STAT OFF;:FUNC DC;:VOLT:OFFS 0; OFFS?"] + set resp [sct_pulser send "BURS:STAT OFF;:FUNC DC;:VOLT:OFFS 0; OFFS?"] pulseron } @@ -61,55 +99,58 @@ proc VoltRamp {start step fin oscno} { set j [expr {$i*$step+$start}] if {$j> $fin && $step > 0} {break} if {$j< $fin && $step < 0} {break} - if {$j== 0} { - PulserOff - } else { - set pulservolt [VoltScale $j] - pulserDC $pulservolt - PulserOn - } - oscmd start $oscno - hmm countblock + SetVolt $j + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } -proc VoltTextureRamp {start step fin mot tstart tstep tfin oscno} { - histmem mode unlimited - - - set loopvar 1 +proc SingleVTexScan {mot tstart tstep tfin oscno} { + global motdir + broadcast in singlevtexscan + set loopvar 1 + set i_bool 0 + histmem mode unlimited + if {$motdir == 1} { + set currentmot $tstart set i 0 - while {$loopvar} { - set j [expr {$i*$step+$start}] - if {$j> $fin && $step > 0} {break} - if {$j< $fin && $step < 0} {break} - if {$j== 0} { - PulserOff - } else { - set pulservolt [VoltScale $j] - pulserDC $pulservolt - PulserOn - } - sampledescription voltage $j - broadcast voltage $j - newfile HISTOGRAM_XY - set m 0 - while {1} { - set n [expr {$m*$tstep+$tstart}] - if {$n> $tfin && $tstep > 0} {break} - if {$n< $tfin && $tstep < 0} {break} - drive $mot $n - oscmd start $oscno - hmm countblock - save $m - incr m - } - oscmd stop - incr i - } + } else { + set currentmot $tfin + set i [expr {int(($tfin-$tstart)/$tstep)}] + } + newfile HISTOGRAM_XY + while {$i_bool==0} { + drive $mot $currentmot + oct oscillate_count $oscno + oct oscillate start + hmm countblock + save $i + if {($motdir > 0)} { + + set currentmot [expr {$currentmot + $tstep}] + if {$currentmot > $tfin} {set i_bool 1} + incr i + } else { + set currentmot [expr {$currentmot - $tstep}] + if {$currentmot < $tstart} {set i_bool 1} + incr i -1 + } + } + set motdir [expr {(-1*$motdir)}] +} + +proc VListTexScan {voltlist mot tstart tstep tfin oscno} { + global rampstep rampdelay + set curvolt [lindex $voltlist 0] + broadcast $curvolt + SetVolt $curvolt + foreach volt $voltlist { + broadcast $volt + VoltSetStep $curvolt $rampstep $volt $rampdelay + SingleVTexScan $mot $tstart $tstep $tfin $oscno + } } @@ -124,12 +165,10 @@ proc SquarePulseTexture {motor start step numsteps volt freq bins oscno} { for {set i 0} {$i < $numsteps} {incr i} { drive $motor [expr $i*$step+$start] - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i } - - oscmd stop } proc UniPulseTexture {motor start step numsteps volt freq bins oscno} { @@ -144,12 +183,10 @@ proc UniPulseTexture {motor start step numsteps volt freq bins oscno} { for {set i 0} {$i < $numsteps} {incr i} { drive $motor [expr $i*$step+$start] - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i } - - oscmd stop } @@ -162,8 +199,8 @@ proc BehlkePulseTexture {motor start step numsteps freq bins oscno} { PulserOn for {set i 0} {$i < $numsteps} {incr i} { drive $motor [expr $i*$step+$start] - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i } } @@ -189,12 +226,11 @@ proc SquarePulseVolt {start step fin freq bins oscno} { PulserOn # sct_pulser send "APPL:SQU $freq,$pulservolt,0" } - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } proc SquarePulseFreq {volt freqlist bins oscno} { @@ -209,12 +245,11 @@ proc SquarePulseFreq {volt freqlist bins oscno} { PulserSquare $freq $pulservolt PulserOn # sct_pulser send "APPL:SQU $freq,$pulservolt,0" - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } proc BehlkePulseFreq {freqlist bins oscno} { @@ -227,12 +262,11 @@ proc BehlkePulseFreq {freqlist bins oscno} { wait 3 PulserSquareOffs $freq 2.5 2.5 PulserOn - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } proc SinePulseFreq {volt freqlist bins oscno} { @@ -246,12 +280,11 @@ proc SinePulseFreq {volt freqlist bins oscno} { wait 3 PulserSin $freq $pulservolt PulserOn - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } @@ -271,12 +304,11 @@ proc UniPulseFreq {volt freqlist bins oscno} { PulserSquareOffs $freq $pulservolt $pulseroffs PulserOn # sct_pulser send "APPL:SQU $freq,$pulservolt,[expr {$pulservolt/2}]" - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $i incr i } - oscmd stop } proc UniPulseFatigue {volt freq bins oscno reps runs} { @@ -290,13 +322,14 @@ proc UniPulseFatigue {volt freq bins oscno reps runs} { for {set i 0} {$i<$runs} {incr i} { newfile HISTOGRAM_XYT for {set j 0} {$j<$reps} {incr j} { - oscmd start $oscno - hmm countblock + oct oscillate_count $oscno + oct oscillate start save $j } oscmd stop } PulserOff + set pulserstate 0 Histmem_strobo_off } @@ -315,6 +348,7 @@ proc PulserBurst {} { if {[string first 1 $sval] >-1} {break} } PulserOff + set pulserstate 0 } @@ -338,6 +372,7 @@ proc VoltPulseRun {vlo vhi freq cycl} { sct_pulser send "BURS:NCYC $prem; NCYC?" PulserBurst PulserOff + set pulserstate 0 sct_pulser send "BURS:STAT OFF; STAT?" } @@ -376,6 +411,7 @@ proc OneTri {volt period} { sct_pulser send "BURS:NCYC 1; NCYC?" PulserBurst PulserOff + set pulserstat 0 } @@ -384,6 +420,9 @@ publish GetVolt user publish SetDC user publish SetVolt user publish SetVoltScale user +publish SingleVTexScan user +publish VListTexScan user +publish SetRampParms user publish SingleVolt user publish VoltRamp user publish SquarePulseVolt user @@ -399,5 +438,6 @@ publish SquarePulseTexture user publish BehlkePulseTexture user publish BehlkePulseFreq user publish UniPulseTexture user - +publish VoltSetStep user + diff --git a/site_ansto/instrument/config/commands/pulser.tcl b/site_ansto/instrument/config/commands/pulser.tcl index 99b2ecaf..bef9a102 100644 --- a/site_ansto/instrument/config/commands/pulser.tcl +++ b/site_ansto/instrument/config/commands/pulser.tcl @@ -54,7 +54,7 @@ proc PulserSquareOffs {Freq Volt Offs} { proc PulserDC {Volt} { #NOTE: Setting FUNC DC generates a remote ctrl error if the # burst mode happens to be on - set resp [sct_pulser transact "BURS:STAT OFF;:FUNC DC;:VOLT:OFFS $Volt; OFFS?"] + set resp [sct_pulser send "BURS:STAT OFF;:FUNC DC;:VOLT:OFFS $Volt; OFFS?"] broadcast $resp } diff --git a/site_ansto/instrument/config/counter/counter_common_1.tcl b/site_ansto/instrument/config/counter/counter_common_1.tcl index 1a16dd32..9ad2782c 100644 --- a/site_ansto/instrument/config/counter/counter_common_1.tcl +++ b/site_ansto/instrument/config/counter/counter_common_1.tcl @@ -7,7 +7,6 @@ namespace eval counter { proc ::counter::transferscript {} { variable isc_numchannels - bm status set val [SplitReply [bm1 gettime]] for {set i 1} {$i <= $isc_numchannels} {incr i} { append val " [SplitReply [bm$i getcounts] ]" diff --git a/site_ansto/instrument/config/environment/temperature/sct_lakeshore_370.tcl b/site_ansto/instrument/config/environment/temperature/sct_lakeshore_370.tcl index 74233b4a..6fe63945 100644 --- a/site_ansto/instrument/config/environment/temperature/sct_lakeshore_370.tcl +++ b/site_ansto/instrument/config/environment/temperature/sct_lakeshore_370.tcl @@ -50,7 +50,7 @@ namespace eval ::scobj::[set vendor]_[set device] { proc debug_log {debug_level arg_string} { # write a timestamped string message to a log file for debugging - set debug_threshold 0 + set debug_threshold 5 if {$debug_level >= $debug_threshold} { set fd [open "[set [namespace current]::log_file]" "a"] set line "[clock format [clock seconds] -format "%T"] $arg_string" diff --git a/site_ansto/instrument/config/environment/temperature/sct_lakeshore_m370.tcl b/site_ansto/instrument/config/environment/temperature/sct_lakeshore_m370.tcl index 401527b9..8e6e7de7 100644 --- a/site_ansto/instrument/config/environment/temperature/sct_lakeshore_m370.tcl +++ b/site_ansto/instrument/config/environment/temperature/sct_lakeshore_m370.tcl @@ -32,7 +32,7 @@ proc ::scobj::lakeshore_m370::mkDriver { sct_controller name device_class simula set ns "[namespace current]" set catch_status [ catch { - MakeSICSObj ${name} SCT_OBJECT user float + MakeSICSObj ${name} SCT_OBJECT user none sicslist setatt ${name} klass ${device_class} sicslist setatt ${name} long_name ${name} @@ -43,8 +43,8 @@ proc ::scobj::lakeshore_m370::mkDriver { sct_controller name device_class simula hsetprop ${scobj_hpath} debug_threshold 5 # mkDriver hook code starts ::scobj::lakeshore_370::mk_sct_driver $sct_controller environment $name $tol - hsetprop ${scobj_hpath}/setpoint permlink data_set T[format "%02d" ${id}]SP01 - hsetprop ${scobj_hpath}/setpoint @description T[format "%02d" ${id}]SP01 + hsetprop ${scobj_hpath}/Loop1/setpoint permlink data_set T[format "%02d" ${id}]SP01 + hsetprop ${scobj_hpath}/Loop1/setpoint @description T[format "%02d" ${id}]SP01 hsetprop ${scobj_hpath}/Sensor/value permlink data_set T[format "%02d" ${id}]S01 hsetprop ${scobj_hpath}/Sensor/value @description T[format "%02d" ${id}]S01 # mkDriver hook code ends diff --git a/site_ansto/instrument/config/environment/temperature/sct_oxford_mercury.tcl b/site_ansto/instrument/config/environment/temperature/sct_oxford_mercury.tcl index 22ebad6b..67266192 100644 --- a/site_ansto/instrument/config/environment/temperature/sct_oxford_mercury.tcl +++ b/site_ansto/instrument/config/environment/temperature/sct_oxford_mercury.tcl @@ -58,7 +58,7 @@ namespace eval ::scobj::[set vendor]_[set device] { proc debug_log {debug_level arg_string} { # write a timestamped string message to a log file for debugging - set debug_threshold 0 + set debug_threshold 5 if {$debug_level >= $debug_threshold} { set fd [open "[set [namespace current]::log_file]" "a"] set line "[clock format [clock seconds] -format "%T"] $arg_string" diff --git a/site_ansto/instrument/config/environment/temperature/west400.tcl b/site_ansto/instrument/config/environment/temperature/west400.tcl index 586247a3..71945a84 100644 --- a/site_ansto/instrument/config/environment/temperature/west400.tcl +++ b/site_ansto/instrument/config/environment/temperature/west400.tcl @@ -20,10 +20,12 @@ MakeRS232Controller sertemp $IP 502 sertemp timeout 300 sertemp sendterminator 0x0 sertemp replyterminator 0x0 -EvFactory new tc1 west4100 sertemp $ID 2 +#ffr 2014-09-22: The modbus addr should be 1 for single port moxas (Not $ID which is a SICS ID) +# EvFactory new tc1 west4100 sertemp $ID 2 +EvFactory new $temp_sobj west4100 sertemp 1 2 -sicslist setatt tc1 units kelvin -sicslist setatt tc1 klass @none +sicslist setatt $temp_sobj units kelvin +sicslist setatt $temp_sobj klass @none } # @brief Adds a west400 temperature controller object. diff --git a/site_ansto/instrument/hipd/config/commands/commands.tcl b/site_ansto/instrument/hipd/config/commands/commands.tcl index 75bd42d8..0eb6d3bc 100644 --- a/site_ansto/instrument/hipd/config/commands/commands.tcl +++ b/site_ansto/instrument/hipd/config/commands/commands.tcl @@ -6,7 +6,7 @@ namespace eval motor { } namespace eval ajscmds { -namespace export SetRadColl SimpleRun SimpleScan RadCollRun RadCollTimed RadCollScan +namespace export SetRadColl SimpleRun SimpleScan RadCollRun RadCollTimed RadCollScan RadCollBiScan # SetRadColl command SetRadColl { @@ -34,13 +34,13 @@ catch { } msg clientput $msg } + # SimpleRun command SimpleRun { float=0:inf steptime int=1:inf numsteps } { -# RadCollOff histmem mode time histmem preset $steptime newfile HISTOGRAM_XY @@ -49,6 +49,7 @@ int=1:inf numsteps save $i } } + # SimpleScan command SimpleScan { text=drivable motor @@ -58,7 +59,6 @@ int=1:inf numsteps float=0:inf steptime } { -# RadCollOff histmem mode time histmem preset $steptime newfile HISTOGRAM_XY @@ -68,13 +68,13 @@ float=0:inf steptime save $i } } + # RadCollRun command RadCollRun { int=1:inf oscno int=1:inf reps } { -# RadCollOn $oscno histmem mode unlimited newfile HISTOGRAM_XY for {set i 0} {$i < $reps} {incr i} { @@ -83,8 +83,8 @@ int=1:inf reps hmm countblock save $i } -# RadCollOff } + # RadCollTimed command RadCollTimed { int=1:inf oscno @@ -99,14 +99,16 @@ float=0:inf time set i 0 set timsecs [expr $time*60] while {$bool == 0} { + oct oscillate_count $oscno + oct oscillate start histmem start block save $i incr i set tim2 [expr [clock seconds] - $tim1] if {$tim2 > $timsecs} {set bool 1} } - RadCollOff } + # RadCollScan command RadCollScan { text=drivable motor @@ -115,8 +117,6 @@ float step int=1:inf numsteps int=1:inf oscno } { - -# RadCollOn $oscno histmem mode unlimited newfile HISTOGRAM_XY for {set i 0} {$i < $numsteps} {incr i} { @@ -126,8 +126,12 @@ int=1:inf oscno hmm countblock save $i } -# RadCollOff } + + + + + } namespace import ::ajscmds::* publish SetRadColl user @@ -140,3 +144,86 @@ publish RadCollScan user proc ::commands::isc_initialize {} { ::commands::ic_initialize } + + +# RadCollScanRange +proc RadCollScanRange {motor start step fin oscno} { + if {$step==0} {break} + if {($start > $fin) && ($step > 0)} {break} + if {($start < $fin) && ($step < 0)} {break} + set i_bool 0 + histmem mode unlimited + set currentmot $start + set i 0 + newfile HISTOGRAM_XY + while {$i_bool==0} { + drive $motor $currentmot + $motor send SH` + oct oscillate_count $oscno + oct oscillate start + hmm countblock + + set currentmot [expr {$currentmot + $step}] + if {($step > 0) && ($currentmot > $fin)} {set i_bool 1} + if {($step < 0) && ($currentmot < $fin)} {set i_bool 1} + if {($i_bool == 0)} {run $motor $currentmot} + save $i + incr i + } +} + +publish RadCollScanRange user + +#RadCollScanBi +proc RadCollScanBi {motor start step fin oscno motdir} { + + set i_bool 0 + set spx -12500 + set spstep [expr {$spx * $step * $motdir}] + histmem stop + histmem mode unlimited + + if {$motdir == 1} { + set currentmot $start + set i 0 + } else { + set currentmot $fin + set i [expr {int(($fin-$start)/$step)}] + } + drive $motor $currentmot + newfile HISTOGRAM_XY + + while {$i_bool==0} { + oct oscillate_count $oscno + oct oscillate start + hmm countblock + + if {($motdir > 0)} { + set currentmot [expr {$currentmot + $step}] + if {$currentmot > $fin} {set i_bool 1} + + } else { + set currentmot [expr {$currentmot - $step}] + if {$currentmot < $start} {set i_bool 1} + + } + + if {($i_bool == 0)} {run $motor $currentmot} + save $i + if {($motdir > 0)} {incr i 1} else {incr i -1} + +# if {($i_bool == 0)} { +# $motor send SH` +# $motor send PR` $spstep +# $motor send BG` +# +# } +# save $i + } +} + +publish RadCollScanBi user + + + + diff --git a/site_ansto/instrument/hipd/config/commands/eulerscan.tcl b/site_ansto/instrument/hipd/config/commands/eulerscan.tcl index 45b0724b..41f0c9a3 100644 --- a/site_ansto/instrument/hipd/config/commands/eulerscan.tcl +++ b/site_ansto/instrument/hipd/config/commands/eulerscan.tcl @@ -1,7 +1,22 @@ # Euler cradle scan commands for texture runs # AJS Dec 2010 +proc EulerScan {mstart mstep mend oscno} { + ephi speed 5 + ephi accel 5 + ephi decel 5 + echi speed 2 + set motdir 1 + drive echi 0 ephi $mstart + foreach chival {0 15 30 45 60 75 90} { + drive echi $chival + RadCollScanBi ephi $mstart $mstep $mend $oscno $motdir + set motdir [expr {$motdir * -1}] + } + drive echi 0 ephi $mstart +} +publish EulerScan user # continous scan for EPHI- the euler cradle phi stage (innermost axis) # note make sure controller 2 has the PHISCAN code in it diff --git a/site_ansto/instrument/hipd/config/hmm/hmm_configuration.tcl b/site_ansto/instrument/hipd/config/hmm/hmm_configuration.tcl index 47087171..58300baa 100644 --- a/site_ansto/instrument/hipd/config/hmm/hmm_configuration.tcl +++ b/site_ansto/instrument/hipd/config/hmm/hmm_configuration.tcl @@ -28,7 +28,7 @@ proc ::histogram_memory::init_OAT_TABLE {args} { hmm configure fat_frame_source INTERNAL - # set resolution "double_x" +# set resolution "double_x" switch $resolution { "hires" { diff --git a/site_ansto/instrument/hipd/config/hmm/hmm_rapid.tcl b/site_ansto/instrument/hipd/config/hmm/hmm_rapid.tcl index fd7c040f..d8b6931f 100644 --- a/site_ansto/instrument/hipd/config/hmm/hmm_rapid.tcl +++ b/site_ansto/instrument/hipd/config/hmm/hmm_rapid.tcl @@ -148,7 +148,7 @@ proc SetHistoOneShot {frq framenum } { bat_table -set NO_REPEAT_ENTRY 1 NO_REPEAT_TABLE 1 NO_EXECUTE_TABLE 1 PERIOD_INDICES { 0 1 } fat_table -set NOS_PERIODS $framenum oat_table -set T {0 2200000} NTC 1 - oat_table -set Y {-0.5 15.5} NYC 16 + oat_table -set Y {-0.5 31.5} NYC 16 histmem freq $frq histmem loadconf @@ -160,4 +160,22 @@ proc SetHistoOneShot {frq framenum } { publish SetHistoOneShot user +proc SetHistoStd {} { + histmem stop + hmm astop + FAT_TABLE -set MULTI_HOST_HISTO_STITCH_OVERLAP 8 MULTI_HOST_HISTO_JOIN_STITCH_ORDER INVERTED + OAT_TABLE -set X { 991.5 987.5 } NXC 248 Y { -0.5 3.5 } NYC 128 T { 0 20000 } NTC 1 + histmem loadconf +} +publish SetHistoStd user + +proc SetHistoDX {} { + histmem stop + hmm astop + FAT_TABLE -set MULTI_HOST_HISTO_STITCH_OVERLAP 16 MULTI_HOST_HISTO_JOIN_STITCH_ORDER INVERTED + OAT_TABLE -set X { 991.5 989.5 } NXC 496 Y { -0.5 3.5 } NYC 128 T { 0 20000 } NTC 1 + histmem loadconf +} + +publish SetHistoDX user diff --git a/site_ansto/instrument/hipd/config/motors/euler_configuration.tcl b/site_ansto/instrument/hipd/config/motors/euler_configuration.tcl index cb4b340e..4d59dad1 100644 --- a/site_ansto/instrument/hipd/config/motors/euler_configuration.tcl +++ b/site_ansto/instrument/hipd/config/motors/euler_configuration.tcl @@ -56,20 +56,20 @@ Motor ephi $motor_driver_type [params \ asyncqueue mc2\ axis C\ units degrees\ - hardlowerlim -185\ - hardupperlim 185\ + hardlowerlim -365\ + hardupperlim 365\ maxSpeed 5\ maxAccel 5\ - maxDecel 1\ + maxDecel 5\ stepsPerX -12500\ absEnc 1\ absEncHome $ephi_Home\ cntsPerX -4096] -setHomeandRange -motor ephi -home 0 -lowrange 180 -uprange 180 -ephi softlowerlim -180 -ephi softupperlim 180 +setHomeandRange -motor ephi -home 0 -lowrange -360 -uprange 360 +ephi softlowerlim -360 +ephi softupperlim 360 ephi home 0 -ephi speed 1 +ephi speed 3 ephi movecount $move_count ephi precision 0.01 ephi part sample diff --git a/site_ansto/instrument/hipd/config/motors/motor_configuration.tcl b/site_ansto/instrument/hipd/config/motors/motor_configuration.tcl index e3953a9f..837972bc 100644 --- a/site_ansto/instrument/hipd/config/motors/motor_configuration.tcl +++ b/site_ansto/instrument/hipd/config/motors/motor_configuration.tcl @@ -24,8 +24,9 @@ if {$sim_mode == "true"} { #set mx_Home 23263535 set mx_Home 8390583 #set mom_Home 9274794 -#set mom_Home 8391038 -set mom_Home 8147038 +##set mom_Home 8391038 +#set mom_Home 8147038 +set mom_Home 7979102 set mtth_Home 19927837 #set mphi_Home 7613516 #set mphi_Home 27847793 @@ -33,6 +34,7 @@ set mphi_Home 8384818 #set mchi_Home 9050090 #set mchi_Home 25561619 set mchi_Home 8389526 +#set mchi_Home 6847710 #set my_Home 6767221 set my_Home 8378212 set som_Home 17214054 @@ -342,7 +344,7 @@ Motor $sample_stage_rotate $motor_driver_type [params \ asyncqueue mc2\ axis E\ units degrees\ - hardlowerlim -71\ + hardlowerlim -121\ hardupperlim 116\ maxSpeed 5\ maxAccel 3\ @@ -362,8 +364,10 @@ Motor stth $motor_driver_type [params \ asyncqueue mc2\ axis F\ units degrees\ - hardlowerlim 15.8\ + hardlowerlim 13\ hardupperlim 29.7\ + softlowerlim 13.4\ + softupperlim 29.6\ maxSpeed 0.5\ maxAccel 0.1\ maxDecel 0.1\ @@ -373,7 +377,7 @@ Motor stth $motor_driver_type [params \ bias_bits 25\ bias_bias 932070\ cntsPerX -93207] -stth softlowerlim 15.9 +stth softlowerlim 13.4 stth softupperlim 29.6 stth home 28.481113 #stth home 18.981113 @@ -413,28 +417,34 @@ oct long_name oct ############################ # -# Monochromator Focusing (HOPG) -#Motor mf1 $motor_driver_type [params \ -# asyncqueue mc3\ -# axis A\ -# units degrees\ -# hardlowerlim xxxx\ -# hardupperlim xxxx\ -# maxSpeed xxxx\ -# maxAccel xxxx\ -# maxDecel xxxx\ -# stepsPerX xxxx\ -# absEnc 1\ -# absEncHome $mf1_Home\ -# cntsPerX xxxx] -#setHomeandRange -motor mf1 -home 0 -lowrange 0 -uprange 360 -#mf1 speed 1 -#mf1 movecount $move_count -#mf1 precision 0.01 -#mf1 part monochromator -#mf1 long_name mf1 +set mf_config 1 + +switch $mf_config { + 1 { +# Monochromator Focusing (HOPG) + Motor mf1 $motor_driver_type [params \ + asyncqueue mc3\ + axis A\ + units degrees\ + hardlowerlim -0.1\ + hardupperlim 1.1\ + maxSpeed 0.1\ + maxAccel 0.1\ + maxDecel 0.1\ + stepsPerX 22000\ + absEnc 1\ + absEncHome 3965\ + cntsPerX -3500] + setHomeandRange -motor mf1 -home 0 -lowrange 0 -uprange 1 + mf1 speed 0.02 +# mf1 movecount $move_count + mf1 precision 0.005 + mf1 part monochromator + mf1 long_name mf1 + } # Monochromator Focusing (Ge) + ## ffr 31/7/2012 ## absEncHome was found to be 16777217 on 31/7/2012 when the ## encoder clocked over to 114 counts to give a posn @@ -443,26 +453,32 @@ oct long_name oct ## and has a 24bit range (ie max cnt=16777216) ## I set a bias of 10000 counts with absenchome = 10000 ## so that SICS can drive the axis to the allowed limits. -Motor mf2 $motor_driver_type [params \ - asyncqueue mc3\ - axis A\ - units degrees\ - hardlowerlim -2\ - hardupperlim 2\ - maxSpeed 0.1\ - maxAccel 0.1\ - maxDecel 0.1\ - stepsPerX 22000\ - absEnc 1\ - absEncHome 42768\ - bias_bits 24\ - bias_bias 10000\ - cntsPerX -3500] -setHomeandRange -motor mf2 -home 0 -lowrange 0 -uprange 2 -mf2 speed 0.02 -mf2 precision 0.005 -mf2 part monochromator -mf2 long_name mf2 + + 2 { + + Motor mf2 $motor_driver_type [params \ + asyncqueue mc3\ + axis A\ + units degrees\ + hardlowerlim -0.1\ + hardupperlim 1.1\ + maxSpeed 0.1\ + maxAccel 0.1\ + maxDecel 0.1\ + stepsPerX 22000\ + absEnc 1\ + absEncHome 10000\ + bias_bits 24\ + bias_bias 10000\ + cntsPerX -3500] + setHomeandRange -motor mf2 -home 0 -lowrange 0 -uprange 1 + mf2 speed 0.02 + mf2 precision 0.005 + mf2 part monochromator + mf2 long_name mf2 + } +} + # Slit 1, right Motor ss1r $motor_driver_type [params \ diff --git a/site_ansto/instrument/hipd/config/motors/tilt_configuration.tcl b/site_ansto/instrument/hipd/config/motors/tilt_configuration.tcl index f4d77b6e..6681b7a6 100644 --- a/site_ansto/instrument/hipd/config/motors/tilt_configuration.tcl +++ b/site_ansto/instrument/hipd/config/motors/tilt_configuration.tcl @@ -1,7 +1,8 @@ # This must be loaded by motor_configuration.tcl set sphi_Home 7938520 -set schi_Home 7586052 +#set schi_Home 7586052 +set schi_Home 9932404 set sy_Home 7790194 set sx_Home 7556649 diff --git a/site_ansto/instrument/hipd/util/sics_config.ini b/site_ansto/instrument/hipd/util/sics_config.ini index ab40aac9..e67afd1d 100644 --- a/site_ansto/instrument/hipd/util/sics_config.ini +++ b/site_ansto/instrument/hipd/util/sics_config.ini @@ -104,7 +104,7 @@ name = sample_stage optype = motion_axis [12tmagnet_oxford] desc = "12 Tesla Oxford Magnet" -driver = "oxford_labview" +driver = "oxford12tlv" imptype = magnetic_field ip = 10.157.205.3 port = 55001 @@ -294,37 +294,17 @@ imptype = motion_axis asyncqueue = sct desc = "VF1 Blue furnace temperature controller" dev_id = 1 -driver = "west4100" -imptype = temperature -ip = 10.157.205.24 -port = 502 - -[vf1_west6100] -asyncprotocol = modbus_ap -desc = "VF1 Blue furnace 6100 temperature controller" -dev_id = 1 driver = "west_6100" imptype = temperature ip = 10.157.205.24 port = 502 -timeout = 2000 [vf2_west4100] asyncqueue = sct desc = "VF2 Blue furnace temperature controller" dev_id = 1 -driver = "west4100" -imptype = temperature -ip = 10.157.205.25 -port = 502 - -[vf2_west6100] -asyncprotocol = modbus_ap -desc = "VF2 Blue furnace 6100 temperature controller" -dev_id = 1 driver = "west_6100" imptype = temperature ip = 10.157.205.25 port = 502 -timeout = 2000 diff --git a/site_ansto/instrument/hipd/wombat_configuration.tcl b/site_ansto/instrument/hipd/wombat_configuration.tcl index e92da140..27c735d4 100644 --- a/site_ansto/instrument/hipd/wombat_configuration.tcl +++ b/site_ansto/instrument/hipd/wombat_configuration.tcl @@ -29,8 +29,9 @@ fileeval $cfPath(environment)/sct_agilent_33220A.tcl fileeval $cfPath(environment)/sct_hiden_xcs.tcl fileeval $cfPath(environment)/sct_huber_pilot.tcl fileeval $cfPath(environment)/sct_isotech_ps.tcl -fileeval $cfPath(environment)/temperature/sct_eurotherm_2000.tcl -fileeval $cfPath(environment)/temperature/sct_eurotherm_m2000.tcl +#fileeval $cfPath(environment)/temperature/sct_eurotherm_2000.tcl +#fileeval $cfPath(environment)/temperature/sct_eurotherm_m2000.tcl +fileeval $cfPath(environment)/temperature/eurotherm_3200_sct.tcl fileeval $cfPath(environment)/sct_keithley_2700.tcl fileeval $cfPath(environment)/sct_keithley_m2700.tcl fileeval $cfPath(environment)/temperature/sct_lakeshore_218.tcl @@ -52,6 +53,7 @@ fileeval $cfPath(environment)/temperature/sct_julabo_lh45_gen.tcl fileeval $cfPath(environment)/temperature/sct_qlink.tcl fileeval $cfPath(environment)/temperature/west400.tcl fileeval $cfPath(environment)/temperature/sct_west4100.tcl +fileeval $cfPath(environment)/temperature/sct_west_6100.tcl fileeval $cfPath(environment)/magneticField/sct_oxford_labview.tcl fileeval $cfPath(environment)/magneticField/sct_oxford12tlv.tcl fileeval $cfPath(environment)/he3/sct_he3.tcl @@ -65,13 +67,16 @@ fileeval $cfPath(commands)/pulser.tcl fileeval $cfPath(commands)/hvcommands.tcl fileeval $cfPath(commands)/vactex.tcl fileeval $cfPath(commands)/eulerscan.tcl +fileeval $cfPath(commands)/cfcommands.tcl fileeval $cfPath(anticollider)/anticollider.tcl +fileeval $cfPath(beamline)/sct_he3_polanal.tcl fileeval $cfPath(hmm)/hmm_rapid.tcl source gumxml.tcl # Wombat only change to hvcommands' scaleval variable SetVoltScale 2000.0 + # The Alice Thing # Qlink : 9600, 8 data, 1 stop, No Parity, None Flow # LS340 : 9600, 7 data, 1 stop, Odd Parity, None Flow