From 3ae5310af90fc81287aba410caf99afc2283111e Mon Sep 17 00:00:00 2001 From: Douglas Clowes Date: Wed, 11 Jun 2014 10:46:38 +1000 Subject: [PATCH] Massage the mercury pressure card driver --- .../config/environment/temperature/mercury_pres.sct | 5 +++-- .../config/environment/temperature/sct_mercury_pres.tcl | 8 +++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/site_ansto/instrument/config/environment/temperature/mercury_pres.sct b/site_ansto/instrument/config/environment/temperature/mercury_pres.sct index 3c236387..dce3b77d 100644 --- a/site_ansto/instrument/config/environment/temperature/mercury_pres.sct +++ b/site_ansto/instrument/config/environment/temperature/mercury_pres.sct @@ -24,7 +24,8 @@ driver mercury_pres = { @ scan [lindex [split "$data" ":"] end] "%s" data } - code Write_function setPoint = { - } + code Write_function setPoint = {%% + # TODO: Check if we can/must put the "mB" on this line + %%} } diff --git a/site_ansto/instrument/config/environment/temperature/sct_mercury_pres.tcl b/site_ansto/instrument/config/environment/temperature/sct_mercury_pres.tcl index f83e7601..894a43f0 100644 --- a/site_ansto/instrument/config/environment/temperature/sct_mercury_pres.tcl +++ b/site_ansto/instrument/config/environment/temperature/sct_mercury_pres.tcl @@ -227,7 +227,13 @@ proc ::scobj::mercury_pres::setPoint {tc_root nextState cmd_str} { } set par [sct target] set cmd "${cmd_str}${par}" -# setPoint hook code goes here +# setPoint hook code starts + # TODO: Check if we can/must put the "mB" on this line +# setPoint hook code ends + if { [hpropexists [sct] geterror] } { + debug_log ${tc_root} 9 "[sct] error: [sct geterror]" + error "[sct geterror]" + } if { [hpropexists [sct] driving] } { if { [hpropexists [sct] writestatus] && [sct writestatus] == "start" } { sct driving 1