-
Notifications
You must be signed in to change notification settings - Fork 49
Additional Hardware Drivers Installation
The standard POCS installation instructions assume you will be using the standard PANOPTES hardware, i.e. DSLR cameras controlled via the gphoto2
library. POCS does include support for a range of other hardware, however some require the installation of additional drivers. This page provides instructions on how to do this.
POCS includes support for ZWO cameras. The vendor supplied drivers must be installed first.
- Download the SDK for linux, available from the Software and Drivers page of their website. Go the the "For Developers" tab on the far right and select the Download link for the latest version. As of this writing the current version is v1.14.0425.
- Move the file to its own directory and extract the compressed archive, e.g.
mkdir ASIBuild
cd ASIBuild
mv ~/Downloads/ASI_linux_mac_SDK_V1.14.0425.tar.bz2 .
tar xvzj ~/Downloads/ASI_linux_mac_SDK_V1.14.0425.tar.bz2
- Find the driver library for your system. These are distributed as compiled shared (dynamically linked) library files (
.so
). From thelib/README.txt
:- ubuntu:x86, x64
- armv7: raspberry pi2
- armv8: arm 64bit
- Either copy the appropriate
libASICamera2.so
file to/usr/local/lib/
or make a symbolic link, e.g.sudo ln -s ~/ASIBuild/lib/x64/libASICamera2.so /usr/local/lib/
- Change to the
lib/
directory and runsudo install asi.rules /etc/udev/rules.d
. - Disconnect and reconnect the camera and then run
cat /sys/module/usbcore/parameters/usbfs_memory_mb
. A correct result should show200
.
POCS includes support for SBIG cameras from Diffraction Limited. The vendor supplied drivers must be installed first.
- Download the Linux Dev Kit. At the time of writing this is only available via the SBIG ftp site, at ftp://ftp.sbig.com/pub/devsw/LinuxDevKit.tar.gz
- Extract the compressed archive to a convenient location, e.g.
tar xvzf ~/Downloads/LinuxDevKit.tar.gz ~/Build/
- Find the driver library for your system. These are distributed as compiled shared (dynamically linked) library files (
.so
).- For x86_64 use
LinuxDevKit/x86/c/lib64/libsbigudrv.so
- For 32 bit x86 use
LinuxDevKit/x86/c/lib32/libsbigudrv.so
- For 32 bit ARM (e.g. Raspberry Pi) use
LinuxDevKit/arm/c/lib/libsbigudrv.so
- For x86_64 use
- Either copy the appropriate
libsbigudrv.so
file to/usr/local/lib/
or make a symbolic link, e.g.sudo ln -s ~/Build/LinuxDevKit/arm/c/lib32/libsbigudrv.so /usr/local/lib/
- Either copy or link the
LinuxDevKit/udev/51-sbig-debian.rules
file to/etc/udev/rules.d/
, e.g.sudo ln -s ~/Build/LinuxDevKit/udev/51-sbig-debian.rules /etc/udev/rules.d/
- Download the current SBIG Universal Driver for OS X, either by going to the Diffraction Limited website, navigating to a camera product page (e.g. STF-8300M), clicking the 'DOWNLOADS' tab, and scrolling down to 'SBIGUDrv', or downloading it directly from the SBIG ftp site at ftp://ftp.sbig.com/pub/SBIGDriverInstallerUniv.dmg
- Double click the downloaded disk image file to mount it, or
Ctrl-click > Open with > Disk Image Mounter
. If that doesn't work you may have to open the Disk Utility app and useFile > Open Disk Image
- Once the disk image is mounted open it in Finder. There will be a
.pkg
file inside. -
Ctrl-click > Open with > Package Installer
to open the.pkg
file. You may be prompted to confirm that you really want to open it. - The installer will now open. Follow the prompts to complete the installation.
POCS includes support for cameras from Finger Lake Instruments (FLI). Some modification/configuration of the vendor supplied drivers is required first.
Installating the currently releases version on Linux requires installing a kernel module and building a shared library from the SDK.
NOTE: Changes to the Linux kernel timer API in version 4.15 mean that the FLI kernel module is not compatible with Linux kernels from 4.15 onwards. For Linux systems with recent kernels see the alternative, libusb based FLI SDK at the bottom of this page.
The FLI kernel module is distributed as source code. The installation process is standard but manual.
- Make sure you have the Linux kernel headers installed. On most distributions this will be a package called
linux-headers
or similar, for Raspberry Pi make sure to installraspberrypi-kernel-headers
instead, i.e.sudo apt-get install raspberrypi-kernel-headers
. - Download the latest Linux kernel module from the FLI Software page, in the 'Development' column on the right. At the time of writing this was version 1.3.2, at http://www.flicamera.com/downloads/sdk/fliusb-1.3.2.tgz
- Extract the compressed archive to a convenient location, e.g.
tar xvzf ~/Downloads/fliusb-1.3.2.tgz ~/Build/
- Change to the directory where you extracted the kernel module source, e.g.
cd ~/Build/fliusb-1.3.2
- Build the kernel module using
make
. The directory should now contain afliusb.ko
file. - Copy the kernel module into the running kernel's module directories, e.g.
sudo cp fliusb.ko /lib/modules/`uname -r`/kernel/drivers/usb/misc/
(note the backticks`
) - Run
sudo depmod
to register the module with the kernel. - Check that the kernel module has been successfully installed & registered with
modinfo fliusb
. This should produce output similar to this:version: 1.3.2 license: Dual BSD/GPL author: Finger Lakes Instrumentation, L.L.C. <[email protected]> srcversion: 8C80657CCB0A10B52275612 alias: usb:v0F18p000Ad*dc*dsc*dp*ic*isc*ip*in* alias: usb:v0F18p0007d*dc*dsc*dp*ic*isc*ip*in* alias: usb:v0F18p0006d*dc*dsc*dp*ic*isc*ip*in* alias: usb:v0F18p0005d*dc*dsc*dp*ic*isc*ip*in* alias: usb:v0F18p0002d*dc*dsc*dp*ic*isc*ip*in* depends: vermagic: 4.9.59-v7+ SMP mod_unload modversions ARMv7 p2v8 parm: buffersize:USB bulk transfer buffer size (uint) parm: timeout:USB bulk transfer timeout (msec) (uint)
When the Linux kernel is updated then you should repeat steps 4-8 (though it would probably be sufficient to repeat just step 6).
When you connect an FLI camera to the computer the fliusb
module should be automatically loaded, and it will create a device node for the camera of the form /dev/fliusbX
, i.e. dev/fliusb0
, /dev/fliusb1
, etc.
By default this device node will only be accessible to the root user, but you can change this by creating a udev
rules file. For example, to grant access to all users create a file /etc/udev/rules.d/52-fliusb.rules
with the following contents:
# Attempt to have FLI camera device nodes (/dev/flibusbX) created with global read/write permissions
SUBSYSTEM=="usb", ATTR{idVendor}=="0f18", ATTR{idProduct}=="000a", MODE="0666", GROUP="plugdev"
Alternatively to grant access only to users in the plugdev
group change the MODE
from 0666
to 0660
.
The FLI software development kit contains a driver library, distributed as C source code. The included Makefile
is configured to build only a statically linked library (libfli.a
) but POCS needs a shared (dynamically linked) library (libfli.so
), which requires some modifications to the Makefile
.
- Download the latest SDK from the FLI Software page, in the 'Development' column on the right. At the time of writing this was version 1.104, at http://www.flicamera.com/downloads/sdk/libfli-1.104.zip
- Extract the compressed archive to a convenient location, e.g.
unzip ~/Downloads/libfli-1.104.zip ~/Build/
- Change to the directory where you extracted the kernel module source, e.g.
cd ~/Build/libfli-1.104
- Edit the
Makefile
as follows:- Add
-fPIC
to theCFLAGS
(line 20), i.e. changeCFLAGS = -Wall -O2 -g $(patsubst %, -I%, $(INC))
toCFLAGS = -Wall -O2 -g $(patsubst %, -I%, $(INC)) -fPIC
- Add a target for the shared library by adding these two lines at line 50 (between the
libfli
anddoc
targets):libfli.so: libfli.o $(ALLOBJ) $(CC) -o $@ $^ $(CFLAGS) -lm -nostartfiles -shared
- Add
libfli.so
to theclean
target, i.e. change line 67 fromrm -f $(ALLOBJ) libfli.o libfli.a
torm -f $(ALLOBJ) libfli.o libfli.a libfli.so
- Add
- Build the object files and statically linked library with
make
. - Build the shared library with
make libfli.so
. - Either copy the
libfli.so
file to/usr/local/lib/
or make a symbolic link, e.g.sudo ln -s libfli.so /usr/local/lib/
.
Installation on OS X requires building a shared library from the SDK.
At the time of writing we have been unable to successfully build a shared (dynamically linked) library from the the current version of the SDK (1.104).
FLI have an as yet unreleased (at the time of writing) version of the FLI SDK that uses libusb
instead of the custom kernel module. This avoids the problem of incompatibility of the fliusb
kernel module with recent Linux kernel versions and also works on Mac OS X.
The pre-release FLI software development kit contains a driver library, distributed as C source code. The included Makefile
is still only configured to build a statically linked library (libfli.a
) but POCS needs a shared (dynamically linked) library (libfli.so
), which requires some modifications to the Makefile
.
- Ensure that
libusb-1.0
and the corresponding development files are installed, e.g. for Ubuntu/Raspbian/etc.sudo apt install libusb-1.0.0 libusb-1.0.0-dev
- Download the latest pre-release SDK. At the time of writing this was only available by email from FLI.
- Extract the compressed archive to a convenient location, e.g.
unzip ~/Downloads/libfli-1.999.1-180223.zip ~/Build/
- Change to the directory where you extracted the kernel module source, e.g.
cd ~/Build/libfli-1.104
- Edit the
Makefile
as follows:- Add a target for the shared library by adding these two lines at line 73 (between the
libfli
anddoc
targets):libfli.so: libfli.o $(ALLOBJ) $(CC) -o $@ $^ $(CFLAGS) -lm -nostartfiles -shared -l usb-1.0
- Add
libfli.so
to theclean
target, i.e. change line 93 fromrm -f $(ALLOBJ) libfli.o libfli.a
torm -f $(ALLOBJ) libfli.o libfli.a libfli.so
- Add a target for the shared library by adding these two lines at line 73 (between the
- Build the object files and statically linked library with
make
. - Build the shared library with
make libfli.so
. - Either copy the
libfli.so
file to/usr/local/lib/
or make a symbolic link, e.g.sudo ln -s libfli.so /usr/local/lib/
.