Merges from ics1-wombat

r2834 | ffr | 2009-12-09 17:07:45 +1100 (Wed, 09 Dec 2009) | 2 lines
This commit is contained in:
Ferdi Franceschini
2009-12-09 17:07:45 +11:00
committed by Douglas Clowes
parent 64ab146a44
commit c73c4c85c8
15 changed files with 3779 additions and 209 deletions

View File

@@ -30,6 +30,10 @@ proc ::histogram_memory::init_OAT_TABLE {args} {
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
}
"double_y_968x128" {
FAT_TABLE -set MULTI_HOST_HISTO_STITCH_OVERLAP 8 MULTI_HOST_HISTO_JOIN_STITCH_ORDER INVERTED BNL_STATUS_MASK_MULTI_Y 1000h
OAT_TABLE -set X { 991.5 987.5 } NXC 248 Y { -0.5 3.5 } NYC 256 T { 0 20000 } NTC 1
}
default {
# Default to std_968x128
FAT_TABLE -set MULTI_HOST_HISTO_STITCH_OVERLAP 8 MULTI_HOST_HISTO_JOIN_STITCH_ORDER INVERTED

View File

@@ -1,33 +1,89 @@
# Test script for multi period acquisition and saving.
# latest mods 21 Oct 09 based on info from Ferdi - ajs
set nos_periods 1
set n_periods 1
proc open_hist_file {} {
newfile HISTOGRAM_XY
}
proc histset_XY {} {
set histstr "proc open_hist_file {} {newfile HISTOGRAM_XY}"
eval $histstr
}
proc histset_XYperiod {} {
set histstr "proc open_hist_file {} {newfile HISTOPERIOD_XY}"
eval $histstr
}
proc histset_XYT {} {
set histstr "proc open_hist_file {} {newfile HISTOGRAM_XYT}"
eval $histstr
}
proc histset_XYTperiod {} {
set histstr "proc open_hist_file {} {newfile HISTOPERIOD_XYT}"
}
proc histmem_period_single { } {
# Because bugs may not yet have been corrected in hmm_configuration_common_1.tcl,
# apply the default settings before attempting del/clear.
global nos_periods
set nos_periods 1
global n_periods
set n_periods 1
FAT_TABLE -set NOS_PERIODS 1
FAT_TABLE -del NOS_PERIODS
BAT_TABLE -set PERIOD_INDICES { 0 } NO_BAT_ENTRIES 1 NO_BAT_PERIODS 1 NO_REPEAT_ENTRY 0 NO_REPEAT_TABLE 0 NO_EXECUTE_TABLE 0
BAT_TABLE -clear
# FAT_TABLE -del NOS_PERIODS
# BAT_TABLE -set PERIOD_INDICES { 0 } NO_BAT_ENTRIES 1 NO_BAT_PERIODS 1 NO_REPEAT_ENTRY 0 NO_REPEAT_TABLE 0 NO_EXECUTE_TABLE 0
BAT_TABLE -set PERIOD_INDICES { 0 } NO_BAT_ENTRIES 1 NO_BAT_PERIODS 1 NO_REPEAT_ENTRY 1 NO_REPEAT_TABLE 1 NO_EXECUTE_TABLE 1
histmem loadconf
# BAT_TABLE -clear
histset_XY
}
Publish histmem_period_single User
proc histmem_period_sequence { Np Nf } {
# orig version of this pre Oct 09
#
#proc histmem_period_sequence { Np Nf } {
# Note - sequence needs to be at least 2 periods.
global nos_periods
set nos_periods $Np
FAT_TABLE -set NOS_PERIODS $Np
BAT_TABLE -set PERIOD_INDICES { 0 1 } NO_BAT_ENTRIES $Np NO_BAT_PERIODS $Np NO_REPEAT_ENTRY $Nf NO_REPEAT_TABLE 1 NO_EXECUTE_TABLE 1
# global n_periods
# set n_periods $Np
# set fatstr "FAT_TABLE -set NOS_PERIODS $Np"
# set fatstr2 "FAT_TABLE -set PERIOD_INDICES { 0 1 }"
# set batstr "BAT_TABLE -set NO_BAT_ENTRIES $Np NO_BAT_PERIODS $Np NO_REPEAT_ENTRY $Nf NO_REPEAT_TABLE 1 NO_EXECUTE_TABLE 1"
# eval $fatstr
# eval $fatstr2
# eval $batstr
# histmem loadconf
#
#}
proc histmem_period_sequence {Np} {
global n_periods
set n_periods $Np
FAT_TABLE -set NOS_PERIODS $Np
BAT_TABLE -set PERIOD_INDICES { 0 } NO_BAT_ENTRIES 1 NO_BAT_PERIODS 1 NO_REPEAT_ENTRY 1 NO_REPEAT_TABLE 1 NO_EXECUTE_TABLE $Np
histmem loadconf
histset_XYperiod
}
proc histmem_period_sequence_off {} {
global n_periods
set n_periods $Np
FAT_TABLE -set NOS_PERIODS 1
BAT_TABLE -set PERIOD_INDICES { 0 } NO_BAT_ENTRIES 1 NO_BAT_PERIODS 1 NO_REPEAT_ENTRY 0 NO_REPEAT_TABLE 0 NO_EXECUTE_TABLE 0
histmem loadconf
histset_XYperiod
}
Publish histmem_period_sequence User
proc histmem_save_period_sequence { } {
global nos_periods
newfile HISTOGRAM_XYT
for { set i 0 } { $i < $nos_periods } { incr i } {
hmm configure read_data_period_number $i
global n_periods
open_hist_file
for { set i 0 } { $i < $n_periods } { incr i } {
# hmm configure read_data_period_number $i
save $i
}
}
@@ -42,6 +98,7 @@ proc histmem_period_strobo {Freq Bins} {
# OAT_TABLE -set T { 0 $bintime } NTC $Bins
eval $oatstr
histmem loadconf
histset_XYT
}
Publish histmem_period_strobo User
@@ -49,6 +106,7 @@ proc histmem_strobo_off {} {
histmem fsrce INTERNAL
OAT_TABLE -set T { 0 200000 } NTC 1
histmem loadconf
histset_XY
}
Publish histmem_strobo_off User
@@ -69,8 +127,8 @@ proc histmem_acquire_period_sequence { Np Nf } {
# clientput "tc1 reading is: " [tc1 get]
global nos_periods
for { set i 0 } { $i < $nos_periods } { incr i } {
global n_periods
for { set i 0 } { $i < $n_periods } { incr i } {
# after $dlytime
# set current_period -1
# while { $current_period < $i } {