I am trying to calculate multimode fiber coupling efficiency by using Geometric Image Analysis through GETTEXTFILE, and I want to do this for different fields and wavelengths. I am trying to change field# and wavelength# by MODIFYSETTINGS, but looks like these two parameters are not allowed to be changed. Following is the list of parameters that MODIFYSETTINGS provides:
I wonder if anyone knows how to make the changes so I can do this calculation using ZPL.
Best answer by David.NguyenView original
As you have noted, the field and wave numbers don’t seem to be editable with MODIFYSETTINGS in ZPL. One solution, if you want to keep using ZPL, is to manually create multiple CFG files prior to running the macro. Each CFG file would have a field and wave number that is identified in its name, and whenever you run an analysis, you start by specifying the CFG file you require with:
For example, you could have a CFG file syntax like so:
And so, for field 1, and wavelength 1, your CFG file is called: MyCFGFile_1_1.CFG, and for field 1, and wavelength 2, it is: MyCFGFile_1_2.CFG, ...etc.
Then, when you call OPENANALYSISWINDOW, you specified which CFG file to use, therefore, which field and wavenumber:
It does require you to create those CFG files manually once before though.
Otherwise, I think you have to use the ZOSAPI until it gets implemented (if ever) in ZPL. In the ZOSAPI, the field and wave numbers are already implemented:
And so, you can access those directly with:
I hope this helps. Take care,