Closed MattBlack85 closed 1 year ago
@MattBlack85 I think actually command to verbose logging of indi server is with three vvv not four :)
indi_server -vvv
In KStars you can find indi_pylibcamera driver inside Others section:
At least on my system wich is Raspberry PI OS Bullseye.
About rewriting repro Ronald will have to ansver. Maybe you can give an example structure of Python package?
course you right with the triple v and I see now the pylibcamera under the Others
thanks!
to @scriptorron
the scaffold would be more or less the following:
repo root
|________indi_pylibcamera
| |
| |__ CameraControl.py
| |__ SnoopingManager.py
| |__ indidevice.py
| |__ print_camera_info.py
|
|________bin
| |
| |__ indi_pylibcamera
|
| _______setup.py
I packaged some python stuff in the past and if you guys like, I can try to make those changes.
This will allow basically to install the scaffold as a python package (pip, pipenv, blabla) and the executable can be installed via pip or packaged for any OS
Maybe the right path here would be to include this driver into https://github.com/indilib/indi-3rdparty?
that would be the best option but I believe it won't make it :|
from what I observed while trying to build it it has a lots of dependencies on external python libraries (which is a first in indi I believe) plus the project structure still implies you are importing a python lib.
Maybe the code from the different files could be merged into a single one (although from a maintenance perspective it is not a good thing), at that point listing the deps would be enough (although, again, I dunno how cmake can be instructed to find for python dependencies when building indi_pylib_camera
Yeah Jasem confirmed that currently it isn't doable: https://indilib.org/forum/ccds-dslrs/12177-indi-libcamera-driver.html?start=180#93433.
So I guess best option would be to turn it to Python pip3 package. If @scriptorron agrees of course.
@sajmons: Thank you for jumping in.
@MattBlack85: You are right and I fully agree with you. This project needs a comfortable (and standardized) way to install it. I believe I can make it a pip package on PyPI. I never did that before with GitHub actions but I think I can learn it.
It is now on PyPi (https://pypi.org/project/indi-pylibcamera/).
Installation procedure is:
sudo apt-get install libcamera-apps indi-bin python3-picamera2 python3-lxml python3-astropy
sudo pip3 install indi_pylibcamera
sudo indi_pylibcamera_postinstall
It is important to install python3-picamera2
with apt-get! Pip could also install it but it is very likely that picamera2
will not fit to the system libcamera
.
I tested it on 3 Raspberries. But would be nice if someone else could test the installation.
Great work @scriptorron! I'll test new installation procedure as soon as I can.
@scriptorron it works for me, I packaged also the camera and all deps for ArchLinux and it's available now as a package for my distro, many thanks!
Hi @scriptorron it's me again :)
I think I got extremly close to start indi_pylibcamera
When I was packaging everything I realized that the actual way to install indi_pylibcamera is to clone the repo and symlinking the entrypoint to the one within the repo.
would you consider (yes, I know it's another request from me :joy: ) to rework the repo in such a way that this will become a full featured python package? This way the helpers may live under
/usr/lib/pythonX.XX/sites-packages/indi_pylibcamera
and /usr/bin/indi_pylibcamera` can be installed under /usr/bin without having to symlinkPS: it seems also that even if the xml spec is there, I don't see the driver on Kstars, any idea on this?