-
Notifications
You must be signed in to change notification settings - Fork 71
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
Including dll driven instruments #349
Comments
I am open to the idea, but we'll need to integrate these DLL/SO files in an intelligent way. Ideally we build them from source for each platform as part of CI. @bmoneke do you have the source code for those DLLs? Or are you speaking to closed-source DLLs provided by a manufacturer? |
Unfortunately I'm talking about closed-source DLLs provided by the manufacturer, as such, I do not have the source code. I know, that it is a difficult question. On one hand, the repository would not be enough to run the device. On the other hand it allows to use the device easily with python, once you follow the manufacturer's installation instructions. |
Okay good to know. I've been investigating how to build a plugin system to allow others to write their own drivers. It can also be used for installing "optional" drivers, say from an |
The idea of an extra repository sounds great. I don't know, how the usage will look like afterwards, but that way there is a clear distinction between byte stream oriented devices with a complete driver and wrappers or more complex drivers. |
If we assume a package of the name First install either by specifying to install the package: $ pip install "instrumentkit-extras" or during the main package installation, but making use of the "extra-deps" functionality of setuptools: $ pip install "instrumentkit[extras]" This would then map to installing Then using the drivers would then ideally be the same as it is right now. |
That sounds great. |
Consider using NiceLib [1], developed by the Hideo Mabuchi Group [2]. It's developed by the Instrumental [3] folks but perhaps it could be used in your new package as well. [1] https://nicelib.readthedocs.io |
I like the ideas with putting drivers that use close-sourced dlls into an extras package. Testing should still be possible and straight forward. Even now we are using the loopback communicator for testing, so the test suite doesn't need the actual instrument. That should basically be the same with the One more thing to keep in mind: IK is currently pretty much platform agnostic, however, loading DLLs with Since you mentioned the high finesse wavemeter above: I actually did write a very simple start for a driver a while ago for the WS6. The idea was to write put it in the |
Interesting @trappitsch , thanks for sharing, I also had found the ws7 driver and based an (yet untested) API on that version. |
One caveat for dll-driven drivers: It is really hard to write meaningful tests for them, as I learned at the pico-python repository for picoscope digital oscilloscopes. I appreciate how easy it is writing tests for instrumentkit due to the great |
This might be ignorant, but I think it should be possible to mock the |
Dear @scasagrande what's your opinion about dll driven instruments? Pymeasure does not want to include those.
I'm looking for a good instruments framework to include my lab instruments (including tests). Right now I have my own simple collection of files.
I'm willing to put my devices in such a framework and publish them upstream.
Some devices use dlls (NKT lasers, High finesse wavemeter etc.), I'd like to include them in the framework, but understand, if it is not desired.
By the way, I like your better testing ability than in pymeasure and that you do not have a gui, while I look for instruments only.
The text was updated successfully, but these errors were encountered: