Open LMSC-NTappy opened 2 years ago
Hello, for this plugin I'm using the package Instrumental that at the time was missing some functionalities. I did a PR from my fork but it seems it is not yet included in the official branch. You can therefore try to install Instrumental from :
https://github.com/CEMES-CNRS/Instrumental
see pip documentation on how to install from a git url!
However Instrumental also requires the thorlabs library to be processed once for the python code to work. If you cannot find how to do it, you can try to execute the module __builduc480.py:
Let me know if it works
Hello,
Did you have success controlling the camera exposure time with your implementation?
I have checked mabuchilab/Instrumental#144 and in my opinion there is something broken beyond the missing exposure
facet.
See mabuchilab/Instrumental#150
Well I got that camera only for a short time to produce the new PID module and the video on it. I don't remember if I made it finally working but I think so. @quantumm is the owner of the camera, so maybe he can do some testing?
If he can, that'd be great!
In any case, I've opened #5 on the topic. For me it currently works so if @quantumm finds some time to test it'd be great
Hello, I will try to do those tests but unfortunately for now it is difficult to find some time :/
Hi,
I tried again to install the plugin to use a DCC camera with a fresh install of pymodaq (3.5.6).
I was surprised to see that this issue is still not solved.
It seems like something wrong happened during the merge of the PR #5 .
Such call like controller.exposure
should have been removed, which is not the case if you look at lign 91 in the current version of this file : https://github.com/CEMES-CNRS/pymodaq_plugins_thorlabs/blob/0.1.2/src/pymodaq_plugins_thorlabs/daq_viewer_plugins/plugins_2D/daq_2Dviewer_Thorlabs_DCx.py
Hi @quantumm,
The merge is fine, the changes have just not been released in a new version of the plugin yet.
For now, you should still install from source the main branch of this PR to obtain theses fix
Ah ok. Think I got it ;) Thanks.
Do you think the modifications in the plugin are stable enough? If yes, I'll publish a new version of the plugin on pypi
Le lun. 11 avr. 2022 à 13:57, quantumm @.***> a écrit :
Ah ok. Think I got it ;) Thanks.
— Reply to this email directly, view it on GitHub https://github.com/CEMES-CNRS/pymodaq_plugins_thorlabs/issues/4#issuecomment-1094961147, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABSNYIZR53TMPJTPJ6EQNC3VEQHTHANCNFSM5NBZPX5Q . You are receiving this because you commented.Message ID: @.***>
I only tested the camera, not the other instruments, but it is fine for that part yes.
I tested myself the new plugin for the TLPM powermeter but it depends on a release of instrumental-lib not yet out... I'd like to put requirements pointing on an archive file of the forked instrumental but could not find the solution yet, any idea? Could be also useful for other libraries where we write drivers that we then need in our plugins...
Le lun. 11 avr. 2022 à 14:25, quantumm @.***> a écrit :
I only tested the camera, not the other instruments, but it is fine for that part yes.
— Reply to this email directly, view it on GitHub https://github.com/CEMES-CNRS/pymodaq_plugins_thorlabs/issues/4#issuecomment-1094985845, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABSNYI64IYNK2HT7KKT462LVEQKZ3ANCNFSM5NBZPX5Q . You are receiving this because you commented.Message ID: @.***>
I think this can be achieved directly from the install_requires if you have a clone of instrumental_lib on github that will reliably work for an extended period of time:
Cheers
Nicolas
well yes, but this option requires git on your system and most windows user will not have it. I would rather try installing from an archive as:
pip install https://github.com/CEMES-CNRS/Instrumental/archive/refs/tags/cemes.0.6.tar.gz
This is working if you type it directly in the command line, but it does not if you place the url directly in the requirements...
FOUND IT !!!
You have to put this in the requirements (in your plugin toml file):
[plugin-install]
packages-required = ["pythonnet", "pywin32", "nicelib", "instrumental-lib @ https://github.com/CEMES-CNRS/Instrumental/archive/refs/tags/cemes.0.6.tar.gz"]
so you can point directly to an archive file without need of git. You could also do it for your dependencies on pylablib also
I will therefore publish a new version of thorlabs plugin including this requirement (until the new version of instrumental is published)
Hi guys,
Just wanted to note that the new release of the plugin didn't get uploaded to pypi
( error in upload workflow)
" Invalid value for requires_dist. Error: Can't have direct dependency:
'instrumental-lib @ https://github.com/CEMES-CNRS/Instrumental/archive/
refs/tags/cemes.0.6.tar.gz'
so at the moment, it cannot be installed by the plugin manager. I was running into the camera exposure issue and it kind of drove me crazy until I noticed that I wasn't on the last release :-)
Ok I reverted the requirements on instrumental-lib for the moment and published v 0.2.0 on pypi manually. I'm in the process of a push release on instrumental so should have the next release soon to make it all work.
Hello,
I am facing an error initialize a thorlabs camera. The Camera is correctly detected
I think the fix might be as easy as replacing https://github.com/CEMES-CNRS/pymodaq_plugins_thorlabs/blob/5df60c9fea7b6f41546dd1b3ea8d3732d351e3e0/src/pymodaq_plugins_thorlabs/daq_viewer_plugins/plugins_2D/daq_2Dviewer_Thorlabs_DCx.py#L91
and other similar instances such as
https://github.com/CEMES-CNRS/pymodaq_plugins_thorlabs/blob/5df60c9fea7b6f41546dd1b3ea8d3732d351e3e0/src/pymodaq_plugins_thorlabs/daq_viewer_plugins/plugins_2D/daq_2Dviewer_Thorlabs_DCx.py#L54
by
self.controller._get_exposure()
andself.controller._set_exposure(Q_(...))
I am unable to submit a PR right now since I don't manage to get this plugin installed from source, see
CEMES-CNRS/PyMoDAQ#71 but I hope to get it right at some point lol