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

Splitting indi-asi #13

Merged
merged 11 commits into from
Nov 3, 2019
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 26 additions & 2 deletions cmake_modules/FindASI.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,36 @@ else (ASI_INCLUDE_DIR AND ASI_LIBRARIES)
${GNUWIN32_DIR}/include
)

find_library(ASI_LIBRARIES NAMES ASICamera2
find_library(ASICAM_LIBRARIES NAMES ASICamera2
PATHS
${_obLinkDir}
${GNUWIN32_DIR}/lib
)

find_library(ASIEFW_LIBRARIES NAMES EFWFilter
PATHS
${_obLinkDir}
${GNUWIN32_DIR}/lib
)

find_library(ASIST4_LIBRARIES NAMES USB2ST4Conv
PATHS
${_obLinkDir}
${GNUWIN32_DIR}/lib
)

find_library(ASIEAF_LIBRARIES NAMES EAFFocuser
PATHS
${_obLinkDir}
${GNUWIN32_DIR}/lib
)


if (ASICAM_LIBRARIES AND ASIEFW_LIBRARIES AND ASIST4_LIBRARIES AND ASIEAF_LIBRARIES)
set(ASI_LIBRARIES ${ASICAM_LIBRARIES} ${ASIEFW_LIBRARIES} ${ASIST4_LIBRARIES} ${ASIEAF_LIBRARIES})
endif (ASICAM_LIBRARIES AND ASIEFW_LIBRARIES AND ASIST4_LIBRARIES AND ASIEAF_LIBRARIES)
knro marked this conversation as resolved.
Show resolved Hide resolved


if(ASI_INCLUDE_DIR AND ASI_LIBRARIES)
set(ASI_FOUND TRUE)
else (ASI_INCLUDE_DIR AND ASI_LIBRARIES)
Expand All @@ -46,5 +70,5 @@ else (ASI_INCLUDE_DIR AND ASI_LIBRARIES)
endif (ASI_FOUND)

mark_as_advanced(ASI_INCLUDE_DIR ASI_LIBRARIES)

endif (ASI_INCLUDE_DIR AND ASI_LIBRARIES)
6 changes: 6 additions & 0 deletions debian/indi-asi/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
indi-asi (1.4) bionic; urgency=medium

* Separating ASI driver from libraries

-- Radek Kaczorek <[email protected]> Sat, 2 Nov 2019 14:39:00 +0100

indi-asi (1.3) bionic; urgency=low

* Adjust maximum resolution to account for the ZWO capture size limitation rules.
Expand Down
4 changes: 2 additions & 2 deletions debian/indi-asi/control
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ Source: indi-asi
Section: science
Priority: extra
Maintainer: Jasem Mutlaq <[email protected]>
Build-Depends: debhelper (>= 5), cdbs, cmake, libusb-1.0-0-dev, libcfitsio3-dev|libcfitsio-dev, libindi-dev, zlib1g-dev, libnova-dev
Build-Depends: debhelper (>= 5), cdbs, cmake, libusb-1.0-0-dev, libcfitsio3-dev|libcfitsio-dev, libindi-dev, zlib1g-dev, libnova-dev, libasi
Standards-Version: 3.9.1

Package: indi-asi
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, libindi1, asi-common
Depends: ${shlibs:Depends}, ${misc:Depends}, libindi1, libasi
conflicts: indi-asicam
replaces: indi-asicam
Description: INDI Driver for ZWO Optics ASI cameras
Expand Down
2 changes: 1 addition & 1 deletion debian/indi-avalon/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ indi-avalon (1.7) stretch; urgency=medium
* 50ms delay after pulse guiding command to avoid device flooding
* Removing tracking speed NONE

-- Wolfgang Reissenberger <[email protected]> Sun 29 Sep 2019 21:47:57 +0200
-- Wolfgang Reissenberger <[email protected]> Sun, 29 Sep 2019 21:47:57 +0200

indi-avalon (1.5) stretch; urgency=medium

Expand Down
Empty file modified debian/indi-ffmv/rules
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion debian/indi-rtlsdr/changelog
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
indi-inovaplx (1.4) bionic; urgency=low
indi-rtlsdr (1.4) bionic; urgency=low

* New upstream version.

Expand Down
2 changes: 1 addition & 1 deletion debian/indi-ssag/control
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Standards-Version: 3.9.1

Package: indi-ssag
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, libindi1, asi-common
Depends: ${shlibs:Depends}, ${misc:Depends}, libindi1
Description: INDI Driver for Orion Starshoot cameras
Driver for Orion Starshoot cameras.
.
Expand Down
Empty file modified debian/indi-talon6/rules
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion debian/libaltaircam/control
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Source: libsaltaircam
Source: libaltaircam
Section: libs
Priority: extra
Maintainer: Jasem Mutlaq <[email protected]>
Expand Down
Empty file modified debian/libaltaircam/rules
100644 → 100755
Empty file.
6 changes: 6 additions & 0 deletions debian/libasi/changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
libasi (1.0) buster; urgency=medium

* Initial release

-- Radek Kaczorek <[email protected]> Sat, 2 Nov 2019 13:06:00 +0100

1 change: 1 addition & 0 deletions debian/libasi/compat
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
9
13 changes: 13 additions & 0 deletions debian/libasi/control
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Source: libasi
Section: libs
Priority: extra
Maintainer: Radek Kaczorek <[email protected]>
Build-Depends: debhelper (>= 6), cdbs, cmake
Standards-Version: 3.9.2

Package: libasi
conflicts: asi-common
replaces: asi-common
Architecture: i386 amd64 armhf arm64
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: Library for ASI Cameras, Filter Wheel, Focuser and ST4
46 changes: 46 additions & 0 deletions debian/libasi/copyright
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: libasi
Upstream-Contact: Jasem Mutlaq <[email protected]>
Source: https://github.com/indilib/indi-3rdparty/libasi

Files: CMakeLists.txt
Copyright: 2019, Radek Kaczorek <[email protected]>
License: GPL-3
This package is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

This package is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this package; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

On Debian systems, the complete text of the GNU General
Public License can be found in `/usr/share/common-licenses/GPL-3'.

Files: *
Copyright: 2015, ZWO Company
License: All rights reserved
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

6 changes: 6 additions & 0 deletions debian/libasi/rules
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/make -f

include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/cmake.mk

DEB_SRCDIR=libasi
1 change: 1 addition & 0 deletions debian/libasi/source/format
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.0 (quilt)
Empty file modified debian/libatik/rules
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion debian/libfishcamp/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ libfishcamp (1.1) precise; urgency=low

* MacOS support.

-- Jasem Mutlaq <[email protected]> Sat, 2 June 2015 18:00:00 +0300
-- Jasem Mutlaq <[email protected]> Sat, 2 Jun 2015 18:00:00 +0300

libfishcamp (1.0) precise; urgency=low

Expand Down
Empty file modified debian/libnncam/rules
100644 → 100755
Empty file.
Empty file modified debian/libqhy/rules
100644 → 100755
Empty file.
Empty file modified debian/libsbig/rules
100644 → 100755
Empty file.
Empty file modified debian/libstarshootg/rules
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion debian/libtoupcam/control
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Source: libstoupcam
Source: libtoupcam
Section: libs
Priority: extra
Maintainer: Jasem Mutlaq <[email protected]>
Expand Down
Empty file modified debian/libtoupcam/rules
100644 → 100755
Empty file.
58 changes: 10 additions & 48 deletions indi-asi/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,23 @@ LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake_modules/")
LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../cmake_modules/")
include(GNUInstallDirs)

find_package(ASI REQUIRED)
find_package(CFITSIO REQUIRED)
find_package(INDI REQUIRED)
find_package(ZLIB REQUIRED)
find_package(USB1 REQUIRED)
find_package(Threads REQUIRED)

# Using ASI Camera SDK Version 1.14.0715 updated on 2019-07-22
# Using ASI EFW SDK Version 0.3.1205 updated on 2017-12-05
# Using ASI ST4 SDK Version 1.0 updated on 2018-07-23
# Using ASI EAF SDK Version 0.1.0524 updated on 2019-06-20
set(ASI_VERSION_MAJOR 1)
set(ASI_VERSION_MINOR 3)
set(ASI_VERSION_MINOR 4)

configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h )
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/indi_asi.xml.cmake ${CMAKE_CURRENT_BINARY_DIR}/indi_asi.xml)

include_directories( ${CMAKE_CURRENT_BINARY_DIR})
include_directories( ${CMAKE_CURRENT_SOURCE_DIR})
include_directories( ${INDI_INCLUDE_DIR})
include_directories( ${ASI_INCLUDE_DIR})
include_directories( ${CFITSIO_INCLUDE_DIR})

include(CMakeCommon)
Expand All @@ -36,78 +34,42 @@ if (INDI_WEBSOCKET)
SET(HAVE_WEBSOCKET 1)
endif()

if (APPLE)
set(ASICAMLIB ${CMAKE_CURRENT_SOURCE_DIR}/mac/libASICamera2.bin)
set(ASIFWLIB ${CMAKE_CURRENT_SOURCE_DIR}/mac/libEFWFilter.bin)
set(ASIEAFLIB ${CMAKE_CURRENT_SOURCE_DIR}/mac/libEAFFocuser.bin)
set(ASIST4LIB ${CMAKE_CURRENT_SOURCE_DIR}/mac/libUSB2ST4Conv.bin)
message("-- Using Mac static ASI library")
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "armv+")
set(ASICAMLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv6/libASICamera2.bin)
set(ASIFWLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv6/libEFWFilter.bin)
set(ASIEAFLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv6/libEAFFocuser.bin)
set(ASIST4LIB ${CMAKE_CURRENT_SOURCE_DIR}/armv6/libUSB2ST4Conv.bin)
add_definitions(-DLOW_USB_BANDWIDTH)
message("-- Using armv6 static ASI library")
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
set(ASICAMLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv8/libASICamera2.bin)
set(ASIFWLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv8/libEFWFilter.bin)
set(ASIEAFLIB ${CMAKE_CURRENT_SOURCE_DIR}/armv8/libEAFFocuser.bin)
set(ASIST4LIB ${CMAKE_CURRENT_SOURCE_DIR}/armv8/libUSB2ST4Conv.bin)
add_definitions(-DLOW_USB_BANDWIDTH)
message("-- Using armv8 static ASI library")
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
set(ASICAMLIB ${CMAKE_CURRENT_SOURCE_DIR}/x64/libASICamera2.bin)
set(ASIFWLIB ${CMAKE_CURRENT_SOURCE_DIR}/x64/libEFWFilter.bin)
set(ASIEAFLIB ${CMAKE_CURRENT_SOURCE_DIR}/x64/libEAFFocuser.bin)
set(ASIST4LIB ${CMAKE_CURRENT_SOURCE_DIR}/x64/libUSB2ST4Conv.bin)
message("-- Using 64 bit static ASI library")
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "i[3-6]86")
set(ASICAMLIB ${CMAKE_CURRENT_SOURCE_DIR}/x86/libASICamera2.bin)
set(ASIFWLIB ${CMAKE_CURRENT_SOURCE_DIR}/x86/libEFWFilter.bin)
set(ASIEAFLIB ${CMAKE_CURRENT_SOURCE_DIR}/x86/libEAFFocuser.bin)
set(ASIST4LIB ${CMAKE_CURRENT_SOURCE_DIR}/x86/libUSB2ST4Conv.bin)
message("-- Using 32 bit static ASI library")
endif ()

########### indi_asi_ccd ###########
set(indi_asi_SRCS
${CMAKE_CURRENT_SOURCE_DIR}/asi_ccd.cpp
)

add_executable(indi_asi_ccd ${indi_asi_SRCS})
target_link_libraries(indi_asi_ccd ${INDI_LIBRARIES} ${CFITSIO_LIBRARIES} ${ASICAMLIB} ${USB1_LIBRARIES} ${ZLIB_LIBRARY} ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(indi_asi_ccd ${INDI_LIBRARIES} ${CFITSIO_LIBRARIES} ${ASI_LIBRARIES} ${USB1_LIBRARIES} ${ZLIB_LIBRARY} ${CMAKE_THREAD_LIBS_INIT})
if (HAVE_WEBSOCKET)
target_link_libraries(indi_asi_ccd ${Boost_LIBRARIES})
endif()



########### indi_asi_wheel ###########
add_executable(indi_asi_wheel ${CMAKE_CURRENT_SOURCE_DIR}/asi_wheel.cpp)
IF (APPLE)
set(CMAKE_EXE_LINKER_FLAGS "-framework IOKit -framework CoreFoundation")
target_link_libraries(indi_asi_wheel ${INDI_LIBRARIES} ${ASIFWLIB} ${LIBUSB_LIBRARIES})
target_link_libraries(indi_asi_wheel ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${LIBUSB_LIBRARIES})
ELSE()
target_link_libraries(indi_asi_wheel ${INDI_LIBRARIES} ${ASIFWLIB} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(indi_asi_wheel ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
ENDIF()

########### indi_asi_st4 ###########
add_executable(indi_asi_st4 ${CMAKE_CURRENT_SOURCE_DIR}/asi_st4.cpp)
IF (APPLE)
set(CMAKE_EXE_LINKER_FLAGS "-framework IOKit -framework CoreFoundation")
target_link_libraries(indi_asi_st4 ${INDI_LIBRARIES} ${ASIST4LIB} ${LIBUSB_LIBRARIES})
target_link_libraries(indi_asi_st4 ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${LIBUSB_LIBRARIES})
ELSE()
target_link_libraries(indi_asi_st4 ${INDI_LIBRARIES} ${ASIST4LIB} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(indi_asi_st4 ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
ENDIF()

########### indi_asi_focuser ###########
add_executable(indi_asi_focuser ${CMAKE_CURRENT_SOURCE_DIR}/asi_focuser.cpp)
IF (APPLE)
set(CMAKE_EXE_LINKER_FLAGS "-framework IOKit -framework CoreFoundation")
target_link_libraries(indi_asi_focuser ${INDI_LIBRARIES} ${ASIEAFLIB} ${LIBUSB_LIBRARIES})
target_link_libraries(indi_asi_focuser ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${LIBUSB_LIBRARIES})
ELSE()
target_link_libraries(indi_asi_focuser ${INDI_LIBRARIES} ${ASIEAFLIB} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(indi_asi_focuser ${INDI_LIBRARIES} ${ASI_LIBRARIES} ${USB1_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
ENDIF()

#####################################
Expand Down
2 changes: 1 addition & 1 deletion indi-asi/asi_ccd.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

#pragma once

#include "ASICamera2.h"
#include <ASICamera2.h>

#include <condition_variable>
#include <mutex>
Expand Down
2 changes: 1 addition & 1 deletion indi-asi/asi_focuser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
*/

#include "asi_focuser.h"
#include "EAF_focuser.h"

#include "indicom.h"

#include <cmath>
Expand Down
2 changes: 2 additions & 0 deletions indi-asi/asi_focuser.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@

#pragma once

#include <EAF_focuser.h>

#include "indifocuser.h"

#include <chrono>
Expand Down
2 changes: 1 addition & 1 deletion indi-asi/asi_st4.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

#pragma once

#include "USB2ST4_Conv.h"
#include <USB2ST4_Conv.h>

#include <defaultdevice.h>
#include <indiguiderinterface.h>
Expand Down
2 changes: 1 addition & 1 deletion indi-asi/asi_wheel.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

#pragma once

#include "EFW_filter.h"
#include <EFW_filter.h>

#include <indifilterwheel.h>

Expand Down
Empty file modified indi-webcam/CMakeLists.txt
100755 → 100644
Empty file.
Empty file modified indi-webcam/config.h.cmake
100755 → 100644
Empty file.
Empty file modified indi-webcam/indi_webcam.cpp
100755 → 100644
Empty file.
Empty file modified indi-webcam/indi_webcam.h
100755 → 100644
Empty file.
Empty file modified indi-webcam/indi_webcam.xml.cmake
100755 → 100644
Empty file.
3 changes: 3 additions & 0 deletions libasi/99-asi.rules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ACTION=="add", ATTR{idVendor}=="03c3", RUN+="/bin/sh -c '/bin/echo 256 >/sys/module/usbcore/parameters/usbfs_memory_mb'"
# All ASI Cameras and filter wheels
SUBSYSTEMS=="usb", ATTR{idVendor}=="03c3", MODE="0666"
File renamed without changes.
Loading