Commit 2693ef5c authored by Alejandro Homs Puron's avatar Alejandro Homs Puron Committed by operator for beamline
Browse files

Merge branch 'doc' into 'master' - Closes #1: Update documentation

parents 39e096ec 4e36ed31
[submodule "slsDetectorPackage"]
path = slsDetectorPackage
url = git@github.com:esrf-bliss/slsDetectorPackage.git
url = git://github.com/esrf-bliss/slsDetectorPackage.git
......@@ -21,16 +21,15 @@
# You should have received a copy of the GNU General Public License
# along with this program; if not, see <http://www.gnu.org/licenses/>.
############################################################################
set(NAME "slsdetector")
set(NAME slsdetector)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-error=format-security")
set(SLS_DETECTORS_DIR "${CMAKE_CURRENT_SOURCE_DIR}/slsDetectorPackage")
set(SLS_DETECTORS_BIN "${SLS_DETECTORS_DIR}/bin")
set(SLS_DETECTORS_SW "${SLS_DETECTORS_DIR}/slsDetectorSoftware")
set(SLS_DETECTORS_RECV "${SLS_DETECTORS_DIR}/slsReceiverSoftware")
set(SLS_DETECTOR_DIR slsDetectorPackage)
set(SLS_DETECTOR_SW ${SLS_DETECTOR_DIR}/slsDetectorSoftware)
set(SLS_DETECTOR_RECV ${SLS_DETECTOR_DIR}/slsReceiverSoftware)
link_directories(${SLS_DETECTORS_BIN})
add_subdirectory(${SLS_DETECTOR_DIR})
set(${NAME}_srcs src/SlsDetectorDefs.cpp src/SlsDetectorArgs.cpp
src/SlsDetectorCPUAffinity.cpp src/SlsDetectorModel.cpp
......@@ -40,29 +39,27 @@ set(${NAME}_srcs src/SlsDetectorDefs.cpp src/SlsDetectorArgs.cpp
add_library(lima${NAME} SHARED ${${NAME}_srcs})
target_include_directories(lima${NAME} PUBLIC
"${CMAKE_CURRENT_SOURCE_DIR}/include")
include
${SLS_DETECTOR_SW}/include
${SLS_DETECTOR_SW}/commonFiles
${SLS_DETECTOR_SW}/slsDetector
${SLS_DETECTOR_SW}/multiSlsDetector
${SLS_DETECTOR_SW}/slsDetectorServer
${SLS_DETECTOR_SW}/slsDetectorAnalysis
${SLS_DETECTOR_SW}/slsReceiverInterface
${SLS_DETECTOR_RECV}/include)
target_include_directories(lima${NAME} PUBLIC
"${SLS_DETECTORS_SW}/include"
"${SLS_DETECTORS_SW}/commonFiles"
"${SLS_DETECTORS_SW}/slsDetector"
"${SLS_DETECTORS_SW}/multiSlsDetector"
"${SLS_DETECTORS_SW}/slsDetectorServer"
"${SLS_DETECTORS_SW}/slsDetectorAnalysis"
"${SLS_DETECTORS_SW}/slsReceiverInterface"
"${SLS_DETECTORS_RECV}/include")
target_link_libraries(lima${NAME} limacore)
target_link_libraries(lima${NAME} SlsDetector)
target_link_libraries(lima${NAME} SlsReceiver)
target_link_libraries(lima${NAME}
limacore
slsDetectorShared slsReceiverShared zmq)
limatools_set_library_soversion(lima${NAME} "VERSION")
limatools_set_library_soversion(lima${NAME} VERSION)
install(TARGETS lima${NAME} LIBRARY DESTINATION lib)
if(LIMA_ENABLE_PYTHON)
limatools_run_sip_for_camera(${NAME})
install(FILES python/__init__.py DESTINATION
"${PYTHON_SITE_PACKAGES_DIR}/Lima/SlsDetector")
${PYTHON_SITE_PACKAGES_DIR}/Lima/SlsDetector)
endif()
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})
......
.. _camera-slsdetector:
SlsDetector camera
--------------
------------------
.. image:: PSI-Eiger-500k.jpg
Introduction
````````````
The PSI/SLS Detector Group has developed a family of X-ray detectors: Mythen, Pilatus, Gotthard,
Eiger, Moench, Jungrau, among others. Most of them are controlled through Ethernet interfaces,
with optional dedicated data link(s). A common protocol has been developed to control these detectors,
based on the *slsDetector* class. A separate software entity receives and dispatch the data: *slsReceiver*.
The SlsDetector LIMA plugin instantiates the necessary software objects to perform data aquisitions
The PSI/SLS Detector Group has developed a family of X-ray detectors: Mythen, Pilatus, Gotthard,
Eiger, Moench, Jungrau, among others. Most of them are controlled through Ethernet interfaces,
with optional dedicated data link(s). A common protocol has been developed to control these detectors,
based on the *slsDetector* class. A separate software entity receives and dispatch the data: *slsReceiver*.
The SlsDetector LIMA plugin instantiates the necessary software objects to perform data aquisitions
with the detectors supported by the slsDetectorsPackage.
The current implementation only works with the PSI/Eiger detectors.
Prerequisite
````````````
The slsDetectorsPackage-v2.3.x is needed by the SlsDetector LIMA plugin. In the compilation phase,
the SLS_DETECTORS_DIR environment variable must point to the directory where the previous package
is extracted; header files and shared libraries are used during compilation and linkage. In particular,
the *libSlsDetector.so* and *libSlsReceiver.so* shared libraries must be reachable both by the compiler
and from the *LD_LIBRARY_PATH* during execution time, in order to run the SlsDetector plugin.
The *slsDetectorPackage-v2.3.x* is needed by the SlsDetector LIMA plugin. As explained in
:doc:`installation`, the *slsDetectorPackage* is included as a submodule in the SlsDetector camera
plugin. It will be automatically compiled and installed during the LIMA build procedure.
In addition to that, a *configuration file*, containing the commands necessary to initialise both
the *slsDetector" and *slsReceiver* instances, is required.
In addition to that, a *configuration file*, containing the commands necessary to initialise both
the *slsDetector" and *slsReceiver* instances, is required.
The library protocol uses Unix System-V IPC shared memory blocks to exchange information between processes.
The segments, referred to by keys matching hex *000016xx*, must be owned by the user running the plugin,
if it is not *root*. The following command, which removes the existing segments, must be run by the segments' owner (or *root*) so they
can be deleted/created by another user:
The library protocol uses Unix System-V IPC shared memory blocks to exchange information between processes.
The segments, referred to by keys matching hex *000016xx*, must be owned by the user running the plugin,
if it is not *root*. The following command, which removes the existing segments, must be run by the
segments' owner (or *root*) so they can be deleted/created by another user:
.. code-block:: sh
......@@ -43,81 +41,22 @@ can be deleted/created by another user:
High-performance Acquisitions
.............................
Some Linux configuration is needed for high-performance data acquisition. Please refer to the
(ESRF on-site only) following documentation:
http://wikiserv.esrf.fr/id01/index.php/NOTES_on_ID01_PSI_EIGER
High-performance acquisitions require a specific backend computer setup.
Please refer to the :doc:`installation`.
Installation & Module configuration
````````````````````````````````````
```````````````````````````````````
- follow first the steps for the linux installation :ref:`linux_installation`
- Follow the steps indicated in :doc:`installation`
The minimum configuration file is *config.inc* :
As a reference, see:
.. code-block:: sh
- :ref:`linux_installation`
- :ref:`linux_compilation`
- :ref:`tango_installation`
COMPILE_CORE=1
COMPILE_SIMULATOR=0
COMPILE_SPS_IMAGE=1
COMPILE_ESPIA=0
COMPILE_FRELON=0
COMPILE_MAXIPIX=0
COMPILE_PILATUS=0
COMPILE_BASLER=0
COMPILE_PROSILICA=0
COMPILE_ROPERSCIENTIFIC=0
COMPILE_MYTHEN=0
COMPILE_MYTHEN3=0
COMPILE_ADSC=0
COMPILE_UEYE=0
COMPILE_XH=0
COMPILE_XSPRESS3=0
COMPILE_ULTRA=0
COMPILE_XPAD=0
COMPILE_PERKINELMER=0
COMPILE_ANDOR=0
COMPILE_ANDOR3=0
COMPILE_PHOTONICSCIENCE=0
COMPILE_PCO=0
COMPILE_MARCCD=0
COMPILE_POINTGREY=0
COMPILE_IMXPAD=0
COMPILE_DEXELA=0
COMPILE_RAYONIXHS=0
COMPILE_AVIEX=0
COMPILE_META=0
COMPILE_MERLIN=0
COMPILE_V4l2=0
COMPILE_EIGER=0
COMPILE_PIXIRAD=0
COMPILE_HEXITEC=0
COMPILE_SLSDETECTOR=1
COMPILE_CBF_SAVING=0
COMPILE_NXS_SAVING=0
COMPILE_FITS_SAVING=0
COMPILE_EDFGZ_SAVING=1
COMPILE_EDFLZ4_SAVING=0
COMPILE_TIFF_SAVING=0
COMPILE_HDF5_SAVING=0
COMPILE_CONFIG=1
COMPILE_GLDISPLAY=0
LINK_STRICT_VERSION=0
export COMPILE_CORE COMPILE_SPS_IMAGE COMPILE_SIMULATOR \
COMPILE_ESPIA COMPILE_FRELON COMPILE_MAXIPIX COMPILE_PILATUS \
COMPILE_BASLER COMPILE_PROSILICA COMPILE_ROPERSCIENTIFIC COMPILE_ADSC \
COMPILE_UEYE COMPILE_XH COMPILE_XSPRESS3 COMPILE_ULTRA COMPILE_XPAD COMPILE_PERKINELMER \
COMPILE_MYTHEN COMPILE_MYTHEN3 COMPILE_HEXITEC \
COMPILE_ANDOR COMPILE_ANDOR3 COMPILE_PHOTONICSCIENCE COMPILE_PCO COMPILE_MARCCD COMPILE_DEXELA \
COMPILE_POINTGREY COMPILE_IMXPAD COMPILE_RAYONIXHS COMPILE_AVIEX COMPILE_META COMPILE_MERLIN COMPILE_V4l2 COMPILE_EIGER COMPILE_PIXIRAD \
COMPILE_SLSDETECTOR \
COMPILE_CBF_SAVING COMPILE_NXS_SAVING COMPILE_FITS_SAVING COMPILE_EDFGZ_SAVING COMPILE_EDFLZ4_SAVING COMPILE_TIFF_SAVING \
COMPILE_HDF5_SAVING COMPILE_CONFIG COMPILE_GLDISPLAY \
LINK_STRICT_VERSION
- start the linux compilation :ref:`linux_compilation`
- finally with the Tango server installation :ref:`tango_installation`
Initialisation and Capabilities
````````````````````````````````
......@@ -126,8 +65,8 @@ provides some important information about the developer's choices.
Camera initialisation
......................
The SlsDetector plugin exports to kind classes: one generic *SlsDetector::Camera* class, with the common
interface to *slsDetector* and *slsReceiver* classes, and detector-specific classes, like *SlsDetector::Eiger*
The SlsDetector plugin exports two kind classes: one generic *SlsDetector::Camera* class, with the common
interface to *slsDetector* and *slsReceiver* classes, and detector-specific classes, like *SlsDetector::Eiger*
which manage the particularities of each model.
First, the *SlsDetector::Camera* must be instantiated with the configuration file, and once the connection to
......@@ -144,8 +83,8 @@ the detector is established, a specific class is created depending on the detect
hw_inter = SlsDetector.Interface(cam)
ct = Core.CtControl(hw_inter)
The raw images returned by the *slsReceiver* class might need to be reconstructed, like in the case of
the PSI/Eiger detector. A LImA software reconstruction task must be then created from the LImA plugin and registered
The raw images returned by the *slsReceiver* class might need to be reconstructed, like in the case of
the PSI/Eiger detector. A LImA software reconstruction task must be then created from the LImA plugin and registered
to the *Core::CtControl* layer:
if cam.getType() == SlsDetector.Camera.EigerDet:
......@@ -155,13 +94,13 @@ to the *Core::CtControl* layer:
Std capabilites
................
This plugin has been implemented in respect of the mandatory capabilites but with limitations according
due to the detector specific features and with some programmer's choices. We do not explain here the
This plugin has been implemented in respect of the mandatory capabilites but with limitations according
due to the detector specific features and with some programmer's choices. We do not explain here the
standard Lima capabilites but you can find in this section the useful information on the SlsDetector specfic features.
* HwDetInfo
TODO
TODO
* HwSync
......@@ -178,20 +117,20 @@ and the *ReadoutFlags* (Parallel, Non-Parallel).
Optional capabilites
........................
In addition to the standard capabilities, we make the choice to implement some optional capabilities in order to
In addition to the standard capabilities, we make the choice to implement some optional capabilities in order to
have an improved simulation.
* HwShutter
*Not implemented*
*Not implemented*
* HwRoi
*Not implemented*
*Not implemented*
* HwBin
* HwBin
*Not implemented*
*Not implemented*
Configuration
`````````````
......@@ -253,8 +192,8 @@ For a quick test one can use Python, this a short code example to work with the
# now ask for 0.2 sec. exposure and 10 frames
acq.setAcqExpoTime(0.2)
acq.setAcqNbFrames(10)
acq.setAcqNbFrames(10)
ct.prepareAcq()
ct.startAcq()
......@@ -263,7 +202,7 @@ For a quick test one can use Python, this a short code example to work with the
while lastimg != 9:
time.sleep(0.1)
lastimg = ct.getStatus().ImageCounters.LastImageReady
# read the first image
im0 = ct.ReadImage(0)
......@@ -277,4 +216,3 @@ For a quick test one can use Python, this a short code example to work with the
del cam; gc.collect()
A more complete **test_slsdetector_control.py** Python script can be found under the *camera/slsdetector/test* directory.
This diff is collapsed.
Subproject commit 130f319061561e8f7e1c465352e5d745d31846cd
Subproject commit 572aabdbd9c4c7dbca7d3a9e800f1338a454244b
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment