Skip to content
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

Advice: implementing support for AndorSDK3+ on Linux #99

Closed
casparvitch opened this issue Feb 6, 2025 · 2 comments
Closed

Advice: implementing support for AndorSDK3+ on Linux #99

casparvitch opened this issue Feb 6, 2025 · 2 comments

Comments

@casparvitch
Copy link

Hiya, thanks for the nice package. Andor cameras working nicely on windows.

We're attempting to move to linux, and so I'm digging into pylablib to see if it's simple to swap to .so libs. Also note #69.

I specify the lib location with:

pll.par["devices/only_windows_dlls"] = False
pll.par["devices/dlls/andor_sdk3"] = "/usr/local/lib/libatcore.so"

So far the roadblocks I've come up against:

  • Even with the only_windows_dlls lib param set to False, you're blocked at load_lib here (easy change, remove the 'not')
  • Am I correct in assuming that the load_lib function should be called with the cdecl call_conv, e.g. here?
  • is ctypes.WINFUNCTYPEctypes.CFUNCTYPE correct? e.g. here

I will continue attempting to sidestep these issues, but if you have any guidance that would be appreciated 🙏

I am happy to lodge a PR eventually (or not) with a clean solution for a couple of camera types, but if you would like a more general solution (across other devices), I am happy to discuss that too.

@AlexShkarin
Copy link
Owner

Thanks for bringing these issues up! I'll fix them by the next release. What you are suggesting (replacing windll with cdecl and WINFUNCTYPE with CFUNCTYPE seem correct to me. And the only_windows_dlls line is, indeed, a typo on my part.

Let me know how this works out, and if you uncover any other issues!

@casparvitch
Copy link
Author

Works well for all of the Andor cameras I have available so far 🚀
I'll let you know if there's any other issues, especially when I go to other manufacturers. Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants