I am trying to set up communication with a 2204A, using Python 3.9 (64 bit) on Windows. I downloaded and installed the 64 bit PicoSDK, and I installed the GitHub python wrapper repo (https://github.com/picotech/picosdk-python-wrappers).
Following the Readme in that repo, I tried executing the verification code:
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Daniel Merthe\AppData\Local\Programs\Python\Python39\lib\site-packages\picosdk\discover.py", line 46, in find_all_units
device = driver.open_unit()
File "C:\Users\Daniel Merthe\AppData\Local\Programs\Python\Python39\lib\site-packages\picosdk\library.py", line 134, in open_unit
return Device(self, self._python_open_unit(serial=serial, resolution=resolution))
File "C:\Users\Daniel Merthe\AppData\Local\Programs\Python\Python39\lib\site-packages\picosdk\library.py", line 146, in _python_open_unit
handle, status = self._python_open_any_unit(resolution)
File "C:\Users\Daniel Merthe\AppData\Local\Programs\Python\Python39\lib\site-packages\picosdk\library.py", line 163, in _python_open_any_unit
resolution = self.DEFAULT_RESOLUTION
AttributeError: 'Ps6000alib' object has no attribute 'DEFAULT_RESOLUTION'
Is this a true bug, or did I miss something in the installation?
After digging around the code in the repository, I find no mention or assignment of the DEFAULT_RESOLUTION attribute of Ps6000alib (class defined in picosdk/ps6000a.py). So, it must be defined at a lower level, which I am not comfortable playing around with.
I installed a second 2204A on a Linux system (w/ Python 3.7) and ran into the same error, so it is not a driver installation error on my part.
However, I found that everything works fine if line 22 in discover.py is commented out (see attached image). This indicates that the implementation (at the driver level?) of the 6000A series of oscilloscopes is different from the other series in a way that conflicts with how this Python library generally handles them.