Navigator hang-up because of energy filter error
Added by Anonymous almost 15 years ago
Hi,
when I try to use the navigator to test image shift and stage modelling I run into problems:
I can acquire an image and can move to the respective location by clicking...but the "moving..." message never stops and the arrow icon next to the node remains turning forever.
I cannot perform any image shift error measurements - I have to kill the application to get the node working again.
The following error message is displayed in the console window (but not in the log):
Exception: Cannot set energy filter width.
The energy filter, however, is not even inserted.
I get this error also in the Presets node (in the log as well as in the console), when I switch from one preset to the other. The error does not depend on whether the filter is to be inserted or not or what width is set (tested: 0, 10, 20 eV).
(Probably unrelated: When switching from one preset to the next I also get "unable to set instrument"?)
-Matthias Brunner
Replies (4)
Re: Navigator hang-up because of energy filter error - Added by Jim Pulokas almost 15 years ago
Let me know what version of DigitalMicrograph you have. The scripting functions for energy filter may have different names in different versions. Here is a quick test you can try to help diagnose this problem:
On the microscope PC, make sure DigitalMicrograph is running. Start a Python command line and enter the following lines:
from pyScope import gatan g = gatan.Gatan() g.setEnergyFilterWidth(10)or instead of 10, put whatever width you want to set it to. Let me know what the error message is. It the error has something to do with the function/attribute not existing or not supported, then continue testing with the following lines:
g.hasScriptFunction("AFSetSlitWidth") g.hasScriptFunction("IFCSetSlitWidth")and let me know the result of each of those functions.
Re: Navigator hang-up because of energy filter error - Added by Anonymous almost 15 years ago
Thanks for the reply!
We have Digital Micrograph version 3.9.5 for GMS 1.4.5
>>> from pyScope import gatan >>> g = gatan.Gatan() >>> g.setEnergyFilterWidth(5) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:\Program Files\Python\lib\site-packages\pyScope\gatan.py", line 253, i n setEnergyFilterWidth raise RuntimeError('unable to set energy filter width') RuntimeError: unable to set energy filter width
Nevertheless, I tested the following:
>>> g.hasScriptFunction("AFSetSlitWidth") True >>> g.hasScriptFunction("IFSetSlitWidth") True
Whether CCD or GIF CCD is selected in the camera panel in Tecnai UI does not matter. Whether the slit is inserted does not matter.
I also checked in Digital Micrograph script:
AFGetSlitWidth returns 0, regardless of the actual width set.
AFSetSlitWidth(5) returns also 0 and has no effect.
IFGetSlitWidth not known, interestingly. And IFSetSlitWidth(5) returns the bizarre error message (paraphrased): "Function not known, try RealNumber IFSetSlitWidth (RealNumber slitwidth)"...which is what I thought I was actually doing.
Since we do not plan to use the energy filter together with Leginon currently, can we just change setEnergyFilterWidth into a dummy function in gatan.py?
Or will this lead to problems elsewhere?
Re: Navigator hang-up because of energy filter error - Added by Jim Pulokas almost 15 years ago
I am glad this is a DigitalMicrograph problem and not with Leginon, but then I am not sure how to fix it.
You can make it a dummy function. Look in simccdcamera.py for the example of how to make it act like it is really working.
Re: Navigator hang-up because of energy filter error - Added by Anonymous almost 15 years ago
Thanks, this did the job...we will also contact Gatan in this matter.