Scan start/finish write exp start/finish times to file
r1392 | ffr | 2007-01-10 09:31:26 +1100 (Wed, 10 Jan 2007) | 2 lines
This commit is contained in:
committed by
Douglas Clowes
parent
087efbe552
commit
98132be65d
@@ -7,6 +7,9 @@ variable scanVariable scan_var scanVarStart 0 scanVarStep 1
|
||||
variable scanVariable;
|
||||
|
||||
nxcreatefile;
|
||||
nxscript updatedictvar entryName start;
|
||||
nxscript puttext estart [sicstime];
|
||||
nxclosefile;
|
||||
# stdscan prepare $sobj $uobj;
|
||||
set vlist [split [$sobj getvarpar 0] = ];
|
||||
set scanVariable [string trim [lindex [split [lindex $vlist 0] . ] 1]];
|
||||
@@ -15,12 +18,23 @@ variable scanVariable scan_var scanVarStart 0 scanVarStep 1
|
||||
hs_prepare $sobj $uobj
|
||||
}
|
||||
|
||||
proc scan_finish {sobj uobj} {
|
||||
nxscript close
|
||||
proc hm_scan_finish {sobj uobj} {
|
||||
hs_finish $sobj $uobj;
|
||||
nxreopenfile;
|
||||
nxscript updatedictvar entryName stop;
|
||||
nxscript puttext eend [sicstime];
|
||||
nxclosefile;
|
||||
}
|
||||
|
||||
#proc scan_finish {sobj uobj} {
|
||||
# nxscript close;
|
||||
proc bm_scan_finish {sobj uobj} {
|
||||
stdscan finish $sobj $uobj;
|
||||
nxreopenfile;
|
||||
nxscript updatedictvar entryName stop;
|
||||
nxscript puttext eend [sicstime];
|
||||
nxclosefile;
|
||||
}
|
||||
#proc hm_scan_finish {sobj uobj} {
|
||||
# nxclosefile;
|
||||
#}
|
||||
|
||||
# Add an nxentry for the current scan point
|
||||
@@ -30,8 +44,8 @@ variable scanVariable scan_var scanVarStart 0 scanVarStep 1
|
||||
variable scanVariable;
|
||||
set scanVarPos [expr $scanVarStart + $pt * $scanVarStep];
|
||||
nxreopenfile;
|
||||
addnxentry nxscript scan_$pt $scanVariable $scanVarPos;
|
||||
nxscript close
|
||||
addnxentry nxscript scan_$pt $scanVariable $scanVarPos $scanVarStep;
|
||||
nxclosefile
|
||||
}
|
||||
|
||||
proc donothing {args} {}
|
||||
@@ -45,6 +59,9 @@ proc bmcount {sobj uobj pt mode preset} {
|
||||
variable scanVarStep;
|
||||
variable scanVariable;
|
||||
nxcreatefile;
|
||||
nxscript updatedictvar entryName start;
|
||||
nxscript puttext estart [sicstime];
|
||||
nxclosefile;
|
||||
set vlist [split [$sobj getvarpar 0] = ];
|
||||
set scanVariable [string trim [lindex [split [lindex $vlist 0] . ] 1]];
|
||||
set scanVarStart [lindex $vlist 1];
|
||||
@@ -57,18 +74,18 @@ proc bmcount {sobj uobj pt mode preset} {
|
||||
variable scanVariable;
|
||||
set scanVarPos [expr $scanVarStart + $pt * $scanVarStep];
|
||||
nxreopenfile;
|
||||
bm_addnxentry nxscript scan_$pt $scanVariable $scanVarPos;
|
||||
nxscript close
|
||||
bm_addnxentry nxscript scan_$pt $scanVariable $scanVarPos $scanVarStep;
|
||||
nxclosefile
|
||||
}
|
||||
}
|
||||
|
||||
publish ::scanCommand::scan_prepare user
|
||||
publish ::scanCommand::scan_finish user
|
||||
publish ::scanCommand::hm_scan_finish user
|
||||
publish ::scanCommand::nxaddpoint user
|
||||
publish ::scanCommand::donothing user
|
||||
|
||||
publish ::scanCommand::bm_scan_prepare user
|
||||
publish ::scanCommand::scan_finish user
|
||||
publish ::scanCommand::bm_scan_finish user
|
||||
publish ::scanCommand::bm_nxaddpoint user
|
||||
publish ::scanCommand::donothing user
|
||||
publish ::scanCommand::bmcount user
|
||||
@@ -76,6 +93,7 @@ publish ::scanCommand::bmcount user
|
||||
hmscan function writeheader ::scanCommand::donothing
|
||||
hmscan function writepoint ::scanCommand::nxaddpoint
|
||||
hmscan function prepare ::scanCommand::scan_prepare
|
||||
hmscan function finish ::scanCommand::hm_scan_finish
|
||||
|
||||
scan2 function writeheader ::scanCommand::donothing
|
||||
scan2 function writepoint ::scanCommand::nxaddpoint
|
||||
@@ -87,3 +105,4 @@ bmonscan function writeheader ::scanCommand::donothing
|
||||
bmonscan function writepoint ::scanCommand::bm_nxaddpoint
|
||||
bmonscan function prepare ::scanCommand::bm_scan_prepare
|
||||
bmonscan function count ::scanCommand::bmcount
|
||||
bmonscan function finish ::scanCommand::bm_scan_finish
|
||||
|
||||
Reference in New Issue
Block a user