diff --git a/script/templates/EnergyScan.py b/script/templates/EnergyScan.py index 72b3621..df40524 100644 --- a/script/templates/EnergyScan.py +++ b/script/templates/EnergyScan.py @@ -1,8 +1,9 @@ +if get_exec_pars().source == CommandSource.ui: + REGIONS = [[523.0, 527.0, 2.0], [527.0, 535.0, 4.0], [535.0, 558.0, 2.0]] -sensors=[i0, scienta.stats[0]] -regions = [[523.0, 527.0, 0.5], [527.0, 535.0, 0.25], [535.0, 558.0, 0.5]] +sensors=[i0, scienta.stats[0], scienta.getSpectrum()] caputq("NAPP-SCIENTA:HDF1:Capture",1) @@ -13,7 +14,7 @@ def trigger(position, scan): try: - rscan(energy, sensors, regions, latency = 0.0, before_read=trigger) + rscan(energy, sensors, REGIONS, latency = 0.0, before_read=trigger) finally: caputq("NAPP-SCIENTA:HDF1:Capture",0) scienta.zeroSupplies() \ No newline at end of file