-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pyVISA error triggered by setting the pm100 averaging window #8
Comments
It works for 300e-3, and for 10, 100, etc. It consistently fails for 0.9 and for 1. |
Note that the averaging window, read from the configuration, is not used at all. To be implemented at the resolution of this issue. |
I just noticed that the get_power() method calls this before it reads the power:
Why does the get_power method need to set the average.count value? And |
@latchr I think you are correct, I do not see a reason for self.ThorlabsPM.sense.average.count = self._averaging_window to be called in However, I still don't see how that line would be a problem. I have commented it out, and will merge into the deployed branch without testing on this branch (bad practice but this should be a non-breaking change. |
Note that the default averaging window listed in the config file is still not set on activation. |
What is affected by this bug?
All functionality with the PM100A is lost after a change to the averaging window.
When does this occur?
When you try and set the PM100A averaging window.
pm100.set_averagin_window(1)
Where on the platform does it happen?
The error is triggered by pyVISA.
How do we replicate the issue?
Load the
pm100
module and run:pm100.set_averagin_window(1)
then try and read the power:
pm100.get_power()
Expected behavior (i.e. solution)
It should not crash.
The text was updated successfully, but these errors were encountered: