Skip to content
Snippets Groups Projects
Commit b65571f7 authored by jmcchesn's avatar jmcchesn
Browse files

debug EA

parent 0ebfcd44
No related branches found
No related tags found
No related merge requests found
......@@ -48,6 +48,11 @@ def log_init(endstation_name,user_name,log_dictionary,set_file=False):
"""
iex.BL.mda.log=Logfile(endstation_name,user_name,log_dictionary,set_file=False)
def log_header(header_list,**kwargs):
"""
writes the header for EA files
"""
iex.BL.mda.log.write_header(header_list,**kwargs)
##############################################################################################################
############################## general logfile functions ##############################
##############################################################################################################
......@@ -243,6 +248,8 @@ class Logfile:
To be used for scanlog and scanEA functions.
Update SaveFile_Header version number when changing the structure of the file (indexing).
** kwargs
header_only = True/False (default => False)
Previously: SaveFile
"""
if d == None:
......
......@@ -17,6 +17,7 @@ from iexcode.instruments.IEX_BL_config import *
from iexcode.instruments.AD_utilities import AD_filepath,AD_prefix
from iexcode.instruments.scanRecord import *
from iexcode.instruments.Logfile import *
from iexcode.instruments.conversions_constants import *
from iexcode.instruments.xrays import energy, scanXAS, BL_energy_tables,energy_get
from iexcode.instruments.shutters import branch_shutter_close
......@@ -190,7 +191,7 @@ def EAlog_header():
d=EA_log_dictionary()
try:
header_list,data_list,format_list = iex.BL.mda.log.log_entries(d)
iex.BL.mda.log.write_entry(header_list,label="EA Header: ")
log_header(header_list,label="EA Header: ")
except:
print("EAlog did not write header")
......@@ -252,9 +253,9 @@ def _scanEATrigger(EAlist,before_after,**kwargs):
_scanEAPrefix("mda",**kwargs)
#set det trigger
mda_kwargs={'scan_dim':kwargs['scan_dim'],'trigger_dictionary':{kwargs['detTrig']:HVscanPV}}
iex.BL.mda.trigger_set(mda_kwargs)
scan_triggers_set(mda_kwargs)
#add scanNum as detector
iex.BL.mda.detectors_set(detector_dictionary={20:EA._savePlugin +"FileName"})
scan_detectors_set({20:EA._savePlugin +"FileName"})
if before_after == "after":
#set prefix
......@@ -353,7 +354,7 @@ def scanEA(EAlist,**kwargs):
"""
kwargs.setdefault('scanIOC',iex.BL.ioc)
kwargs.setdefault('scanIOC',mda_ioc())
kwargs.setdefault('scan_dim',1)
kwargs.setdefault('execute',True)
kwargs.setdefault("debug",False)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment