Changelog for the IRIS simulator
By Martin Wiesmann (UIO)

From build ‘2013.09.25’ to build ‘2014.05.27’

IRIS Simulator:
-	The filterwheel values can now differ from the ‘real’ value by a maximum of 3 instead of 1 (i.e. 33 counts as 31), change was made in irissim_xml2struct__define.pro only, irissim_constants still only accepts the ‘real’ values(1, 31, 61, 91, 121, 151)

From build ‘2013.09.05’ to build ‘2013.09.25’

IRIS Simulator:
-	the log of multiple OBS can now be passed out through the keyword logall from IRISsim_multiobs, if the keyword getlogstruct has been set
-	FOV y is now also in this log structure for all FUV/NUV and SJI (before, it was calculated in IRISsim_writelogfile)

From build ‘2013.09.04’ to build ‘2013.09.05’

IRIS Simulator:
-	flipping of coordinates is now fully implemented, the overview of the xml files shows the original values, but the boxes overlain on the CCD images are flipped
-	also keywords TSCn, TECn, TSRn, TERn are now flipped

From build ‘2013.05.29’ to build ‘2013.09.04’

IRIS Simulator:
-	Implemented the flipping of the window coordinates, still has to be done for widget which shows regions on CCD and complete flipping with summing for level 1 keywords
-	Fixed bug DAI 163, threshold is now calculated for each SJI and FW separately

From build ‘2013.05.24’ to build ‘2013.05.29’

IRIS Simulator:
-	introduced new common variable to handle the memory leak even better, now in practice there is no memory leak anyore

From build ‘2013.05.21’ to build ‘2013.05.24’

IRIS Simulator:
-	almost fixed bug DAI 257 (actually Stein Vidar Hagfors Haugan did), the memory leak is now much smaller (about a factor of 100), but there is still some. It is most likely coming from XMLffXMLSAX object

From build ‘2013.05.05’ to build ‘2013.05.21’

IRIS Simulator:
-	fixed bug DAI 258, now logfile has larger space for time

From build ‘2013.04.25’ to build ‘2013.05.05’

IRIS Simulator:
-	fixed bug in IRISsim_multiOBS.pro
-	changed the order in which the windows appear, when iris_simulator is started. Now the window with the parameters first appears.
-	On this new first window is a button, which opens new windows, which show the content of the XML files
-	The directories of the FRM- FDB- and CRS files can now be given (and saved) in the GUI

From build ‘2013.04.23’ to build ‘2013.04.25’

IRIS Simulator:
-	added new log entry ‘FovY’, which shows the largest y-range of a subregion in the according CRS, divided by 6 (pixel dispersion: 0.167’’)
-	Implemented same timing scheme as the flight software, except simulator does not skip frames, in these cases the time would jump backwards
-	Changed the logic of finding the xml files slightly, and introduced the new keywords ‘FRMdir’, ‘FDBdir’, ‘CRSdir’, which the user can use to specify the locations of these files

From build ‘2013.04.18’ to build ‘2013.04.23’

IRIS Simulator:
-	added the sum values to the log, and fitted the log to the new OBS/FRM/FDB/CRS IDs
-	further optimization
-	new keywords for level 1 fits files

From build ‘2013.04.16’ to build ‘2013.04.18’

IRIS Simulator:
-	added keyword ‘quiet’, which, if set, suppresses most of the output to the command line
-	optimized to code for the use with multiple OBS, using simrep

From build ‘2013.04.13’ to build ‘2013.04.16’

IRIS Simulator:
-	fixed bug DAI 223
-	added some more keywords

From build ‘2013.04.11’ to build ‘2013.04.13’

IRIS Simulator:
-	If the keyword logonly is set, the FRM-, FDB- and CRS tables are read in at the beginning of the simulation, and those will be kept in memory for use in simrep, reducing the time spent on reading in files

From build ‘2013.03.27’ to build ‘2013.04.11’

IRIS Simulator:
-	If the keyword ‘logonly’ is set, the logfile will only be written when the simulation is completely done, and not for each step
-	Also, if this keyword is set, one can choose a directory in which to save the logs with the new keyword ‘logdir’, this directory may contain the character # which will be replace by a number, and it is possible to set a maximum number of files per folder, a new folder will be created automatically

From build ‘2013.02.27’ to build ‘2013.03.27’

IRIS Simulator:
-	Changed the logics of reading the xml-files slighlty so that it can now read the new filenames

From build ‘2013.02.21’ to build ‘2013.02.27’

IRIS Simulator:
-	Introduced new class ‘IRISsim_instrument’, which now contains all the instrument specific variables and methods
-	Changed the PZT logic slightly, so that it is now as defined in the Technical Note 1

From build ‘2013.02.20’ to build ‘2013.02.21’

IRIS Simulator:
-	CRS view on CCD window couldn’t be closed due to renaming of the IRIS simulator, fixed that bug (DAI 168)

From build ‘2013.02.18’ to build ‘2013.02.20’

IRIS Simulator:
-	Fixed some bugs with the constants (DAI 165)
-	Fixed PZT logic, so that the first image of an OBS is now always at [0,0] if PZT Off is set to 9999 (DAI 166)
-	Added two new keywords to fits files: ‘DATA_OBS’: Date and time when OBS started, ‘T_OBS’: Date and time when exposure started

From build ‘2013.02.08’ to build ‘2013.02.18’

IRIS Simulator:
-	Changed the layout slightly, so that the windows take less space
-	Changed the variable type of the exposure duration from integer to longword integer in ‘irissim_syntool.pro’
-	Changed the keywords for the fits-files
-	Changed the name of the simulator back to ‘IRIS_simulator’ (from ‘IRISsimulator’)
-	Fixed a bug, which made the simulator crash, when there was only one large spectral subregion

From build ‘2013.01.31’ to build ‘2013.02.08’

IRIS Simulator:
-	Introduced new keyword: ‘OBSrep’, if set, the given number will overwrite the number of repetition in the XML-file
-	Introduced new keyword: ‘savelogfull’, if set, a logfile will be created in csv-format, with all information about the exposure
-	Introduced new keyword: ‘logfulldir’, the logl2-file will be saved into this given directory (must already exist), if not given, it will be written into the same directory as the other output of the simulator
-	Introduced new keyword: ‘noplot’, if set all graphical output will be suppressed, but otherwise the whole simulation will be run
-	The progress bar no longer shows up, if the ‘logonly’ keyword is set
-	Solved a bug, which made the simulator crash, whe PZT Off was a large negative number (DAI 160)

From build ‘2013.01.24’ to build ‘2013.01.31’

IRIS Simulator:
-	Fixed a bug, which made NUV spectra ‘jump’
-	Added OBS ID as the title of the progress bar window
-	Incorporated the NUV simulation files, this requires every user to download the new files, old files are not compatible with new version (and vice versa)
-	Changed the behaviour of the tabs, they will now show more than one line, if there is not enough space for the tabs
-	Introduced a new class, called ‘IRISsim_constants’, which contains all constants, and some conversions, such as region on CCD to region-description, and exposure type number to a text
-	Replaced the function greek with hershey font (for lambda on plots), because greek.pro is not in vanilla installation of IDL
-	CRS region names are now calculated by the simulator, instead of taken from the description field in the CRS file (DAI 84)
-	Filterwheel will now be shown in wavelength, instead of internal number in first overview window

Level 1 to Level 2 tool:
-	Added exposure duration to level 2 fits files, in last image, in the auxiliary data

From build ‘2013.01.22’ to build ‘2013.01.24’

IRIS Simulator:
-	Minor bug fixed, Off X/Y was shown as ‘9999’ when a value was defined in the xml-file, and ‘0’ when it should have shown ‘9999’ (DAI 157)
-	Flush in FRM window always showed ‘0’, fixed that (DAI 155)
-	Exposure type will now be shown as text instead of a number (DAI 156)

From build ‘2013.01.21’ to build ‘2013.01.22’

IRIS Simulator:
-	Added new keyword to ‘IRISsim_readtables’, called ‘quiet’. If set, the print-output to IDL-commandline is suppressed
-	Fixed a bug, which made the simulation crash, in certain cases when the step size is negative

From build ‘2013.01.16’ to build ‘2013.01.21’

IRIS Simulator:
-	The logfiles which are opened, will now be closed again using free_lun (DAI 134)
-	Changed the counter in the logfiles, so that numbers aren’t repeated (DAI 132)
-	If logonly keyword is set, the SIMdata doesn’t have to be given now (DAI 135)
-	Changed the keyword in ‘pzt2xy’ and ‘xy2pzt’ from ‘step’ to ‘NoOffset’, and use this keyword also for the conversion of FRM-offsets, only OBS-offset does not use it (DAI 138)
-	Fixed a bug, which made the simulation crash in certain cases with no SJI FDBs (DAI 125, 133)

From build ‘2013.01.12’ to build ‘2013.01.16’

IRIS Simulator:
-	Changed the names of the output files, so that they start now with the OBS ID (DAI 91)
-	Added commanded exposure duration to logfiles
-	In start window of simulation, the PZT x/y are now shown as 9999, if they have this value in the xml-file, and not 0 (DAI 122)
-	Renamed the functions and procedures, files used for the simulator have now prefix ‘IRISsim_’, and files used by level1to2-tool have prefix ‘IRISl12’ (DAI 89)

