Ignore:
Timestamp:
Jun 27, 2017 1:53:15 PM (5 years ago)
Author:
srkline
Message:

added procedures to use the measured values for the 5 slot masks for detector calibration.

added procedures to save detector panels to be later read in for calibration fitting.

Location:
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Test_RAW_Panel.ipf

    r1044 r1049  
    127127Window VSANS_DataPanel() : Panel 
    128128        PauseUpdate; Silent 1           // building window... 
    129         NewPanel /W=(37,45,1038,719) /N=VSANS_Data 
     129        NewPanel /W=(37,45,1038,719) /K=1 /N=VSANS_Data 
    130130//      ShowTools/A 
    131131        ModifyPanel cbRGB=(65535,60076,49151) 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_TubeAdjustments.ipf

    r1048 r1049  
    9898// 
    9999// TODO 
    100 // -- the slot positioning may be different for the L/R and T/B detectors 
     100// -- the slot positioning is different for the L/R and T/B detectors 
    101101// 
    102102Proc V_SetupSlotDimensions() 
    103         Make/O/D/N=5 peak_spacing_mm_ctr 
    104         peak_spacing_mm_ctr = {-350,-190,0,190,350} 
     103        Make/O/D/N=5 peak_spacing_mm_ctr_TB,peak_spacing_mm_ctr_LR 
     104        peak_spacing_mm_ctr_TB = {-159.54,-80.17,0,80.17,159.54} 
     105        peak_spacing_mm_ctr_LR = {-379.4,-189.7,0,189.7,380.2} 
    105106        DoWindow/F Real_mm_Table 
    106107        if(V_Flag == 0) 
    107                 Edit/N=Real_mm_Table peak_spacing_mm_ctr 
     108                Edit/N=Real_mm_Table peak_spacing_mm_ctr_TB,peak_spacing_mm_ctr_LR 
    108109        endif 
    109110End 
     
    134135        String wStr 
    135136         
     137        String/G root:detUsed = wStr 
     138         
    136139        Variable ii,numTubes=48 
    137140        String str="tube" 
     
    256259                Edit/N=Refined_Positions position_refined 
    257260        endif 
     261         
    258262End 
    259263 
     
    361365        if(V_flag == 0) 
    362366                Edit/N=Quad_Coefficients TubeCoefTable 
     367        endif 
     368 
     369        String detUsed = root:detUsed 
     370         
     371        if(strsearch(detUsed,"L",0) >= 0 || strsearch(detUsed,"R",0) >= 0) 
     372                Duplicate/O     peak_spacing_mm_ctr_LR, peak_spacing_mm_ctr 
     373                DoAlert 0,"Using peak spacing for L/R" 
     374        else 
     375                Duplicate/O     peak_spacing_mm_ctr_TB, peak_spacing_mm_ctr 
     376                DoAlert 0,"Using peak spacing for T/B" 
    363377        endif 
    364378End 
     
    10451059 
    10461060//////////////////////////////////// 
    1047  
    1048  
     1061// 
     1062// TODO  
     1063// -- document the "simple" save of the detector panels for import and subsequent fitting. 
     1064// 
     1065// takes the data from RAW, by default. This is OK, since even though whatever is in the calibration data 
     1066// of the file is used when loading into RAW, it is only used for the calculation of q. The actual data 
     1067// array is unchanged. Alternatively, the data could be pulled from the RawVSANS folder after a 
     1068// file catalog operation 
     1069 
     1070Macro V_CopyDetectorsToRoot() 
     1071 
     1072        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_B:data data_B 
     1073 
     1074        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_ML:data data_ML 
     1075        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_MR:data data_MR 
     1076        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_MT:data data_MT 
     1077        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_MB:data data_MB 
     1078 
     1079        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_FL:data data_FL 
     1080        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_FR:data data_FR 
     1081        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_FT:data data_FT 
     1082        Duplicate/O root:Packages:NIST:VSANS:RAW:entry:instrument:detector_FB:data data_FB 
     1083         
     1084End 
     1085 
     1086Macro V_SaveDetectorsITX() 
     1087// binary save makes each wave an individual file. Igor text groups them all into one file. 
     1088//      Save/C data_B,data_FB,data_FL,data_FR,data_FT,data_MB,data_ML,data_MR,data_MT 
     1089        Save/T/M="\r\n" data_B,data_FB,data_FL,data_FR,data_FT,data_MB,data_ML,data_MR,data_MT as "data_B++.itx" 
     1090 
     1091End 
Note: See TracChangeset for help on using the changeset viewer.