 Timestamp:
 Apr 1, 2009 4:16:09 PM (13 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

sans/Dev/trunk/NCNR_User_Procedures/Reduction/SANS/NCNR_DataReadWrite.ipf
r472 r483 88 88 Make/O/N=52 $"root:Packages:NIST:RAW:RealsRead" 89 89 Make/O/T/N=11 $"root:Packages:NIST:RAW:TextRead" 90 Make/O/N=7 $"root:Packages:NIST:RAW:LogicalsRead" 90 91 91 92 Wave intw=$"root:Packages:NIST:RAW:IntegersRead" 92 93 Wave realw=$"root:Packages:NIST:RAW:RealsRead" 93 94 Wave/T textw=$"root:Packages:NIST:RAW:TextRead" 95 Wave logw=$"root:Packages:NIST:RAW:LogicalsRead" 94 96 95 97 //***NOTE **** … … 163 165 intw[10] = integer 164 166 167 165 168 //2 integers 166 169 FSetPos refNum,308 … … 206 209 FBinRead/F=3/B=3 refNum, integer 207 210 intw[22] = integer 208 211 212 //Get Logicals 213 //Read logicals as int  ICE is writing integers here 214 FSetPos refNum,304 215 FBinRead/F=3/B=3 refNum, integer 216 logw[0] = integer 217 FSetPos refNum,316 218 FBinRead/F=3/B=3 refNum, integer 219 logw[1] = integer 220 FSetPos refNum,340 221 FBinRead/F=3/B=3 refNum, integer 222 logw[2] = integer 223 FSetPos refNum,344 224 FBinRead/F=3/B=3 refNum, integer 225 logw[3] = integer 226 FSetPos refNum,446 227 FBinRead/F=3/B=3 refNum, integer 228 logw[4] = integer 229 FSetPos refNum,462 230 FBinRead/F=3/B=3 refNum, integer 231 logw[5] = integer 232 FSetPos refNum,466 233 FBinRead/F=3/B=3 refNum, integer 234 logw[6] = integer 235 209 236 Close refNum 210 237 … … 2324 2351 return(0) 2325 2352 End 2353 2354 Function ExamineHeader(type) 2355 String type 2356 2357 String data_folder = type 2358 String dataPath = "root:Packages:NIST:"+data_folder 2359 String cur_folder = "ExamineHeader" 2360 String curPath = "root:Packages:NIST:"+cur_folder 2361 2362 //SetDataFolder curPath 2363 2364 Wave intw=$(dataPath+":IntegersRead") 2365 Wave realw=$(dataPath+":RealsRead") 2366 Wave/T textw=$(dataPath+":TextRead") 2367 Wave logw=$(dataPath+":LogicalsRead") 2368 2369 2370 print "" 2371 print "Header Details" 2372 print "" 2373 print "fname :\t\t"+textw[0] 2374 // 2375 print "run.npre :\t\t"+num2str(intw[0]) 2376 print "run.ctime :\t\t"+num2str(intw[1]) 2377 print "run.rtime :\t\t"+num2str(intw[2]) 2378 print "run.numruns :\t\t"+num2str(intw[3]) 2379 // 2380 print "run.moncnt :\t\t"+num2str(realw[0]) 2381 print "run.savmon :\t\t"+num2str(realw[1]) 2382 print "run.detcnt :\t\t"+num2str(realw[2]) 2383 print "run.atten :\t\t"+num2str(realw[3]) 2384 // 2385 print "run.timdat:\t\t"+textw[1] 2386 print "run.type:\t\t"+textw[2] 2387 print "run.defdir:\t\t"+textw[3] 2388 print "run.mode:\t\t"+textw[4] 2389 print "run.reserve:\t\t"+textw[5] 2390 print "sample.labl:\t\t"+textw[6] 2391 // 2392 print "sample.trns:\t\t"+num2str(realw[4]) 2393 print "sample.thk:\t\t"+num2str(realw[5]) 2394 print "sample.position:\t\t"+num2str(realw[6]) 2395 print "sample.rotang:\t\t"+num2str(realw[7]) 2396 // 2397 print "sample.table:\t\t"+num2str(intw[4]) 2398 print "sample.holder:\t\t"+num2str(intw[5]) 2399 print "sample.blank:\t\t"+num2str(intw[6]) 2400 // 2401 print "sample.temp:\t\t"+num2str(realw[8]) 2402 print "sample.field:\t\t"+num2str(realw[9]) 2403 // 2404 print "sample.tctrlr:\t\t"+num2str(intw[7]) 2405 print "sample.magnet:\t\t"+num2str(intw[8]) 2406 // 2407 print "sample.tunits:\t\t"+textw[7] 2408 print "sample.funits:\t\t"+textw[8] 2409 print "det.typ:\t\t"+textw[9] 2410 // 2411 print "det.calx(1):\t\t"+num2str(realw[10]) 2412 print "det.calx(2):\t\t"+num2str(realw[11]) 2413 print "det.calx(3):\t\t"+num2str(realw[12]) 2414 print "det.caly(1):\t\t"+num2str(realw[13]) 2415 print "det.caly(2):\t\t"+num2str(realw[14]) 2416 print "det.caly(3):\t\t"+num2str(realw[15]) 2417 // 2418 print "det.num:\t\t"+num2str(intw[9]) 2419 print "det.spacer:\t\t"+num2str(intw[10]) 2420 // 2421 print "det.beamx:\t\t"+num2str(realw[16]) 2422 print "det.beamy:\t\t"+num2str(realw[17]) 2423 print "det.dis:\t\t"+num2str(realw[18]) 2424 print "det.offset:\t\t"+num2str(realw[19]) 2425 print "det.siz:\t\t"+num2str(realw[20]) 2426 print "det.bstop:\t\t"+num2str(realw[21]) 2427 print "det.blank:\t\t"+num2str(realw[22]) 2428 print "resolution.ap1:\t\t"+num2str(realw[23]) 2429 print "resolution.ap2:\t\t"+num2str(realw[24]) 2430 print "resolution.ap12dis:\t\t"+num2str(realw[25]) 2431 print "resolution.lmda:\t\t"+num2str(realw[26]) 2432 print "resolution.dlmda:\t\t"+num2str(realw[27]) 2433 print "resolution.nlenses:\t\t"+num2str(realw[28]) 2434 // 2435 print "tslice.slicing:\t\t"+num2str(logw[0]) 2436 // 2437 print "tslice.multfact:\t\t"+num2str(intw[11]) 2438 print "tslice.ltslice:\t\t"+num2str(intw[12]) 2439 // 2440 print "temp.printemp:\t\t"+num2str(logw[1]) 2441 // 2442 print "temp.hold:\t\t"+num2str(realw[29]) 2443 print "temp.err:\t\t"+num2str(realw[30]) 2444 print "temp.blank:\t\t"+num2str(realw[31]) 2445 // 2446 print "temp.extra:\t\t"+num2str(intw[13]) 2447 print "temp.err:\t\t"+num2str(intw[14]) 2448 // 2449 print "magnet.printmag:\t\t"+num2str(logw[2]) 2450 print "magnet.sensor:\t\t"+num2str(logw[3]) 2451 // 2452 print "magnet.current:\t\t"+num2str(realw[32]) 2453 print "magnet.conv:\t\t"+num2str(realw[33]) 2454 print "magnet.fieldlast:\t\t"+num2str(realw[34]) 2455 print "magnet.blank:\t\t"+num2str(realw[35]) 2456 print "magnet.spacer:\t\t"+num2str(realw[36]) 2457 print "bmstp.xpos:\t\t"+num2str(realw[37]) 2458 print "bmstop.ypos:\t\t"+num2str(realw[38]) 2459 // 2460 print "params.blank1:\t\t"+num2str(intw[15]) 2461 print "params.blank2:\t\t"+num2str(intw[16]) 2462 print "params.blank3:\t\t"+num2str(intw[17]) 2463 // 2464 print "params.trnscnt:\t\t"+num2str(realw[39]) 2465 print "params.extra1:\t\t"+num2str(realw[40]) 2466 print "params.extra2:\t\t"+num2str(realw[41]) 2467 print "params.extra3:\t\t"+num2str(realw[42]) 2468 // 2469 print "params.reserve:\t\t"+textw[10] 2470 // 2471 print "voltage.printemp:\t\t"+num2str(logw[4]) 2472 // 2473 print "voltage.volts:\t\t"+num2str(realw[43]) 2474 print "voltage.blank:\t\t"+num2str(realw[44]) 2475 // 2476 print "voltage.spacer:\t\t"+num2str(intw[18]) 2477 // 2478 print "polarization.printpol:\t\t"+num2str(logw[5]) 2479 print "polarization.flipper:\t\t"+num2str(logw[6]) 2480 // 2481 print "polarization.horiz:\t\t"+num2str(realw[45]) 2482 print "polarization.vert:\t\t"+num2str(realw[46]) 2483 // 2484 print "analysis.rows(1):\t\t"+num2str(intw[19]) 2485 print "analysis.rows(2):\t\t"+num2str(intw[20]) 2486 print "analysis.cols(1):\t\t"+num2str(intw[21]) 2487 print "analysis.cols(2):\t\t"+num2str(intw[22]) 2488 // 2489 print "analysis.factor:\t\t"+num2str(realw[47]) 2490 print "analysis.qmin:\t\t"+num2str(realw[48]) 2491 print "analysis.qmax:\t\t"+num2str(realw[49]) 2492 print "analysis.imin:\t\t"+num2str(realw[50]) 2493 print "analysis.imax:\t\t"+num2str(realw[51]) 2494 2495 End
Note: See TracChangeset
for help on using the changeset viewer.