From build ‘2013.01.11’ to build ‘2013.01.12’

IRIS Simulator:
-	Added keyword to functions ‘pzt2xy’ and ‘xy2pzt’, the keyword is ‘step’ and if set, the offset of the conversion will be set to zero, instead of 248 (DAI 100)

From build ‘2012.12.21’ to build ‘2013.01.11’

IRIS Simulator:
-	Fixed a bug, which made the program crash if only SJI, or only FUV/NUV FDBs are called (DAI 90/92)
-	Fixed bug DAI 88, where filename extensions were not properly dealt with in some cases
-	The PZT X/Y off are set to (0,0) at the beginning of the OBS, unless other values are specified for the first entry of the OBS (DAI 95)
-	If the filterwheel doesn’t move, the logfile shows now the correct value, instead of 9999 (DAI 102)
-	Removed the last line of the logfile, which showed the end time only (DAI 98)
-	Added an image number to the logfile, at the beginning of each line (DAI 94)
-	Added new keyword to syntool, ‘logonly’. If this is set, only the logfiles will be created and saved, thus increasing the speed considerably (DAI 103)

From build ‘2012.12.18’ to build ‘2012.12.21’

Level 1 to Level 2 tool:
-	made this tool more general, now the rasters for FUV and NUV are calculated correctly, also when there are more than one CRS and when sumspec and sumspat is greater than 1

From build ‘2012.12.12’ to build ‘2012.12.18’

IRIS Simulator:
-	Changed log-files, so that it shows one file entry per line, and adjusted txt-logfile in the same manner, except that PZTA/B/C is not shown for reasons of readabilty

From build ‘2012.12.05’ to build ‘2012.12.12’

IRIS Simulator:
-	Added some parameters to csv-logfile (PZTA, PZTB, PZTC, Focus, Flush, LUT, CompN, CompK
-	Changed the position of the CRS window, so that scroll area can be avoided if possible

From build ‘2012.11.28’ to build ‘2012.12.05’

IRIS Simulator:
-	Changed the default parameters, so that fuv/nuv folders and output folder are empty
-	If one of the the folders in the parameter fields are empty, the current directory is placed there

From build ‘2012.11.23’ to build ‘2012.11.28’

IRIS Simulator:
-	Added a progress bar, during the simulation, including a button to abort the simulation
-	Fixed some minor bugs
-	Prepended ‘IRIS_’ to IRIS-specific procedures

From build ‘2012.11.21’ to build ‘2012.11.23’

Pt -> IRIS_simulator:
-	The program can now be started from any directory, and the images are still found
-	Renamed ‘Pt’ to ‘IRIS_simulator’
-	Created new procedure, which builds the link between ‘Pt’ and ‘syntool’
-	‘IRIS_simulator’ now has a menu point in the OBS window ‘Simulator’ -> ‘Start Simulation’, when clicking a new window opens, where all parameters for syntool can be seen and changed. At the bottom of this window, there is a button ‘Start Simulation’, which starts syntool, with the given parameters. Parameters can be saved, either to a default file (which is in the user-idl-folder (user/.idl/) or an arbitrary file. Those files can be loaded again.
-	Introduced a new input parameter ‘outputfolder’, the user can pick a directory into which the resulting data should be saved

From build ‘2012.11.20’ to build ‘2012.11.21’

Syntool:
-	Adapted the arcsec-axes of SJI and spectral plots to the overview SJI, so that they now show the same range, as the box in the overview SJI (IRISDAI0074).
-	Fixed a bug in the calculation of the positions of the plots

From build ‘2012.11.16’ to build ‘2012.11.20’

Pt:
-	Added the CRS IDs to the images of the CCDs
-	Changed the logic of opening a new CCD window, if it already exists with the same CRSs, then instead of creating a new window, the old one is set to the front
-	FRM-, FDB- and CRS-window cannot be closed anymore (preventing a crash, which occurred when one of those windows was closed, and the user clicks on a tab/table on another window)
-	Fixed bug, readtables.pro searches for the xml-files in subfolder, now when it finds more than 1, it takes the one, which is in the same directory as the OBS-file.

Syntool:
-	Changed the way the spectral graphs are distributed onto the lines, now it is more evenly arranged (IRISDAI0079).

From build ‘2012.11.15’ to build ‘2012.11.16’

Syntool:
-	Fixed a bug in ‘datapreparesji.pro’, which made the program crash in certain cases

From build ‘2012.11.14’ to build ‘2012.11.15’

Syntool:
-	Changed the order of the axes, so that ‘Solar Y [arcsec]’ is on the left, ‘Solar Y [Px]’ is on the right, ‘Solar X [arcsec]’/’lambda [A]’ is on the bottom and ‘Solar X [Px]’/’lambda [Px]’ is on the top
-	Fixed a bug in the txt-logfile creation, when there is no FDB/CRS ID for a CCD, the string was too short, distorting the table
-	If a FUV SJI is included in the OBS the overview SJI was calculated too large, fixed that
-	Fixed some typos which made the program crash, when rebinning SJI
-	Implemented a check for the size of the subregions, the width and height of a subregion must be at least half a pixel, otherwise ‘expand_tv’ crashes

From build ‘2012.11.13’ to build ‘2012.11.14’

Syntool:
-	Changed the range of the SJI overview axes (top and right) so that its zero always points to the middle of the plot, and axes showing arcsec of all other plots will now adapt their range according to the current PZT (IRISDAI0074)
-	Fixed bug IRISDAI0073, now a subregion of a SJI can be bigger than the FUV/NUV area, however the fits file still only contains this area
-	Rewrote the logic of the SJI calculation, now the whole SJI area (both FUV and NUV) is calculated and saved into the fits-file, however only half of it contains any data, either FUV or NUV, according to the Filterwheel in use. This allows for whole-CCD regions and multiple regions within a CRS

From build ‘2012.11.12’ to build ‘2012.11.13’

Syntool:
-	Added a few more keywords to the fits-file headers, e.g. names of subregions
-	Fixed the bug, which showed wrong numbers on the axes of the graphs
-	Removed lower x- and left axes from overview SJI
-	Fixed some minor bugs

From build ‘2012.10.31’ to build ‘2012.11.12’

Syntool:
-	Made it compatible with new version of xml-files (‘irisplantool_20121017’)
-	Only the filename of the simulation input files is now saved into the logfile, instead of the full path, the path of the input is written as part of the header of the logfile
-	Fixed bug (A4 from Juan’s report), where the overview SJI was calculated incorrectly when startrow/-column was very small (actually when it was smaller then the SJI frame). In these cases the start pixels can be negative
-	Program calculates now number of ticks on all axes so that they are readable, distance between SJI has also been increased (bug A2c)
-	SJI and spectral windows are now arranged according to their y-range, and then according to wavelength. The axes are now displayed on the right and left side of each of the group of windows (bug B8)
-	The correct FW value is now taken into account, when calculating a SJI region (bug B1 & B6)
-	Program can now handle more than one region per CRS for the SJI (bug B2)
-	Changed the range of the SJI overview axes (top and right) so that its zero always points to the middle of the CCD (bug A1)
-	Log file changed from ‘.txt’ to ‘.csv’ (comma-separated-value file)
-	Additional kind of log file: human readable text file
-	Changed the load-logics of the simulation files,  program uses now ‘find_file’ and can handle ‘missing’ files (i.e. non-consecutive file numbers)
-	Added ‘_L1’ to folder- and fits-file-names
-	If no filename is given as input, a file-pick-dialog pops up
-	All input variables can be set as keywords on the command line, instead of within the procedure
-	Tested it with the output from ‘irisplantool_20121030’
-	Fixed some minor bugs

Pt:
-	Introduced ‘Inhibit Skip’ into OBS and FRM tables, changed ‘Flags’ to ‘Flush’ in FRM table, and introduced ‘Exp_Min’ in FDB table
-	Fixed a bug, which would crash the program in the case, where one uses two or more screens and more than one has an x-offset of zero
-	If no filename is given as an input, a file-pick-dialog is opened

General:
-	Changed the load-logics for the xml-files to adapt to possible appendix to filename and OBS, FRM, FDB, CRS possibly being in separate folders (readtables.pro)

From build ‘2012.10.29’ to build ‘2012.10.31’

Pt:
-	Added a button in the CRS window, which, when clicked on, will open a new window, displaying the CCDs and drawn on them the regions from the selected CRS files
-	The input variables can now be given in the command line, as input to the procedure, and don’t have to be changed within pt.pro anymore

Level 1 to Level 2 tool:
-	First draft implemented, only works correctly if there is just one CRS file for each, the FUV and NUV spectrum, PZT y is ignored, with spectral/spatial summations there will be problems with the row/column numbers

From build ‘2012.10.26’ to build ‘2012.10.29’

Pt:
-	Fixed bug, which displayed only part of the CRS window when a scroll area was applied (in case the screen is too small), but introduced new bug: one can now resize the CRS window, but then the scroll area will be wrong again, in the case where the window is set too small to display the full content, workaround: make the window big enough
-	Program checks now, if all windows’ offsets are within the bounds of the screen, if not, they are placed within the screen. If there is enough space on the screen, the FDB window will be placed next to the FRM window, otherwise next to OBS window (which is narrower), or on top of OBS window, if necessary.