diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index ee5446272..107e1c436 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -17,7 +17,7 @@ jobs: - uses: actions/checkout@v3 - uses: awalsh128/cache-apt-pkgs-action@latest with: - packages: libzmq3-dev libhdf5-dev qtbase5-dev qt5-qmake libqt5svg5-dev + packages: libhdf5-dev qtbase5-dev qt5-qmake libqt5svg5-dev version: 1.0 - name: Configure CMake diff --git a/CMakeFiles/cmake.check_cache b/CMakeFiles/cmake.check_cache new file mode 100644 index 000000000..3dccd7317 --- /dev/null +++ b/CMakeFiles/cmake.check_cache @@ -0,0 +1 @@ +# This file is generated by cmake for dependency checking of the CMakeCache.txt file diff --git a/CMakeLists.txt b/CMakeLists.txt index 132ac8d65..60ac7bde0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,7 +33,7 @@ else() # Standard behaviour use libzmq included in this repo (libs/libzmq) FetchContent_Declare( libzmq - URL ${CMAKE_SOURCE_DIR}/libs/libzmq/libzmq-4.3.4.tar.gz + URL ${CMAKE_CURRENT_SOURCE_DIR}/libs/libzmq/libzmq-4.3.4.tar.gz URL_HASH MD5=cc20b769ac10afa352e5ed2769bb23b3 ) endif() @@ -244,6 +244,7 @@ if(SLS_USE_SANITIZER) # target_link_libraries(slsProjectOptions INTERFACE -fsanitize=thread) endif() + if(SLS_TUNE_LOCAL) target_compile_options(slsProjectOptions INTERFACE -mtune=native -march=native) endif() diff --git a/bash_autocomplete.sh b/bash_autocomplete.sh new file mode 120000 index 000000000..f79749d0d --- /dev/null +++ b/bash_autocomplete.sh @@ -0,0 +1 @@ +slsDetectorSoftware/generator/autocomplete/bash_autocomplete.sh \ No newline at end of file diff --git a/cmk.sh b/cmk.sh index 29f28f2d5..dd58a37e1 100755 --- a/cmk.sh +++ b/cmk.sh @@ -26,7 +26,7 @@ CMAKE_PRE="" CMAKE_POST="" usage() { echo -e " -Usage: $0 [-b] [-c] [-d ] [e] [g] [-h] [i] [-j ] [-k ] [-l ] [m] [n] [-p] [r] [s] [t] [u] [z] +Usage: $0 [-b] [-c] [-d ] [-e] [-g] [-h] [-i] [-j ] [-k ] [-l ] [-m] [-n] [-p] [-r] [-s] [-t] [-u] [-z] -[no option]: only make -b: Builds/Rebuilds CMake files normal mode -c: Clean diff --git a/conda-recepie/conda_build_config.yaml b/conda-recepie/conda_build_config.yaml index b49d8ca09..b1396f187 100644 --- a/conda-recepie/conda_build_config.yaml +++ b/conda-recepie/conda_build_config.yaml @@ -2,7 +2,6 @@ python: - 3.8 - 3.9 - 3.10 - - 3.11 + - 3.11 + - 3.12 -numpy: - - 1.17 diff --git a/conda-recepie/meta.yaml b/conda-recepie/meta.yaml index a06d2c4be..da620c859 100755 --- a/conda-recepie/meta.yaml +++ b/conda-recepie/meta.yaml @@ -18,7 +18,6 @@ requirements: - {{compiler('cxx')}} - cmake - qt 5.* - - zeromq - xorg-libx11 - xorg-libice - xorg-libxext @@ -37,7 +36,6 @@ requirements: host: - libstdcxx-ng - libgcc-ng - - zeromq - xorg-libx11 - xorg-libice - xorg-libxext @@ -48,7 +46,6 @@ requirements: - expat run: - - zeromq - libstdcxx-ng - libgcc-ng @@ -63,15 +60,11 @@ outputs: - {{compiler('cxx')}} - libstdcxx-ng - libgcc-ng - - zeromq - host: - - zeromq run: - libstdcxx-ng - libgcc-ng - - zeromq - name: slsdet @@ -84,10 +77,12 @@ outputs: - {{compiler('cxx')}} - {{ pin_subpackage('slsdetlib', exact=True) }} - setuptools + - pybind11=2.11 host: - python - {{ pin_subpackage('slsdetlib', exact=True) }} + - pybind11=2.11 run: diff --git a/docs/src/consuming.rst b/docs/src/consuming.rst index b66a01b23..02d23608c 100644 --- a/docs/src/consuming.rst +++ b/docs/src/consuming.rst @@ -19,7 +19,7 @@ A minimal CMakeLists.txt could look like this: .. code-block:: cmake project(myDetectorIntegration) - cmake_minimum_required(VERSION 3.12) + cmake_minimum_required(VERSION 3.14) add_subdirectory(slsDetectorPackage) #Add your executable @@ -43,7 +43,7 @@ should be needed, otherwise specify cmake prefix path. .. code-block:: cmake - cmake_minimum_required(VERSION 3.12) + cmake_minimum_required(VERSION 3.14) project(myintegration) find_package(slsDetectorPackage 5.0 REQUIRED) diff --git a/docs/src/dependencies.rst b/docs/src/dependencies.rst index 7940809fc..846fc0ff1 100644 --- a/docs/src/dependencies.rst +++ b/docs/src/dependencies.rst @@ -13,24 +13,36 @@ To use the basic building blocks, meaning sls_detector_get/put and the shared libraries these are needed: * Linux, preferably recent kernel (currently no cross platform support) - * CMake > 3.12 + * CMake >= 3.14 * C++11 compatible compiler. (We test with gcc and clang) - * ZeroMQ version 4 - ------------------------ -GUI ------------------------ - - * Qt 5.9 - * Qwt 6.1.5 (packaged in libs/) ----------------------- Python bindings ----------------------- * Python > 3.6 - * pybind11 (packaged in libs/) + * pybind11 2.11.0 (packaged in libs) +.. note :: + + Refer :ref:`pybind11 notes. ` + +----------------------- +ZeroMQ +----------------------- + + * Zeromq 4.3.4 (packaged in libs) + +.. note :: + + Refer :ref:`zeromq notes. ` + +----------------------- +GUI +----------------------- + + * Qt 5.9 + * Qwt 6.1.5 (packaged in libs) ----------------------- Moench executables @@ -54,4 +66,6 @@ Packaged in libs/ * catch2 (unit testing) * rapidjson (streaming from receiver) - * pybind11 (python bindings) \ No newline at end of file + * pybind11 (python bindings) + * qwt (gui plotting) + * libzmq (streaming to/from receiver) \ No newline at end of file diff --git a/docs/src/detector.rst b/docs/src/detector.rst index a78447f99..9c8ec8be2 100644 --- a/docs/src/detector.rst +++ b/docs/src/detector.rst @@ -1,16 +1,19 @@ Detector ============================================== -The sls::Detector is the new public API to control +The sls::Detector is the public API to control detectors from C++. This API is also used internally for the Python bindings and the command line interface. -If a receiver has been configured this is also controlled +If a receiver has been configured, this is also controlled through this class. Most, if not all, functions are called in parallel and the return value is a thin std::vector wrapper -containing results from all modules. (Result) +containing results from all modules. (:ref:`Result class`) +Here are some :ref:`examples ` on how to use the API. + +.. _Cplusplus Api Examples: .. doxygenclass:: sls::Detector :members: :undoc-members: \ No newline at end of file diff --git a/docs/src/examples.rst b/docs/src/examples.rst index d22f3bc6d..65d734c8e 100644 --- a/docs/src/examples.rst +++ b/docs/src/examples.rst @@ -1,3 +1,4 @@ +.. _Cplusplus Api Examples: @@ -53,8 +54,8 @@ then set up the detector. jungfrauDetectorServer_virtual -This launches a virtual Jungfrau detector server. As default is uses port 1952 and 1953 -for communication over TCP. Most commands go on 1952 and only stop and status on 1953. +This launches a virtual Jungfrau detector server. As default it uses port 1952 and 1953 +for communication over TCP. Most commands go on 1952 and only a few such as stop and status on 1953. **Run example to configure** @@ -90,7 +91,10 @@ std::vector. sls::Result res1{1, 1, 1}; std::cout << "res1: " << res1 << '\n'; res1.squash(); + # return -1 if different res1.squash(-1); + # throw exception with custom message if different + res1.tsquash("Values are different); diff --git a/docs/src/firmware.rst b/docs/src/firmware.rst index ab97380ff..a372ecb04 100644 --- a/docs/src/firmware.rst +++ b/docs/src/firmware.rst @@ -120,7 +120,7 @@ Program from console # removes old server from respawn, sets up new lnked server to respawn # programs fpga, reboots - # v5.0.0 - 6.0.0 (copies server from tftp folder of the pc) + # older versions: v5.0.0 - 6.0.0 using tftp from tftp folder of pc sls_detector_put update jungfrauDetectorServervxxx pcxxx xx.pof # v6.1.1 - present (copies server from the full path provided) @@ -190,7 +190,7 @@ Program from console # removes old server from respawn, sets up new lnked server to respawn # programs fpga, reboots - # v5.0.0 - 6.0.0 (copies server from tftp folder of the pc) + # older versions: v5.0.0 - 6.0.0 using tftp from tftp folder of pc sls_detector_put update mythen3DetectorServervxxx pcxxx xxx.rbf # v6.1.1 - present (copies server from the full path provided) @@ -224,7 +224,7 @@ Program from console # removes old server from respawn, sets up new lnked server to respawn # programs fpga, reboots - # v5.0.0 - 6.0.0 (copies server from tftp folder of the pc) + # older versions: v5.0.0 - 6.0.0 using tftp from tftp folder of pc sls_detector_put update gotthard2DetectorServervxxx pcxxx xxx.rbf # v6.1.1 - present (copies server from the full path provided) @@ -275,7 +275,7 @@ Program from console # removes old server from respawn, sets up new lnked server to respawn # programs fpga, reboots - # v5.0.0 - 6.0.0 (copies server from tftp folder of the pc) + # older versions: v5.0.0 - 6.0.0 using tftp from tftp folder of pc sls_detector_put update moenchDetectorServervxxx pcxxx xx.pof # v6.1.1 - present (copies server from the full path provided) @@ -310,7 +310,7 @@ Program from console # removes old server from respawn, sets up new lnked server to respawn # programs fpga, reboots - # v5.0.0 - 6.0.0 (copies server from tftp folder of the pc) + # older versions: v5.0.0 - 6.0.0 using tftp from tftp folder of pc sls_detector_put update ctbDetectorServervxxx pcxxx xx.pof # v6.1.1 - present (copies server from the full path provided) diff --git a/docs/src/index.rst b/docs/src/index.rst index d19592e4d..1bdca9dd1 100644 --- a/docs/src/index.rst +++ b/docs/src/index.rst @@ -8,8 +8,8 @@ Welcome to slsDetectorPackage's documentation! .. note :: - This is the documentation for the latest development version of slsDetectorPackage - For documentation on current and previous releases visit the official page: https://www.psi.ch/en/detectors/documentation + This is the documentation for the latest development version of slsDetectorPackage. + For further documentation, visit the official page: https://www.psi.ch/en/detectors/documentation .. toctree:: :maxdepth: 1 diff --git a/docs/src/installation.rst b/docs/src/installation.rst index 1a2003192..c8717851f 100644 --- a/docs/src/installation.rst +++ b/docs/src/installation.rst @@ -57,7 +57,6 @@ We have three different packages available: Build from source ------------------- - 1. Download Source Code from github ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -65,23 +64,9 @@ Build from source git clone https://github.com/slsdetectorgroup/slsDetectorPackage.git --branch 6.1.1 +.. note :: -| **Pybind for Python** -| v7.0.0+: -| pybind11 packaged into 'libs/pybind'. No longer a submodule. No need for "recursive" or "submodule update". -| -| Older versions: -| pybind11 is a submodule. Must be cloned using "recursive" and updated when switching between versions using the following commands. - -.. code-block:: bash - - # clone using recursive to get pybind11 submodule - git clone --recursive https://github.com/slsdetectorgroup/slsDetectorPackage.git - - # update submodule when switching between releases - cd slsDetectorPackage - git submodule update --init - + For v6.x.x of slsDetectorPackage and older, refer :ref:`pybind11 notes on cloning. ` .. _build from source using cmake: @@ -118,20 +103,23 @@ Instead of the cmake command, one can use ccmake to get a list of options to con ccmake .. # choose the options - # first press [c] - configure + # first press [c] - configure (maybe multiple times till you see [g]) # then press [g] - generate - -=============================== =========================================== +=============================== =============================== Example cmake options Comment -=============================== =========================================== +=============================== =============================== -DSLS_USE_PYTHON=ON Python --DPython_FIND_VIRTUALENV=ONLY Python from only the conda environment --DZeroMQ_HINT=/usr/lib64 Use system zmq instead +-DPython_FIND_VIRTUALENV=ONLY Python from the conda env -DSLS_USE_GUI=ON GUI -=============================== =========================================== +-DSLS_USE_HDF5=ON HDF5 +-DSLS_USE_SIMULATOR=ON Simulator +=============================== =============================== +.. note :: + + For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for cmake option to hint library location. ` Build using in-built cmk.sh script @@ -142,9 +130,9 @@ Build using in-built cmk.sh script The binaries are generated in slsDetectorPackage/build/bin directory. - Usage: ./cmk.sh [-b] [-c] [-d ] [e] [g] [-h] [i] [-j ] - [-k ] [-l ] [m] [n] [-p] [-q ] - [r] [s] [t] [u] [z] + Usage: $0 [-b] [-c] [-d ] [-e] [-g] [-h] [-i] + [-j ] [-k ] [-l ] + [-m] [-n] [-p] [-r] [-s] [-t] [-u] [-z] -[no option]: only make -b: Builds/Rebuilds CMake files normal mode -c: Clean @@ -159,7 +147,6 @@ Build using in-built cmk.sh script -m: Manuals -n: Manuals without compiling doxygen (only rst) -p: Builds/Rebuilds Python API - -q: Zmq hint directory -r: Build/Rebuilds only receiver -s: Simulator -t: Build/Rebuilds only text client @@ -176,9 +163,13 @@ Build using in-built cmk.sh script # new build, python and compile in parallel: ./cmk.sh -cbpj5 - #To use the system zmq (/usr/lib64) instead - ./cmk.sh -cbj5 -q /usr/lib64 + #For rebuilding only certain sections + ./cmk.sh -tg #only text client and gui + ./cmk.sh -r #only receiver +.. note :: + + For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for cmk script option to hint library location. ` Build on old distributions @@ -191,7 +182,7 @@ using this compiler .. code-block:: bash #Create an environment with the dependencies - conda create -n myenv gxx_linux-64 cmake zmq + conda create -n myenv gxx_linux-64 cmake conda activate myenv # outside slsDetecorPackage folder @@ -200,6 +191,11 @@ using this compiler make -j12 +.. note :: + + For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for dependencies for conda. ` + + Build slsDetectorGui (Qt5) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -228,9 +224,9 @@ Build slsDetectorGui (Qt5) # create environment to compile # on rhel7 - conda create -n slsgui zeromq gxx_linux-64 gxx_linux-64 mesa-libgl-devel-cos6-x86_64 qt + conda create -n slsgui gxx_linux-64 gxx_linux-64 mesa-libgl-devel-cos6-x86_64 qt # on fedora or newer systems - conda create -n slsgui zeromq qt + conda create -n slsgui qt # when using conda compilers, would also need libgl, but no need for it on fedora unless maybe using it with ROOT @@ -246,6 +242,9 @@ Build slsDetectorGui (Qt5) cd slsDetectorPackage ./cmk.sh -cbgj9 +.. note :: + + For v7.x.x of slsDetectorPackage and older, refer :ref:`zeromq notes for dependencies for conda. ` @@ -258,7 +257,7 @@ is to use conda .. code-block:: bash - conda create -n myenv python sphinx_rtd_theme breathe + conda create -n myenv python=3.12 sphinx sphinx_rtd_theme breathe doxygen numpy .. code-block:: bash @@ -270,3 +269,51 @@ is to use conda make docs # generate API docs and build Sphinx RST make rst # rst only, saves time in case the API did not change + + +Pybind and Zeromq +^^^^^^^^^^^^^^^^^^^ + +.. _pybind for different slsDetectorPackage versions: + + +| **Pybind for Python** +| v8.0.0+: +| pybind11 (v2.11.0) is built +| * by default from tar file in repo (libs/pybind/v2.11.0.tar.gz) +| * or use advanced option SLS_FETCH_PYBIND11_FROM_GITHUB [`link `__]. +| +| v7.x.x: +| pybind11 packaged into 'libs/pybind'. No longer a submodule. No need for "recursive" or "submodule update". +| +| Older versions: +| pybind11 is a submodule. Must be cloned using "recursive" and updated when switching between versions using the following commands. + +.. code-block:: bash + + # Note: Only for v6.x.x versions and older + + # clone using recursive to get pybind11 submodule + git clone --recursive https://github.com/slsdetectorgroup/slsDetectorPackage.git + + # update submodule when switching between releases + cd slsDetectorPackage + git submodule update --init + + +.. _zeromq for different slsDetectorPackage versions: + + + +| **Zeromq** +| v8.0.0+: +| zeromq (v4.3.4) is built +| * by default from tar file in repo (libs/libzmq/libzmq-4.3.4.tar.gz) +| * or use advanced option SLS_FETCH_ZMQ_FROM_GITHUB [`link `__]. +| +| v7.x.x and older: +| zeromq must be installed and one can hint its location using +| * cmake option:'-DZeroMQ_HINT=/usr/lib64' or +| * option '-q' in cmk.sh script: : ./cmk.sh -cbj5 -q /usr/lib64 +| * 'zeromq' dependency added when installing using conda + diff --git a/docs/src/quick_start_guide.rst b/docs/src/quick_start_guide.rst index 428d77989..9ccd28506 100644 --- a/docs/src/quick_start_guide.rst +++ b/docs/src/quick_start_guide.rst @@ -109,12 +109,14 @@ For Multiple Modules # connects to mulitple modules hostname bchipxxx+bchipyyy+ - # connects to receivers at ports 2012 and 2014 - rx_hostname mpc1922:2012+mpc1922:2013+ + # tcp port increases for each module (multi detector command) + rx_tcpport 2012 - # sets differernt destination udp ports - 0:udp_dstport 50012 - 1:udp_dstport 50014 + # connects to receivers at ports 2012 and 2014 + rx_hostname mpc1922 + + # increasing udp ports (multi detector command) + udp_dstport 50012 # source udp ips must be same subnet at destintaion udp ips 0:udp_srcip 192.168.1.112 diff --git a/docs/src/result.rst b/docs/src/result.rst index 1abd1b4a3..c1af431cd 100644 --- a/docs/src/result.rst +++ b/docs/src/result.rst @@ -1,3 +1,5 @@ +.. _Result Class: + Result ============================================== diff --git a/docs/src/slsreceiver.rst b/docs/src/slsreceiver.rst index 6e794a30c..0cccaf012 100644 --- a/docs/src/slsreceiver.rst +++ b/docs/src/slsreceiver.rst @@ -52,8 +52,13 @@ Client Commands # multi modules with custom ports rx_hostname xxx:1955+xxx:1956+ + + + # multi modules using increasing tcp ports when using multi detector command + rx_tcpport 1955 + rx_hostname xxx - # multi modules with custom ports on same rxr pc + # or specify multi modules with custom ports on same rxr pc 0:rx_tcpport 1954 1:rx_tcpport 1955 2:rx_tcpport 1956 diff --git a/docs/src/troubleshooting.rst b/docs/src/troubleshooting.rst index 164886f67..72a3814f8 100644 --- a/docs/src/troubleshooting.rst +++ b/docs/src/troubleshooting.rst @@ -92,6 +92,9 @@ Common sls_detector_put rx_arping 1 +#. Only the slaves get no data + * Check trigger cabling and trigger configuration + * When you cannot stop Jungfrau slaves in sync mode, refer to :ref:`Cannot stop slaves`. .. _Receiver PC Tuning: @@ -421,3 +424,20 @@ Cannot get multi module data * Comment out this line in the config file: powerchip 1 * Powering on the chip increases the power consumption by a considerable amount. If commenting out this line aids in getting data (strange data due to powered off chip), then it could be the power supply current limit. Fix it (possibly to 8A current limit) and uncomment the powerchip line back in config file. + + +.. _Jungfrau Troubleshooting Sync Slaves Cannot Stop: + +Cannot stop slaves in sync mode +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +#. If cabling is accessible, ensure termination board and flatband cable between the masters and the slaves are connnected properly. Then try to stop. +#. If cabling is inaccessible, unsync first so that the slaves can get the stop directly from the client using the command. Then, don't use sync mode until the cabling is fixed. + + .. code-block:: bash + + # unsync, slaves command will fail as it is still in waiting state + sls_detector_put sync 0 + + # stop should now be successful as master does not determine the stop anymore + sls_detector_put stop diff --git a/docs/src/virtualserver.rst b/docs/src/virtualserver.rst index 7a030347a..ae1073d8e 100644 --- a/docs/src/virtualserver.rst +++ b/docs/src/virtualserver.rst @@ -86,7 +86,8 @@ For a Single Module (With Options) udp_dstport 50012 # source udp ips must be same subnet at destintaion udp ips - udp_srcip 192.168.1.112 + # takes the same ip as hostname + udp_srcip auto # destination udp ip picked up from rx_hostname (if auto) udp_dstip auto @@ -101,12 +102,14 @@ For Multiple Modules virtual 2 1912 # or hostname localhost:1912+localhost:1914+ - # connects to receivers at ports 2012 and 2014 - rx_hostname mpc1922:2012+mpc1922:2013+ + # increasing receiver tcp ports (multi detector command) + rx_tcpport 2012 - # sets differernt destination udp ports - 0:udp_dstport 50012 - 1:udp_dstport 50014 + # connects to reciever at port 2012 and 2013 + rx_hostname mpc1922 + + # sets increasing destination udp ports + udp_dstport 50012 # source udp ips must be same subnet at destintaion udp ips 0:udp_srcip 192.168.1.112 diff --git a/examples/eiger_10Gb.config b/examples/eiger_10Gb.config index 30bb33213..97078974b 100755 --- a/examples/eiger_10Gb.config +++ b/examples/eiger_10Gb.config @@ -4,27 +4,33 @@ detsize 1024 512 # detector hostname for controls hostname beb059+beb058+ -# 1Gb receiver pc hostname with tcp port to configure receiver -rx_hostname x12sa-vcons:1991+x12sa-vcons:1992 +# increasing receiver tcp port (multi detector command) +rx_tcpport 1991 + +# 1Gb receiver pc hostname to configure receiver +rx_hostname x12sa-vcons + +# or 1Gb receiver pc hostname with tcp port to configure receiver +#rx_hostname x12sa-vcons:1991+x12sa-vcons:1992 + +# increasing udp destination ports for all half modules +udp_dstport 50011 # udp port first quadrant, first halfmodule -0:udp_dstport 50011 - +#0:udp_dstport 50011 # udp port second quadrant, first halfmodule -0:udp_dstport2 50012 - +#0:udp_dstport2 50012 +# udp port first quadrant, second halfmodule +#1:udp_dstport 50013 +# udp port second quadrant, second halfmodule +#1:udp_dstport2 50014 + # udp IP of the receiver over 10Gb 0:udp_dstip 10.0.30.210 # first half module 10 Gb IP (same subnet as 0:udp_dstip) 0:udp_srcip 10.0.30.100 -# udp port first quadrant, second halfmodule -1:udp_dstport 50013 - -# udp port second quadrant, second halfmodule -1:udp_dstport2 50014 - # udp IP of the receiver over 10Gb, 1:udp_dstip 10.0.40.210 diff --git a/examples/eiger_1Gb.config b/examples/eiger_1Gb.config index 936473f35..15322c94b 100755 --- a/examples/eiger_1Gb.config +++ b/examples/eiger_1Gb.config @@ -4,18 +4,23 @@ detsize 1024 512 # detector hostname for controls hostname beb059+beb058+ -# 1Gb receiver pc hostname with tcp port to configure receiver -rx_hostname x12sa-vcons:1991+x12sa-vcons:1992 +# increasing receiver tcp port (multi detector command) +rx_tcpport 1991 + +# 1Gb receiver pc hostname to configure receiver +rx_hostname x12sa-vcons + +# increasing udp destination ports for all half modules +udp_dstport 50011 # udp port first quadrant, first halfmodule -0:udp_dstport 50011 +#0:udp_dstport 50011 #udp port second quadrant, first halfmodule -0:udp_dstport2 50012 - +#0:udp_dstport2 50012 # udp port first quadrant, second halfmodule -1:udp_dstport 50013 +#1:udp_dstport 50013 # udp port second quadrant, second halfmodule -1:udp_dstport2 50014 +#1:udp_dstport2 50014 # output directory fpath /sls/X12SA/data/x12saop/Data10/Eiger0.5M diff --git a/examples/jungfrau_two.config b/examples/jungfrau_two.config index 4ee3f9d7f..2e6665f49 100755 --- a/examples/jungfrau_two.config +++ b/examples/jungfrau_two.config @@ -4,14 +4,18 @@ detsize 1024 1024 # detector hostname hostname bchip048+bchip052+ -# 1Gb receiver pc hostname (default tcpport: 1954) -rx_hostname pcmoench01:1954+pcmoench01:1955+ +# increasing receiver ports 1954 and 1955 (multi detector command) +rx_tcpport 1954 + +# 1Gb receiver pc hostname +rx_hostname pcmoench01 +# increasing udp ports 50004 and 50005 (multi detector command) +udp_dstport 50004 +# or custom udp destination port (receiver) for 1st module +#0:udp_dstport 50014 -# udp configurations for 1st module -# udp destination port (receiver) -0:udp_dstport 50004 # udp destination ip (receiver) 0:udp_dstip 10.1.1.100 @@ -19,17 +23,11 @@ rx_hostname pcmoench01:1954+pcmoench01:1955+ # udp source ip (same subnet as 0:udp_dstip) 0:udp_srcip 10.1.1.10 - - -# udp configurations for 2nd module -# udp destination port (receiver) -1:udp_dstport 50005 - # udp destination ip (receiver) -1:udp_dstip 10.1.1.100 +1:udp_dstip 10.1.2.100 # udp source ip (same subnet as 1:udp_dstip) -1:udp_srcip 10.1.1.11 +1:udp_srcip 10.1.2.11 @@ -45,5 +43,5 @@ timing trigger # output file directory fpath /external_pool/jungfrau_data/softwaretest -# disable file writing +# disable file writing (default) fwrite 0 \ No newline at end of file diff --git a/examples/rawdata.config b/examples/rawdata.config new file mode 100644 index 000000000..d8cff656b --- /dev/null +++ b/examples/rawdata.config @@ -0,0 +1,22 @@ +numfiles 1 +nthreads 5, +fifosize 5000 +nsigma 5 +gainfile none +detectorMode counting +threshold 0 +pedestalfile none +nframes 0 +xMin 0 +xMax 400 +yMin 0 +yMax 400 +outdir ./ +indir ./ +flist none +fformat none +runmin 0 +runmax -1 +readnrows 400 +eMin 0 +eMax 16000 diff --git a/examples/virtual_eiger_2_half_modules.config b/examples/virtual_eiger_2_half_modules.config index e4d1f5ed8..0df877cf0 100644 --- a/examples/virtual_eiger_2_half_modules.config +++ b/examples/virtual_eiger_2_half_modules.config @@ -2,10 +2,8 @@ hostname localhost:1900+localhost:1902+ # udp destination ports -0:udp_dstport 50000 -0:udp_dstport2 50001 -1:udp_dstport 50002 -1:udp_dstport2 50003 +udp_dstport 50000 +udp_dstport2 50001 # receiver hostname rx_hostname mpc1922:2000+mpc1922:2001+ diff --git a/examples/virtual_jungfrau_4.config b/examples/virtual_jungfrau_4.config index 021c2c4ae..f688a5456 100644 --- a/examples/virtual_jungfrau_4.config +++ b/examples/virtual_jungfrau_4.config @@ -5,24 +5,26 @@ detsize 2048 1024 virtual 4 1952 # udp destination ports -0:udp_dstport2 50001 -0:udp_dstport2 50002 -1:udp_dstport 50003 -1:udp_dstport2 50004 -2:udp_dstport 50005 -2:udp_dstport2 50006 -3:udp_dstport 50007 -3:udp_dstport2 50008 +udp_dstport 50001 +#0:udp_dstport2 50001 +#0:udp_dstport2 50002 +#1:udp_dstport 50003 +#1:udp_dstport2 50004 +#2:udp_dstport 50005 +#2:udp_dstport2 50006 +#3:udp_dstport 50007 +#3:udp_dstport2 50008 # udp source ip (same subnet as udp_dstip) udp_srcip 192.168.1.100 udp_srcip2 192.168.1.100 # receiver hostname and tcpports -0:rx_tcpport 1970 -1:rx_tcpport 1971 -2:rx_tcpport 1972 -3:rx_tcpport 1973 +rx_tcpport 1970 +#0:rx_tcpport 1970 +#1:rx_tcpport 1971 +#2:rx_tcpport 1972 +#3:rx_tcpport 1973 rx_hostname mpc1922 # udp destination ip from rx_hostname diff --git a/examples/zmq.config b/examples/zmq.config new file mode 100644 index 000000000..e4d39fc14 --- /dev/null +++ b/examples/zmq.config @@ -0,0 +1,16 @@ +numinterfaces 1 +rx_zmqip 10.1.2.102 +rx_zmqport 1978 +zmqip 129.129.202.57 +zmqport 1979 +nthreads 6 +fifosize 5000 +nsigma 5 +gainfile none +nbinsx 5 +nbinsy 5 +etafile none +etabinsx 1000 +etabinsy 1000 +etamin -1 +etamax 2 \ No newline at end of file diff --git a/psi-pmodules/DetectorSoftware/slsDetectorPackage/files/variants b/psi-pmodules/DetectorSoftware/slsDetectorPackage/files/variants index 27216a3b2..9bfcc52e8 100644 --- a/psi-pmodules/DetectorSoftware/slsDetectorPackage/files/variants +++ b/psi-pmodules/DetectorSoftware/slsDetectorPackage/files/variants @@ -3,3 +3,10 @@ slsDetectorPackage/7.0.1_rh7 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 slsDetectorPackage/7.0.1_rh8 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 slsDetectorPackage/7.0.2_rh7 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 slsDetectorPackage/7.0.2_rh8 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 +slsDetectorPackage/7.0.3_rh7 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 +slsDetectorPackage/7.0.3_rh8 stable cmake/3.15.5 zeromq/4.3.4 Qt/5.12.10 +slsDetectorPackage/8.0.0_rh7 stable cmake/3.15.5 Qt/5.12.10 +slsDetectorPackage/8.0.0_rh8 stable cmake/3.15.5 Qt/5.12.10 +slsDetectorPackage/8.0.1_rh7 stable cmake/3.15.5 Qt/5.12.10 +slsDetectorPackage/8.0.1_rh8 stable cmake/3.15.5 Qt/5.12.10 + diff --git a/python/setup.py b/python/setup.py index aee81b640..a467a4727 100755 --- a/python/setup.py +++ b/python/setup.py @@ -7,7 +7,6 @@ Build upon the pybind11 example found here: https://github.com/pybind/python_exa import os import sys -sys.path.append('../libs/pybind') from setuptools import setup, find_packages from pybind11.setup_helpers import Pybind11Extension, build_ext @@ -41,11 +40,10 @@ ext_modules = [ , include_dirs=[ - os.path.join('../libs/pybind/include'), os.path.join(get_conda_path(), 'include'), ], - libraries=['SlsDetector', 'SlsSupport', 'SlsReceiver', 'zmq'], + libraries=['SlsDetector', 'SlsSupport', 'SlsReceiver'], library_dirs=[ os.path.join(get_conda_path(), 'lib'), ], diff --git a/python/slsdet/detector.py b/python/slsdet/detector.py index 95e3593cc..8a900a588 100755 --- a/python/slsdet/detector.py +++ b/python/slsdet/detector.py @@ -232,7 +232,7 @@ class Detector(CppDetectorApi): @element def hardwareversion(self): """ - [Jungfrau][Moench][Gotthard2][Myhten3][Gotthard][Ctb] Hardware version of detector. \n + Hardware version of detector. \n [Eiger] Hardware version of front FPGA on detector. """ return self.getHardwareVersion() @@ -308,7 +308,7 @@ class Detector(CppDetectorApi): ----- [Eiger] Options: 4, 8, 12, 16, 32. If set to 32, also sets clkdivider to 2 (quarter speed), else to 0 (full speed)\n [Mythen3] Options: 8, 16, 32 \n - [Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2] 16 + [Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2][Xilinx Ctb] 16 """ return self.getDynamicRange() @@ -360,7 +360,8 @@ class Detector(CppDetectorApi): @property def settings(self): """ - Detector settings. Enum: detectorSettings + Detector settings. + Enum: detectorSettings Note ----- @@ -399,7 +400,10 @@ class Detector(CppDetectorApi): @element def framesl(self): """ - [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB] Number of frames left in acquisition.\n + [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB][Xilinx CTB] Number of frames left in acquisition.\n + + Note + ---- [Gotthard2] only in continuous auto mode. :setter: Not Implemented @@ -475,7 +479,8 @@ class Detector(CppDetectorApi): @element def gaincaps(self): """ - [Mythen3] Gain caps. Enum: M3_GainCaps \n + [Mythen3] Gain caps. + Enum: M3_GainCaps Note ---- @@ -573,8 +578,6 @@ class Detector(CppDetectorApi): """ Period between frames, accepts either a value in seconds or datetime.timedelta - Note - ----- :getter: always returns in seconds. To get in DurationWrapper, use getPeriod Example @@ -641,9 +644,6 @@ class Detector(CppDetectorApi): """ [Gotthard][Jungfrau][Moench][CTB][Mythen3][Gotthard2] Delay after trigger, accepts either a value in seconds, DurationWrapper or datetime.timedelta - Note - ----- - :getter: always returns in seconds. To get in DurationWrapper, use getDelayAfterTrigger Example @@ -895,7 +895,8 @@ class Detector(CppDetectorApi): @element def rx_discardpolicy(self): """ - Frame discard policy of receiver. Enum: frameDiscardPolicy + Frame discard policy of receiver. + Enum: frameDiscardPolicy Note ----- @@ -969,7 +970,8 @@ class Detector(CppDetectorApi): @property @element def fformat(self): - """ File format of data file in receiver. Enum: fileFormat + """ File format of data file in receiver. + Enum: fileFormat Note ----- @@ -1565,7 +1567,8 @@ class Detector(CppDetectorApi): @property @element def status(self): - """Gets detector status. Enum: runStatus + """Gets detector status. + Enum: runStatus Note ----- @@ -1579,7 +1582,8 @@ class Detector(CppDetectorApi): @property @element def rx_status(self): - """Gets receiver listener status. Enum: runStatus + """Gets receiver listener status. + Enum: runStatus Note ----- @@ -1673,6 +1677,11 @@ class Detector(CppDetectorApi): def sync(self): """ [Jungfrau][Moench] Enables or disables synchronization between modules. + + Note + ---- + Sync mode requires at least one master configured. Also requires flatband cabling between master and slave with termination board. + """ return self.getSynchronization() @@ -1803,6 +1812,7 @@ class Detector(CppDetectorApi): def daclist(self): """ List of enums/names for every dac for this detector + :setter: Only implemented for Chiptestboard """ @@ -1815,9 +1825,7 @@ class Detector(CppDetectorApi): @property def adclist(self): """ - List of names for every adc for this board. 32 adcs - :setter: Only implemented for Chiptestboard - + [Chiptestboard] List of names for every adc for this board. 32 adcs """ return self.getAdcNames() @@ -1828,9 +1836,7 @@ class Detector(CppDetectorApi): @property def signallist(self): """ - List of names for every io signal for this board. 64 signals - :setter: Only implemented for Chiptestboard - + [Chiptestboard] List of names for every io signal for this board. 64 signals """ return self.getSignalNames() @@ -1841,8 +1847,7 @@ class Detector(CppDetectorApi): @property def powerlist(self): """ - List of names for every power for this board. 5 power supply - :setter: Only implemented for Chiptestboard + [Chiptestboard] List of names for every power for this board. 5 power supply """ return self.getPowerNames() @@ -1854,8 +1859,7 @@ class Detector(CppDetectorApi): @property def slowadclist(self): """ - List of names for every slowadc for this board. 8 slowadc - :setter: Only implemented for Chiptestboard + [Chiptestboard] List of names for every slowadc for this board. 8 slowadc """ return self.getSlowADCNames() @@ -1874,7 +1878,7 @@ class Detector(CppDetectorApi): @property def powervalues(self): - """Gets the power values for every power for this detector.""" + """[Chiptestboard] Gets the power values for every power for this detector.""" return { power.name.lower(): element_if_equal(np.array(self.getPower(power))) for power in self.getPowerList() @@ -1882,7 +1886,7 @@ class Detector(CppDetectorApi): @property def slowadcvalues(self): - """Gets the slow adc values for every slow adc for this detector.""" + """[Chiptestboard] Gets the slow adc values for every slow adc for this detector.""" return { slowadc.name.lower(): element_if_equal(np.array(self.getSlowADC(slowadc))) for slowadc in self.getSlowADCList() @@ -1947,7 +1951,7 @@ class Detector(CppDetectorApi): @element def triggersl(self): """ - [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB] Number of triggers left in acquisition.\n + [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB][Xilinx CTB] Number of triggers left in acquisition.\n Note ---- @@ -2056,8 +2060,7 @@ class Detector(CppDetectorApi): ----- To set default rate correction from trimbit file, use setDefaultRateCorrection - Known Issue - ------------ + Known Issue: :getter: Always give 0 due to the microseconds precision. :setter: Use scientific notation to set custom rate correction, since timedelta resolution is 1 microseconds. \n @@ -2081,7 +2084,8 @@ class Detector(CppDetectorApi): @element def readoutspeed(self): """ - [Eiger][Jungfrau|Gotthard2] Readout speed of chip. Enum: speedLevel + [Eiger][Jungfrau|Gotthard2] Readout speed of chip. + Enum: speedLevel Note ----- @@ -2170,12 +2174,13 @@ class Detector(CppDetectorApi): @element def timing(self): """ - Set Timing Mode of detector. Enum: timingMode + Set Timing Mode of detector. + Enum: timingMode Note ----- Default: AUTO_TIMING \n - [Jungfrau][Moench][Gotthard][Ctb][Gotthard2] AUTO_TIMING, TRIGGER_EXPOSURE \n + [Jungfrau][Moench][Gotthard][Ctb][Gotthard2][Xilinx Ctb] AUTO_TIMING, TRIGGER_EXPOSURE \n [Mythen3] AUTO_TIMING, TRIGGER_EXPOSURE, GATED, TRIGGER_GATED \n [Eiger] AUTO_TIMING, TRIGGER_EXPOSURE, GATED, BURST_TRIGGER """ @@ -2230,13 +2235,11 @@ class Detector(CppDetectorApi): @property @element def type(self): - """ Returns detector type. Enum: detectorType - - Note - ---- + """ Returns detector type. + Enum: detectorType + [EIGER, JUNGFRAU, GOTTHARD, MOENCH, MYTHEN3, GOTTHARD2, CHIPTESTBOARD] :setter: Not implemented - Values: EIGER, JUNGFRAU, GOTTHARD, MOENCH, MYTHEN3, GOTTHARD2, CHIPTESTBOARD """ return self.getDetectorType() @@ -2497,9 +2500,6 @@ class Detector(CppDetectorApi): """ [Eiger] Measured sub frame period between last sub frame and previous one. - Note - ----- - :setter: Not implemented """ return ut.reduce_time(self.getMeasuredSubFramePeriod()) @@ -2777,7 +2777,8 @@ class Detector(CppDetectorApi): @property def gainmode(self): """ - [Jungfrau] Detector gain mode. Enum: gainMode + [Jungfrau] Detector gain mode. + Enum: gainMode Note ----- @@ -2890,11 +2891,8 @@ class Detector(CppDetectorApi): @property def maxclkphaseshift(self): """ - [Gotthard2][Mythen3] Absolute maximum Phase shift of clocks. - - Note - ---- - + [Gotthard2][Mythen3] Absolute maximum Phase shift of clocks. + :setter: Not Implemented Example @@ -2912,7 +2910,8 @@ class Detector(CppDetectorApi): @element def timingsource(self): """ - [Gotthard2] Timing source. Enum: timingSourceType + [Gotthard2] Timing source. + Enum: timingSourceType Note ----- @@ -2956,7 +2955,8 @@ class Detector(CppDetectorApi): @property @element def burstmode(self): - """[Gotthard2] Burst mode of detector. Enum: burstMode + """[Gotthard2] Burst mode of detector. + Enum: burstMode Note ---- @@ -2974,9 +2974,6 @@ class Detector(CppDetectorApi): """ [Gotthard2] Period between 2 bursts. Only in burst mode and auto timing mode. - Note - ----- - :getter: always returns in seconds. To get in DurationWrapper, use getBurstPeriod :setter: Not Implemented @@ -3099,7 +3096,8 @@ class Detector(CppDetectorApi): @property def vetoalg(self): - """[Gotthard2] Algorithm used for veto. Enum: vetoAlgorithm, streamingInterface + """[Gotthard2] Algorithm used for veto. + Enum: vetoAlgorithm, streamingInterface Note ---- @@ -3273,7 +3271,8 @@ class Detector(CppDetectorApi): @element def romode(self): """ - [CTB] Readout mode of detector. Enum: readoutMode + [CTB] Readout mode of detector. + Enum: readoutMode Note ------ @@ -3379,9 +3378,6 @@ class Detector(CppDetectorApi): def maxdbitphaseshift(self): """[CTB][Jungfrau] Absolute maximum Phase shift of of the clock to latch digital bits. - Note - ----- - :setter: Not Implemented """ return self.getMaxDBITPhaseShift() @@ -3426,9 +3422,6 @@ class Detector(CppDetectorApi): def maxadcphaseshift(self): """[Jungfrau][Moench][CTB] Absolute maximum Phase shift of ADC clock. - Note - ----- - :setter: Not Implemented """ return self.getMaxADCPhaseShift() @@ -3478,20 +3471,14 @@ class Detector(CppDetectorApi): """ [Ctb] Sync clock in MHz. - Note - ----- - :setter: Not implemented """ return self.getSYNCClock() @property def pattern(self): - """[Mythen3][Ctb] Loads ASCII pattern file directly to server (instead of executing line by line). - - Note - ---- - + """[Mythen3][Ctb][Xilinx Ctb] Loads ASCII pattern file directly to server (instead of executing line by line). + :getter: Not Implemented Example @@ -3508,7 +3495,7 @@ class Detector(CppDetectorApi): @property def patfname(self): """ - [Ctb][Mythen3] Gets the pattern file name including path of the last pattern uploaded. Returns an empty if nothing was uploaded or via a server default + [Ctb][Mythen3][Xilinx Ctb] Gets the pattern file name including path of the last pattern uploaded. Returns an empty if nothing was uploaded or via a server default file """ return self.getPatterFileName() @@ -3533,7 +3520,7 @@ class Detector(CppDetectorApi): @property @element def patlimits(self): - """[Ctb][Mythen3] Limits (start and stop address) of complete pattern. + """[Ctb][Mythen3][Xilinx Ctb] Limits (start and stop address) of complete pattern. Example --------- @@ -3553,7 +3540,7 @@ class Detector(CppDetectorApi): @property @element def patsetbit(self): - """[Ctb][Mythen3] Sets the mask applied to every pattern to the selected bits. + """[Ctb][Mythen3][Xilinx Ctb] Sets the mask applied to every pattern to the selected bits. Example -------- @@ -3570,7 +3557,7 @@ class Detector(CppDetectorApi): @property @element def patmask(self): - """[Ctb][Mythen3] Selects the bits that will have a pattern mask applied to the selected patmask for every pattern. + """[Ctb][Mythen3][Xilinx Ctb] Selects the bits that will have a pattern mask applied to the selected patmask for every pattern. Example -------- @@ -3588,7 +3575,7 @@ class Detector(CppDetectorApi): # @element def patwait(self): """ - [Ctb][Mythen3] Wait address of loop level provided. + [Ctb][Mythen3][Xilinx Ctb] Wait address of loop level provided. Example ------- @@ -3605,7 +3592,7 @@ class Detector(CppDetectorApi): @property @element def patwait0(self): - """[Ctb][Mythen3] Wait 0 address. + """[Ctb][Mythen3][Xilinx Ctb] Wait 0 address. Example -------- @@ -3625,7 +3612,7 @@ class Detector(CppDetectorApi): @property @element def patwait1(self): - """[Ctb][Mythen3] Wait 1 address. + """[Ctb][Mythen3][Xilinx Ctb] Wait 1 address. Example -------- @@ -3645,7 +3632,7 @@ class Detector(CppDetectorApi): @property @element def patwait2(self): - """[Ctb][Mythen3] Wait 2 address. + """[Ctb][Mythen3][Xilinx Ctb] Wait 2 address. Example -------- @@ -3665,7 +3652,7 @@ class Detector(CppDetectorApi): @property def patwaittime(self): """ - [Ctb][Mythen3] Wait time in clock cycles of loop level provided. + [Ctb][Mythen3][Xilinx Ctb] Wait time in clock cycles of loop level provided. Example ------- @@ -3682,7 +3669,7 @@ class Detector(CppDetectorApi): @property @element def patwaittime0(self): - """[Ctb][Mythen3] Wait 0 time in clock cycles.""" + """[Ctb][Mythen3][Xilinx Ctb] Wait 0 time in clock cycles.""" return self.getPatternWaitTime(0) @patwaittime0.setter @@ -3693,7 +3680,7 @@ class Detector(CppDetectorApi): @property @element def patwaittime1(self): - """[Ctb][Mythen3] Wait 1 time in clock cycles.""" + """[Ctb][Mythen3][Xilinx Ctb] Wait 1 time in clock cycles.""" return self.getPatternWaitTime(1) @patwaittime1.setter @@ -3704,7 +3691,7 @@ class Detector(CppDetectorApi): @property @element def patwaittime2(self): - """[Ctb][Mythen3] Wait 2 time in clock cycles.""" + """[Ctb][Mythen3][Xilinx Ctb] Wait 2 time in clock cycles.""" return self.getPatternWaitTime(2) @patwaittime2.setter @@ -3716,7 +3703,7 @@ class Detector(CppDetectorApi): @property def patloop(self): """ - [Ctb][Mythen3] Limits (start and stop address) of the loop provided. + [Ctb][Mythen3][Xilinx Ctb] Limits (start and stop address) of the loop provided. Example ------- @@ -3733,7 +3720,7 @@ class Detector(CppDetectorApi): @property @element def patloop0(self): - """[Ctb][Mythen3] Limits (start and stop address) of loop 0. + """[Ctb][Mythen3][Xilinx Ctb] Limits (start and stop address) of loop 0. Example --------- @@ -3753,7 +3740,7 @@ class Detector(CppDetectorApi): @property @element def patloop1(self): - """[Ctb][Mythen3] Limits (start and stop address) of loop 1. + """[Ctb][Mythen3][Xilinx Ctb] Limits (start and stop address) of loop 1. Example --------- @@ -3774,7 +3761,7 @@ class Detector(CppDetectorApi): @property @element def patloop2(self): - """[Ctb][Mythen3] Limits (start and stop address) of loop 2. + """[Ctb][Mythen3][Xilinx Ctb] Limits (start and stop address) of loop 2. Example --------- @@ -3796,7 +3783,7 @@ class Detector(CppDetectorApi): @property def patnloop(self): """ - [Ctb][Mythen3] Number of cycles of the loop provided. + [Ctb][Mythen3][Xilinx Ctb] Number of cycles of the loop provided. Example ------- @@ -3813,7 +3800,7 @@ class Detector(CppDetectorApi): @property @element def patnloop0(self): - """[Ctb][Mythen3] Number of cycles of loop 0.""" + """[Ctb][Mythen3][Xilinx Ctb] Number of cycles of loop 0.""" return self.getPatternLoopCycles(0) @patnloop0.setter @@ -3824,7 +3811,7 @@ class Detector(CppDetectorApi): @property @element def patnloop1(self): - """[Ctb][Mythen3] Number of cycles of loop 1.""" + """[Ctb][Mythen3][Xilinx Ctb] Number of cycles of loop 1.""" return self.getPatternLoopCycles(1) @patnloop1.setter @@ -3835,7 +3822,7 @@ class Detector(CppDetectorApi): @property @element def patnloop2(self): - """[Ctb][Mythen3] Number of cycles of loop 2.""" + """[Ctb][Mythen3][Xilinx Ctb] Number of cycles of loop 2.""" return self.getPatternLoopCycles(2) @patnloop2.setter @@ -3919,10 +3906,7 @@ class Detector(CppDetectorApi): @element def im_a(self): """[Ctb] Measured current of power supply a in mA. - - Note - ----- - + :setter: Not implemented """ return self.getMeasuredCurrent(dacIndex.I_POWER_A) @@ -3932,9 +3916,6 @@ class Detector(CppDetectorApi): def im_b(self): """[Ctb] Measured current of power supply b in mA. - Note - ----- - :setter: Not implemented """ return self.getMeasuredCurrent(dacIndex.I_POWER_B) @@ -3944,9 +3925,6 @@ class Detector(CppDetectorApi): def im_c(self): """[Ctb] Measured current of power supply c in mA. - Note - ----- - :setter: Not implemented """ return self.getMeasuredCurrent(dacIndex.I_POWER_C) @@ -3956,9 +3934,6 @@ class Detector(CppDetectorApi): def im_d(self): """[Ctb] Measured current of power supply d in mA. - Note - ----- - :setter: Not implemented """ return self.getMeasuredCurrent(dacIndex.I_POWER_D) @@ -3968,9 +3943,6 @@ class Detector(CppDetectorApi): def im_io(self): """[Ctb] Measured current of power supply io in mA. - Note - ----- - :setter: Not implemented """ return self.getMeasuredCurrent(dacIndex.I_POWER_IO) @@ -4020,9 +3992,6 @@ class Detector(CppDetectorApi): def exptimel(self): """[Gotthard] Exposure time left for current frame. - Note - ----- - :getter: always returns in seconds. To get in DurationWrapper, use getExptimeLeft :setter: Not Implemented @@ -4057,9 +4026,6 @@ class Detector(CppDetectorApi): """ [Gotthard2][Mythen3] Frequency of clock in Hz. - Note - ---- - :setter: Not implemented. Use clkdiv to set frequency Example @@ -4079,7 +4045,9 @@ class Detector(CppDetectorApi): @property @element def polarity(self): - """[Mythen3] Set positive or negative polarity. Enum: polarity""" + """[Mythen3] Set positive or negative polarity. + Enum: polarity + """ return self.getPolarity() @polarity.setter diff --git a/slsDetectorCalibration/dataStructures/moench03v2Data.h b/slsDetectorCalibration/dataStructures/moench03v2Data.h new file mode 100644 index 000000000..44998b6dd --- /dev/null +++ b/slsDetectorCalibration/dataStructures/moench03v2Data.h @@ -0,0 +1,240 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#ifndef MOENCH03v2DATA_H +#define MOENCH03v2DATA_H +//#define MYROOT + +#ifndef MYROOT +#include "sls/sls_detector_defs.h" +#endif + + + + +#ifdef MYROOT + + typedef struct { + uint64_t frameNumber; + uint32_t expLength; + uint32_t packetNumber; + uint64_t bunchId; + uint64_t timestamp; + uint16_t modId; + uint16_t row; + uint16_t column; + uint16_t reserved; + uint32_t debug; + uint16_t roundRNumber; + uint8_t detType; + uint8_t version; + } sls_detector_header; +#define MAX_NUM_PACKETS 512 +// using sls_bitset = std::bitset; +// using bitset_storage = uint8_t[MAX_NUM_PACKETS / 8]; + struct sls_receiver_header { + sls_detector_header detHeader; /**< is the detector header */ + uint8_t packetsMask[64]; /**< is the packets caught bit mask */ + }; +#endif + +#include "slsDetectorData.h" +#ifdef RAWDATA +#define DATA_OFFSET sizeof(header) +#endif +#ifndef RAWDATA +#define DATA_OFFSET 0 +#endif + + +class moench03v2Data : public slsDetectorData { + + private: + int iframe; + const int nRows; + + + + double ghost[200][25]; + + // Single point of definition if we need to customize +#ifndef MYROOT + using header = sls::defs::sls_receiver_header; +#endif +#ifdef MYROOT + sls_receiver_header header; +#endif + public: + /** + Implements the slsReceiverData structure for the moench02 prototype read + out by a module i.e. using the slsReceiver (160x160 pixels, 40 packets + 1286 large etc.) \param c crosstalk parameter for the output buffer + + */ + moench03v2Data(int nrows = 200) + : slsDetectorData(400, nrows*2,2* 400*nrows*2 + DATA_OFFSET), + nRows(nrows) { + + std::cout << "MOENCH width new firmware " << dataSize << std::endl; + + int off=DATA_OFFSET; + for (int ix = 0; ix < 400; ix++) { + for (int iy = 0; iy < nRows*2; iy++) { + dataMap[iy][ix]=off+2*(iy*400+ix); + } + } + + iframe = 0; + // cout << "data struct created" << endl; + }; + + /** + Returns the value of the selected channel for the given dataset as + double. \param data pointer to the dataset (including headers etc) \param + ix pixel number in the x direction \param iy pixel number in the y + direction \returns data for the selected channel, with inversion if + required as double + + */ + double getValue(char *data, int ix, int iy = 0) override { + uint16_t val = getChannel(data, ix, iy) & 0x3fff; + return val; + }; + + virtual void calcGhost(char *data, int ix, int iy) { + double val = 0; + /* for (int ix=0; ix<25; ix++){ */ + /* for (int iy=0; iy<200; iy++) { */ + val = 0; + // cout << "** "; + for (int isc = 0; isc < 16; isc++) { + // for (int ii=0; ii<2; ii++) { + val += getChannel(data, ix + 25 * isc, iy); + // cout << "(" << isc << "," << val << " " ; + val += getChannel(data, ix + 25 * isc, 399 - iy); + // cout << val << " " ; + // } + } + ghost[iy][ix] = val; //-6224; + // cout << " --"<< endl; + /* } */ + /* } */ + // cout << "*" << endl; + } + + virtual void calcGhost(char *data) { + for (int ix = 0; ix < 25; ix++) { + for (int iy = 0; iy < 200; iy++) { + calcGhost(data, ix, iy); + } + } + // cout << "*" << endl; + } + + double getGhost(int ix, int iy) { + if (iy < 200) + return ghost[iy][ix % 25]; + if (iy < 400) + return ghost[399 - iy][ix % 25]; + return 0; + }; + + /** + + Returns the frame number for the given dataset. Purely virtual func. + \param buff pointer to the dataset + \returns frame number + + */ + + int getFrameNumber(char *buff) { +#ifdef RAWDATA + return ((sls::defs::sls_receiver_header *)buff)->detHeader.frameNumber; +#endif +#ifndef RAWDATA + return 1; +#endif + + } + + /** + + Returns the packet number for the given dataset. purely virtual func + \param buff pointer to the dataset + \returns packet number number + + + + */ + int getPacketNumber(char *buff) { +#ifdef RAWDATA + return ((sls::defs::sls_receiver_header *)buff)->detHeader.packetNumber; +#endif +#ifndef RAWDATA + return 0; +#endif + + } + + char *readNextFrame(std::ifstream &filebin) override { + int ff = -1, np = -1; + return readNextFrame(filebin, ff, np); + } + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff) { + int np = -1; + return readNextFrame(filebin, ff, np); + }; + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff, int &np) { + char *data = new char[dataSize]; + char *d = readNextFrame(filebin, ff, np, data); + if (d == NULL) { + delete[] data; + data = NULL; + } + return data; + } + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff, int &np, + char *data) { + np = 0; + if (filebin.is_open()) { + if (filebin.read(data, dataSize)) { + ff = getFrameNumber(data); + np = getPacketNumber(data); + // std::cout << "**" << ff << " " << dataSize << " " << ff << " " << np << std::endl; + + return data; + } + } + std::cout << "**" << ff << " " << dataSize << " " << ff << " " << np << std::endl; + return nullptr; + } + + /** + + Loops over a memory slot until a complete frame is found (i.e. all + packets 0 to nPackets, same frame number). purely virtual func \param + data pointer to the memory to be analyzed \param ndata reference to the + amount of data found for the frame, in case the frame is incomplete at + the end of the memory slot \param dsize size of the memory slot to be + analyzed \returns pointer to the beginning of the last good frame (might + be incomplete if ndata smaller than dataSize), or NULL if no frame is + found + + */ + char *findNextFrame(char *data, int &ndata, int dsize) override { + if (dsize < dataSize) + ndata = dsize; + else + ndata = dataSize; + return data; + } + + // int getPacketNumber(int x, int y) {return dataMap[y][x]/packetSize;}; +}; + +#endif diff --git a/slsDetectorCalibration/dataStructures/moench03v2HalfData.h b/slsDetectorCalibration/dataStructures/moench03v2HalfData.h new file mode 100644 index 000000000..383f37327 --- /dev/null +++ b/slsDetectorCalibration/dataStructures/moench03v2HalfData.h @@ -0,0 +1,240 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#ifndef MOENCH03v2DATA_H +#define MOENCH03v2DATA_H +//#define MYROOT + +#ifndef MYROOT +#include "sls/sls_detector_defs.h" +#endif + + + + +#ifdef MYROOT + + typedef struct { + uint64_t frameNumber; + uint32_t expLength; + uint32_t packetNumber; + uint64_t bunchId; + uint64_t timestamp; + uint16_t modId; + uint16_t row; + uint16_t column; + uint16_t reserved; + uint32_t debug; + uint16_t roundRNumber; + uint8_t detType; + uint8_t version; + } sls_detector_header; +#define MAX_NUM_PACKETS 512 +// using sls_bitset = std::bitset; +// using bitset_storage = uint8_t[MAX_NUM_PACKETS / 8]; + struct sls_receiver_header { + sls_detector_header detHeader; /**< is the detector header */ + uint8_t packetsMask[64]; /**< is the packets caught bit mask */ + }; +#endif + +#include "slsDetectorData.h" +#ifdef RAWDATA +#define DATA_OFFSET sizeof(header) +#endif +#ifndef RAWDATA +#define DATA_OFFSET 0 +#endif + + +class moench03v2Data : public slsDetectorData { + + private: + int iframe; + const int nRows; + + + + double ghost[200][25]; + + // Single point of definition if we need to customize +#ifndef MYROOT + using header = sls::defs::sls_receiver_header; +#endif +#ifdef MYROOT + sls_receiver_header header; +#endif + public: + /** + Implements the slsReceiverData structure for the moench02 prototype read + out by a module i.e. using the slsReceiver (160x160 pixels, 40 packets + 1286 large etc.) \param c crosstalk parameter for the output buffer + + */ + moench03v2Data(int nrows = 200) + : slsDetectorData(400, nrows*2,2* 400*nrows*2 + DATA_OFFSET), + nRows(nrows) { + + std::cout << "MOENCH width new firmware " << dataSize << std::endl; + + int off=DATA_OFFSET; + for (int ix = 0; ix < 400; ix++) { + for (int iy = 0; iy < nRows*2; iy++) { + dataMap[iy][ix]=off+2*(iy*400+ix); + } + } + + iframe = 0; + // cout << "data struct created" << endl; + }; + + /** + Returns the value of the selected channel for the given dataset as + double. \param data pointer to the dataset (including headers etc) \param + ix pixel number in the x direction \param iy pixel number in the y + direction \returns data for the selected channel, with inversion if + required as double + + */ + double getValue(char *data, int ix, int iy = 0) override { + uint16_t val = getChannel(data, ix, iy) & 0x3fff; + return val; + }; + + virtual void calcGhost(char *data, int ix, int iy) { + double val = 0; + /* for (int ix=0; ix<25; ix++){ */ + /* for (int iy=0; iy<200; iy++) { */ + val = 0; + // cout << "** "; + for (int isc = 0; isc < 16; isc++) { + // for (int ii=0; ii<2; ii++) { + val += getChannel(data, ix + 25 * isc, iy); + // cout << "(" << isc << "," << val << " " ; + val += getChannel(data, ix + 25 * isc, 399 - iy); + // cout << val << " " ; + // } + } + ghost[iy][ix] = val; //-6224; + // cout << " --"<< endl; + /* } */ + /* } */ + // cout << "*" << endl; + } + + virtual void calcGhost(char *data) { + for (int ix = 0; ix < 25; ix++) { + for (int iy = 0; iy < 200; iy++) { + calcGhost(data, ix, iy); + } + } + // cout << "*" << endl; + } + + double getGhost(int ix, int iy) { + if (iy < 200) + return ghost[iy][ix % 25]; + if (iy < 400) + return ghost[399 - iy][ix % 25]; + return 0; + }; + + /** + + Returns the frame number for the given dataset. Purely virtual func. + \param buff pointer to the dataset + \returns frame number + + */ + + int getFrameNumber(char *buff) { +#ifdef RAWDATA + return ((sls::defs::sls_receiver_header *)buff)->detHeader.frameNumber; +#endif +#ifndef RAWDATA + return 1; +#endif + + } + + /** + + Returns the packet number for the given dataset. purely virtual func + \param buff pointer to the dataset + \returns packet number number + + + + */ + int getPacketNumber(char *buff) { +#ifdef RAWDATA + return ((sls::defs::sls_receiver_header *)buff)->detHeader.packetNumber; +#endif +#ifndef RAWDATA + return 0; +#endif + + } + + char *readNextFrame(std::ifstream &filebin) override { + int ff = -1, np = -1; + return readNextFrame(filebin, ff, np); + } + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff) { + int np = -1; + return readNextFrame(filebin, ff, np); + }; + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff, int &np) { + char *data = new char[dataSize]; + char *d = readNextFrame(filebin, ff, np, data); + if (d == NULL) { + delete[] data; + data = NULL; + } + return data; + } + + // not present in base class + virtual char *readNextFrame(std::ifstream &filebin, int &ff, int &np, + char *data) { + np = 0; + if (filebin.is_open()) { + if (filebin.read(data, dataSize)) { + ff = getFrameNumber(data); + np = getPacketNumber(data); + std::cout << "**" << ff << " " << dataSize << " " << ff << " " << np << std::endl; + + return data; + } + } + std::cout << "**" << ff << " " << dataSize << " " << ff << " " << np << std::endl; + return nullptr; + } + + /** + + Loops over a memory slot until a complete frame is found (i.e. all + packets 0 to nPackets, same frame number). purely virtual func \param + data pointer to the memory to be analyzed \param ndata reference to the + amount of data found for the frame, in case the frame is incomplete at + the end of the memory slot \param dsize size of the memory slot to be + analyzed \returns pointer to the beginning of the last good frame (might + be incomplete if ndata smaller than dataSize), or NULL if no frame is + found + + */ + char *findNextFrame(char *data, int &ndata, int dsize) override { + if (dsize < dataSize) + ndata = dsize; + else + ndata = dataSize; + return data; + } + + // int getPacketNumber(int x, int y) {return dataMap[y][x]/packetSize;}; +}; + +#endif diff --git a/slsDetectorCalibration/moenchExecutables/moench03Interpolation.cpp b/slsDetectorCalibration/moenchExecutables/moench03Interpolation.cpp index 3b17d3bf0..d1bd1c4ad 100644 --- a/slsDetectorCalibration/moenchExecutables/moench03Interpolation.cpp +++ b/slsDetectorCalibration/moenchExecutables/moench03Interpolation.cpp @@ -33,7 +33,7 @@ int main(int argc, char *argv[]) { #ifndef FF if (argc < 9) { cout << "Wrong usage! Should be: " << argv[0] - << " infile etafile outfile runmin runmax ns cmin cmax" << endl; + << " infile etafile outfile runmin runmax ns [cmin cmax xmin xmax ymin ymax]" << endl; return 1; } #endif @@ -41,7 +41,7 @@ int main(int argc, char *argv[]) { #ifdef FF if (argc < 7) { cout << "Wrong usage! Should be: " << argv[0] - << " infile etafile runmin runmax cmin cmax" << endl; + << " infile etafile runmin runmax [cmin cmax xmin xmax ymin ymax]" << endl; return 1; } #endif @@ -65,13 +65,30 @@ int main(int argc, char *argv[]) { nsubpix = atoi(argv[iarg++]); cout << "Subpix: " << nsubpix << endl; #endif - float cmin = atof(argv[iarg++]); - float cmax = atof(argv[iarg++]); + + float cmin = 0; + float cmax=1000000; + if (argc>iarg) + cmin=atof(argv[iarg++]); + if (argc>iarg) + cmax= atof(argv[iarg++]); cout << "Energy min: " << cmin << endl; cout << "Energy max: " << cmax << endl; + int xmin=0, xmax=NC, ymin=0, ymax=NR; + + if (argc>iarg) + xmin=atof(argv[iarg++]); + if (argc>iarg) + xmax= atof(argv[iarg++]); + + if (argc>iarg) + ymin=atof(argv[iarg++]); + if (argc>iarg) + ymax= atof(argv[iarg++]); + // int etabins=500; int etabins = 1000; // nsubpix*2*100; - double etamin = -1, etamax = 2; + double etamin = -0.25, etamax = 1.25; // double etamin=-0.1, etamax=1.1; // double eta3min = -2, eta3max = 2; double sum, totquad; @@ -80,7 +97,7 @@ int main(int argc, char *argv[]) { // double eta3x, eta3y, int3_x, int3_y, noint_x, noint_y; int ix, iy, isx, isy; - int nframes = 0, lastframe = -1; + int nframes = 0, lastframe = -1, iframe, nphFrame; //double d_x, d_y, res = 5, xx, yy; int nph = 0, totph = 0; //badph = 0, @@ -98,7 +115,7 @@ int main(int argc, char *argv[]) { // int nSubPixels = nsubpix; #ifndef NOINTERPOLATION eta2InterpolationPosXY *interp = - new eta2InterpolationPosXY(NC, NR, nsubpix, nsubpix,etabins,etabins, etamin, etamax); + new eta2InterpolationPosXY(NC, NR, nsubpix, nsubpix, etabins, etabins, etamin, etamax); // eta2InterpolationCleverAdaptiveBins *interp=new // eta2InterpolationCleverAdaptiveBins(NC, NR, nsubpix, etabins, etamin, // etamax); @@ -107,8 +124,8 @@ int main(int argc, char *argv[]) { noInterpolation *interp = new noInterpolation(NC, NR, nsubpix); #endif -#ifndef FF int quad; +#ifndef FF #ifndef NOINTERPOLATION char fname[10000]; int ok; @@ -142,19 +159,26 @@ int main(int argc, char *argv[]) { #endif int irun; - for (irun = runmin; irun < runmax; irun++) { + for (irun = runmin; irun <= runmax; irun++) { sprintf(infname, argv[1], irun); #ifndef FF sprintf(outfname, argv[3], irun); #endif + f = fopen(infname, "r"); if (f) { cout << infname << endl; nframes = 0; //f0 = -1; - while (cl.read(f)) { + //iff=0; + while (fread((void*)&iframe, 1, sizeof(int), f)) { + //n=0; + if (fread((void*)&nphFrame, 1, sizeof(int), f)) { + for (int iph=0; iphcalcQuad(cl.get_cluster(), sum, totquad, sDum); -#ifndef FF +// #ifndef FF +// quad = interp->calcEta(cl.get_cluster(), etax, etay, sum, +// totquad, sDum); +// #endif +// #ifdef FF + quad = interp->calcEta(cl.get_cluster(), etax, etay, sum, totquad, sDum); -#endif -#ifdef FF - interp->calcEta(cl.get_cluster(), etax, etay, sum, - totquad, sDum); -#endif + + + /* cl.print(); + cout << "(" << etax <<","<< etay <<")"<< quad<< endl; + */ + //#endif - if (sum > cmin && totquad / sum > 0.8 && totquad / sum < 1.2 && - sum < cmax) { - nph++; + if (totquad > cmin && cl.x >= xmin && cl.x <= xmax && + cl.y >= ymin && cl.y <= ymax && + totquad < cmax) { + + // if (sum > cmin && totquad / sum > 0.8 && totquad / sum < 1.2 && + // sum < cmax) { + nph++; // if (sum>200 && sum<580) { // interp->getInterpolatedPosition(cl.x,cl.y, // totquad,quad,cl.get_cluster(),int_x, int_y); @@ -227,9 +261,12 @@ int main(int argc, char *argv[]) { #ifdef FF interp->writeFlatField(outfname); #endif + } } } - } + } + } + } fclose(f); #ifdef FF diff --git a/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp b/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp index 6dcada915..69620e7f4 100644 --- a/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp +++ b/slsDetectorCalibration/moenchExecutables/moenchRawDataProcess.cpp @@ -13,7 +13,7 @@ #ifndef MOENCH04 #ifndef RECT -#include "moench03T1ReceiverDataNew.h" +#include "moench03v2Data.h" #endif #endif @@ -41,34 +41,147 @@ using namespace std; int main(int argc, char *argv[]) { - if (argc < 4) { + std::map args = { + {"numfiles","1"}, + {"nthreads","5"}, + {"fifosize","5000"}, + {"nsigma","5"}, + {"gainfile","none"}, + {"detectorMode","counting"}, + {"threshold","0"}, + {"pedestalfile","none"}, + {"nframes","0"}, + {"xMin","0"}, + {"xMax","400"}, + {"yMin","0"}, + {"yMax","400"}, + {"eMin","0"}, + {"eMax","16000"}, + {"outdir","./"}, + {"indir","./"}, + {"flist","none"}, + {"fformat","none"}, + {"runmin","0"}, + {"runmax","-1"}, + {"readnrows","400"} + }; + //float *gm; + + int ff, np; + // cout << " data size is " << dsize; + + ifstream filebin; + if (argc < 4) { + std::string name, value,sline; + int ic=0; + ifstream flist; + flist.open (argv[1], std::ifstream::in); + if (flist.is_open()) { + cout << "Using config file " <0 means photon counting" + "threshold>0 means photon counting" << endl; cout << "nframes <0 means sum everything; nframes=0 means one file per " - "run; nframes>0 means one file every nframes" + "run; nframes>0 means one file every nframes" << endl; - return 1; + return EXIT_FAILURE; + } + } else { + args["indir"]=argv[1]; + args["outdir"]=argv[1]; + args["fformat"]=argv[3]; + if (argc >= 5) { + args["runmin"] = argv[4]; + } + args["runmax"] = args["runmin"]; + + if (argc >= 6) { + args["runmax"] = argv[5]; + } + if (argc >= 7) { + args["pedestalfile"] = argv[6]; + } + if (argc >= 8) { + args["threshold"] = argv[7]; + } + if (argc >= 9) { + args["nframes"] = argv[8]; + } + if (argc >= 13) { + args["xMin"] = argv[9]; + args["xMax"] = argv[10]; + args["yMin"] = argv[11]; + args["yMax"] = argv[12]; + } + if (argc > 13) { + args["gainfile"] = argv[13]; + } + + if (atof(args["threshold"].c_str())<0) { + args["detectorMode"]="analog"; + } + } - int fifosize = 1000; - int nthreads = 10; - int csize = 3; - int nsigma = 5; - int nped = 10000; + + for (auto const& x : args) + { + std::cout << x.first // string (key) + << ':' + << x.second // string's value + << std::endl; + } + + + string indir=args["indir"]; + string outdir = args["outdir"]; + string fformat= args["fformat"]; + int runmin = atoi(args["runmin"].c_str()); + int runmax = atoi(args["runmin"].c_str()); + string pedfile =args["pedestalfile"]; + double thr = atof(args["threshold"].c_str()); + double thr1 = 1; + + int nframes = atoi(args["nframes"].c_str()); + + int xmin = atoi(args["xMin"].c_str()), xmax = atoi(args["xMax"].c_str()), ymin = atoi(args["yMin"].c_str()), ymax = atoi(args["yMax"].c_str()); + + string gainfname=args["gainfile"]; + + int fifosize = atoi(args["fifosize"].c_str()); + int nthreads = atoi(args["nthreads"].c_str()); + int nsigma = atoi(args["nsigma"].c_str()); + int nrows = atoi(args["readnrows"].c_str()); + float eMin = atof(args["eMin"].c_str()); + float eMax = atof(args["eMax"].c_str()); + int csize = 3; + int nped = 1000; + int cf = 0; - int numberOfPackets=40; + int numberOfPackets=nrows/8; + #ifdef RECT cout << "Should be rectangular but now it will crash! No data structure defined!" << endl; #endif - + #ifndef MOENCH04 - moench03T1ReceiverDataNew *decoder = new moench03T1ReceiverDataNew(); + moench03v2Data *decoder = new moench03v2Data(100); cout << "MOENCH03!" << endl; #endif @@ -77,7 +190,7 @@ int main(int argc, char *argv[]) { moench04CtbZmq10GbData *decoder = new moench04CtbZmq10GbData(5000,0); cout << "MOENCH04!" << endl; #endif - + #ifdef MOENCH04_DGS moench04CtbZmq10GbData *decoder = new moench04CtbZmq10GbData(5000,5000); cout << "MOENCH04 DGS!" << endl; @@ -86,63 +199,11 @@ int main(int argc, char *argv[]) { #endif - //Read detector size from decoder int nx , ny; decoder->getDetectorSize(nx, ny); - //float *gm; - - int ff, np; - // cout << " data size is " << dsize; - - ifstream filebin; - char *indir = argv[1]; - char *outdir = argv[2]; - char *fformat = argv[3]; - int runmin = 0; - - // cout << "argc is " << argc << endl; - if (argc >= 5) { - runmin = atoi(argv[4]); - } - - int runmax = runmin; - - if (argc >= 6) { - runmax = atoi(argv[5]); - } - - char *pedfile = NULL; - if (argc >= 7) { - pedfile = argv[6]; - } - double thr = 0; - double thr1 = 1; - - if (argc >= 8) { - thr = atof(argv[7]); - } - - int nframes = 0; - - if (argc >= 9) { - nframes = atoi(argv[8]); - } - - int xmin = 0, xmax = nx, ymin = 0, ymax = ny; - if (argc >= 13) { - xmin = atoi(argv[9]); - xmax = atoi(argv[10]); - ymin = atoi(argv[11]); - ymax = atoi(argv[12]); - } - - char *gainfname = NULL; - if (argc > 13) { - gainfname = argv[13]; - cout << "Gain map file name is: " << gainfname << endl; - } - + //Read detector size from decoder + char ffname[10000]; char fname[10000]; char imgfname[10000]; @@ -151,17 +212,6 @@ int main(int argc, char *argv[]) { std::time_t end_time; FILE *of = NULL; - cout << "input directory is " << indir << endl; - cout << "output directory is " << outdir << endl; - cout << "input file is " << fformat << endl; - cout << "runmin is " << runmin << endl; - cout << "runmax is " << runmax << endl; - if (pedfile) - cout << "pedestal file is " << pedfile << endl; - if (thr > 0) - cout << "threshold is " << thr << endl; - cout << "Nframes is " << nframes << endl; - uint32_t nnx, nny; @@ -182,50 +232,62 @@ int main(int argc, char *argv[]) { singlePhotonDetector *filter = new singlePhotonDetector( decoder, csize, nsigma, 1, cm, nped, 200, -1, -1, gainmap, gs); - if (gainfname) { + //if (gainfname) { - if (filter->readGainMap(gainfname)) + if (filter->readGainMap(gainfname.c_str())) cout << "using gain map " << gainfname << endl; else cout << "Could not open gain map " << gainfname << endl; - } else - thr = 0.15 * thr; + // } else + thr = 0.15 * thr; filter->newDataSet(); //int dsize = decoder->getDataSize(); if (thr > 0) { - cout << "threshold is " << thr << endl; - filter->setThreshold(thr); - cf = 0; - + cout << "threshold is " << thr << endl; + filter->setThreshold(thr); + cf = 0; } else - cf = 1; - + cf = 1; + filter->setROI(xmin, xmax, ymin, ymax); + filter->setEnergyRange(eMin, eMax); std::time(&end_time); cout << std::ctime(&end_time) << endl; char *buff; - + // multiThreadedAnalogDetector *mt=new // multiThreadedAnalogDetector(filter,nthreads,fifosize); multiThreadedCountingDetector *mt = new multiThreadedCountingDetector(filter, nthreads, fifosize); -#ifndef ANALOG - mt->setDetectorMode(ePhotonCounting); - cout << "Counting!" << endl; - if (thr > 0) { + + if (args["detectorMode"]=="counting") { + mt->setDetectorMode(ePhotonCounting); + if (thr > 0) { cf = 0; + } + } else { + mt->setDetectorMode(eAnalog); + cf = 0; } -#endif -//{ -#ifdef ANALOG - mt->setDetectorMode(eAnalog); - cout << "Analog!" << endl; - cf = 0; - // thr1=thr; -#endif - // } + + +// #ifndef ANALOG +// mt->setDetectorMode(ePhotonCounting); +// cout << "Counting!" << endl; +// if (thr > 0) { +// cf = 0; +// } +// #endif +// //{ +// #ifdef ANALOG +// mt->setDetectorMode(eAnalog); +// cout << "Analog!" << endl; +// cf = 0; +// // thr1=thr; +// #endif +// // } mt->StartThreads(); mt->popFree(buff); @@ -236,84 +298,117 @@ int main(int argc, char *argv[]) { char froot[1000]; double *ped=new double[nx * ny];//, *ped1; int pos,pos1; + //return 0; + if (pedfile.find(".raw") != std::string::npos) { + pos1=pedfile.rfind("/"); + strcpy(froot,pedfile.substr(pos1).c_str()); + pos=string(froot).find(".raw"); + froot[pos]='\0'; + } - if (pedfile) { - if (string(pedfile).find(".raw") != std::string::npos) { - pos1=string(pedfile).rfind("/"); - strcpy(froot,pedfile+pos1); - pos=string(froot).find(".raw"); - froot[pos]='\0'; - } - - cout << "PEDESTAL " << endl; - if (string(pedfile).find(".tif") == std::string::npos) { - sprintf(fname, "%s", pedfile); + cout << "PEDESTAL " << endl; + if (pedfile.find(".tif") == std::string::npos) { + sprintf(fname, "%s", pedfile.c_str()); cout << fname << endl; std::time(&end_time); //cout << "aaa" << std::ctime(&end_time) << endl; - + mt->setFrameMode(ePedestal); // sprintf(fn,fformat,irun); filebin.open((const char *)(fname), ios::in | ios::binary); // //open file if (filebin.is_open()) { - ff = -1; + ff = -1; while (decoder->readNextFrame(filebin, ff, np, buff)) { - if (np == numberOfPackets) { - mt->pushData(buff); + if (np == numberOfPackets) { + mt->pushData(buff); mt->nextThread(); mt->popFree(buff); ifr++; - if (ifr % 100 == 0) - cout << ifr << " " << ff << " " << np << endl; - } else - cout << ifr << " " << ff << " " << np << endl; + if (ifr % 100 == 0) + cout << ifr << " " << ff << " " << np << endl; + // break; + } else { + cout << ifr << " " << ff << " " << np << endl; + break; + } ff = -1; } filebin.close(); while (mt->isBusy()) { - ; - } + ; - sprintf(imgfname, "%s/%s_ped.tiff", outdir,froot); + } + + sprintf(imgfname, "%s/%s_ped.tiff", outdir.c_str(),froot); mt->writePedestal(imgfname); - sprintf(imgfname, "%s/%s_var.tiff", outdir,froot); + sprintf(imgfname, "%s/%s_var.tiff", outdir.c_str(),froot); mt->writePedestalRMS(imgfname); } else - cout << "Could not open pedestal file " << fname - << " for reading " << endl; - } else { - float *pp = ReadFromTiff(pedfile, nny, nnx); - if (pp && (int)nnx == nx && (int)nny == ny) { - for (int i = 0; i < nx * ny; i++) { + cout << "Could not open pedestal file " << fname + << " for reading " << endl; + } else { + float *pp = ReadFromTiff(pedfile.c_str(), nny, nnx); + if (pp && (int)nnx == nx && (int)nny == ny) { + for (int i = 0; i < nx * ny; i++) { ped[i] = pp[i]; - } - delete[] pp; - mt->setPedestal(ped); - cout << "Pedestal set from tiff file " << pedfile << endl; - } else { - cout << "Could not open pedestal tiff file " << pedfile + } + delete[] pp; + mt->setPedestal(ped); + cout << "Pedestal set from tiff file " << pedfile << endl; + } else { + cout << "Could not open pedestal tiff file " << pedfile << " for reading " << endl; - } - } - std::time(&end_time); - cout << std::ctime(&end_time) << endl; + } } + std::time(&end_time); + cout << std::ctime(&end_time) << endl; + ifr = 0; int ifile = 0; mt->setFrameMode(eFrame); + //t filelist=0; + ifstream flist; + flist.open (args["flist"].c_str(), std::ifstream::in); + if (flist.is_open()) { + cout << "Using file list" << endl; + runmin=0; + runmax=0; + while (flist.getline(ffname,10000)){ + cout << ffname << endl; + runmax++; + } + runmax--; + flist.close(); + cout << "Found " << runmax << " files " << endl; + flist.open (fformat, std::ifstream::in); + } for (int irun = runmin; irun <= runmax; irun++) { cout << "DATA "; // sprintf(fn,fformat,irun); - sprintf(ffname, "%s/%s.raw", indir, fformat); - sprintf(fname, (const char*)ffname, irun); - sprintf(ffname, "%s/%s.tiff", outdir, fformat); - sprintf(imgfname, (const char*)ffname, irun); - sprintf(ffname, "%s/%s.clust", outdir, fformat); - sprintf(cfname, (const char*)ffname, irun); + // sprintf(ffname, "%s/%s.raw", indir, fformat); + // sprintf(fname, (const char*)ffname, irun); + // sprintf(ffname, "%s/%s.tiff", outdir, fformat); + // sprintf(imgfname, (const char*)ffname, irun); + // sprintf(ffname, "%s/%s.clust", outdir, fformat); + // sprintf(cfname, (const char*)ffname, irun); + if (flist.is_open()) { + flist.getline(ffname,10000); + cout << "file list " << ffname << endl; + } else { + //sprintf(ffname,(const char*)fformat,irun); + sprintf(ffname,args["fformat"].c_str(),irun); + cout << "loop " << ffname << endl; + } + cout << "ffname "<< ffname << endl; + sprintf(fname, "%s/%s.raw",indir.c_str(),ffname); + sprintf(imgfname, "%s/%s.tiff",outdir.c_str(),ffname); + sprintf(cfname, "%s/%s.clust",outdir.c_str(),ffname); + + cout << fname << " "; cout << imgfname << endl; std::time(&end_time); @@ -323,7 +418,7 @@ int main(int argc, char *argv[]) { // //open file ifile = 0; if (filebin.is_open()) { - if (thr <= 0 && cf != 0) { // cluster finder + if (cf != 0) { // cluster finder if (of == NULL) { of = fopen(cfname, "w"); if (of) { @@ -341,7 +436,7 @@ int main(int argc, char *argv[]) { ff = -1; ifr = 0; while (decoder->readNextFrame(filebin, ff, np, buff)) { - if (np == numberOfPackets) { + if (np == numberOfPackets) { // //push mt->pushData(buff); // // //pop @@ -350,21 +445,26 @@ int main(int argc, char *argv[]) { ifr++; if (ifr % 100 == 0) - cout << ifr << " " << ff << endl; + cout << ifr << " " << ff << " " << np << endl; + //break; if (nframes > 0) { if (ifr % nframes == 0) { - sprintf(ffname, "%s/%s_f%05d.tiff", outdir, fformat, - ifile); - sprintf(imgfname, (const char*)ffname, irun); + // sprintf(ffname, "%s/%s_f%05d.tiff", outdir, fformat, + // ifile); + // sprintf(imgfname, (const char*)ffname, irun); + sprintf(imgfname, "%s/%s_f%05d.tiff",outdir.c_str(),ffname,ifile); + while (mt->isBusy()) + ; + mt->writeImage(imgfname, thr1); mt->clearImage(); ifile++; } } - } else { - cout << "bp " << ifr << " " << ff << " " << np << endl; - //break; - } + } else { + cout << "bp " << ifr << " " << ff << " " << np << endl; + //break; + } ff = -1; } cout << "--" << endl; @@ -374,13 +474,17 @@ int main(int argc, char *argv[]) { } if (nframes >= 0) { if (nframes > 0) { - sprintf(ffname, "%s/%s_f%05d.tiff", outdir, fformat, ifile); - sprintf(imgfname, (const char*)ffname, irun); + sprintf(imgfname, "%s/%s_f%05d.tiff",outdir.c_str(),ffname,ifile); + // sprintf(ffname, "%s/%s_f%05d.tiff", outdir, fformat, ifile); + //sprintf(imgfname, (const char*)ffname, irun); } else { - sprintf(ffname, "%s/%s.tiff", outdir, fformat); - sprintf(imgfname, (const char*)ffname, irun); + sprintf(imgfname, "%s/%s.tiff",outdir.c_str(),ffname); + // sprintf(ffname, "%s/%s.tiff", outdir, fformat); + // sprintf(imgfname, (const char*)ffname, irun); } - cout << "Writing tiff to " << imgfname << " " << thr1 << endl; + cout << "Writing tiff to " << imgfname << " " << thr1 << endl; + while (mt->isBusy()) + ; mt->writeImage(imgfname, thr1); mt->clearImage(); if (of) { @@ -395,11 +499,16 @@ int main(int argc, char *argv[]) { cout << "Could not open " << fname << " for reading " << endl; } if (nframes < 0) { - sprintf(ffname, "%s/%s.tiff", outdir, fformat); - strcpy(imgfname, ffname); - cout << "Writing tiff to " << imgfname << " " << thr1 << endl; - mt->writeImage(imgfname, thr1); + //sprintf(ffname, "%s/%s.tiff", outdir, fformat); + // strcpy(imgfname, ffname); + sprintf(imgfname, "%s/%s_tot.tiff",outdir.c_str(),ffname); + cout << "Writing tiff to " << imgfname << " " << thr1 << endl; + while (mt->isBusy()) + ; + mt->writeImage(imgfname, thr1); + } + if (flist.is_open()) { + flist.close(); } - return 0; } diff --git a/slsDetectorCalibration/moenchExecutables/moenchZmqProcess.cpp b/slsDetectorCalibration/moenchExecutables/moenchZmqProcess.cpp index 55220f781..f69184230 100644 --- a/slsDetectorCalibration/moenchExecutables/moenchZmqProcess.cpp +++ b/slsDetectorCalibration/moenchExecutables/moenchZmqProcess.cpp @@ -13,7 +13,8 @@ #include "sls/sls_detector_defs.h" #ifndef MOENCH04 //#ifndef RECT -#include "moench03T1ZmqDataNew.h" +#include "moench03v2Data.h" +//#include "moench03T1ZmqDataNew.h" //#endif //#ifdef RECT //#include "moench03T1ZmqDataNewRect.h" @@ -31,6 +32,7 @@ #include #include #include +#include #include //json header in zmq stream @@ -63,36 +65,48 @@ int main(int argc, char *argv[]) { * trial.o [socket ip] [starting port number] [send_socket ip] [send port * number] * - */ - FILE *of = NULL; - int fifosize = 5000; + */ + std::map args = { + {"numinterfaces","1"}, + {"rx_zmqip","10.1.2.102"}, + {"rx_zmqport","7770"}, + {"zmqip","129.129.202.153"}, + {"zmqport","7780"}, + {"nthreads","5"}, + {"fifosize","5000"}, + {"nsigma","5"}, + {"gainfile","none"}, + {"nbinsx","5"}, + {"nbinsy","5"}, + {"etafile","none"}, + {"etabinsx","1000"}, + {"etamin","-1"}, + {"etamax","2"} }; + FILE *of = NULL; int etabins = 1000, etabinsy = 1000; // nsubpix*2*100; double etamin = -1, etamax = 2; int nSubPixelsX = 2; int emin, emax; int nSubPixelsY = 2; + int nthreads = 5; + int fifosize = 5000; + uint32_t nSigma = 5; - // help - if (argc < 3) { - cprintf(RED, "Help: ./trial [receive socket ip] [receive starting port " - "number] [send_socket ip] [send starting port number] " - "[nthreads] [nsubpix] [gainmap] [etafile]\n"); - return EXIT_FAILURE; - } + string etafname;// = NULL; + string gainfname;// = NULL; // receive parameters bool send = false; - char *socketip = argv[1]; - uint32_t portnum = atoi(argv[2]); // send parameters if any - char *socketip2 = 0; - uint32_t portnum2 = 0; + string socketip2;// = 0; + uint32_t portnum2 = 0; + string socketip;// = 0; + uint32_t portnum = 0; sls::zmqHeader zHeader, outHeader; zHeader.jsonversion = SLS_DETECTOR_JSON_HEADER_VERSION; outHeader.jsonversion = SLS_DETECTOR_JSON_HEADER_VERSION; - uint32_t nSigma = 5; int ok; @@ -102,48 +116,85 @@ int main(int argc, char *argv[]) { // time_t begin,end,finished; int rms = 0; - if (argc > 4) { - socketip2 = argv[3]; - portnum2 = atoi(argv[4]); - if (portnum2 > 0) - send = true; - } - cout << "\nrx socket ip : " << socketip << "\nrx port num : " << portnum; - if (send) { - cout << "\ntx socket ip : " << socketip2 - << "\ntx port num : " << portnum2; - } - int nthreads = 5; - if (argc > 5) - nthreads = atoi(argv[5]); + send = true; + // help + if (argc < 5) { + std::string name, value,sline; + int ic=0; + ifstream flist; + flist.open (argv[1], std::ifstream::in); + if (flist.is_open()) { + cout << "Using config file " < 6) { - nSubPixelsX = atoi(argv[6]); - nSubPixelsY = nSubPixelsX; -#ifdef RECT - nSubPixelsX = 2; -#endif - } - cout << "Number of subpixels is: " << nSubPixelsX << " " << nSubPixelsY - << endl; + } + flist.close(); + } else { + cprintf(RED, "Arguments are either: \n [config file] \n or the following list (deprecated): [receive socket ip] [receive starting port " + "number] [send_socket ip] [send starting port number] " + "[nthreads] [nsubpix] [gainmap] [etafile]\n"); + return EXIT_FAILURE; + } + } else { + args["rx_zmqip"]=argv[1]; + args["rx_zmqport"]=argv[2]; + + args["zmqip"]=argv[3]; + args["zmqport"]=argv[4]; + if (argc > 5) + args["nthreads"] = argv[5]; + if (argc > 6) { + args["nbinsx"]=argv[6]; + args["nbinsy"]=argv[6]; + } + + if (argc > 7) { + args["gainfile"]=argv[7]; + } + if (argc > 8) { + args["etafilefile"]=argv[8]; + } - char *gainfname = NULL; - if (argc > 7) { - gainfname = argv[7]; - cout << "Gain map file name is: " << gainfname << endl; } - char *etafname = NULL; - if (argc > 8) { - etafname = argv[8]; - cout << "Eta file name is: " << etafname << endl; + for (auto const& x : args) + { + std::cout << x.first // string (key) + << ':' + << x.second // string's value + << std::endl; + } + + socketip = args["rx_zmqip"]; + portnum = atoi(args["rx_zmqport"].c_str()); + + socketip2 = args["zmqip"]; + portnum2 = atoi(args["zmqport"].c_str()); + + nthreads = atoi(args["nthreads"].c_str()); + nSubPixelsX =atoi(args["nbinsx"].c_str()); + nSubPixelsY =atoi(args["nbinsy"].c_str()); + gainfname = args["gainfile"]; + etafname = args["etafilefile"]; + + if (atoi(args["nuninterfaces"].c_str())>1){ + cprintf(RED, "Sorry, at the moment only a single interface is supported instead of %d\n",atoi(args["nuninterfaces"].c_str())); + return EXIT_FAILURE; } + // slsDetectorData *det=new moench03T1ZmqDataNew(); #ifndef MOENCH04 - cout << "This is a Moench03" << endl; - moench03T1ZmqDataNew *det = new moench03T1ZmqDataNew(); + cout << "This is a Moench03 v2" << endl; + //moench03T1ZmqDataNew *det = new moench03T1ZmqDataNew(); + moench03v2Data *det = new moench03v2Data(); + cout << "MOENCH03!" << endl; #endif #ifdef MOENCH04 cout << "This is a Moench04" << endl; @@ -177,8 +228,8 @@ int main(int argc, char *argv[]) { double *gmap = NULL; uint32_t nnnx, nnny; - if (gainfname) { - gm = ReadFromTiff(gainfname, nnny, nnnx); + //if (gainfname) { + gm = ReadFromTiff(gainfname.c_str(), nnny, nnnx); if (gm && nnnx == (uint)npx && nnny == (uint)npy) { gmap = new double[npx * npy]; for (int i = 0; i < npx * npy; i++) { @@ -187,7 +238,7 @@ int main(int argc, char *argv[]) { delete[] gm; } else cout << "Could not open gain map " << gainfname << endl; - } + //} // analogDetector *filter=new // analogDetector(det,1,NULL,1000); @@ -205,8 +256,8 @@ int main(int argc, char *argv[]) { eta2InterpolationPosXY *interp = new eta2InterpolationPosXY( npx, npy, nSubPixelsX, nSubPixelsY, etabins, etabinsy, etamin, etamax); - if (etafname) - interp->readFlatField(etafname); + //if (etafname) + interp->readFlatField(etafname.c_str()); interpolatingDetector *filter = new interpolatingDetector( det, interp, nSigma, 1, cm, 1000, 10, -1, -1, gainmap, gs); @@ -226,13 +277,13 @@ int main(int argc, char *argv[]) { try { #endif - zmqsocket = new sls::ZmqSocket(socketip, portnum); + zmqsocket = new sls::ZmqSocket(socketip.c_str(), portnum); #ifdef NEWZMQ } catch (...) { cprintf(RED, "Error: Could not create Zmq socket on port %d with ip %s\n", - portnum, socketip); + portnum, socketip.c_str()); delete zmqsocket; return EXIT_FAILURE; } @@ -242,7 +293,7 @@ int main(int argc, char *argv[]) { if (zmqsocket->IsError()) { cprintf(RED, "Error: Could not create Zmq socket on port %d with ip %s\n", - portnum, socketip); + portnum, socketip.c_str()); delete zmqsocket; return EXIT_FAILURE; } @@ -263,14 +314,14 @@ int main(int argc, char *argv[]) { // receive socket try { #endif - zmqsocket2 = new sls::ZmqSocket(portnum2, socketip2); + zmqsocket2 = new sls::ZmqSocket(portnum2, socketip2.c_str()); #ifdef NEWZMQ } catch (...) { cprintf(RED, "Error: Could not create Zmq socket server on port %d and " "ip %s\n", - portnum2, socketip2); + portnum2, socketip2.c_str()); // delete zmqsocket2; // zmqsocket2=NULL; // delete zmqsocket; @@ -284,7 +335,7 @@ int main(int argc, char *argv[]) { cprintf(RED, "AAA Error: Could not create Zmq socket server on port %d " "and ip %s\n", - portnum2, socketip2); + portnum2, socketip2.c_str()); // delete zmqsocket2; // delete zmqsocket; // return EXIT_FAILURE; @@ -722,6 +773,25 @@ int main(int argc, char *argv[]) { cprintf(MAGENTA, "%d %d %d %d\n", xmin, xmax, ymin, ymax); mt->setROI(xmin, xmax, ymin, ymax); + + if (addJsonHeader.find("xMin") != addJsonHeader.end()) { + istringstream(addJsonHeader.at("xMin")) >> xmin; + } + + if (addJsonHeader.find("yMin") != addJsonHeader.end()) { + istringstream(addJsonHeader.at("yMin")) >> ymin; + } + + if (addJsonHeader.find("xMax") != addJsonHeader.end()) { + istringstream(addJsonHeader.at("xMax")) >> xmax; + } + + if (addJsonHeader.find("yMax") != addJsonHeader.end()) { + istringstream(addJsonHeader.at("yMax")) >> ymax; + } + + + if (addJsonHeader.find("dynamicRange") != addJsonHeader.end()) { istringstream(addJsonHeader.at("dynamicRange")) >> dr; dr = 32; @@ -821,7 +891,7 @@ int main(int argc, char *argv[]) { // cout << acqIndex << " " << frameIndex << " " << subFrameIndex << " // "<< detSpec1 << " " << timestamp << " " << packetNumber << endl; // cprintf(GREEN, "frame\n"); - if (packetNumber >= 40) { + if (packetNumber <= 50) { //*((int*)buff)=frameIndex; if (insubframe == 0) f0 = frameIndex; diff --git a/slsDetectorGui/src/qTabMeasurement.cpp b/slsDetectorGui/src/qTabMeasurement.cpp index c3282d67e..dc97903bb 100644 --- a/slsDetectorGui/src/qTabMeasurement.cpp +++ b/slsDetectorGui/src/qTabMeasurement.cpp @@ -803,8 +803,9 @@ void qTabMeasurement::GetNextFrameNumber() { "Inconsistent starting frame number for all detectors."); spinNextFrameNumber->setValue(retval); } - CATCH_DISPLAY("Could not get starting frame number.", - "qTabMeasurement::GetNextFrameNumber") + CATCH_HANDLE("Could not get starting frame number.", + "qTabMeasurement::GetNextFrameNumber", spinNextFrameNumber, + &QSpinBox::setValue, -1) connect(spinNextFrameNumber, SIGNAL(valueChanged(int)), this, SLOT(SetNextFrameNumber(int))); } diff --git a/slsDetectorServers/CMakeLists.txt b/slsDetectorServers/CMakeLists.txt index 2bb9386b0..703cd77f0 100644 --- a/slsDetectorServers/CMakeLists.txt +++ b/slsDetectorServers/CMakeLists.txt @@ -11,6 +11,7 @@ install(TARGETS slsProjectCSettings PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} ) add_subdirectory(ctbDetectorServer) +add_subdirectory(xilinx_ctbDetectorServer) add_subdirectory(eigerDetectorServer) add_subdirectory(gotthardDetectorServer) add_subdirectory(jungfrauDetectorServer) diff --git a/slsDetectorServers/compileAllServers.sh b/slsDetectorServers/compileAllServers.sh index fe48f61fd..eec8907bf 100644 --- a/slsDetectorServers/compileAllServers.sh +++ b/slsDetectorServers/compileAllServers.sh @@ -8,7 +8,8 @@ det_list=("ctbDetectorServer gotthard2DetectorServer jungfrauDetectorServer mythen3DetectorServer - moenchDetectorServer" + moenchDetectorServer + xilinx_ctbDetectorServer" ) usage="\nUsage: compileAllServers.sh [server|all(opt)] [branch(opt)]. \n\tNo arguments mean all servers with 'developer' branch. \n\tNo 'branch' input means 'developer branch'" diff --git a/slsDetectorServers/compileAllServers_noAPIUpdate.sh b/slsDetectorServers/compileAllServers_noAPIUpdate.sh index 2d16347b1..ecfbdf6fb 100644 --- a/slsDetectorServers/compileAllServers_noAPIUpdate.sh +++ b/slsDetectorServers/compileAllServers_noAPIUpdate.sh @@ -9,6 +9,7 @@ det_list=("ctbDetectorServer" "jungfrauDetectorServer" "mythen3DetectorServer" "moenchDetectorServer" + "xilinx_ctbDetectorServer" ) usage="\nUsage: compileAllServers.sh [server|all(opt)] [branch(opt)]. \n\tNo arguments mean all servers with 'developer' branch. \n\tNo 'branch' input means 'developer branch'" diff --git a/slsDetectorServers/ctbDetectorServer/bin/ctbDetectorServer_developer b/slsDetectorServers/ctbDetectorServer/bin/ctbDetectorServer_developer index e8aff2c87..46a6e3bc4 100755 Binary files a/slsDetectorServers/ctbDetectorServer/bin/ctbDetectorServer_developer and b/slsDetectorServers/ctbDetectorServer/bin/ctbDetectorServer_developer differ diff --git a/slsDetectorServers/eigerDetectorServer/bin/eigerDetectorServer_developer b/slsDetectorServers/eigerDetectorServer/bin/eigerDetectorServer_developer index dc23c0984..c88182af4 100755 Binary files a/slsDetectorServers/eigerDetectorServer/bin/eigerDetectorServer_developer and b/slsDetectorServers/eigerDetectorServer/bin/eigerDetectorServer_developer differ diff --git a/slsDetectorServers/eigerDetectorServer/slsDetectorServer_defs.h b/slsDetectorServers/eigerDetectorServer/slsDetectorServer_defs.h index 57c8d9a0c..5e4a62f1b 100644 --- a/slsDetectorServers/eigerDetectorServer/slsDetectorServer_defs.h +++ b/slsDetectorServers/eigerDetectorServer/slsDetectorServer_defs.h @@ -10,7 +10,7 @@ #define HARDWARE_VERSION_NAMES \ { "FX70T", "FX30T" } -#define REQUIRED_FIRMWARE_VERSION (31) +#define REQUIRED_FIRMWARE_VERSION (32) // virtual ones renamed for consistency // real ones keep previous name for compatibility (already in production) #ifdef VIRTUAL diff --git a/slsDetectorServers/gotthard2DetectorServer/bin/gotthard2DetectorServer_developer b/slsDetectorServers/gotthard2DetectorServer/bin/gotthard2DetectorServer_developer index 9ae5e2cac..7e05b13de 100755 Binary files a/slsDetectorServers/gotthard2DetectorServer/bin/gotthard2DetectorServer_developer and b/slsDetectorServers/gotthard2DetectorServer/bin/gotthard2DetectorServer_developer differ diff --git a/slsDetectorServers/gotthardDetectorServer/bin/gotthardDetectorServer_developer b/slsDetectorServers/gotthardDetectorServer/bin/gotthardDetectorServer_developer index 9aaaff86b..55866dae2 100755 Binary files a/slsDetectorServers/gotthardDetectorServer/bin/gotthardDetectorServer_developer and b/slsDetectorServers/gotthardDetectorServer/bin/gotthardDetectorServer_developer differ diff --git a/slsDetectorServers/gotthardDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/gotthardDetectorServer/slsDetectorFunctionList.c index f95c613f1..67894579b 100644 --- a/slsDetectorServers/gotthardDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/gotthardDetectorServer/slsDetectorFunctionList.c @@ -90,6 +90,7 @@ void basictests() { "Could not map to memory. Cannot proceed. Check Firmware.\n"); LOG(logERROR, (initErrorMessage)); initError = FAIL; + return; } #ifndef VIRTUAL // does check only if flag is 0 (by default), set by command line diff --git a/slsDetectorServers/jungfrauDetectorServer/RegisterDefs.h b/slsDetectorServers/jungfrauDetectorServer/RegisterDefs.h index e00358c91..5aea7924d 100644 --- a/slsDetectorServers/jungfrauDetectorServer/RegisterDefs.h +++ b/slsDetectorServers/jungfrauDetectorServer/RegisterDefs.h @@ -24,16 +24,18 @@ #define RUN_BUSY_OFST (0) #define RUN_BUSY_MSK (0x00000001 << RUN_BUSY_OFST) -#define WAITING_FOR_TRIGGER_OFST (3) +#define WAITING_FOR_TRIGGER_OFST (1) #define WAITING_FOR_TRIGGER_MSK (0x00000001 << WAITING_FOR_TRIGGER_OFST) -#define DELAYBEFORE_OFST (4) // Not used in software -#define DELAYBEFORE_MSK (0x00000001 << DELAYBEFORE_OFST) // Not used in software -#define DELAYAFTER_OFST (5) // Not used in software -#define DELAYAFTER_MSK (0x00000001 << DELAYAFTER_OFST) // Not used in software -#define STOPPED_OFST (15) +#define WAITING_FOR_START_FRAME_OFST (2) +#define WAITING_FOR_START_FRAME_MSK (0x00000001 << WAITING_FOR_START_FRAME_OFST) +#define ACQUIRING_FRAME_OFST (3) // Not used in software +#define ACQUIRING_FRAME_MSK (0x00000001 << ACQUIRING_FRAME_OFST) +#define WAITING_FOR_PERIOD_TO_ELAPSE_OFST (4) // Not used in software +#define WAITING_FOR_PERIOD_TO_ELAPSE_MSK (0x00000001 << WAITING_FOR_PERIOD_TO_ELAPSE_OFST) +#define STOPPED_OFST (8) #define STOPPED_MSK (0x00000001 << STOPPED_OFST) -#define RUNMACHINE_BUSY_OFST (17) -#define RUNMACHINE_BUSY_MSK (0x00000001 << RUNMACHINE_BUSY_OFST) +#define INTERNAL_STOP_OFST (9) +#define INTERNAL_STOP_MSK (0x00000001 << INTERNAL_STOP_OFST) /* Look at me register */ #define LOOK_AT_ME_REG (0x03 << MEM_MAP_SHIFT) // Not used in firmware or software diff --git a/slsDetectorServers/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer b/slsDetectorServers/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer index 93d1e3bc8..7dfc45b9e 100755 Binary files a/slsDetectorServers/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer and b/slsDetectorServers/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer differ diff --git a/slsDetectorServers/jungfrauDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/jungfrauDetectorServer/slsDetectorFunctionList.c index a3972d215..212056d65 100644 --- a/slsDetectorServers/jungfrauDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/jungfrauDetectorServer/slsDetectorFunctionList.c @@ -88,6 +88,7 @@ void basictests() { "Could not map to memory. Cannot proceed. Check Firmware.\n"); LOG(logERROR, (initErrorMessage)); initError = FAIL; + return; } #ifndef VIRTUAL // does check only if flag is 0 (by default), set by command line @@ -2924,14 +2925,17 @@ int softwareTrigger(int block) { LOG(logINFO, ("Sending Software Trigger\n")); bus_w(CONTROL_REG, bus_r(CONTROL_REG) | CONTROL_SOFTWARE_TRIGGER_MSK); bus_w(CONTROL_REG, bus_r(CONTROL_REG) & ~CONTROL_SOFTWARE_TRIGGER_MSK); + // wait to make sure its out of this state and even 'wait for start frame' + usleep(100); #ifndef VIRTUAL - // block till frame is sent out + // block till frame sent out & back to wait for trigger (or not busy + // anymore) if (block) { - enum runStatus s = getRunStatus(); - while (s == RUNNING || s == TRANSMITTING) { + uint32_t retval = bus_r(STATUS_REG); + while ((retval & RUN_BUSY_MSK) && !(retval & WAITING_FOR_TRIGGER_MSK)) { usleep(5000); - s = getRunStatus(); + retval = bus_r(STATUS_REG); } } LOG(logINFO, ("Ready for Next Trigger...\n")); @@ -2964,9 +2968,16 @@ enum runStatus getRunStatus() { u_int32_t retval = bus_r(STATUS_REG); LOG(logINFO, ("Status Register: %08x\n", retval)); + // error + if (retval & INTERNAL_STOP_MSK) { + LOG(logINFOBLUE, ("Status: ERROR\n")); + s = ERROR; + } + // running - if (retval & RUN_BUSY_MSK) { - if (retval & WAITING_FOR_TRIGGER_MSK) { + else if (retval & RUN_BUSY_MSK) { + if ((retval & WAITING_FOR_TRIGGER_MSK) || + (retval & WAITING_FOR_START_FRAME_MSK)) { LOG(logINFOBLUE, ("Status: WAITING\n")); s = WAITING; } else { @@ -2977,19 +2988,13 @@ enum runStatus getRunStatus() { // not running else { - // stopped or error + // stopped or idle if (retval & STOPPED_MSK) { LOG(logINFOBLUE, ("Status: STOPPED\n")); s = STOPPED; - } else if (retval & RUNMACHINE_BUSY_MSK) { - LOG(logINFOBLUE, ("Status: READ MACHINE BUSY\n")); - s = TRANSMITTING; - } else if (!retval) { + } else { LOG(logINFOBLUE, ("Status: IDLE\n")); s = IDLE; - } else { - LOG(logERROR, ("Status: Unknown status %08x\n", retval)); - s = ERROR; } } diff --git a/slsDetectorServers/moenchDetectorServer/bin/moenchDetectorServer_developer b/slsDetectorServers/moenchDetectorServer/bin/moenchDetectorServer_developer index b253cbd16..16b15b856 100755 Binary files a/slsDetectorServers/moenchDetectorServer/bin/moenchDetectorServer_developer and b/slsDetectorServers/moenchDetectorServer/bin/moenchDetectorServer_developer differ diff --git a/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c index e4ec00a8c..19f2d6c98 100644 --- a/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c @@ -82,6 +82,7 @@ void basictests() { "Could not map to memory. Cannot proceed. Check Firmware.\n"); LOG(logERROR, ("%s\n\n", initErrorMessage)); initError = FAIL; + return; } #ifndef VIRTUAL // does check only if flag is 0 (by default), set by command line @@ -481,7 +482,6 @@ void setupDetector() { return; } - setReadoutSpeed(DEFAULT_SPEED); cleanFifos(); resetCore(); @@ -495,6 +495,7 @@ void setupDetector() { initReadoutConfiguration(); // Initialization of acquistion parameters + setReadoutSpeed(DEFAULT_SPEED); setSettings(DEFAULT_SETTINGS); setNumFrames(DEFAULT_NUM_FRAMES); setNumTriggers(DEFAULT_NUM_CYCLES); @@ -699,14 +700,12 @@ int setExpTime(int64_t val) { } LOG(logINFO, ("Setting exptime %lld ns\n", (long long int)val)); val *= (1E-3 * CLK_RUN); - val -= ACQ_TIME_MIN_CLOCK; if (val < 0) { val = 0; } set64BitReg(val, SET_EXPTIME_LSB_REG, SET_EXPTIME_MSB_REG); // validate for tolerance - val += ACQ_TIME_MIN_CLOCK; int64_t retval = getExpTime(); val /= (1E-3 * CLK_RUN); if (val != retval) { @@ -716,8 +715,7 @@ int setExpTime(int64_t val) { } int64_t getExpTime() { - return (get64BitReg(SET_EXPTIME_LSB_REG, SET_EXPTIME_MSB_REG) + - ACQ_TIME_MIN_CLOCK) / + return get64BitReg(SET_EXPTIME_LSB_REG, SET_EXPTIME_MSB_REG) / (1E-3 * CLK_RUN); } diff --git a/slsDetectorServers/moenchDetectorServer/slsDetectorServer_defs.h b/slsDetectorServers/moenchDetectorServer/slsDetectorServer_defs.h index 4eecb9264..a2ca7be9b 100644 --- a/slsDetectorServers/moenchDetectorServer/slsDetectorServer_defs.h +++ b/slsDetectorServers/moenchDetectorServer/slsDetectorServer_defs.h @@ -5,7 +5,7 @@ #include "sls/sls_detector_defs.h" #define REQRD_FRMWRE_VRSN_BOARD2 0x444445 // 1.0 pcb (version = 010) -#define REQRD_FRMWRE_VRSN 0x230710 // 2.0 pcb (version = 011) +#define REQRD_FRMWRE_VRSN 0x231026 // 2.0 pcb (version = 011) #define NUM_HARDWARE_VERSIONS (2) #define HARDWARE_VERSION_NUMBERS \ @@ -58,11 +58,10 @@ /* Defines in the Firmware */ #define MAX_TIMESLOT_VAL (0x1F) #define MAX_THRESHOLD_TEMP_VAL (127999) // millidegrees -#define ACQ_TIME_MIN_CLOCK (2) #define ASIC_FILTER_MAX_RES_VALUE (1) #define MAX_SELECT_CHIP10_VAL (63) -#define MAX_PHASE_SHIFTS (240) +#define MAX_PHASE_SHIFTS (200) #define BIT16_MASK (0xFFFF) #define ADC_DECMT_QUARTER_SPEED (0x3) diff --git a/slsDetectorServers/mythen3DetectorServer/bin/mythen3DetectorServer_developer b/slsDetectorServers/mythen3DetectorServer/bin/mythen3DetectorServer_developer index ca8e99814..290738b43 100755 Binary files a/slsDetectorServers/mythen3DetectorServer/bin/mythen3DetectorServer_developer and b/slsDetectorServers/mythen3DetectorServer/bin/mythen3DetectorServer_developer differ diff --git a/slsDetectorServers/mythen3DetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/mythen3DetectorServer/slsDetectorFunctionList.c index 3fcfda045..4c069b452 100644 --- a/slsDetectorServers/mythen3DetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/mythen3DetectorServer/slsDetectorFunctionList.c @@ -92,6 +92,7 @@ void basictests() { "Could not map to memory. Cannot proceed. Check Firmware.\n"); LOG(logERROR, (initErrorMessage)); initError = FAIL; + return; } #ifndef VIRTUAL // does check only if flag is 0 (by default), set by command line diff --git a/slsDetectorServers/slsDetectorServer/include/arm64.h b/slsDetectorServers/slsDetectorServer/include/arm64.h new file mode 100644 index 000000000..06e8f7b26 --- /dev/null +++ b/slsDetectorServers/slsDetectorServer/include/arm64.h @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#pragma once + +#include +#include + +void bus_w(u_int32_t offset, u_int32_t data); +u_int32_t bus_r(u_int32_t offset); +uint64_t getU64BitReg(int aLSB, int aMSB); +void setU64BitReg(uint64_t value, int aLSB, int aMSB); +int mapCSP0(void); diff --git a/slsDetectorServers/slsDetectorServer/include/loadPattern.h b/slsDetectorServers/slsDetectorServer/include/loadPattern.h index 1d87956b9..290e50506 100644 --- a/slsDetectorServers/slsDetectorServer/include/loadPattern.h +++ b/slsDetectorServers/slsDetectorServer/include/loadPattern.h @@ -6,10 +6,12 @@ #include "clogger.h" void initializePatternAddresses(); -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) #ifdef VIRTUAL void initializePatternWord(); #endif +#endif +#if defined(CHIPTESTBOARDD) // TODO || defined(XILINX_CHIPTESTBOARDD) uint64_t validate_readPatternIOControl(); int validate_writePatternIOControl(char *message, uint64_t arg); void writePatternIOControl(uint64_t word); diff --git a/slsDetectorServers/slsDetectorServer/include/slsDetectorFunctionList.h b/slsDetectorServers/slsDetectorServer/include/slsDetectorFunctionList.h index d7858498f..7cbc24cf0 100644 --- a/slsDetectorServers/slsDetectorServer/include/slsDetectorFunctionList.h +++ b/slsDetectorServers/slsDetectorServer/include/slsDetectorFunctionList.h @@ -25,6 +25,10 @@ #include "blackfin.h" #endif +#ifdef ARMPROCESSOR +#include "arm64.h" +#endif + #ifdef MYTHEN3D #include "mythen3.h" #endif @@ -61,8 +65,7 @@ typedef struct udpStruct_s { int isInitCheckDone(); int getInitResult(char **mess); void basictests(); -#if defined(GOTTHARDD) || defined(JUNGFRAUD) || defined(MOENCHD) || \ - defined(CHIPTESTBOARDD) || defined(MYTHEN3D) || defined(GOTTHARD2D) +#if !defined(EIGERD) int checkType(); int testFpga(); int testBus(); @@ -81,13 +84,17 @@ u_int64_t getFirmwareVersion(); #ifdef EIGERD uint64_t getFrontEndFirmwareVersion(enum fpgaPosition fpgaPosition); #endif +#ifndef XILINX_CHIPTESTBOARDD u_int64_t getFirmwareAPIVersion(); +#endif void getHardwareVersion(char *version); #ifdef EIGERD int getHardwareVersionNumber(); #else +#ifndef XILINX_CHIPTESTBOARDD u_int16_t getHardwareVersionNumber(); #endif +#endif #if defined(JUNGFRAUD) || defined(MOENCHD) || defined(CHIPTESTBOARDD) u_int16_t getHardwareSerialNumber(); #endif @@ -111,7 +118,6 @@ int updateModuleId(); void setModuleId(int modid); #endif #endif - u_int64_t getDetectorMAC(); u_int32_t getDetectorIP(); @@ -136,7 +142,7 @@ int updateDatabytesandAllocateRAM(); void updateDataBytes(); #endif -#ifndef CHIPTESTBOARDD +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) int resetToDefaultDacs(int hardReset); int getDefaultDac(enum DACINDEX index, enum detectorSettings sett, int *retval); int setDefaultDac(enum DACINDEX index, enum detectorSettings sett, int value); @@ -245,12 +251,14 @@ void setNumFrames(int64_t val); int64_t getNumFrames(); void setNumTriggers(int64_t val); int64_t getNumTriggers(); +#ifndef XILINX_CHIPTESTBOARDD #ifndef MYTHEN3D int setExpTime(int64_t val); int64_t getExpTime(); #endif int setPeriod(int64_t val); int64_t getPeriod(); +#endif #ifdef MYTHEN3D void setNumIntGates(int val); void setNumGates(int val); @@ -299,12 +307,15 @@ uint32_t getCounterMask(); void updatePacketizing(); #endif +#ifndef EIGERD +int64_t getNumFramesLeft(); +int64_t getNumTriggersLeft(); +#endif #if defined(JUNGFRAUD) || defined(MOENCHD) || defined(GOTTHARDD) || \ defined(CHIPTESTBOARDD) || defined(MYTHEN3D) || defined(GOTTHARD2D) int setDelayAfterTrigger(int64_t val); int64_t getDelayAfterTrigger(); -int64_t getNumFramesLeft(); -int64_t getNumTriggersLeft(); + int64_t getDelayAfterTriggerLeft(); int64_t getPeriodLeft(); #endif @@ -337,10 +348,12 @@ int setTrimbits(int *trimbits); int setAllTrimbits(int val); int getAllTrimbits(); #endif +#ifndef XILINX_CHIPTESTBOARDD #ifndef CHIPTESTBOARDD enum detectorSettings setSettings(enum detectorSettings sett); #endif enum detectorSettings getSettings(); +#endif #if defined(JUNGFRAUD) enum gainMode getGainMode(); void setGainMode(enum gainMode mode); @@ -366,10 +379,14 @@ void setDAC(enum DACINDEX ind, int val, int mV, int counterEnableCheck); void setGeneralDAC(enum DACINDEX ind, int val, int mV); void setVthDac(int index, int enable); #else +#ifndef XILINX_CHIPTESTBOARDD void setDAC(enum DACINDEX ind, int val, int mV); #endif +#endif +#ifndef XILINX_CHIPTESTBOARDD int getDAC(enum DACINDEX ind, int mV); int getMaxDacSteps(); +#endif #if defined(CHIPTESTBOARDD) int dacToVoltage(int dac); int checkVLimitCompliant(int mV); @@ -394,14 +411,17 @@ void powerOff(); #if defined(MYTHEN3D) || defined(GOTTHARD2D) int getADC(enum ADCINDEX ind, int *value); #else +#ifndef XILINX_CHIPTESTBOARDD int getADC(enum ADCINDEX ind); #endif +#endif #ifdef CHIPTESTBOARDD int getSlowADC(int ichan); int getSlowADCTemperature(); #endif - +#ifndef XILINX_CHIPTESTBOARDD int setHighVoltage(int val); +#endif // parameters - timing, extsig #if defined(EIGERD) || defined(GOTTHARD2D) || defined(JUNGFRAUD) || \ @@ -674,11 +694,13 @@ int setTransmissionDelayRight(int value); #endif // aquisition +#ifndef XILINX_CHIPTESTBOARDD int startStateMachine(); #ifdef VIRTUAL void *start_timer(void *arg); #endif int stopStateMachine(); +#endif #ifdef MYTHEN3D int softwareTrigger(); #endif @@ -692,8 +714,10 @@ enum runStatus getRunStatus(); #ifdef EIGERD void waitForAcquisitionEnd(int *ret, char *mess); #else +#ifndef XILINX_CHIPTESTBOARDD void waitForAcquisitionEnd(); #endif +#endif #if defined(CHIPTESTBOARDD) int validateUDPSocket(); void readandSendUDPFrames(); @@ -714,11 +738,15 @@ u_int32_t runState(enum TLogLevel lev); #endif // common +#ifndef XILINX_CHIPTESTBOARDD int calculateDataBytes(); int getTotalNumberOfChannels(); -#if defined(CHIPTESTBOARDD) +#endif +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) void getNumberOfChannels(int *nchanx, int *nchany); #endif +#ifndef XILINX_CHIPTESTBOARDD int getNumberOfChips(); int getNumberOfDACs(); int getNumberOfChannelsPerChip(); +#endif \ No newline at end of file diff --git a/slsDetectorServers/slsDetectorServer/src/arm64.c b/slsDetectorServers/slsDetectorServer/src/arm64.c new file mode 100644 index 000000000..8fff6550b --- /dev/null +++ b/slsDetectorServers/slsDetectorServer/src/arm64.c @@ -0,0 +1,73 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "arm64.h" +#include "RegisterDefs.h" +#include "clogger.h" +#include "common.h" +#include "sls/ansi.h" +#include "sls/sls_detector_defs.h" + +#include // open +#include // mmap + +/* global variables */ +#define CSP0 (0xB0010000) +#define MEM_SIZE 0x100000 + +u_int32_t *csp0base = 0; + +void bus_w(u_int32_t offset, u_int32_t data) { + volatile u_int32_t *ptr1; + ptr1 = (u_int32_t *)(csp0base + offset / (sizeof(u_int32_t))); + *ptr1 = data; +} + +u_int32_t bus_r(u_int32_t offset) { + volatile u_int32_t *ptr1; + ptr1 = (u_int32_t *)(csp0base + offset / (sizeof(u_int32_t))); + return *ptr1; +} + +uint64_t getU64BitReg(int aLSB, int aMSB) { + uint64_t retval = bus_r(aMSB); + retval = (retval << 32) | bus_r(aLSB); + return retval; +} + +void setU64BitReg(uint64_t value, int aLSB, int aMSB) { + bus_w(aLSB, value & (0xffffffff)); + bus_w(aMSB, (value >> 32) & (0xffffffff)); +} + +int mapCSP0(void) { + // if not mapped + if (csp0base == 0) { + LOG(logINFO, ("Mapping memory\n")); +#ifdef VIRTUAL + csp0base = malloc(MEM_SIZE); + if (csp0base == NULL) { + LOG(logERROR, ("Could not allocate virtual memory.\n")); + return FAIL; + } + LOG(logINFO, ("memory allocated\n")); +#else + int fd; + fd = open("/dev/mem", O_RDWR | O_SYNC, 0); + if (fd == -1) { + LOG(logERROR, ("Can't find /dev/mem\n")); + return FAIL; + } + LOG(logDEBUG1, ("/dev/mem opened\n")); + csp0base = (u_int32_t *)mmap(0, MEM_SIZE, PROT_READ | PROT_WRITE, + MAP_FILE | MAP_SHARED, fd, CSP0); + if (csp0base == MAP_FAILED) { + LOG(logERROR, ("Can't map memmory area\n")); + return FAIL; + } +#endif + LOG(logINFO, ("csp0base mapped from %p to %p\n", csp0base, + (csp0base + MEM_SIZE))); + } else + LOG(logINFO, ("Memory already mapped before\n")); + return OK; +} diff --git a/slsDetectorServers/slsDetectorServer/src/blackfin.c b/slsDetectorServers/slsDetectorServer/src/blackfin.c index 30bc58937..dc9011b96 100644 --- a/slsDetectorServers/slsDetectorServer/src/blackfin.c +++ b/slsDetectorServers/slsDetectorServer/src/blackfin.c @@ -15,6 +15,11 @@ u_int32_t *csp0base = 0; #define CSP0 0x20200000 #define MEM_SIZE 0x100000 +#ifdef JUNGFRAUD + +extern void configureChip(); +#endif + void bus_w16(u_int32_t offset, u_int16_t data) { volatile u_int16_t *ptr1; ptr1 = (u_int16_t *)(csp0base + offset / 2); @@ -80,7 +85,21 @@ u_int32_t readRegister(u_int32_t offset) { } u_int32_t writeRegister(u_int32_t offset, u_int32_t data) { + // if electron mode bit touched +#ifdef JUNGFRAUD + int electronCollectionModeChange = 0; + if ((offset << MEM_MAP_SHIFT) == DAQ_REG) { + if ((readRegister(offset) ^ data) & DAQ_ELCTRN_CLLCTN_MDE_MSK) { + electronCollectionModeChange = 1; + } + } +#endif bus_w(offset << MEM_MAP_SHIFT, data); +#ifdef JUNGFRAUD + if (electronCollectionModeChange) { + configureChip(); + } +#endif return readRegister(offset); } diff --git a/slsDetectorServers/slsDetectorServer/src/common.c b/slsDetectorServers/slsDetectorServer/src/common.c index 3a00038e3..64784b543 100644 --- a/slsDetectorServers/slsDetectorServer/src/common.c +++ b/slsDetectorServers/slsDetectorServer/src/common.c @@ -114,6 +114,11 @@ int getTimeFromString(char *buf, time_t *result) { t.tm_mday, t.tm_mon, t.tm_year + 1900, t.tm_hour, t.tm_min, t.tm_sec)); *result = mktime(&t); + /* Do not check as it fails with nios + if (*result == (time_t)-1) { + LOG(logERROR, ("Could not convert time structure to time_t\n")); + return FAIL; + }*/ return OK; } @@ -143,14 +148,25 @@ int validateKernelVersion(char *expectedVersion) { #ifdef VIRTUAL strcpy(currentVersion, expectedVersion); #else +#ifndef ARMPROCESSOR // remove first word (#version number) - const char *ptr = strchr(version, ' '); + const char *ptr = strstr(version, " "); if (ptr == NULL) { LOG(logERROR, ("Could not parse kernel version\n")); return FAIL; } - strcpy(currentVersion, version + (ptr - version + 1)); + strcpy(currentVersion, ptr + 1); +#else + // remove first two words (#version number and SMP) + const char *ptr = strstr(version, "SMP "); + if (ptr == NULL) { + LOG(logERROR, ("Could not parse kernel version\n")); + return FAIL; + } + strcpy(currentVersion, ptr + 4); #endif +#endif + currentVersion[sizeof(currentVersion) - 1] = '\0'; // convert kernel date string into time time_t kernelDate; @@ -159,6 +175,7 @@ int validateKernelVersion(char *expectedVersion) { ("Could not parse retrieved kernel date, %s\n", currentVersion)); return FAIL; } + LOG(logDEBUG, ("Kernel Date: [%s]\n", ctime(&kernelDate))); // convert expected date into time time_t expDate; @@ -167,11 +184,12 @@ int validateKernelVersion(char *expectedVersion) { ("Could not parse expected kernel date, %s\n", expectedVersion)); return FAIL; } + LOG(logDEBUG, ("Expected Date: [%s]\n", ctime(&expDate))); // compare if kernel time is older than expected time if (kernelDate < expDate) { - LOG(logERROR, ("Kernel Version Incompatible (too old)! Expected: [%s], " - "Got [%s]\n", + LOG(logERROR, ("Kernel Version Incompatible (too old)!\nExpected: '%s'" + "\nGot : '%s'\n", expectedVersion, currentVersion)); return FAIL; } diff --git a/slsDetectorServers/slsDetectorServer/src/loadPattern.c b/slsDetectorServers/slsDetectorServer/src/loadPattern.c index 1c2e49f04..0cec27019 100644 --- a/slsDetectorServers/slsDetectorServer/src/loadPattern.c +++ b/slsDetectorServers/slsDetectorServer/src/loadPattern.c @@ -13,7 +13,7 @@ extern enum TLogLevel trimmingPrint; #endif -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) #ifdef VIRTUAL uint64_t virtual_pattern[MAX_PATTERN_LENGTH]; #endif @@ -21,8 +21,8 @@ uint64_t virtual_pattern[MAX_PATTERN_LENGTH]; extern void bus_w(u_int32_t offset, u_int32_t data); extern u_int32_t bus_r(u_int32_t offset); -extern int64_t get64BitReg(int aLSB, int aMSB); -extern int64_t set64BitReg(int64_t value, int aLSB, int aMSB); +// extern int64_t get64BitReg(int aLSB, int aMSB); TODO for all servers (only +// uint64_t) extern int64_t set64BitReg(int64_t value, int aLSB, int aMSB); extern uint64_t getU64BitReg(int aLSB, int aMSB); extern void setU64BitReg(uint64_t value, int aLSB, int aMSB); @@ -44,13 +44,15 @@ void initializePatternAddresses() { } } -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) #ifdef VIRTUAL void initializePatternWord() { memset(virtual_pattern, 0, sizeof(virtual_pattern)); } #endif +#endif +#if defined(CHIPTESTBOARDD) // TODO || defined(XILINX_CHIPTESTBOARDD) uint64_t validate_readPatternIOControl() { return getU64BitReg(PATTERN_IO_CNTRL_LSB_REG, PATTERN_IO_CNTRL_MSB_REG); } @@ -101,7 +103,7 @@ uint64_t readPatternWord(int addr) { // the first word in RAM as base plus the offset of the word to write (addr) uint32_t reg_lsb = PATTERN_STEP0_LSB_REG + addr * REG_OFFSET * 2; uint32_t reg_msb = PATTERN_STEP0_MSB_REG + addr * REG_OFFSET * 2; - return get64BitReg(reg_lsb, reg_msb); + return getU64BitReg(reg_lsb, reg_msb); #else LOG(logDEBUG1, (" Reading (Executing) Pattern Word (addr:0x%x)\n", addr)); uint32_t reg = PATTERN_CNTRL_REG; @@ -118,7 +120,7 @@ uint64_t readPatternWord(int addr) { // read value #ifndef VIRTUAL - return get64BitReg(PATTERN_OUT_LSB_REG, PATTERN_OUT_MSB_REG); + return getU64BitReg(PATTERN_OUT_LSB_REG, PATTERN_OUT_MSB_REG); #else return virtual_pattern[addr]; #endif @@ -160,7 +162,7 @@ void writePatternWord(int addr, uint64_t word) { uint32_t reg = PATTERN_CNTRL_REG; // write word - set64BitReg(word, PATTERN_IN_LSB_REG, PATTERN_IN_MSB_REG); + setU64BitReg(word, PATTERN_IN_LSB_REG, PATTERN_IN_MSB_REG); // overwrite with only addr bus_w(reg, ((addr << PATTERN_CNTRL_ADDR_OFST) & PATTERN_CNTRL_ADDR_MSK)); @@ -178,7 +180,7 @@ void writePatternWord(int addr, uint64_t word) { // the first word in RAM as base plus the offset of the word to write (addr) uint32_t reg_lsb = PATTERN_STEP0_LSB_REG + addr * REG_OFFSET * 2; uint32_t reg_msb = PATTERN_STEP0_MSB_REG + addr * REG_OFFSET * 2; - set64BitReg(word, reg_lsb, reg_msb); + setU64BitReg(word, reg_lsb, reg_msb); #endif } @@ -311,24 +313,24 @@ int validate_getPatternWaitTime(char *message, int level, uint64_t *waittime) { uint64_t getPatternWaitTime(int level) { switch (level) { case 0: - return get64BitReg(PATTERN_WAIT_TIMER_0_LSB_REG, - PATTERN_WAIT_TIMER_0_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_0_LSB_REG, + PATTERN_WAIT_TIMER_0_MSB_REG); case 1: - return get64BitReg(PATTERN_WAIT_TIMER_1_LSB_REG, - PATTERN_WAIT_TIMER_1_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_1_LSB_REG, + PATTERN_WAIT_TIMER_1_MSB_REG); case 2: - return get64BitReg(PATTERN_WAIT_TIMER_2_LSB_REG, - PATTERN_WAIT_TIMER_2_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_2_LSB_REG, + PATTERN_WAIT_TIMER_2_MSB_REG); #ifndef MYTHEN3D case 3: - return get64BitReg(PATTERN_WAIT_TIMER_3_LSB_REG, - PATTERN_WAIT_TIMER_3_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_3_LSB_REG, + PATTERN_WAIT_TIMER_3_MSB_REG); case 4: - return get64BitReg(PATTERN_WAIT_TIMER_4_LSB_REG, - PATTERN_WAIT_TIMER_4_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_4_LSB_REG, + PATTERN_WAIT_TIMER_4_MSB_REG); case 5: - return get64BitReg(PATTERN_WAIT_TIMER_5_LSB_REG, - PATTERN_WAIT_TIMER_5_MSB_REG); + return getU64BitReg(PATTERN_WAIT_TIMER_5_LSB_REG, + PATTERN_WAIT_TIMER_5_MSB_REG); #endif default: return -1; @@ -369,29 +371,29 @@ void setPatternWaitTime(int level, uint64_t t) { (long long int)t)); switch (level) { case 0: - set64BitReg(t, PATTERN_WAIT_TIMER_0_LSB_REG, - PATTERN_WAIT_TIMER_0_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_0_LSB_REG, + PATTERN_WAIT_TIMER_0_MSB_REG); break; case 1: - set64BitReg(t, PATTERN_WAIT_TIMER_1_LSB_REG, - PATTERN_WAIT_TIMER_1_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_1_LSB_REG, + PATTERN_WAIT_TIMER_1_MSB_REG); break; case 2: - set64BitReg(t, PATTERN_WAIT_TIMER_2_LSB_REG, - PATTERN_WAIT_TIMER_2_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_2_LSB_REG, + PATTERN_WAIT_TIMER_2_MSB_REG); break; #ifndef MYTHEN3D case 3: - set64BitReg(t, PATTERN_WAIT_TIMER_3_LSB_REG, - PATTERN_WAIT_TIMER_3_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_3_LSB_REG, + PATTERN_WAIT_TIMER_3_MSB_REG); break; case 4: - set64BitReg(t, PATTERN_WAIT_TIMER_4_LSB_REG, - PATTERN_WAIT_TIMER_4_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_4_LSB_REG, + PATTERN_WAIT_TIMER_4_MSB_REG); break; case 5: - set64BitReg(t, PATTERN_WAIT_TIMER_5_LSB_REG, - PATTERN_WAIT_TIMER_5_MSB_REG); + setU64BitReg(t, PATTERN_WAIT_TIMER_5_LSB_REG, + PATTERN_WAIT_TIMER_5_MSB_REG); break; #endif default: @@ -775,7 +777,7 @@ int loadPattern(char *message, enum TLogLevel printLevel, } } // iocontrol -#ifndef MYTHEN3D +#if !defined(MYTHEN3D) && !defined(XILINX_CHIPTESTBOARDD) // TODO if (ret == OK) { ret = validate_writePatternIOControl(message, pat->ioctrl); } @@ -835,7 +837,7 @@ int getPattern(char *message, patternParameters *pat) { pat->word[i] = retval64; } // iocontrol -#ifndef MYTHEN3D +#if !defined(MYTHEN3D) && !defined(XILINX_CHIPTESTBOARDD) // TODO if (ret == OK) { validate_readPatternIOControl(); } @@ -956,7 +958,7 @@ int loadPatternFile(char *patFname, char *errMessage) { uint64_t word = 0; // cannot scan values -#ifdef VIRTUAL +#if defined(VIRTUAL) || defined(XILINX_CHIPTESTBOARDD) if (sscanf(line, "%s 0x%x 0x%lx", command, &addr, &word) != 3) { #else if (sscanf(line, "%s 0x%x 0x%llx", command, &addr, &word) != 3) { @@ -971,7 +973,7 @@ int loadPatternFile(char *patFname, char *errMessage) { } // patioctrl -#ifndef MYTHEN3D +#if !defined(MYTHEN3D) && !defined(XILINX_CHIPTESTBOARDD) // TODO if (!strncmp(line, "patioctrl", strlen("patioctrl"))) { uint64_t arg = 0; @@ -1063,7 +1065,7 @@ int loadPatternFile(char *patFname, char *errMessage) { uint64_t waittime = 0; // cannot scan values -#ifdef VIRTUAL +#if defined(VIRTUAL) || defined(XILINX_CHIPTESTBOARDD) if (sscanf(line, "%s %d %ld", command, &level, &waittime) != 3) { #else if (sscanf(line, "%s %d %lld", command, &level, &waittime) != 3) { diff --git a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c index 9cbc8b4da..2bd34870b 100644 --- a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c +++ b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c @@ -7,7 +7,8 @@ #include "sls/sls_detector_funcs.h" #include "slsDetectorFunctionList.h" -#if defined(CHIPTESTBOARDD) || defined(MYTHEN3D) +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) || \ + defined(MYTHEN3D) #include "Pattern.h" #include "loadPattern.h" #endif @@ -33,6 +34,8 @@ const enum detectorType myDetectorType = MOENCH; const enum detectorType myDetectorType = MYTHEN3; #elif GOTTHARD2D const enum detectorType myDetectorType = GOTTHARD2; +#elif XILINX_CHIPTESTBOARDD +const enum detectorType myDetectorType = XILINX_CHIPTESTBOARD; #else const enum detectorType myDetectorType = GENERIC; #endif @@ -532,6 +535,11 @@ int executeCommand(char *command, char *result, enum TLogLevel level) { fflush(stdout); FILE *sysFile = popen(cmd, "r"); + if (sysFile == NULL) { + ret = FAIL; + sprintf(mess, "Executing cmd[%s] failed\n", cmd); + return ret; + } while (fgets(temp, tempsize, sysFile) != NULL) { // size left excludes terminating character size_t sizeleft = MAX_STR_LENGTH - strlen(result) - 1; @@ -547,17 +555,15 @@ int executeCommand(char *command, char *result, enum TLogLevel level) { if (strlen(result) == 0) { strcpy(result, "No result"); } - - int retval = OK; int success = pclose(sysFile); - if (success) { - retval = FAIL; - LOG(logERROR, ("Executing cmd[%s]:%s\n", cmd, result)); + if (success == -1) { + ret = FAIL; + strcpy(mess, result); + LOG(logERROR, ("Executing cmd[%s] failed:%s\n", cmd, mess)); } else { LOG(level, ("Result:\n[%s]\n", result)); } - - return retval; + return ret; } int M_nofunc(int file_des) { @@ -585,7 +591,7 @@ int exec_command(int file_des) { // set if (Server_VerifyLock() == OK) { - ret = executeCommand(cmd, retval, logINFO); + executeCommand(cmd, retval, logINFO); } return Server_SendResult(file_des, OTHER, retval, sizeof(retval)); } @@ -784,7 +790,7 @@ int get_serial_number(int file_des) { ret = OK; memset(mess, 0, sizeof(mess)); int64_t retval = -1; -#ifdef EIGERD +#if defined(EIGERD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else retval = getDetectorNumber(); @@ -1116,6 +1122,8 @@ enum DACINDEX getDACIndex(enum dacIndex ind) { case IBIAS_SFP: serverDacIndex = MO_IBIAS_SFP; break; +#elif XILINX_CHIPTESTBOARDD + #endif default: @@ -1134,8 +1142,9 @@ enum DACINDEX getDACIndex(enum dacIndex ind) { int validateAndSetDac(enum dacIndex ind, int val, int mV) { int retval = -1; - enum DACINDEX serverDacIndex = 0; +#ifndef XILINX_CHIPTESTBOARDD + enum DACINDEX serverDacIndex = 0; // valid enums switch (ind) { case HIGH_VOLTAGE: @@ -1386,6 +1395,7 @@ int validateAndSetDac(enum dacIndex ind, int val, int mV) { #endif break; } +#endif return retval; } @@ -1398,6 +1408,9 @@ int set_dac(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else enum dacIndex ind = args[0]; int mV = args[1]; int val = args[2]; @@ -1408,6 +1421,7 @@ int set_dac(int file_des) { if ((val == GET_FLAG) || (Server_VerifyLock() == OK)) { retval = validateAndSetDac(ind, val, mV); } +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -1420,6 +1434,9 @@ int get_adc(int file_des) { if (receiveData(file_des, &ind, sizeof(ind), INT32) < 0) return printSocketReadError(); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else enum ADCINDEX serverAdcIndex = 0; // get @@ -1541,6 +1558,7 @@ int get_adc(int file_des) { LOG(logDEBUG1, ("ADC(%d): %d\n", serverAdcIndex, retval)); #endif } +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -1557,6 +1575,9 @@ int write_register(int file_des) { uint32_t val = args[1]; LOG(logDEBUG1, ("Writing to register 0x%x, data 0x%x\n", addr, val)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { #ifdef GOTTHARDD @@ -1591,6 +1612,7 @@ int write_register(int file_des) { } LOG(logDEBUG1, ("Write register (0x%x): 0x%x\n", retval)); } +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -1605,6 +1627,10 @@ int read_register(int file_des) { LOG(logDEBUG1, ("Reading from register 0x%x\n", addr)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else + // get #ifdef GOTTHARDD retval = readRegister16And32(addr); @@ -1621,7 +1647,7 @@ int read_register(int file_des) { retval = readRegister(addr); #endif LOG(logINFO, ("Read register (0x%x): 0x%x\n", addr, retval)); - +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -1825,7 +1851,7 @@ int set_settings(int file_des) { if (receiveData(file_des, &isett, sizeof(isett), INT32) < 0) return printSocketReadError(); -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else LOG(logDEBUG1, ("Setting settings %d\n", isett)); @@ -1902,6 +1928,9 @@ int acquire(int blocking, int file_des) { } else { LOG(logINFOBLUE, ("Unblocking Acquisition\n")); } +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { #if defined(JUNGFRAUD) @@ -1948,64 +1977,64 @@ int acquire(int blocking, int file_des) { #ifdef EIGERD // check for hardware mac and hardware ip if (udpDetails[0].srcmac != getDetectorMAC()) { - ret = FAIL; - uint64_t sourcemac = getDetectorMAC(); - char src_mac[MAC_ADDRESS_SIZE]; - getMacAddressinString(src_mac, MAC_ADDRESS_SIZE, sourcemac); - sprintf( - mess, + ret = FAIL; + uint64_t sourcemac = getDetectorMAC(); + char src_mac[MAC_ADDRESS_SIZE]; + getMacAddressinString(src_mac, MAC_ADDRESS_SIZE, sourcemac); + sprintf(mess, "Invalid udp source mac address for this detector. Must be " "same as hardware detector mac address %s\n", src_mac); - LOG(logERROR, (mess)); - } else if (!enableTenGigabitEthernet(GET_FLAG) && - (udpDetails[0].srcip != getDetectorIP())) { - ret = FAIL; - uint32_t sourceip = getDetectorIP(); - char src_ip[INET_ADDRSTRLEN]; - getIpAddressinString(src_ip, sourceip); - sprintf( - mess, + LOG(logERROR, (mess)); + } else if (!enableTenGigabitEthernet(GET_FLAG) && + (udpDetails[0].srcip != getDetectorIP())) { + ret = FAIL; + uint32_t sourceip = getDetectorIP(); + char src_ip[INET_ADDRSTRLEN]; + getIpAddressinString(src_ip, sourceip); + sprintf(mess, "Invalid udp source ip address for this detector. Must be " "same as hardware detector ip address %s in 1G readout " "mode \n", src_ip); - LOG(logERROR, (mess)); - } else + LOG(logERROR, (mess)); + } else #endif - if (configured == FAIL) { + if (configured == FAIL) { + ret = FAIL; + strcpy(mess, "Could not start acquisition because "); + strcat(mess, configureMessage); + LOG(logERROR, (mess)); + } else if (sharedMemory_getScanStatus() == RUNNING) { + ret = FAIL; + strcpy(mess, "Could not start acquisition because a scan is " + "already running!\n"); + LOG(logERROR, (mess)); + } else { + memset(scanErrMessage, 0, MAX_STR_LENGTH); + sharedMemory_setScanStop(0); + sharedMemory_setScanStatus(IDLE); // if it was error + if (pthread_create(&pthread_tid, NULL, &start_state_machine, + &blocking)) { ret = FAIL; - strcpy(mess, "Could not start acquisition because "); - strcat(mess, configureMessage); - LOG(logERROR, (mess)); - } else if (sharedMemory_getScanStatus() == RUNNING) { - ret = FAIL; - strcpy(mess, "Could not start acquisition because a scan is " - "already running!\n"); + strcpy(mess, "Could not start acquisition thread!\n"); LOG(logERROR, (mess)); } else { - memset(scanErrMessage, 0, MAX_STR_LENGTH); - sharedMemory_setScanStop(0); - sharedMemory_setScanStatus(IDLE); // if it was error - if (pthread_create(&pthread_tid, NULL, &start_state_machine, - &blocking)) { - ret = FAIL; - strcpy(mess, "Could not start acquisition thread!\n"); - LOG(logERROR, (mess)); - } else { - // wait for blocking always (scan or not) - // non blocking-no scan also wait (for error message) - // non blcoking-scan dont wait (there is scanErrorMessage) - if (blocking || !scan) { - pthread_join(pthread_tid, NULL); - } + // wait for blocking always (scan or not) + // non blocking-no scan also wait (for error message) + // non blcoking-scan dont wait (there is scanErrorMessage) + if (blocking || !scan) { + pthread_join(pthread_tid, NULL); } } + } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } void *start_state_machine(void *arg) { +#ifndef XILINX_CHIPTESTBOARDD int *blocking = (int *)arg; int times = 1; // start of scan @@ -2131,6 +2160,7 @@ void *start_state_machine(void *arg) { if (scan && sharedMemory_getScanStatus() != ERROR) { sharedMemory_setScanStatus(IDLE); } +#endif return NULL; } @@ -2148,6 +2178,9 @@ int stop_acquisition(int file_des) { memset(mess, 0, sizeof(mess)); LOG(logDEBUG1, ("Stopping Acquisition\n")); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { ret = stopStateMachine(); @@ -2157,6 +2190,7 @@ int stop_acquisition(int file_des) { } LOG(logDEBUG1, ("Stopping Acquisition ret: %d\n", ret)); } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -2166,9 +2200,13 @@ int get_run_status(int file_des) { enum runStatus retval = ERROR; LOG(logDEBUG1, ("Getting status\n")); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only get retval = getRunStatus(); LOG(logDEBUG1, ("Status: %d\n", retval)); +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -2446,6 +2484,9 @@ int get_exptime(int file_des) { if (receiveData(file_des, &gateIndex, sizeof(gateIndex), INT32) < 0) return printSocketReadError(); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only #ifdef MYTHEN3D if (gateIndex < 0 || gateIndex > 2) { @@ -2469,6 +2510,7 @@ int get_exptime(int file_des) { retval = getExpTime(); LOG(logDEBUG1, ("retval exptime %lld ns\n", (long long int)retval)); } +#endif #endif return Server_SendResult(file_des, INT64, &retval, sizeof(retval)); } @@ -2485,6 +2527,9 @@ int set_exptime(int file_des) { LOG(logDEBUG1, ("Setting exptime %lld ns (gateIndex:%d)\n", (long long int)val, gateIndex)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { #ifdef MYTHEN3D @@ -2532,7 +2577,7 @@ int set_exptime(int file_des) { if (gateIndex != -1) { ret = FAIL; sprintf(mess, - "Could not get exposure time. Gate index not implemented " + "Could not set exposure time. Gate index not implemented " "for this detector\n"); LOG(logERROR, (mess)); } else { @@ -2549,6 +2594,7 @@ int set_exptime(int file_des) { } #endif } +#endif return Server_SendResult(file_des, INT64, NULL, 0); } @@ -2557,9 +2603,13 @@ int get_period(int file_des) { memset(mess, 0, sizeof(mess)); int64_t retval = -1; +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = getPeriod(); LOG(logDEBUG1, ("retval period %lld ns\n", (long long int)retval)); +#endif return Server_SendResult(file_des, INT64, &retval, sizeof(retval)); } @@ -2572,6 +2622,9 @@ int set_period(int file_des) { return printSocketReadError(); LOG(logDEBUG1, ("Setting period %lld ns\n", (long long int)arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { ret = setPeriod(arg); @@ -2583,6 +2636,7 @@ int set_period(int file_des) { LOG(logERROR, (mess)); } } +#endif return Server_SendResult(file_des, INT64, NULL, 0); } @@ -2824,7 +2878,8 @@ int get_frames_left(int file_des) { int64_t retval = -1; #if !defined(JUNGFRAUD) && !defined(MOENCHD) && !defined(GOTTHARDD) && \ - !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) && !defined(GOTTHARD2D) + !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) && !defined(GOTTHARD2D) && \ + !defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // get only @@ -2840,7 +2895,8 @@ int get_triggers_left(int file_des) { int64_t retval = -1; #if !defined(JUNGFRAUD) && !defined(MOENCHD) && !defined(GOTTHARDD) && \ - !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) && !defined(GOTTHARD2D) + !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) && !defined(GOTTHARD2D) && \ + !defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // get only @@ -3010,7 +3066,8 @@ int set_dynamic_range(int file_des) { case 32: #endif #if defined(GOTTHARDD) || defined(JUNGFRAUD) || defined(MOENCHD) || \ - defined(CHIPTESTBOARDD) || defined(GOTTHARD2D) + defined(CHIPTESTBOARDD) || defined(GOTTHARD2D) || \ + defined(XILINX_CHIPTESTBOARDD) case 16: #endif if (dr >= 0) { @@ -3152,7 +3209,7 @@ int enable_ten_giga(int file_des) { LOG(logDEBUG, ("Setting 10GbE: %d\n", arg)); #if defined(JUNGFRAUD) || defined(MOENCHD) || defined(GOTTHARDD) || \ - defined(GOTTHARD2D) + defined(GOTTHARD2D) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // set & get @@ -3283,7 +3340,8 @@ int set_pattern_word(int file_des) { if (receiveData(file_des, args, sizeof(args), INT64) < 0) return printSocketReadError(); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else int addr = (int)args[0]; @@ -3311,7 +3369,8 @@ int set_pattern_loop_addresses(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else int loopLevel = args[0]; @@ -3357,7 +3416,8 @@ int set_pattern_loop_cycles(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else int loopLevel = args[0]; @@ -3386,7 +3446,8 @@ int set_pattern_wait_addr(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else int loopLevel = args[0]; @@ -3415,7 +3476,8 @@ int set_pattern_wait_time(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else int loopLevel = (int)args[0]; @@ -3445,7 +3507,8 @@ int set_pattern_mask(int file_des) { return printSocketReadError(); LOG(logDEBUG1, ("Set Pattern Mask to %d\n", arg)); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else // only set @@ -3473,7 +3536,8 @@ int get_pattern_mask(int file_des) { LOG(logDEBUG1, ("Get Pattern Mask\n")); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else // only get @@ -3494,7 +3558,8 @@ int set_pattern_bit_mask(int file_des) { return printSocketReadError(); LOG(logDEBUG1, ("Set Pattern Bit Mask to %d\n", arg)); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else // only set @@ -3523,7 +3588,8 @@ int get_pattern_bit_mask(int file_des) { LOG(logDEBUG1, ("Get Pattern Bit Mask\n")); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else // only get @@ -3546,7 +3612,8 @@ int write_adc_register(int file_des) { uint32_t val = args[1]; LOG(logDEBUG1, ("Writing 0x%x to ADC Register 0x%x\n", val, addr)); -#if defined(EIGERD) || defined(GOTTHARD2D) || defined(MYTHEN3D) +#if defined(EIGERD) || defined(GOTTHARD2D) || defined(MYTHEN3D) || \ + defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else #ifndef VIRTUAL @@ -3941,7 +4008,7 @@ int reset_fpga(int file_des) { LOG(logDEBUG1, ("Reset FPGA\n")); #if defined(EIGERD) || defined(GOTTHARDD) || defined(GOTTHARD2D) || \ - defined(MYTHEN3D) + defined(MYTHEN3D) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // only set @@ -4321,7 +4388,7 @@ int reboot_controller(int file_des) { ret = OK; memset(mess, 0, sizeof(mess)); -#ifdef EIGERD +#if defined(EIGERD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #elif VIRTUAL ret = GOODBYE; @@ -4771,7 +4838,8 @@ int set_read_n_rows(int file_des) { functionNotImplemented(); #else // only set - if (Server_VerifyLock() == OK) { + if ((Server_VerifyLock() == OK) && + (check_detector_idle("set number of rows") == OK)) { if (arg < MIN_ROWS_PER_READOUT || arg > MAX_ROWS_PER_READOUT) { ret = FAIL; sprintf(mess, @@ -4803,8 +4871,7 @@ int set_read_n_rows(int file_des) { LOG(logERROR, (mess)); } else #elif defined(JUNGFRAUD) || defined(MOENCHD) - if ((check_detector_idle("set number of rows") == OK) && - (arg % READ_N_ROWS_MULTIPLE != 0)) { + if (arg % READ_N_ROWS_MULTIPLE != 0) { ret = FAIL; sprintf(mess, "Could not set number of rows. %d must be a multiple " @@ -5079,6 +5146,9 @@ int set_source_udp_ip(int file_des) { arg = __builtin_bswap32(arg); LOG(logINFO, ("Setting udp source ip: 0x%x\n", arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (check_detector_idle("configure mac") == OK) { @@ -5091,6 +5161,7 @@ int set_source_udp_ip(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -5100,11 +5171,14 @@ int get_source_udp_ip(int file_des) { uint32_t retval = -1; LOG(logDEBUG1, ("Getting udp source ip\n")); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = udpDetails[0].srcip; retval = __builtin_bswap32(retval); LOG(logDEBUG1, ("udp soure ip retval: 0x%x\n", retval)); - +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -5164,6 +5238,9 @@ int set_dest_udp_ip(int file_des) { arg = __builtin_bswap32(arg); LOG(logINFO, ("Setting udp destination ip: 0x%x\n", arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (check_detector_idle("configure mac") == OK) { @@ -5173,6 +5250,7 @@ int set_dest_udp_ip(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -5182,11 +5260,14 @@ int get_dest_udp_ip(int file_des) { uint32_t retval = -1; LOG(logDEBUG1, ("Getting destination ip\n")); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = udpDetails[0].dstip; retval = __builtin_bswap32(retval); LOG(logDEBUG1, ("udp destination ip retval: 0x%x\n", retval)); - +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -5242,6 +5323,9 @@ int set_source_udp_mac(int file_des) { return printSocketReadError(); LOG(logINFO, ("Setting udp source mac: 0x%lx\n", arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (check_detector_idle("configure mac") == OK) { @@ -5263,6 +5347,7 @@ int set_source_udp_mac(int file_des) { } } } +#endif return Server_SendResult(file_des, INT64, NULL, 0); } @@ -5271,11 +5356,13 @@ int get_source_udp_mac(int file_des) { memset(mess, 0, sizeof(mess)); uint64_t retval = -1; LOG(logDEBUG1, ("Getting udp source mac\n")); - +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = udpDetails[0].srcmac; LOG(logDEBUG1, ("udp soure mac retval: 0x%lx\n", retval)); - +#endif return Server_SendResult(file_des, INT64, &retval, sizeof(retval)); } @@ -5332,6 +5419,9 @@ int set_dest_udp_mac(int file_des) { return printSocketReadError(); LOG(logINFO, ("Setting udp destination mac: 0x%lx\n", arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (check_detector_idle("configure mac") == OK) { @@ -5341,6 +5431,7 @@ int set_dest_udp_mac(int file_des) { } } } +#endif return Server_SendResult(file_des, INT64, NULL, 0); } @@ -5349,11 +5440,13 @@ int get_dest_udp_mac(int file_des) { memset(mess, 0, sizeof(mess)); uint64_t retval = -1; LOG(logDEBUG1, ("Getting udp destination mac\n")); - +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = udpDetails[0].dstmac; LOG(logDEBUG1, ("udp destination mac retval: 0x%lx\n", retval)); - +#endif return Server_SendResult(file_des, INT64, &retval, sizeof(retval)); } @@ -5407,6 +5500,9 @@ int set_dest_udp_port(int file_des) { return printSocketReadError(); LOG(logINFO, ("Setting udp destination port: %hu\n", arg)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (check_detector_idle("configure mac") == OK) { @@ -5416,6 +5512,7 @@ int set_dest_udp_port(int file_des) { } } } +#endif return Server_SendResult(file_des, INT16, NULL, 0); } @@ -5424,11 +5521,13 @@ int get_dest_udp_port(int file_des) { memset(mess, 0, sizeof(mess)); uint16_t retval = -1; LOG(logDEBUG1, ("Getting destination port")); - +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // get only retval = udpDetails[0].dstport; LOG(logDEBUG, ("udp destination port retval: %hu\n", retval)); - +#endif return Server_SendResult(file_des, INT16, &retval, sizeof(retval)); } @@ -5484,7 +5583,8 @@ int set_num_interfaces(int file_des) { return printSocketReadError(); LOG(logINFO, ("Setting number of interfaces: %d\n", arg)); -#if !defined(JUNGFRAUD) && !defined(MOENCHD) && !defined(GOTTHARD2D) +#if !defined(JUNGFRAUD) && !defined(MOENCHD) && !defined(GOTTHARD2D) && \ + !defined(XLINX_CHIPTESTBOARDD) // fixed number of udp interfaces int num_interfaces = getNumberofUDPInterfaces(); if (arg != num_interfaces) { @@ -5556,7 +5656,6 @@ int get_num_interfaces(int file_des) { // get only retval = getNumberofUDPInterfaces(); - LOG(logDEBUG1, ("Number of udp interfaces retval: %u\n", retval)); return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } @@ -6987,7 +7086,7 @@ int get_num_channels(int file_des) { LOG(logDEBUG1, ("Getting number of channels\n")); -#if !defined(CHIPTESTBOARDD) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // get only @@ -7019,6 +7118,10 @@ int get_receiver_parameters(int file_des) { memset(mess, 0, sizeof(mess)); LOG(logDEBUG1, ("Getting receiver parameters\n")); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); + Server_SendResult(file_des, INT32, NULL, 0); +#else // get only Server_SendResult(file_des, INT32, NULL, 0); @@ -7476,7 +7579,7 @@ int get_receiver_parameters(int file_des) { return printSocketReadError(); LOG(logINFO, ("Sent %d bytes for receiver parameters\n", n)); - +#endif return OK; } @@ -7705,7 +7808,8 @@ int set_pattern(int file_des) { char args[MAX_STR_LENGTH]; memset(args, 0, MAX_STR_LENGTH); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else @@ -7742,7 +7846,8 @@ int get_pattern_file(int file_des) { LOG(logDEBUG1, ("Getting pattern file name\n")); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); #else // get only @@ -7756,7 +7861,8 @@ int get_pattern(int file_des) { ret = OK; memset(mess, 0, sizeof(mess)); -#if !defined(CHIPTESTBOARDD) && !defined(MYTHEN3D) +#if !defined(CHIPTESTBOARDD) && !defined(XILINX_CHIPTESTBOARDD) && \ + !defined(MYTHEN3D) functionNotImplemented(); return Server_SendResult(file_des, INT32, NULL, 0); #else @@ -7818,6 +7924,9 @@ int set_scan(int file_des) { if (receiveData(file_des, &dacTime, sizeof(dacTime), INT64) < 0) return printSocketReadError(); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { int enable = args[0]; @@ -7907,6 +8016,7 @@ int set_scan(int file_des) { } } } +#endif return Server_SendResult(file_des, INT64, &retval, sizeof(retval)); } @@ -8264,6 +8374,9 @@ int reconfigure_udp(int file_des) { ret = OK; memset(mess, 0, sizeof(mess)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else if (Server_VerifyLock() == OK) { LOG(logINFO, ("Reconfiguring UDP\n")); if (check_detector_idle("configure mac") == OK) { @@ -8276,6 +8389,7 @@ int reconfigure_udp(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -8376,7 +8490,7 @@ int reset_to_default_dacs(int file_des) { return printSocketReadError(); LOG(logDEBUG1, ("Resetting dacs to defaults (hard reset: %d)\n", arg)); -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else if (Server_VerifyLock() == OK) { @@ -8471,9 +8585,9 @@ int set_master(int file_des) { functionNotImplemented(); #else // only set - if (Server_VerifyLock() == OK) { - if ((check_detector_idle("set master") == OK) && - (arg != 0 && arg != 1)) { + if ((Server_VerifyLock() == OK) && + (check_detector_idle("set master") == OK)) { + if (arg != 0 && arg != 1) { ret = FAIL; sprintf(mess, "Could not set master. Invalid argument %d.\n", arg); LOG(logERROR, (mess)); @@ -8791,7 +8905,7 @@ int get_default_dac(int file_des) { LOG(logDEBUG1, ("Getting default dac [dacindex:%d, settings: %d]\n", dacindex, sett)); -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // get only @@ -8831,7 +8945,7 @@ int set_default_dac(int file_des) { LOG(logDEBUG1, ("Setting default dac [dacindex: %d, settings: %d] to %d\n", (int)dacindex, (int)sett, value)); -#ifdef CHIPTESTBOARDD +#if defined(CHIPTESTBOARDD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); #else // only set @@ -9027,9 +9141,9 @@ int set_flip_rows(int file_des) { functionNotImplemented(); #else // only set - if (Server_VerifyLock() == OK) { - if ((check_detector_idle("set flip rows") == OK) && - (arg != 0 && arg != 1)) { + if ((Server_VerifyLock() == OK) && + (check_detector_idle("set flip rows") == OK)) { + if (arg != 0 && arg != 1) { ret = FAIL; sprintf(mess, "Could not set flip rows. Invalid argument %d.\n", arg); @@ -9451,6 +9565,11 @@ int clear_all_udp_dst(int file_des) { memset(mess, 0, sizeof(mess)); LOG(logINFO, ("Clearing all udp destinations\n")); + +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else + if (Server_VerifyLock() == OK) { if (check_detector_idle("clear all udp destinations") == OK) { memset(udpDetails, 0, sizeof(udpDetails)); @@ -9478,6 +9597,7 @@ int clear_all_udp_dst(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -9636,7 +9756,7 @@ int get_kernel_version(int file_des) { int update_kernel(int file_des) { ret = OK; memset(mess, 0, sizeof(mess)); -#ifdef EIGERD +#if defined(EIGERD) || defined(XILINX_CHIPTESTBOARDD) functionNotImplemented(); return Server_SendResult(file_des, INT32, NULL, 0); #else @@ -9688,7 +9808,8 @@ int receive_program(int file_des, enum PROGRAM_INDEX index) { LOG(logINFO, ("\tServer Name: %s\n", serverName)); } -#if !defined(GOTTHARD2D) && !defined(MYTHEN3D) && !defined(EIGERD) +#if !defined(GOTTHARD2D) && !defined(MYTHEN3D) && !defined(EIGERD) && \ + !defined(XILINX_CHIPTESTBOARDD) int forceDeleteNormalFile = 0; if (receiveData(file_des, &forceDeleteNormalFile, sizeof(forceDeleteNormalFile), INT32) < 0) @@ -9724,7 +9845,8 @@ int receive_program(int file_des, enum PROGRAM_INDEX index) { } if (ret == OK) { -#if defined(GOTTHARD2D) || defined(MYTHEN3D) || defined(EIGERD) +#if defined(GOTTHARD2D) || defined(MYTHEN3D) || defined(EIGERD) || \ + defined(XILINX_CHIPTESTBOARDD) receive_program_default(file_des, index, functionType, filesize, checksum, serverName); #else @@ -9870,7 +9992,8 @@ void receive_program_via_blackfin(int file_des, enum PROGRAM_INDEX index, void receive_program_default(int file_des, enum PROGRAM_INDEX index, char *functionType, uint64_t filesize, char *checksum, char *serverName) { -#if !defined(GOTTHARD2D) && !defined(MYTHEN3D) && !defined(EIGERD) +#if !defined(GOTTHARD2D) && !defined(MYTHEN3D) && !defined(EIGERD) && \ + !defined(XILINX_CHIPTESTBOARDD) ret = FAIL; sprintf(mess, "Could not %s. program via blackfin not implmented for this " @@ -10364,9 +10487,9 @@ int set_synchronization(int file_des) { functionNotImplemented(); #else // only set - if (Server_VerifyLock() == OK) { - if ((check_detector_idle("set synchronization") == OK) && - (arg != 0 && arg != 1)) { + if ((Server_VerifyLock() == OK) && + (check_detector_idle("set synchronization") == OK)) { + if (arg != 0 && arg != 1) { ret = FAIL; sprintf(mess, "Could not set synchronization. Invalid argument %d.\n", @@ -10388,8 +10511,10 @@ int get_hardware_version(int file_des) { memset(mess, 0, sizeof(mess)); char retvals[MAX_STR_LENGTH]; memset(retvals, 0, MAX_STR_LENGTH); + getHardwareVersion(retvals); LOG(logDEBUG1, ("hardware version retval: %s\n", retvals)); + return Server_SendResult(file_des, OTHER, retvals, sizeof(retvals)); } @@ -10442,6 +10567,10 @@ int set_bit(int file_des) { int nBit = (int)args[1]; LOG(logDEBUG1, ("Setting bit %d of reg 0x%x\n", nBit, addr)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else + // only set if (Server_VerifyLock() == OK) { if (nBit < 0 || nBit > 31) { @@ -10472,6 +10601,7 @@ int set_bit(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -10486,6 +10616,9 @@ int clear_bit(int file_des) { int nBit = (int)args[1]; LOG(logDEBUG1, ("Clearing bit %d of reg 0x%x\n", nBit, addr)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else // only set if (Server_VerifyLock() == OK) { if (nBit < 0 || nBit > 31) { @@ -10516,6 +10649,7 @@ int clear_bit(int file_des) { } } } +#endif return Server_SendResult(file_des, INT32, NULL, 0); } @@ -10531,6 +10665,9 @@ int get_bit(int file_des) { int nBit = (int)args[1]; LOG(logDEBUG1, ("Getting bit %d of reg 0x%x\n", nBit, addr)); +#ifdef XILINX_CHIPTESTBOARDD + functionNotImplemented(); +#else if (nBit < 0 || nBit > 31) { ret = FAIL; sprintf(mess, @@ -10555,6 +10692,7 @@ int get_bit(int file_des) { LOG(logDEBUG1, ("regval: 0x%x bit value:0%d\n", regval, retval)); #endif } +#endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); } diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/CMakeLists.txt b/slsDetectorServers/xilinx_ctbDetectorServer/CMakeLists.txt new file mode 100644 index 000000000..2f93c61f8 --- /dev/null +++ b/slsDetectorServers/xilinx_ctbDetectorServer/CMakeLists.txt @@ -0,0 +1,39 @@ +# SPDX-License-Identifier: LGPL-3.0-or-other +# Copyright (C) 2021 Contributors to the SLS Detector Package +add_executable(xilinx_ctbDetectorServer_virtual + slsDetectorFunctionList.c + ../slsDetectorServer/src/slsDetectorServer.c + ../slsDetectorServer/src/slsDetectorServer_funcs.c + ../slsDetectorServer/src/communication_funcs.c + ../slsDetectorServer/src/arm64.c + ../slsDetectorServer/src/common.c + ../slsDetectorServer/src/sharedMemory.c + ../slsDetectorServer/src/loadPattern.c + ../../slsSupportLib/src/md5.c +) + +include_directories( + ../slsDetectorServer/include + ../../slsSupportLib/include + ../../slsDetectorSoftware/include/sls/ +) + +target_include_directories(xilinx_ctbDetectorServer_virtual + PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} +) + +target_compile_definitions(xilinx_ctbDetectorServer_virtual + PUBLIC XILINX_CHIPTESTBOARDD ARMPROCESSOR VIRTUAL STOP_SERVER +) + +target_link_libraries(xilinx_ctbDetectorServer_virtual + PUBLIC pthread rt slsProjectCSettings +) + +set_target_properties(xilinx_ctbDetectorServer_virtual PROPERTIES + RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin +) + +install(TARGETS xilinx_ctbDetectorServer_virtual + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} +) diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/Makefile b/slsDetectorServers/xilinx_ctbDetectorServer/Makefile new file mode 100755 index 000000000..e5e3a6b54 --- /dev/null +++ b/slsDetectorServers/xilinx_ctbDetectorServer/Makefile @@ -0,0 +1,47 @@ +# SPDX-License-Identifier: LGPL-3.0-or-other +# Copyright (C) 2021 Contributors to the SLS Detector Package +current_dir = $(shell pwd) +main_inc = ../slsDetectorServer/include/ +main_src = ../slsDetectorServer/src/ +support_lib = ../../slsSupportLib/include/ +det_lib = ../../slsDetectorSoftware/include/sls/ +md5_dir = ../../slsSupportLib/src/ + +CROSS = aarch64-none-linux-gnu- +CC = $(CROSS)gcc +#TODO: allow these warnings and fix code +CFLAGS += -Wall -std=gnu99 -Wno-format-overflow -Wno-format-truncation -DXILINX_CHIPTESTBOARDD -DARMPROCESSOR -DSTOP_SERVER -I$(main_inc) -I$(support_lib) -I$(det_lib) -I$(current_dir) #-DDEBUG1 #-DVERBOSEI #-DVERBOSE +#CFLAGS += -Wall -std=gnu99 -DXILINX_CHIPTESTBOARDD -DARMPROCESSOR -DSTOP_SERVER -I$(main_inc) -I$(support_lib) -I$(det_lib) -I$(current_dir) #-DDEBUG1 #-DVERBOSEI #-DVERBOSE +LDLIBS += -lm -lrt -pthread +PROGS = xilinx_ctbDetectorServer +DESTDIR ?= bin +INSTMODE = 0777 + +SRCS = slsDetectorFunctionList.c +SRCS += $(main_src)slsDetectorServer.c $(main_src)slsDetectorServer_funcs.c $(main_src)communication_funcs.c $(main_src)arm64.c $(main_src)common.c $(main_src)/sharedMemory.c $(main_src)/loadPattern.c $(md5_dir)md5.c + +OBJS = $(SRCS:.c=.o) + +all: clean $(PROGS) +version: clean versioning $(PROGS) + +boot: $(OBJS) + +version_branch=$(API_BRANCH) +version_name=APIXILINXCTB +version_path=slsDetectorServers/xilinx_ctbDetectorServer +versioning: + cd ../../ && echo $(PWD) && echo `tput setaf 6; ./updateAPIVersion.sh $(version_name) $(version_path) $(version_branch); tput sgr0;` + + +$(PROGS): $(OBJS) +# echo $(OBJS) + mkdir -p $(DESTDIR) + $(CC) -o $@ $^ $(CFLAGS) $(LDLIBS) + mv $(PROGS) $(DESTDIR) + rm $(main_src)*.o $(md5_dir)*.o +clean: + rm -rf $(DESTDIR)/$(PROGS) *.o *.gdb $(main_src)*.o $(md5_dir)*.o + + + diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/RegisterDefs.h b/slsDetectorServers/xilinx_ctbDetectorServer/RegisterDefs.h new file mode 100644 index 000000000..6055a2c94 --- /dev/null +++ b/slsDetectorServers/xilinx_ctbDetectorServer/RegisterDefs.h @@ -0,0 +1,968 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#pragma once + +#define CTRLREG1 (0x0) + +#define CTRLREG2 (0x4) + +#define STATUSREG1 (0x8) + +#define STATUSREG2 (0xC) + +#define FPGAVERSIONREG (0x10) + +#define COMPDATE_OFST (0) +#define COMPDATE_MSK (0x00ffffff << COMPDATE_OFST) +#define DETTYPE_OFST (24) +#define DETTYPE_MSK (0x000000ff << DETTYPE_OFST) + +#define EMPTY14REG (0x14) + +#define EMPTY18REG (0x18) + +#define EMPTY1CREG (0x1C) + +#define EMPTY20REG (0x20) + +#define EMPTY24REG (0x24) + +#define PKTPACKETLENGTHREG (0x28) + +#define PACKETLENGTH1G_OFST (0) +#define PACKETLENGTH1G_MSK (0x0000ffff << PACKETLENGTH1G_OFST) +#define PACKETLENGTH10G_OFST (16) +#define PACKETLENGTH10G_MSK (0x0000ffff << PACKETLENGTH10G_OFST) + +#define EMPTY2CREG (0x2C) + +#define PKTNOPACKETSREG (0x30) + +#define NOPACKETS1G_OFST (0) +#define NOPACKETS1G_MSK (0x0000003f << NOPACKETS1G_OFST) +#define NOPACKETS10G_OFST (16) +#define NOPACKETS10G_MSK (0x0000003f << NOPACKETS10G_OFST) + +#define EMPTY34REG (0x34) + +#define PKTCTRLREG (0x38) + +#define NOSERVERS_OFST (0) +#define NOSERVERS_MSK (0x0000003f << NOSERVERS_OFST) +#define SERVERSTART_OFST (8) +#define SERVERSTART_MSK (0x0000001f << SERVERSTART_OFST) +#define ETHINTERF_OFST (16) +#define ETHINTERF_MSK (0x00000001 << ETHINTERF_OFST) + +#define EMPTY3CREG (0x3C) + +#define PKTCOORDREG1 (0x40) + +#define COORDX_OFST (0) +#define COORDX_MSK (0x0000ffff << COORDX_OFST) +#define COORDY_OFST (16) +#define COORDY_MSK (0x0000ffff << COORDY_OFST) + +#define EMPTY44REG (0x44) + +#define PKTCOORDREG2 (0x48) + +#define COORDZ_OFST (0) +#define COORDZ_MSK (0x0000ffff << COORDZ_OFST) + +#define EMPTY4CREG (0x4C) + +#define EMPTY50REG (0x50) + +#define EMPTY54REG (0x54) + +#define EMPTY58REG (0x58) + +#define EMPTY5CREG (0x5C) + +#define EMPTY60REG (0x60) + +#define EMPTY64REG (0x64) + +#define EMPTY68REG (0x68) + +#define EMPTY6CREG (0x6C) + +#define EMPTY70REG (0x70) + +#define EMPTY74REG (0x74) + +#define EMPTY78REG (0x78) + +#define EMPTY7CREG (0x7C) + +#define EMPTY80REG (0x80) + +#define EMPTY84REG (0x84) + +#define EMPTY88REG (0x88) + +#define EMPTY8CREG (0x8C) + +#define EMPTY90REG (0x90) + +#define EMPTY94REG (0x94) + +#define EMPTY98REG (0x98) + +#define EMPTY9CREG (0x9C) + +#define FLOWSTATUSREG (0x100) + +#define RSMBUSY_OFST (0) +#define RSMBUSY_MSK (0x00000001 << RSMBUSY_OFST) +#define RSMTRGWAIT_OFST (3) +#define RSMTRGWAIT_MSK (0x00000001 << RSMTRGWAIT_OFST) +#define CSMBUSY_OFST (17) +#define CSMBUSY_MSK (0x00000001 << CSMBUSY_OFST) + +#define EMPTY104REG (0x104) + +#define FLOWCONTROLREG (0x108) + +#define STARTF_OFST (0) +#define STARTF_MSK (0x00000001 << STARTF_OFST) +#define STOPF_OFST (1) +#define STOPF_MSK (0x00000001 << STOPF_OFST) +#define RSTF_OFST (2) +#define RSTF_MSK (0x00000001 << RSTF_OFST) +#define SWTRIGGERF_OFST (3) +#define SWTRIGGERF_MSK (0x00000001 << SWTRIGGERF_OFST) +#define TRIGGERENABLE_OFST (4) +#define TRIGGERENABLE_MSK (0x00000001 << TRIGGERENABLE_OFST) + +#define EMPTY10CREG (0x10C) + +#define TIMEFROMSTARTOUTREG1 (0x110) + +#define TIMEFROMSTARTOUTREG2 (0x114) + +#define FRAMESFROMSTARTOUTREG1 (0x118) + +#define FRAMESFROMSTARTOUTREG2 (0x11C) + +#define FRAMETIMEOUTREG1 (0x120) + +#define FRAMETIMEOUTREG2 (0x124) + +#define DELAYOUTREG1 (0x128) + +#define DELAYOUTREG2 (0x12C) + +#define CYCLESOUTREG1 (0x130) + +#define CYCLESOUTREG2 (0x134) + +#define FRAMESOUTREG1 (0x138) + +#define FRAMESOUTREG2 (0x13C) + +#define PERIODOUTREG1 (0x140) + +#define PERIODOUTREG2 (0x144) + +#define DELAYINREG1 (0x148) + +#define DELAYINREG2 (0x14C) + +#define CYCLESINREG1 (0x150) + +#define CYCLESINREG2 (0x154) + +#define FRAMESINREG1 (0x158) + +#define FRAMESINREG2 (0x15C) + +#define PERIODINREG1 (0x160) + +#define PERIODINREG2 (0x164) + +#define EMPTY168REG (0x168) + +#define EMPTY16CREG (0x16C) + +#define EMPTY170REG (0x170) + +#define EMPTY174REG (0x174) + +#define EMPTY178REG (0x178) + +#define EMPTY17CREG (0x17C) + +#define EMPTY180REG (0x180) + +#define EMPTY184REG (0x184) + +#define EMPTY188REG (0x188) + +#define EMPTY18CREG (0x18C) + +#define EMPTY190REG (0x190) + +#define EMPTY194REG (0x194) + +#define EMPTY198REG (0x198) + +#define EMPTY19CREG (0x19C) + +#define PATTERN_OUT_LSB_REG (0x200) + +#define PATTERN_OUT_MSB_REG (0x204) + +#define PATTERN_IN_LSB_REG (0x208) + +#define PATTERN_IN_MSB_REG (0x20C) + +#define PATTERN_MASK_LSB_REG (0x210) + +#define PATTERN_MASK_MSB_REG (0x214) + +#define PATTERN_SET_LSB_REG (0x218) + +#define PATTERN_SET_MSB_REG (0x21C) + +#define PATTERN_CNTRL_REG (0x220) + +#define PATTERN_CNTRL_WR_OFST (0) +#define PATTERN_CNTRL_WR_MSK (0x00000001 << PATTERN_CNTRL_WR_OFST) +#define PATTERN_CNTRL_RD_OFST (1) +#define PATTERN_CNTRL_RD_MSK (0x00000001 << PATTERN_CNTRL_RD_OFST) +#define PATTERN_CNTRL_ADDR_OFST (16) +#define PATTERN_CNTRL_ADDR_MSK (0x00001fff << PATTERN_CNTRL_ADDR_OFST) + +#define EMPTY224REG (0x224) + +#define PATTERN_LIMIT_REG (0x228) + +#define PATTERN_LIMIT_STRT_OFST (0) +#define PATTERN_LIMIT_STRT_MSK (0x00001fff << PATTERN_LIMIT_STRT_OFST) +#define PATTERN_LIMIT_STP_OFST (16) +#define PATTERN_LIMIT_STP_MSK (0x00001fff << PATTERN_LIMIT_STP_OFST) + +#define EMPTY22CREG (0x22C) + +#define PATTERN_LOOP_0_ADDR_REG (0x230) + +#define PATTERN_LOOP_0_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_0_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_0_ADDR_STRT_OFST) +#define PATTERN_LOOP_0_ADDR_STP_OFST (16) +#define PATTERN_LOOP_0_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_0_ADDR_STP_OFST) + +#define EMPTY234REG (0x234) + +#define PATTERN_LOOP_0_ITERATION_REG (0x238) + +#define EMPTY23CREG (0x23C) + +#define PATTERN_WAIT_0_ADDR_REG (0x240) + +#define PATTERN_WAIT_0_ADDR_OFST (0) +#define PATTERN_WAIT_0_ADDR_MSK (0x00001fff << PATTERN_WAIT_0_ADDR_OFST) + +#define EMPTY244REG (0x244) + +#define PATTERN_WAIT_TIMER_0_LSB_REG (0x248) + +#define PATTERN_WAIT_TIMER_0_MSB_REG (0x24C) + +#define PATTERN_LOOP_1_ADDR_REG (0x250) + +#define PATTERN_LOOP_1_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_1_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_1_ADDR_STRT_OFST) +#define PATTERN_LOOP_1_ADDR_STP_OFST (16) +#define PATTERN_LOOP_1_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_1_ADDR_STP_OFST) + +#define EMPTY254REG (0x254) + +#define PATTERN_LOOP_1_ITERATION_REG (0x258) + +#define EMPTY25CREG (0x25C) + +#define PATTERN_WAIT_1_ADDR_REG (0x260) + +#define PATTERN_WAIT_1_ADDR_OFST (0) +#define PATTERN_WAIT_1_ADDR_MSK (0x00001fff << PATTERN_WAIT_1_ADDR_OFST) + +#define EMPTY264REG (0x264) + +#define PATTERN_WAIT_TIMER_1_LSB_REG (0x268) + +#define PATTERN_WAIT_TIMER_1_MSB_REG (0x26C) + +#define PATTERN_LOOP_2_ADDR_REG (0x270) + +#define PATTERN_LOOP_2_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_2_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_2_ADDR_STRT_OFST) +#define PATTERN_LOOP_2_ADDR_STP_OFST (16) +#define PATTERN_LOOP_2_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_2_ADDR_STP_OFST) + +#define EMPTY274REG (0x274) + +#define PATTERN_LOOP_2_ITERATION_REG (0x278) + +#define EMPTY27CREG (0x27C) + +#define PATTERN_WAIT_2_ADDR_REG (0x280) + +#define PATTERN_WAIT_2_ADDR_OFST (0) +#define PATTERN_WAIT_2_ADDR_MSK (0x00001fff << PATTERN_WAIT_2_ADDR_OFST) + +#define EMPTY284REG (0x284) + +#define PATTERN_WAIT_TIMER_2_LSB_REG (0x288) + +#define PATTERN_WAIT_TIMER_2_MSB_REG (0x28C) + +#define PATTERN_LOOP_3_ADDR_REG (0x290) + +#define PATTERN_LOOP_3_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_3_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_3_ADDR_STRT_OFST) +#define PATTERN_LOOP_3_ADDR_STP_OFST (16) +#define PATTERN_LOOP_3_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_3_ADDR_STP_OFST) + +#define EMPTY294REG (0x294) + +#define PATTERN_LOOP_3_ITERATION_REG (0x298) + +#define EMPTY29CREG (0x29C) + +#define PATTERN_WAIT_3_ADDR_REG (0x300) + +#define PATTERN_WAIT_3_ADDR_OFST (0) +#define PATTERN_WAIT_3_ADDR_MSK (0x00001fff << PATTERN_WAIT_3_ADDR_OFST) + +#define EMPTY304REG (0x304) + +#define PATTERN_WAIT_TIMER_3_LSB_REG (0x308) + +#define PATTERN_WAIT_TIMER_3_MSB_REG (0x30C) + +#define PATTERN_LOOP_4_ADDR_REG (0x310) + +#define PATTERN_LOOP_4_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_4_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_4_ADDR_STRT_OFST) +#define PATTERN_LOOP_4_ADDR_STP_OFST (16) +#define PATTERN_LOOP_4_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_4_ADDR_STP_OFST) + +#define EMPTY314REG (0x314) + +#define PATTERN_LOOP_4_ITERATION_REG (0x318) + +#define EMPTY31CREG (0x31C) + +#define PATTERN_WAIT_4_ADDR_REG (0x320) + +#define PATTERN_WAIT_4_ADDR_OFST (0) +#define PATTERN_WAIT_4_ADDR_MSK (0x00001fff << PATTERN_WAIT_4_ADDR_OFST) + +#define EMPTY324REG (0x324) + +#define PATTERN_WAIT_TIMER_4_LSB_REG (0x328) + +#define PATTERN_WAIT_TIMER_4_MSB_REG (0x32C) + +#define PATTERN_LOOP_5_ADDR_REG (0x330) + +#define PATTERN_LOOP_5_ADDR_STRT_OFST (0) +#define PATTERN_LOOP_5_ADDR_STRT_MSK \ + (0x00001fff << PATTERN_LOOP_5_ADDR_STRT_OFST) +#define PATTERN_LOOP_5_ADDR_STP_OFST (16) +#define PATTERN_LOOP_5_ADDR_STP_MSK (0x00001fff << PATTERN_LOOP_5_ADDR_STP_OFST) + +#define EMPTY334REG (0x334) + +#define PATTERN_LOOP_5_ITERATION_REG (0x338) + +#define EMPTY33CREG (0x33C) + +#define PATTERN_WAIT_5_ADDR_REG (0x340) + +#define PATTERN_WAIT_5_ADDR_OFST (0) +#define PATTERN_WAIT_5_ADDR_MSK (0x00001fff << PATTERN_WAIT_5_ADDR_OFST) + +#define EMPTY344REG (0x344) + +#define PATTERN_WAIT_TIMER_5_LSB_REG (0x348) + +#define PATTERN_WAIT_TIMER_5_MSB_REG (0x34C) + +#define PINIOCTRLREG (0x350) + +#define EMPTY354REG (0x354) + +#define EMPTY358REG (0x358) + +#define EMPTY35CREG (0x35C) + +#define EMPTY360REG (0x360) + +#define EMPTY364REG (0x364) + +#define EMPTY368REG (0x368) + +#define EMPTY36CREG (0x36C) + +#define EMPTY370REG (0x370) + +#define EMPTY374REG (0x374) + +#define EMPTY378REG (0x378) + +#define EMPTY37CREG (0x37C) + +#define EMPTY380REG (0x380) + +#define EMPTY384REG (0x384) + +#define EMPTY388REG (0x388) + +#define EMPTY38CREG (0x38C) + +#define EMPTY390REG (0x390) + +#define EMPTY394REG (0x394) + +#define EMPTY398REG (0x398) + +#define EMPTY39CREG (0x39C) + +#define EMPTY3A0REG (0x3A0) + +#define EMPTY3A4REG (0x3A4) + +#define EMPTY3A8REG (0x3A8) + +#define EMPTY3ACREG (0x3AC) + +#define EMPTY3B0REG (0x3B0) + +#define EMPTY3B4REG (0x3B4) + +#define EMPTY3B8REG (0x3B8) + +#define EMPTY3BCREG (0x3BC) + +#define EMPTY3C0REG (0x3C0) + +#define EMPTY3C4REG (0x3C4) + +#define EMPTY3C8REG (0x3C8) + +#define EMPTY3CCREG (0x3CC) + +#define EMPTY3D0REG (0x3D0) + +#define EMPTY3D4REG (0x3D4) + +#define EMPTY3D8REG (0x3D8) + +#define EMPTY3DCREG (0x3DC) + +#define EMPTY3E0REG (0x3E0) + +#define EMPTY3E4REG (0x3E4) + +#define EMPTY3E8REG (0x3E8) + +#define EMPTY3ECREG (0x3EC) + +#define EMPTY3F0REG (0x3F0) + +#define EMPTY3F4REG (0x3F4) + +#define EMPTY3F8REG (0x3F8) + +#define EMPTY3FCREG (0x3FC) + +#define EXPCTRLREG (0x400) + +#define STARTP_OFST (0) +#define STARTP_MSK (0x00000001 << STARTP_OFST) + +#define EMPTY404REG (0x404) + +#define EXPFRAMESREG (0x408) + +#define EMPTY40CREG (0x40C) + +#define EXPTIMEREG (0x410) + +#define EMPTY414REG (0x414) + +#define EMPTY418REG (0x418) + +#define EMPTY41CREG (0x41C) + +#define EMPTY420REG (0x420) + +#define EMPTY424REG (0x424) + +#define EMPTY428REG (0x428) + +#define EMPTY42CREG (0x42C) + +#define EMPTY430REG (0x430) + +#define EMPTY434REG (0x434) + +#define EMPTY438REG (0x438) + +#define EMPTY43CREG (0x43C) + +#define EMPTY440REG (0x440) + +#define EMPTY444REG (0x444) + +#define EMPTY448REG (0x448) + +#define EMPTY44CREG (0x44C) + +#define EMPTY450REG (0x450) + +#define EMPTY454REG (0x454) + +#define EMPTY458REG (0x458) + +#define EMPTY45CREG (0x45C) + +#define EMPTY460REG (0x460) + +#define EMPTY464REG (0x464) + +#define EMPTY468REG (0x468) + +#define EMPTY46CREG (0x46C) + +#define EMPTY470REG (0x470) + +#define EMPTY474REG (0x474) + +#define EMPTY478REG (0x478) + +#define EMPTY47CREG (0x47C) + +#define EMPTY480REG (0x480) + +#define EMPTY484REG (0x484) + +#define EMPTY488REG (0x488) + +#define EMPTY48CREG (0x48C) + +#define EMPTY490REG (0x490) + +#define EMPTY494REG (0x494) + +#define EMPTY498REG (0x498) + +#define EMPTY49CREG (0x49C) + +#define EMPTY4A0REG (0x4A0) + +#define EMPTY4A4REG (0x4A4) + +#define EMPTY4A8REG (0x4A8) + +#define EMPTY4ACREG (0x4AC) + +#define EMPTY4B0REG (0x4B0) + +#define EMPTY4B4REG (0x4B4) + +#define EMPTY4B8REG (0x4B8) + +#define EMPTY4BCREG (0x4BC) + +#define EMPTY4C0REG (0x4C0) + +#define EMPTY4C4REG (0x4C4) + +#define EMPTY4C8REG (0x4C8) + +#define EMPTY4CCREG (0x4CC) + +#define EMPTY4D0REG (0x4D0) + +#define EMPTY4D4REG (0x4D4) + +#define EMPTY4D8REG (0x4D8) + +#define EMPTY4DCREG (0x4DC) + +#define EMPTY4E0REG (0x4E0) + +#define EMPTY4E4REG (0x4E4) + +#define EMPTY4E8REG (0x4E8) + +#define EMPTY4ECREG (0x4EC) + +#define EMPTY4F0REG (0x4F0) + +#define EMPTY4F4REG (0x4F4) + +#define EMPTY4F8REG (0x4F8) + +#define EMPTY4FCREG (0x4FC) + +#define FIFOTOGBCONTROLREG (0x500) + +#define ENABLEDCHANNELS_OFST (0) +#define ENABLEDCHANNELS_MSK (0x00001fff << ENABLEDCHANNELS_OFST) +#define ROMODE_OFST (13) +#define ROMODE_MSK (0x00000007 << ROMODE_OFST) +#define COUNTFRAMESFROMUPDATE_OFST (16) +#define COUNTFRAMESFROMUPDATE_MSK (0x00000001 << COUNTFRAMESFROMUPDATE_OFST) +#define STARTSTREAMING_P_OFST (17) +#define STARTSTREAMING_P_MSK (0x00000001 << STARTSTREAMING_P_OFST) + +#define EMPTY504REG (0x504) + +#define NOSAMPLESDREG (0x508) + +#define NOSAMPLESD_OFST (0) +#define NOSAMPLESD_MSK (0x00003fff << NOSAMPLESD_OFST) + +#define EMPTY50CREG (0x50C) + +#define NOSAMPLESAREG (0x510) + +#define NOSAMPLESA_OFST (0) +#define NOSAMPLESA_MSK (0x00003fff << NOSAMPLESA_OFST) + +#define EMPTY514REG (0x514) + +#define NOSAMPLESXREG (0x518) + +#define NOSAMPLESX_OFST (0) +#define NOSAMPLESX_MSK (0x00001fff << NOSAMPLESX_OFST) + +#define EMPTY51CREG (0x51C) + +#define COUNTFRAMESFROMREG1 (0x520) + +#define COUNTFRAMESFROMREG2 (0x524) + +#define LOCALFRAMENUMBERREG1 (0x528) + +#define LOCALFRAMENUMBERREG2 (0x52C) + +#define EMPTY530REG (0x530) + +#define EMPTY534REG (0x534) + +#define EMPTY538REG (0x538) + +#define EMPTY53CREG (0x53C) + +#define EMPTY540REG (0x540) + +#define EMPTY544REG (0x544) + +#define EMPTY548REG (0x548) + +#define EMPTY54CREG (0x54C) + +#define EMPTY550REG (0x550) + +#define EMPTY554REG (0x554) + +#define EMPTY558REG (0x558) + +#define EMPTY55CREG (0x55C) + +#define EMPTY560REG (0x560) + +#define EMPTY564REG (0x564) + +#define EMPTY568REG (0x568) + +#define EMPTY56CREG (0x56C) + +#define EMPTY570REG (0x570) + +#define EMPTY574REG (0x574) + +#define EMPTY578REG (0x578) + +#define EMPTY57CREG (0x57C) + +#define EMPTY580REG (0x580) + +#define EMPTY584REG (0x584) + +#define EMPTY588REG (0x588) + +#define EMPTY58CREG (0x58C) + +#define EMPTY590REG (0x590) + +#define EMPTY594REG (0x594) + +#define EMPTY598REG (0x598) + +#define EMPTY59CREG (0x59C) + +#define EMPTY5A0REG (0x5A0) + +#define EMPTY5A4REG (0x5A4) + +#define EMPTY5A8REG (0x5A8) + +#define EMPTY5ACREG (0x5AC) + +#define EMPTY5B0REG (0x5B0) + +#define EMPTY5B4REG (0x5B4) + +#define EMPTY5B8REG (0x5B8) + +#define EMPTY5BCREG (0x5BC) + +#define EMPTY5C0REG (0x5C0) + +#define EMPTY5C4REG (0x5C4) + +#define EMPTY5C8REG (0x5C8) + +#define EMPTY5CCREG (0x5CC) + +#define EMPTY5D0REG (0x5D0) + +#define EMPTY5D4REG (0x5D4) + +#define EMPTY5D8REG (0x5D8) + +#define EMPTY5DCREG (0x5DC) + +#define EMPTY5E0REG (0x5E0) + +#define EMPTY5E4REG (0x5E4) + +#define EMPTY5E8REG (0x5E8) + +#define EMPTY5ECREG (0x5EC) + +#define EMPTY5F0REG (0x5F0) + +#define EMPTY5F4REG (0x5F4) + +#define EMPTY5F8REG (0x5F8) + +#define EMPTY5FCREG (0x5FC) + +#define MATTERHORNSPIREG1 (0x600) + +#define MATTERHORNSPIREG2 (0x604) + +#define MATTERHORNSPICTRL (0x608) + +#define MATTERHORNSPICTRL_EN_OFST (0) +#define MATTERHORNSPICTRL_EN_MSK (0x00000001 << MATTERHORNSPICTRL_EN_OFST) +#define CONFIGSTART_OFST (1) +#define CONFIGSTART_MSK (0x00000001 << CONFIGSTART_OFST) +#define START_P_OFST (2) +#define START_P_MSK (0x00000001 << START_P_OFST) +#define STARTREAD_P_OFST (3) +#define STARTREAD_P_MSK (0x00000001 << STARTREAD_P_OFST) +#define BUSY_OFST (4) +#define BUSY_MSK (0x00000001 << BUSY_OFST) + +#define EMPTY60CREG (0x60C) + +#define EMPTY610REG (0x610) + +#define EMPTY614REG (0x614) + +#define EMPTY618REG (0x618) + +#define EMPTY61CREG (0x61C) + +#define EMPTY620REG (0x620) + +#define EMPTY624REG (0x624) + +#define EMPTY628REG (0x628) + +#define EMPTY62CREG (0x62C) + +#define TRANSCEIVERRXCTRL0REG1 (0x630) + +#define TRANSCEIVERRXCTRL0REG2 (0x634) + +#define TRANSCEIVERRXCTRL1REG1 (0x638) + +#define TRANSCEIVERRXCTRL1REG2 (0x63C) + +#define TRANSCEIVERRXCTRL2REG (0x640) + +#define EMPTY644REG (0x644) + +#define TRANSCEIVERRXCTRL3REG (0x648) + +#define EMPTY64CREG (0x64C) + +#define TRANSCEIVERSTATUS (0x650) + +#define LINKDOWNLATCHEDOUT_OFST (0) +#define LINKDOWNLATCHEDOUT_MSK (0x00000001 << LINKDOWNLATCHEDOUT_OFST) +#define TXUSERCLKACTIVE_OFST (1) +#define TXUSERCLKACTIVE_MSK (0x00000001 << TXUSERCLKACTIVE_OFST) +#define RXUSERCLKACTIVE_OFST (2) +#define RXUSERCLKACTIVE_MSK (0x00000001 << RXUSERCLKACTIVE_OFST) +#define RXCOMMADET_OFST (3) +#define RXCOMMADET_MSK (0x0000000f << RXCOMMADET_OFST) +#define RXBYTEREALIGN_OFST (7) +#define RXBYTEREALIGN_MSK (0x0000000f << RXBYTEREALIGN_OFST) +#define RXBYTEISALIGNED_OFST (11) +#define RXBYTEISALIGNED_MSK (0x0000000f << RXBYTEISALIGNED_OFST) +#define GTWIZRXCDRSTABLE_OFST (15) +#define GTWIZRXCDRSTABLE_MSK (0x00000001 << GTWIZRXCDRSTABLE_OFST) +#define RESETTXDONE_OFST (16) +#define RESETTXDONE_MSK (0x00000001 << RESETTXDONE_OFST) +#define RESETRXDONE_OFST (17) +#define RESETRXDONE_MSK (0x00000001 << RESETRXDONE_OFST) +#define RXPMARESETDONE_OFST (18) +#define RXPMARESETDONE_MSK (0x0000000f << RXPMARESETDONE_OFST) +#define TXPMARESETDONE_OFST (22) +#define TXPMARESETDONE_MSK (0x0000000f << TXPMARESETDONE_OFST) +#define GTTPOWERGOOD_OFST (26) +#define GTTPOWERGOOD_MSK (0x0000000f << GTTPOWERGOOD_OFST) + +#define EMPTY654REG (0x654) + +#define TRANSCEIVERCONTROL (0x658) + +#define GTWIZRESETALL_OFST (0) +#define GTWIZRESETALL_MSK (0x00000001 << GTWIZRESETALL_OFST) +#define RESETTXPLLANDDATAPATH_OFST (1) +#define RESETTXPLLANDDATAPATH_MSK (0x00000001 << RESETTXPLLANDDATAPATH_OFST) +#define RESETTXDATAPATHIN_OFST (2) +#define RESETTXDATAPATHIN_MSK (0x00000001 << RESETTXDATAPATHIN_OFST) +#define RESETRXPLLANDDATAPATH_OFST (3) +#define RESETRXPLLANDDATAPATH_MSK (0x00000001 << RESETRXPLLANDDATAPATH_OFST) +#define RESETRXDATAPATHIN_OFST (4) +#define RESETRXDATAPATHIN_MSK (0x00000001 << RESETRXDATAPATHIN_OFST) + +#define EMPTY65CREG (0x65C) + +#define EMPTY660REG (0x660) + +#define EMPTY664REG (0x664) + +#define EMPTY668REG (0x668) + +#define EMPTY66CREG (0x66C) + +#define EMPTY670REG (0x670) + +#define EMPTY674REG (0x674) + +#define EMPTY678REG (0x678) + +#define EMPTY67CREG (0x67C) + +#define EMPTY680REG (0x680) + +#define EMPTY684REG (0x684) + +#define EMPTY688REG (0x688) + +#define EMPTY68CREG (0x68C) + +#define EMPTY690REG (0x690) + +#define EMPTY694REG (0x694) + +#define EMPTY698REG (0x698) + +#define EMPTY69CREG (0x69C) + +#define EMPTY6A0REG (0x6A0) + +#define EMPTY6A4REG (0x6A4) + +#define EMPTY6A8REG (0x6A8) + +#define EMPTY6ACREG (0x6AC) + +#define EMPTY6B0REG (0x6B0) + +#define EMPTY6B4REG (0x6B4) + +#define EMPTY6B8REG (0x6B8) + +#define EMPTY6BCREG (0x6BC) + +#define EMPTY6C0REG (0x6C0) + +#define EMPTY6C4REG (0x6C4) + +#define EMPTY6C8REG (0x6C8) + +#define EMPTY6CCREG (0x6CC) + +#define EMPTY6D0REG (0x6D0) + +#define EMPTY6D4REG (0x6D4) + +#define EMPTY6D8REG (0x6D8) + +#define EMPTY6DCREG (0x6DC) + +#define EMPTY6E0REG (0x6E0) + +#define EMPTY6E4REG (0x6E4) + +#define EMPTY6E8REG (0x6E8) + +#define EMPTY6ECREG (0x6EC) + +#define EMPTY6F0REG (0x6F0) + +#define EMPTY6F4REG (0x6F4) + +#define EMPTY6F8REG (0x6F8) + +#define EMPTY6FCREG (0x6FC) + +#define DBITFIFOCTRLREG (0x700) + +#define DBITRD_OFST (0) +#define DBITRD_MSK (0x00000001 << DBITRD_OFST) +#define DBITRST_OFST (1) +#define DBITRST_MSK (0x00000001 << DBITRST_OFST) +#define DBITFULL_OFST (2) +#define DBITFULL_MSK (0x00000001 << DBITFULL_OFST) +#define DBITEMPTY_OFST (3) +#define DBITEMPTY_MSK (0x00000001 << DBITEMPTY_OFST) +#define DBITUNDERFLOW_OFST (4) +#define DBITUNDERFLOW_MSK (0x00000001 << DBITUNDERFLOW_OFST) +#define DBITOVERFLOW_OFST (5) +#define DBITOVERFLOW_MSK (0x00000001 << DBITOVERFLOW_OFST) + +#define EMPTYREG (0x704) + +#define DBITFIFODATAREG1 (0x708) + +#define DBITFIFODATAREG2 (0x70C) + +#define EMPTY710REG (0x710) + +#define EMPTY714REG (0x714) + +#define EMPTY718REG (0x718) + +#define EMPTY71CREG (0x71C) + +#define EMPTY720REG (0x720) diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/bin/xilinx_ctbDetectorServer_developer b/slsDetectorServers/xilinx_ctbDetectorServer/bin/xilinx_ctbDetectorServer_developer new file mode 100755 index 000000000..92c65c1ba Binary files /dev/null and b/slsDetectorServers/xilinx_ctbDetectorServer/bin/xilinx_ctbDetectorServer_developer differ diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorFunctionList.c new file mode 100644 index 000000000..589693c22 --- /dev/null +++ b/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorFunctionList.c @@ -0,0 +1,435 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "slsDetectorFunctionList.h" +#include "arm64.h" +#include "clogger.h" +#include "common.h" +#include "sharedMemory.h" +#include "sls/versionAPI.h" + +#include "loadPattern.h" + +#include // INET_ADDRSTRLEN +#include +#include // usleep + +// Global variable from slsDetectorServer_funcs +extern int debugflag; +extern int updateFlag; +extern const enum detectorType myDetectorType; + +// Global variable from communication_funcs.c +extern int isControlServer; + +int initError = OK; +int initCheckDone = 0; +char initErrorMessage[MAX_STR_LENGTH]; + +int detPos[2] = {0, 0}; + +int isInitCheckDone() { return initCheckDone; } + +int getInitResult(char **mess) { + *mess = initErrorMessage; + return initError; +} + +void basictests() { + initError = OK; + initCheckDone = 0; + memset(initErrorMessage, 0, MAX_STR_LENGTH); +#ifdef VIRTUAL + LOG(logINFOBLUE, ("****** Xilinx Chip Test Board Virtual Server ******\n")); +#else + LOG(logINFOBLUE, ("********** Xilinx Chip Test Board Server **********\n")); +#endif + if (mapCSP0() == FAIL) { + strcpy(initErrorMessage, + "Could not map to memory. Cannot proceed. Check Firmware.\n"); + LOG(logERROR, (initErrorMessage)); + initError = FAIL; + return; + } + +#ifndef VIRTUAL + if ((!debugflag) && (!updateFlag) && + ((validateKernelVersion(KERNEL_DATE_VRSN) == FAIL) || + (checkType() == FAIL) || (testFpga() == FAIL) || + (testBus() == FAIL))) { + sprintf(initErrorMessage, + "Could not pass basic tests of FPGA and bus. Cannot proceed. " + "Check Firmware. (Firmware version:0x%lx) \n", + getFirmwareVersion()); + LOG(logERROR, ("%s\n\n", initErrorMessage)); + initError = FAIL; + return; + } +#endif + uint32_t ipadd = getDetectorIP(); + uint64_t macadd = getDetectorMAC(); + int64_t fwversion = getFirmwareVersion(); + char swversion[MAX_STR_LENGTH] = {0}; + memset(swversion, 0, MAX_STR_LENGTH); + getServerVersion(swversion); + uint32_t requiredFirmwareVersion = REQRD_FRMWRE_VRSN; + + LOG(logINFOBLUE, + ("**************************************************\n" + "Detector IP Addr:\t\t 0x%x\n" + "Detector MAC Addr:\t\t 0x%lx\n\n" + + "Firmware Version:\t\t 0x%lx\n" + "Software Version:\t\t %s\n" + "Required Firmware Version:\t 0x%x\n" + "********************************************************\n", + ipadd, macadd, fwversion, swversion, requiredFirmwareVersion)); +} + +int checkType() { +#ifdef VIRTUAL + return OK; +#endif + u_int32_t type = ((bus_r(FPGAVERSIONREG) & DETTYPE_MSK) >> DETTYPE_OFST); + if (type != XILINX_CHIPTESTBOARD) { + LOG(logERROR, + ("This is not a Xilinx CTB firmware (read %d, expected %d)\n", type, + XILINX_CHIPTESTBOARD)); + return FAIL; + } + return OK; +} + +int testFpga() { +#ifdef VIRTUAL + return OK; +#endif + LOG(logINFO, ("Testing FPGA:\n")); + + // fixed pattern + int ret = OK; + + /* TODO: FIX PATTERN not defined in firmware + uint32_t val = bus_r(FIX_PATT_REG); + if (val == FIX_PATT_VAL) { + LOG(logINFO, ("\tFixed pattern: successful match (0x%08x)\n", val)); + } else { + LOG(logERROR, + ("Fixed pattern does not match! Read 0x%08x, expected 0x%08x\n", + val, FIX_PATT_VAL)); + ret = FAIL; + } + */ + + if (ret == OK) { + // Delay LSB reg + LOG(logINFO, ("\tTesting Delay LSB Register:\n")); + uint32_t addr = DELAYINREG1; + + // store previous delay value + uint32_t previousValue = bus_r(addr); + + volatile uint32_t val = 0, readval = 0; + int times = 1000 * 1000; + for (int i = 0; i < times; ++i) { + val = 0x5A5A5A5A - i; + bus_w(addr, val); + readval = bus_r(addr); + if (readval != val) { + LOG(logERROR, ("1:Mismatch! Loop(%d): Wrote 0x%x, read 0x%x\n", + i, val, readval)); + ret = FAIL; + break; + } + val = (i + (i << 10) + (i << 20)); + bus_w(addr, val); + readval = bus_r(addr); + if (readval != val) { + LOG(logERROR, ("2:Mismatch! Loop(%d): Wrote 0x%x, read 0x%x\n", + i, val, readval)); + ret = FAIL; + break; + } + val = 0x0F0F0F0F; + bus_w(addr, val); + readval = bus_r(addr); + if (readval != val) { + LOG(logERROR, ("3:Mismatch! Loop(%d): Wrote 0x%x, read 0x%x\n", + i, val, readval)); + ret = FAIL; + break; + } + val = 0xF0F0F0F0; + bus_w(addr, val); + readval = bus_r(addr); + if (readval != val) { + LOG(logERROR, ("4:Mismatch! Loop(%d): Wrote 0x%x, read 0x%x\n", + i, val, readval)); + ret = FAIL; + break; + } + } + // write back previous value + bus_w(addr, previousValue); + if (ret == OK) { + LOG(logINFO, + ("\tSuccessfully tested FPGA Delay LSB Register %d times\n", + times)); + } + } + + return ret; +} + +int testBus() { +#ifdef VIRTUAL + return OK; +#endif + LOG(logINFO, ("Testing Bus:\n")); + + int ret = OK; + uint32_t addr = DELAYINREG1; + + // store previous delay value + uint32_t previousValue = bus_r(addr); + + volatile uint32_t val = 0, readval = 0; + int times = 1000 * 1000; + + for (int i = 0; i < times; ++i) { + val += 0xbbbbb; + bus_w(addr, val); + readval = bus_r(addr); + if (readval != val) { + LOG(logERROR, ("Mismatch! Loop(%d): Wrote 0x%x, read 0x%x\n", i, + val, readval)); + ret = FAIL; + } + } + + // write back previous value + bus_w(addr, previousValue); + + if (ret == OK) { + LOG(logINFO, ("\tSuccessfully tested bus %d times\n", times)); + } + return ret; +} + +/* Ids */ + +void getServerVersion(char *version) { strcpy(version, APIXILINXCTB); } + +uint64_t getFirmwareVersion() { +#ifdef VIRTUAL + return REQRD_FRMWRE_VRSN; +#endif + return ((bus_r(FPGAVERSIONREG) & COMPDATE_MSK) >> COMPDATE_OFST); +} + +void getHardwareVersion(char *version) { strcpy(version, "Not applicable"); } + +u_int64_t getDetectorMAC() { +#ifdef VIRTUAL + return 0; +#else + char output[255], mac[255] = ""; + u_int64_t res = 0; + FILE *sysFile = + popen("ifconfig eth0 | grep ether | awk '{ print $2 }'", "r"); + fgets(output, sizeof(output), sysFile); + pclose(sysFile); + // getting rid of ":" + char *pch; + pch = strtok(output, ":"); + while (pch != NULL) { + strcat(mac, pch); + pch = strtok(NULL, ":"); + } + sscanf(mac, "%lx", &res); + return res; +#endif +} + +u_int32_t getDetectorIP() { +#ifdef VIRTUAL + return 0; +#endif + char temp[INET_ADDRSTRLEN] = ""; + u_int32_t res = 0; + // execute and get address + char output[255]; + FILE *sysFile = popen( + "ifconfig | grep 'inet '| grep -v '127.0.0.1' | awk '{ print $2 }'", + "r"); + fgets(output, sizeof(output), sysFile); + pclose(sysFile); + + // converting IPaddress to hex. + char *pcword = strtok(output, "."); + while (pcword != NULL) { + sprintf(output, "%02x", atoi(pcword)); + strcat(temp, output); + pcword = strtok(NULL, "."); + } + strcpy(output, temp); + sscanf(output, "%x", &res); + // LOG(logINFO, ("ip:%x\n",res); + + return res; +} + +/* initialization */ + +void initControlServer() { + if (!updateFlag && initError == OK) { + setupDetector(); + } + initCheckDone = 1; +} + +void initStopServer() { + if (!updateFlag && initError == OK) { + usleep(CTRL_SRVR_INIT_TIME_US); + if (mapCSP0() == FAIL) { + initError = FAIL; + strcpy(initErrorMessage, + "Stop Server: Map Fail. Cannot proceed. Check Firmware.\n"); + LOG(logERROR, (initErrorMessage)); + initCheckDone = 1; + return; + } +#ifdef VIRTUAL + sharedMemory_setStop(0); +#endif + } + initCheckDone = 1; +} + +/* set up detector */ + +void setupDetector() { + LOG(logINFO, ("Setting up Server for 1 Xilinx Chip Test Board\n")); +#ifdef VIRTUAL + sharedMemory_setStatus(IDLE); + initializePatternWord(); +#endif + + LOG(logINFOBLUE, ("Setting Default parameters\n")); + initializePatternAddresses(); + + setNumFrames(DEFAULT_NUM_FRAMES); + setNumTriggers(DEFAULT_NUM_CYCLES); + setTiming(DEFAULT_TIMING_MODE); +} + +/* set parameters - dr */ + +int setDynamicRange(int dr) { + if (dr == 16) + return OK; + return FAIL; +} + +int getDynamicRange(int *retval) { + *retval = DYNAMIC_RANGE; + return OK; +} + +/* parameters - timer */ + +void setNumFrames(int64_t val) { + if (val > 0) { + LOG(logINFO, ("Setting number of frames %ld\n", val)); + setU64BitReg(val, FRAMESINREG1, FRAMESINREG2); + } +} + +int64_t getNumFrames() { return getU64BitReg(FRAMESINREG1, FRAMESINREG2); } + +void setNumTriggers(int64_t val) { + if (val > 0) { + LOG(logINFO, ("Setting number of triggers %ld\n", val)); + setU64BitReg(val, CYCLESINREG1, CYCLESINREG2); + } +} + +int64_t getNumTriggers() { return getU64BitReg(CYCLESINREG1, CYCLESINREG2); } + +int64_t getNumFramesLeft() { + return getU64BitReg(FRAMESOUTREG1, FRAMESOUTREG2); +} + +int64_t getNumTriggersLeft() { + return getU64BitReg(CYCLESOUTREG1, CYCLESOUTREG2); +} + +/* parameters - timing, extsig */ + +void setTiming(enum timingMode arg) { + switch (arg) { + case AUTO_TIMING: + LOG(logINFO, ("Set Timing: Auto\n")); + bus_w(FLOWCONTROLREG, bus_r(FLOWCONTROLREG) & ~TRIGGERENABLE_MSK); + break; + case TRIGGER_EXPOSURE: + LOG(logINFO, ("Set Timing: Trigger\n")); + bus_w(FLOWCONTROLREG, bus_r(FLOWCONTROLREG) | TRIGGERENABLE_MSK); + break; + default: + LOG(logERROR, ("Unknown timing mode %d\n", arg)); + } +} + +enum timingMode getTiming() { + if (bus_r(FLOWCONTROLREG) == TRIGGERENABLE_MSK) + return TRIGGER_EXPOSURE; + return AUTO_TIMING; +} + +int setDetectorPosition(int pos[]) { + memcpy(detPos, pos, sizeof(detPos)); + // TODO + return OK; +} + +int configureMAC() { + // TODO + LOG(logINFO, ("Configuring MAC\n")); + return OK; +} + +int *getDetectorPosition() { return detPos; } + +int getNumberofUDPInterfaces() { return 1; } + +/* aquisition */ + +enum runStatus getRunStatus() { + LOG(logDEBUG1, ("Getting status\n")); + // scan error or running + if (sharedMemory_getScanStatus() == ERROR) { + LOG(logINFOBLUE, ("Status: scan ERROR\n")); + return ERROR; + } + if (sharedMemory_getScanStatus() == RUNNING) { + LOG(logINFOBLUE, ("Status: scan RUNNING\n")); + return RUNNING; + } +#ifdef VIRTUAL + if (sharedMemory_getStatus() == RUNNING) { + LOG(logINFOBLUE, ("Status: RUNNING\n")); + return RUNNING; + } + LOG(logINFOBLUE, ("Status: IDLE\n")); + return IDLE; +#endif + // TODO: get status + LOG(logINFOBLUE, ("Status: IDLE\n")); + return IDLE; +} + +void getNumberOfChannels(int *nchanx, int *nchany) { + // TODO + *nchanx = NCHAN; + *nchany = 1; +} \ No newline at end of file diff --git a/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorServer_defs.h b/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorServer_defs.h new file mode 100644 index 000000000..4e15e20d2 --- /dev/null +++ b/slsDetectorServers/xilinx_ctbDetectorServer/slsDetectorServer_defs.h @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#pragma once +#include "RegisterDefs.h" +#include "sls/sls_detector_defs.h" + +#define REQRD_FRMWRE_VRSN (0x230000) +#define KERNEL_DATE_VRSN "Wed Nov 29 17:32:14 CET 2023" + +#define LINKED_SERVER_NAME "xilinx_ctbDetectorServer" + +#define CTRL_SRVR_INIT_TIME_US (2 * 1000 * 1000) + +/* Hardware Definitions */ +#define NCHAN (1) + +enum ADCINDEX { V_PWR_IO }; +enum DACINDEX { D0 }; + +/** Default Parameters */ +#define DEFAULT_NUM_FRAMES (1) +#define DEFAULT_NUM_CYCLES (1) +#define DYNAMIC_RANGE (16) +#define DEFAULT_TIMING_MODE (AUTO_TIMING) + +/* Defines in the Firmware */ +#define WAIT_TIME_PATTERN_READ (10) \ No newline at end of file diff --git a/slsDetectorSoftware/CMakeLists.txt b/slsDetectorSoftware/CMakeLists.txt index 692302d11..e97f31bb9 100755 --- a/slsDetectorSoftware/CMakeLists.txt +++ b/slsDetectorSoftware/CMakeLists.txt @@ -4,10 +4,13 @@ set(SOURCES src/DetectorImpl.cpp src/Module.cpp src/Detector.cpp - src/CmdProxy.cpp + src/HelpDacs.cpp src/CmdParser.cpp src/Pattern.cpp src/CtbConfig.cpp + src/Caller.cpp + src/CallerSpecial.cpp + src/inferAction.cpp ) add_library(slsDetectorObject OBJECT @@ -76,26 +79,30 @@ endif() if(SLS_USE_TEXTCLIENT) - # Loop over list to generate command line binaries - set(bin_names "sls_detector_put" + set(det_bin_names "sls_detector_put" "sls_detector_get" "sls_detector_acquire" - "sls_detector_help") - set(cmd_name "PUT" "GET" "READOUT" "HELP") - list(LENGTH bin_names len1) + "sls_detector_help" + "sls_detector" + ) + set(det_cmd_name "PUT" "GET" "READOUT" "HELP" "INFER") + list(LENGTH det_bin_names len1) math(EXPR len2 "${len1} - 1") foreach(val RANGE ${len2}) - list(GET bin_names ${val} val1) - list(GET cmd_name ${val} val2) + list(GET det_bin_names ${val} val1) + list(GET det_cmd_name ${val} val2) message(STATUS "${val1} ${val2}") - add_executable(${val1} src/CmdLineApp.cpp) + add_executable(${val1} src/CmdApp.cpp) + target_link_libraries(${val1} - slsDetectorStatic - pthread - rt + slsDetectorStatic + pthread + rt ) + SET_SOURCE_FILES_PROPERTIES( src/Caller.cpp PROPERTIES COMPILE_FLAGS "-Wno-unused-variable -Wno-unused-but-set-variable") + set_target_properties(${val1} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin COMPILE_DEFINITIONS ${val2}=1 @@ -104,7 +111,8 @@ if(SLS_USE_TEXTCLIENT) set_property(TARGET ${val1} PROPERTY INTERPROCEDURAL_OPTIMIZATION True) endif() endforeach() - install(TARGETS ${bin_names} DESTINATION bin) + install(TARGETS ${det_bin_names} DESTINATION bin) + endif(SLS_USE_TEXTCLIENT) diff --git a/slsDetectorSoftware/generator/Caller.in.cpp b/slsDetectorSoftware/generator/Caller.in.cpp new file mode 100644 index 000000000..4e7129cc7 --- /dev/null +++ b/slsDetectorSoftware/generator/Caller.in.cpp @@ -0,0 +1,10 @@ +#include "Caller.h" +#include "sls/logger.h" +#include "sls/string_utils.h" +#include + +namespace sls { + +// THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE + +} \ No newline at end of file diff --git a/slsDetectorSoftware/generator/Caller.in.h b/slsDetectorSoftware/generator/Caller.in.h new file mode 100644 index 000000000..21c4ac098 --- /dev/null +++ b/slsDetectorSoftware/generator/Caller.in.h @@ -0,0 +1,88 @@ +// This file is used as input to generate the caller class + +#include "CmdParser.h" +#include "HelpDacs.h" +#include "sls/Detector.h" + +#include +#include +#include +namespace sls { + +class Caller { + public: + Caller(Detector *ptr) : det(ptr) {} + void call(const std::string &command, + const std::vector &arguments, int detector_id, + int action, std::ostream &os = std::cout, int receiver_id = -1); + + IpAddr getDstIpFromAuto(); + IpAddr getSrcIpFromAuto(); + UdpDestination getUdpEntry(); + void GetLevelAndUpdateArgIndex(int action, + std::string levelSeparatedCommand, + int &level, int &iArg, size_t nGetArgs, + size_t nPutArgs); + void WrongNumberOfParameters(size_t expected); + + template std::string OutStringHex(const V &value) { + if (value.equal()) + return ToStringHex(value.front()); + return ToStringHex(value); + } + + template std::string OutStringHex(const V &value, int width) { + if (value.equal()) + return ToStringHex(value.front(), width); + return ToStringHex(value, width); + } + + template std::string OutString(const Result &value) { + if (value.equal()) + return ToString(value.front()); + return ToString(value); + } + + template std::string OutString(const V &value) { + return ToString(value); + } + + template + std::string OutString(const V &value, const std::string &unit) { + if (value.equal()) + return ToString(value.front(), unit); + return ToString(value, unit); + } + + std::vector getAllCommands(); + std::string list(int action); + + // THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1) + + std::vector args; + std::string cmd; + Detector *det; + int det_id{-1}; + int rx_id{-1}; + + private: + bool ReplaceIfDepreciated(std::string &command); + using FunctionMap = std::map; + using StringMap = std::map; + Detector *ptr; // pointer to the detector that executes the command + + FunctionMap functions{ + {"list", &Caller::list}, + + // THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (2) + + }; + + StringMap depreciated_functions{ + + // THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (3) + + }; +}; + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/generator/autocomplete/autocomplete.py b/slsDetectorSoftware/generator/autocomplete/autocomplete.py new file mode 100644 index 000000000..008531a05 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/autocomplete.py @@ -0,0 +1,236 @@ +import argparse +import json +from pathlib import Path + +# command to generate the ast +# clang version: 14.0.0-1ubuntu1.1 +# clang++ -Xclang -ast-dump=json -Xclang -ast-dump-filter -Xclang StringTo -c ToString.cpp -I ../include/ -std=gnu++11 +# +import yaml + +AUTOCOMPLETE_PATH = Path(__file__).parent +DUMP_PATH = AUTOCOMPLETE_PATH / 'dump.json' +FIXED_PATH = AUTOCOMPLETE_PATH / 'fixed.json' + +type_values = { + 'special::mv': ["mv", "mV"], + "special::deg": ["deg"], + "special::time_unit": ["s", "ms", "us", "ns"], + "special::hard": ["hard"], + "special::force-delete-normal-file": ["--force-delete-normal-file"], + "special::currentSourceFix": ["fix", "nofix"], + "special::currentSourceLow": ["normal", "low"], + "special::path": [], + "special::pedestal_parameters" : ["", "0"] + +} + + +def get_types(arg_types): + ret = set() + for arg_type in arg_types: + if type_info(arg_type) == 'base': + if arg_type == 'bool': + ret = ret.union(["0", "1"]) + else: + tmp = [not_list for not_list in type_values[arg_type] if not isinstance(not_list, list)] + ret = ret.union(tmp) + + #Intercept the options and in case detector specific options appear replace the + #list of options with a command line call that fetches them + #TODO! Rename sls_detector_get + if "defs::dacIndex" in arg_types: + return "`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\\1/' | sed 's/,//g'`" + elif "defs::detectorSettings" in arg_types: + return "`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\\1/' | sed 's/,//g'`" + elif "defs::timingMode" in arg_types: + return "`sls_detector_get timinglist | sed -e 's/.*\[\(.*\)\].*/\\1/' | sed 's/,//g'`" + + + return ret + + +def type_info(type_name): + if type_name.startswith('defs::') or type_name.startswith('slsDetectorDefs::'): + return 'enum' + if type_name.startswith('special::'): + return 'special' + return 'base' + + +def get_enum(function): + return function['type']['qualType'].split(' ')[0] + + +def get_literal(ifstmt): + stringliteral = [] + expression = ifstmt['inner'][0] + if expression['kind'] == 'BinaryOperator': + if expression['opcode'] == '!=': + return None, None + for cxxOperatorCall in expression['inner']: + if cxxOperatorCall['kind'] == 'CXXOperatorCallExpr': + implicitCastExpr = cxxOperatorCall['inner'][2] + stringliteral.append(implicitCastExpr['inner'][0]['value'][1:-1]) + else: + cxxOperatorCall = expression + implicitCastExpr = cxxOperatorCall['inner'][2] + stringliteral = implicitCastExpr['inner'][0]['value'][1:-1] + + retstmt = get_object_by_kind(ifstmt['inner'], 'ReturnStmt') + declrefexpt = get_object_by_kind(retstmt['inner'], 'DeclRefExpr') + enum_val = declrefexpt["referencedDecl"]["name"] + + return enum_val, stringliteral + + +def get_object_by_kind(inner, kind, position=1): + for obj in inner: + if obj['kind'] == kind: + position -= 1 + if position == 0: + return obj + return None + + +def generate_type_values(): + functions = json.loads(FIXED_PATH.read_text()) + for function in functions: + if function['kind'] != 'FunctionDecl' or function['name'] != 'StringTo': + continue + enum = get_enum(function) + + if not enum.startswith('defs::'): + continue + # if enum != 'defs::dacIndex': + # continue + if not function['loc']['file'].endswith('ToString.cpp'): + continue + + compound_stmt = get_object_by_kind(function['inner'], 'CompoundStmt') + + for ifstmt in compound_stmt['inner']: + if ifstmt['kind'] != 'IfStmt': + continue + enum_val, stringliteral = get_literal(ifstmt) + if enum_val is None: + continue + + if enum not in type_values or type_values[enum] is None: + type_values[enum] = [] + type_values[enum].append(stringliteral) + items = list(type_values.items()) + for key, val in items: + if key.startswith('defs::'): + new_key = key.split('::')[1] + new_key = 'slsDetectorDefs::' + new_key + type_values[new_key] = val + elif key.startswith('slsDetectorDefs::'): + new_key = key.split('::')[1] + new_key = 'defs::' + new_key + type_values[new_key] = val + + return json.dumps(type_values, indent=2) + + +def fix_json(): + with DUMP_PATH.open('r') as f: + tmp = '[\n' + for line in f.read().split('\n'): + if line.startswith('}'): + tmp += line + ',\n' + else: + tmp += line + '\n' + tmp = tmp[:-3] + '\n]' + with FIXED_PATH.open('w') as f: + f.write(tmp) + + +def generate_bash_autocomplete(output_path=Path(__file__).parent / 'bash_autocomplete.sh', input_path=Path(__file__).parent / 'bash_autocomplete.in.sh'): + generate_type_values() + output_file = output_path.open('w') + template_file = input_path.open('r') + + def writeline(line): + output_file.write(line + '\n') + + class if_block: + def __init__(self, condition): + self.condition = condition + + def __enter__(self): + output_file.write('if [[ ' + self.condition + ' ]]; then\n') + + def __exit__(self, type, value, traceback): + output_file.write('fi\n') + + class function: + def __init__(self, name): + self.name = name + + def __enter__(self): + output_file.write(self.name + '() {\n') + + def __exit__(self, type, value, traceback): + output_file.write('}\n') + + command_path = Path(__file__).parent.parent / 'extended_commands.yaml' + commands = yaml.unsafe_load(command_path.open('r')) + + for line in template_file: + if '-- THIS LINE WILL BE REPLACED WITH GENERATED CODE --' not in line: + output_file.write(line) + continue + writeline(f'local SLS_COMMANDS=" {" ".join(commands.keys())} "') + # generate functions + for command_name, command in commands.items(): + # added for debugging + if command_name == 'xxxexptime': + continue + with function('__' + command_name): + writeline('FCN_RETURN=""') + + actions = ['GET', 'PUT'] + for action in actions: + if action in command['actions'] and 'args' in command['actions'][action]: + args = command['actions'][action]['args'] + possible_argc = {} + for arg in args: + if arg['argc'] == 0: + pass + for i in range(arg['argc']): + if i + 1 not in possible_argc: + possible_argc[i + 1] = [] + possible_argc[i + 1].append(arg['arg_types'][i]) + if possible_argc: + with if_block(f'${{IS_GET}} -eq {"1" if action == "GET" else "0"}'): + for argc in possible_argc: + with if_block(f'"${{cword}}" == "{argc + 1}"'): + if "defs::detectorSettings" in possible_argc[argc]: + print(argc, command_name, possible_argc[argc]) + choices = get_types(possible_argc[argc]) + + #check if we got choices back or a bash command + if isinstance(choices, (list,set)): + writeline(f'FCN_RETURN="{" ".join(sorted(choices))}"') + else: + writeline(f'FCN_RETURN="{choices}"') + if 'special::path' in possible_argc[argc]: + writeline('IS_PATH=1') + + writeline('return 0') + + + + output_file.close() + + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description='use parsed c++ code to generate autocomplete snippets') + parser.add_argument('-f', '--fix', action='store_true', help='fix the parsed ast to make it loadable') + # parser.add_argument('-p', '--path', type=str, help='output path to the fixed ast', default='ast.json') + args = parser.parse_known_args() + if args[0].fix: + fix_json() + ret = generate_type_values() + print(ret) diff --git a/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.in.sh b/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.in.sh new file mode 100644 index 000000000..d55b10c07 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.in.sh @@ -0,0 +1,167 @@ +# GENERATED FILE - DO NOT EDIT +# ANY CHANGES TO THIS FILE WILL BE OVERWRITTEN + +_sd() { + + # Taken from https://github.com/scop/bash-completion/blob/15b74b1050333f425877a7cbd99af2998b95c476/bash_completion#L770C12-L770C12 + # Reassemble command line words, excluding specified characters from the + # list of word completion separators (COMP_WORDBREAKS). + # @param $1 chars Characters out of $COMP_WORDBREAKS which should + # NOT be considered word breaks. This is useful for things like scp where + # we want to return host:path and not only path, so we would pass the + # colon (:) as $1 here. + # @param $2 words Name of variable to return words to + # @param $3 cword Name of variable to return cword to + # + _comp__reassemble_words() +{ + local exclude="" i j line ref + # Exclude word separator characters? + if [[ $1 ]]; then + # Yes, exclude word separator characters; + # Exclude only those characters, which were really included + exclude="[${1//[^$COMP_WORDBREAKS]/}]" + fi + + # Default to cword unchanged + printf -v "$3" %s "$COMP_CWORD" + # Are characters excluded which were former included? + if [[ $exclude ]]; then + # Yes, list of word completion separators has shrunk; + line=$COMP_LINE + # Re-assemble words to complete + for ((i = 0, j = 0; i < ${#COMP_WORDS[@]}; i++, j++)); do + # Is current word not word 0 (the command itself) and is word not + # empty and is word made up of just word separator characters to + # be excluded and is current word not preceded by whitespace in + # original line? + while [[ $i -gt 0 && ${COMP_WORDS[i]} == +($exclude) ]]; do + # Is word separator not preceded by whitespace in original line + # and are we not going to append to word 0 (the command + # itself), then append to current word. + [[ $line != [[:blank:]]* ]] && ((j >= 2)) && ((j--)) + # Append word separator to current or new word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + # Remove optional whitespace + word separator from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate next word if available, else end *both* while and + # for loop + if ((i < ${#COMP_WORDS[@]} - 1)); then + ((i++)) + else + break 2 + fi + # Start new word if word separator in original line is + # followed by whitespace. + [[ $line == [[:blank:]]* ]] && ((j++)) + done + # Append word to current word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Remove optional whitespace + word from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + done + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + else + # No, list of word completions separators hasn't changed; + for i in "${!COMP_WORDS[@]}"; do + printf -v "$2[i]" %s "${COMP_WORDS[i]}" + done + fi +} + + + local FCN_RETURN="" + local IS_PATH=0 + + + # -- THIS LINE WILL BE REPLACED WITH GENERATED CODE -- + + + COMPREPLY=() + local OPTIONS_NEW="" + + # check if bash or zsh + # _get_comp_words_by_ref is a bash built-in function, we check if it exists + declare -Ff _get_comp_words_by_ref > /dev/null && IS_BASH=1 || IS_BASH=0 + + + # bash interprets the colon character : as a special character and splits the argument in two + # different than what zsh does + # https://stackoverflow.com/a/3224910 + # https://stackoverflow.com/a/12495727 + local cur + local cword words=() + _comp__reassemble_words ":" words cword + cur=${words[cword]} + + # check the action (get or put) + case "${words[0]}" in + "sls_detector_get" | "g" | "detg") + local IS_GET=1 + ;; + *) + local IS_GET=0 + ;; + esac + + # if no command is written, autocomplete with the commands + if [[ ${cword} -eq 1 ]]; then +# local SLS_COMMANDS="trimbits exptime" + local SLS_COMMANDS_NEW="" + + case "$cur" in + [0-9]*:*) + local suggestions=($(compgen -W "${SLS_COMMANDS}" -- "${cur#*:}")) + COMPREPLY=( ${suggestions[*]} ) + ;; + [0-9]*) + COMPREPLY=() + ;; + *) + COMPREPLY=( $( compgen -W "$SLS_COMMANDS -h" -- "$cur" ) );; + + esac + return 0 + fi + + if [[ ${cword} -eq 2 ]] && [[ ${words[1]} == "-h" ]]; then + COMPREPLY=( $( compgen -W "$SLS_COMMANDS" -- "$cur" ) ) + return 0 + fi + + # if a command is written, autocomplete with the options + # call the function for the command + + if [[ "$SLS_COMMANDS" == *"${words[1]##*:}"* ]]; then + __"${words[1]##*:}" + fi + + # if IS_PATH is activated, autocomplete with the path + if [[ ${IS_PATH} -eq 1 ]]; then + COMPREPLY=($(compgen -f -- "${cur}")) + return 0 + fi + + # autocomplete with the options + COMPREPLY=($(compgen -W "${FCN_RETURN}" -- "${cur}")) + + + +} + +complete -F _sd -o filenames sls_detector_get +complete -F _sd -o filenames g +complete -F _sd -o filenames detg + +complete -F _sd -o filenames sls_detector_put +complete -F _sd -o filenames p +complete -F _sd -o filenames detp + +complete -F _sd -o filenames sls_detector +complete -F _sd -o filenames det diff --git a/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.sh b/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.sh new file mode 100644 index 000000000..6ed628f94 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/bash_autocomplete.sh @@ -0,0 +1,3255 @@ +# GENERATED FILE - DO NOT EDIT +# ANY CHANGES TO THIS FILE WILL BE OVERWRITTEN + +_sd() { + + # Taken from https://github.com/scop/bash-completion/blob/15b74b1050333f425877a7cbd99af2998b95c476/bash_completion#L770C12-L770C12 + # Reassemble command line words, excluding specified characters from the + # list of word completion separators (COMP_WORDBREAKS). + # @param $1 chars Characters out of $COMP_WORDBREAKS which should + # NOT be considered word breaks. This is useful for things like scp where + # we want to return host:path and not only path, so we would pass the + # colon (:) as $1 here. + # @param $2 words Name of variable to return words to + # @param $3 cword Name of variable to return cword to + # + _comp__reassemble_words() +{ + local exclude="" i j line ref + # Exclude word separator characters? + if [[ $1 ]]; then + # Yes, exclude word separator characters; + # Exclude only those characters, which were really included + exclude="[${1//[^$COMP_WORDBREAKS]/}]" + fi + + # Default to cword unchanged + printf -v "$3" %s "$COMP_CWORD" + # Are characters excluded which were former included? + if [[ $exclude ]]; then + # Yes, list of word completion separators has shrunk; + line=$COMP_LINE + # Re-assemble words to complete + for ((i = 0, j = 0; i < ${#COMP_WORDS[@]}; i++, j++)); do + # Is current word not word 0 (the command itself) and is word not + # empty and is word made up of just word separator characters to + # be excluded and is current word not preceded by whitespace in + # original line? + while [[ $i -gt 0 && ${COMP_WORDS[i]} == +($exclude) ]]; do + # Is word separator not preceded by whitespace in original line + # and are we not going to append to word 0 (the command + # itself), then append to current word. + [[ $line != [[:blank:]]* ]] && ((j >= 2)) && ((j--)) + # Append word separator to current or new word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + # Remove optional whitespace + word separator from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate next word if available, else end *both* while and + # for loop + if ((i < ${#COMP_WORDS[@]} - 1)); then + ((i++)) + else + break 2 + fi + # Start new word if word separator in original line is + # followed by whitespace. + [[ $line == [[:blank:]]* ]] && ((j++)) + done + # Append word to current word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Remove optional whitespace + word from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + done + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + else + # No, list of word completions separators hasn't changed; + for i in "${!COMP_WORDS[@]}"; do + printf -v "$2[i]" %s "${COMP_WORDS[i]}" + done + fi +} + + + local FCN_RETURN="" + local IS_PATH=0 + + +local SLS_COMMANDS=" acquire activate adcclk adcenable adcenable10g adcindex adcinvert adclist adcname adcphase adcpipeline adcreg adcvpp apulse asamples autocompdisable badchannels blockingtrigger burstmode burstperiod bursts burstsl bustest cdsgain chipversion clearbit clearbusy clearroi clientversion clkdiv clkfreq clkphase column compdisabletime confadc config counters currentsource dac dacindex daclist dacname dacvalues datastream dbitclk dbitphase dbitpipeline defaultdac defaultpattern delay delayl detectorserverversion detsize diodelay dpulse dr drlist dsamples execcommand exptime exptime1 exptime2 exptime3 exptimel extrastoragecells extsampling extsamplingsrc extsig fformat filtercells filterresistor findex firmwaretest firmwareversion fliprows flowcontrol10g fmaster fname foverwrite fpath framecounter frames framesl frametime free fwrite gaincaps gainmode gappixels gatedelay gatedelay1 gatedelay2 gatedelay3 gates getbit hardwareversion highvoltage hostname im_a im_b im_c im_d im_io imagetest initialchecks inj_ch interpolation interruptsubframe kernelversion lastclient led lock master maxadcphaseshift maxclkphaseshift maxdbitphaseshift measuredperiod measuredsubperiod moduleid nextframenumber nmod numinterfaces overflow packageversion parallel parameters partialreset patfname patioctrl patlimits patloop patloop0 patloop1 patloop2 patmask patnloop patnloop0 patnloop1 patnloop2 patsetbit patternX patternstart patwait patwait0 patwait1 patwait2 patwaittime patwaittime0 patwaittime1 patwaittime2 patword pedestalmode period periodl polarity port powerchip powerindex powerlist powername powervalues programfpga pulse pulsechip pulsenmove pumpprobe quad ratecorr readnrows readout readoutspeed readoutspeedlist rebootcontroller reg resetdacs resetfpga roi romode row runclk runtime rx_arping rx_clearroi rx_dbitlist rx_dbitoffset rx_discardpolicy rx_fifodepth rx_frameindex rx_framescaught rx_framesperfile rx_hostname rx_jsonaddheader rx_jsonpara rx_lastclient rx_lock rx_missingpackets rx_padding rx_printconfig rx_realudpsocksize rx_roi rx_silent rx_start rx_status rx_stop rx_tcpport rx_threads rx_udpsocksize rx_version rx_zmqfreq rx_zmqhwm rx_zmqip rx_zmqport rx_zmqstartfnum rx_zmqstream samples savepattern scan scanerrmsg selinterface serialnumber setbit settings settingslist settingspath signalindex signallist signalname slowadc slowadcindex slowadclist slowadcname slowadcvalues start status stop stopport storagecell_delay storagecell_start subdeadtime subexptime sync syncclk temp_10ge temp_adc temp_control temp_dcdc temp_event temp_fpga temp_fpgaext temp_fpgafl temp_fpgafr temp_slowadc temp_sodl temp_sodr temp_threshold templist tempvalues tengiga threshold thresholdnotb timing timinglist timingsource top transceiverenable trigger triggers triggersl trimbits trimen trimval tsamples txdelay txdelay_frame txdelay_left txdelay_right type udp_cleardst udp_dstip udp_dstip2 udp_dstlist udp_dstmac udp_dstmac2 udp_dstport udp_dstport2 udp_firstdst udp_numdst udp_reconfigure udp_srcip udp_srcip2 udp_srcmac udp_srcmac2 udp_validate update updatedetectorserver updatekernel updatemode user v_a v_b v_c v_chip v_d v_io v_limit vchip_comp_adc vchip_comp_fe vchip_cs vchip_opa_1st vchip_opa_fd vchip_ref_comp_fe versions veto vetoalg vetofile vetophoton vetoref vetostream virtual vm_a vm_b vm_c vm_d vm_io zmqhwm zmqip zmqport " +__acquire() { +FCN_RETURN="" +return 0 +} +__activate() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__adcclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcenable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcenable10g() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcinvert() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adclist() { +FCN_RETURN="" +return 0 +} +__adcname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__adcpipeline() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcreg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcvpp() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__apulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__asamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__autocompdisable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__badchannels() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__blockingtrigger() { +FCN_RETURN="" +return 0 +} +__burstmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="burst_external burst_internal cw_external cw_internal" +fi +fi +return 0 +} +__burstperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__bursts() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__burstsl() { +FCN_RETURN="" +return 0 +} +__bustest() { +FCN_RETURN="" +return 0 +} +__cdsgain() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__chipversion() { +FCN_RETURN="" +return 0 +} +__clearbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clearbusy() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clearroi() { +FCN_RETURN="" +return 0 +} +__clientversion() { +FCN_RETURN="" +return 0 +} +__clkdiv() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clkfreq() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clkphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__column() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__compdisabletime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__confadc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__config() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__counters() { +FCN_RETURN="" +return 0 +} +__currentsource() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="fix nofix" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="low normal" +fi +fi +return 0 +} +__dac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="mV mv" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__dacindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__daclist() { +FCN_RETURN="" +return 0 +} +__dacname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dacvalues() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="mV mv" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__datastream() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="bottom left right top" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="bottom left right top" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__dbitclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dbitphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__dbitpipeline() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__defaultdac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__defaultpattern() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__delay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__delayl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__detectorserverversion() { +FCN_RETURN="" +return 0 +} +__detsize() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__diodelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dpulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__dr() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__drlist() { +FCN_RETURN="" +return 0 +} +__dsamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__execcommand() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__exptime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime1() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime3() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptimel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__extrastoragecells() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__extsampling() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__extsamplingsrc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__extsig() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="inversion_off inversion_on trigger_in_falling_edge trigger_in_rising_edge" +fi +fi +return 0 +} +__fformat() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="binary hdf5" +fi +fi +return 0 +} +__filtercells() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__filterresistor() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__findex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__firmwaretest() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__firmwareversion() { +FCN_RETURN="" +return 0 +} +__fliprows() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__flowcontrol10g() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fmaster() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__foverwrite() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fpath() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__framecounter() { +FCN_RETURN="" +return 0 +} +__frames() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__framesl() { +FCN_RETURN="" +return 0 +} +__frametime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__free() { +FCN_RETURN="" +return 0 +} +__fwrite() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__gaincaps() { +FCN_RETURN="" +return 0 +} +__gainmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="dynamic fixg0 fixg1 fixg2 forceswitchg1 forceswitchg2" +fi +fi +return 0 +} +__gappixels() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__gatedelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay1() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay3() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gates() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__getbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__hardwareversion() { +FCN_RETURN="" +return 0 +} +__highvoltage() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__hostname() { +FCN_RETURN="" +return 0 +} +__im_a() { +FCN_RETURN="" +return 0 +} +__im_b() { +FCN_RETURN="" +return 0 +} +__im_c() { +FCN_RETURN="" +return 0 +} +__im_d() { +FCN_RETURN="" +return 0 +} +__im_io() { +FCN_RETURN="" +return 0 +} +__imagetest() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__initialchecks() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__inj_ch() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__interpolation() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__interruptsubframe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__kernelversion() { +FCN_RETURN="" +return 0 +} +__lastclient() { +FCN_RETURN="" +return 0 +} +__led() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__lock() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__master() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__maxadcphaseshift() { +FCN_RETURN="" +return 0 +} +__maxclkphaseshift() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__maxdbitphaseshift() { +FCN_RETURN="" +return 0 +} +__measuredperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__measuredsubperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__moduleid() { +FCN_RETURN="" +return 0 +} +__nextframenumber() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__nmod() { +FCN_RETURN="" +return 0 +} +__numinterfaces() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__overflow() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__packageversion() { +FCN_RETURN="" +return 0 +} +__parallel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__parameters() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__partialreset() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__patfname() { +FCN_RETURN="" +return 0 +} +__patioctrl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patlimits() { +FCN_RETURN="" +return 0 +} +__patloop() { +FCN_RETURN="" +return 0 +} +__patloop0() { +FCN_RETURN="" +return 0 +} +__patloop1() { +FCN_RETURN="" +return 0 +} +__patloop2() { +FCN_RETURN="" +return 0 +} +__patmask() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patnloop() { +FCN_RETURN="" +return 0 +} +__patnloop0() { +FCN_RETURN="" +return 0 +} +__patnloop1() { +FCN_RETURN="" +return 0 +} +__patnloop2() { +FCN_RETURN="" +return 0 +} +__patsetbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patternX() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patternstart() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patwait() { +FCN_RETURN="" +return 0 +} +__patwait0() { +FCN_RETURN="" +return 0 +} +__patwait1() { +FCN_RETURN="" +return 0 +} +__patwait2() { +FCN_RETURN="" +return 0 +} +__patwaittime() { +FCN_RETURN="" +return 0 +} +__patwaittime0() { +FCN_RETURN="" +return 0 +} +__patwaittime1() { +FCN_RETURN="" +return 0 +} +__patwaittime2() { +FCN_RETURN="" +return 0 +} +__patword() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pedestalmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN=" 0" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__period() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__periodl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__polarity() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="neg pos" +fi +fi +return 0 +} +__port() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powerchip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__powerindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powerlist() { +FCN_RETURN="" +return 0 +} +__powername() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powervalues() { +FCN_RETURN="" +return 0 +} +__programfpga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="--force-delete-normal-file" +fi +fi +return 0 +} +__pulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="--force-delete-normal-file" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pulsechip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pulsenmove() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pumpprobe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__quad() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__ratecorr() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readnrows() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readout() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readoutspeed() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1 108 144 2 full_speed half_speed quarter_speed" +fi +fi +return 0 +} +__readoutspeedlist() { +FCN_RETURN="" +return 0 +} +__rebootcontroller() { +FCN_RETURN="" +return 0 +} +__reg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__resetdacs() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hard" +fi +fi +return 0 +} +__resetfpga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hard" +fi +fi +return 0 +} +__roi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__romode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="analog analog_digital digital digital_transceiver transceiver" +fi +fi +return 0 +} +__row() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__runclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__runtime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__rx_arping() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_clearroi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_dbitlist() { +FCN_RETURN="" +return 0 +} +__rx_dbitoffset() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_discardpolicy() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="discardempty discardpartial nodiscard" +fi +fi +return 0 +} +__rx_fifodepth() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_frameindex() { +FCN_RETURN="" +return 0 +} +__rx_framescaught() { +FCN_RETURN="" +return 0 +} +__rx_framesperfile() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_hostname() { +FCN_RETURN="" +return 0 +} +__rx_jsonaddheader() { +FCN_RETURN="" +return 0 +} +__rx_jsonpara() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_lastclient() { +FCN_RETURN="" +return 0 +} +__rx_lock() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_missingpackets() { +FCN_RETURN="" +return 0 +} +__rx_padding() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_printconfig() { +FCN_RETURN="" +return 0 +} +__rx_realudpsocksize() { +FCN_RETURN="" +return 0 +} +__rx_roi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_silent() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_start() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_status() { +FCN_RETURN="" +return 0 +} +__rx_stop() { +FCN_RETURN="" +return 0 +} +__rx_tcpport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_threads() { +FCN_RETURN="" +return 0 +} +__rx_udpsocksize() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_version() { +FCN_RETURN="" +return 0 +} +__rx_zmqfreq() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqhwm() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqstartfnum() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqstream() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__samples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__savepattern() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__scan() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "6" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__scanerrmsg() { +FCN_RETURN="" +return 0 +} +__selinterface() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__serialnumber() { +FCN_RETURN="" +return 0 +} +__setbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__settings() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__settingslist() { +FCN_RETURN="" +return 0 +} +__settingspath() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__signalindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__signallist() { +FCN_RETURN="" +return 0 +} +__signalname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadcindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadclist() { +FCN_RETURN="" +return 0 +} +__slowadcname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadcvalues() { +FCN_RETURN="" +return 0 +} +__start() { +FCN_RETURN="" +return 0 +} +__status() { +FCN_RETURN="" +return 0 +} +__stop() { +FCN_RETURN="" +return 0 +} +__stopport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__storagecell_delay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__storagecell_start() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__subdeadtime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__subexptime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__sync() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__syncclk() { +FCN_RETURN="" +return 0 +} +__temp_10ge() { +FCN_RETURN="" +return 0 +} +__temp_adc() { +FCN_RETURN="" +return 0 +} +__temp_control() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__temp_dcdc() { +FCN_RETURN="" +return 0 +} +__temp_event() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__temp_fpga() { +FCN_RETURN="" +return 0 +} +__temp_fpgaext() { +FCN_RETURN="" +return 0 +} +__temp_fpgafl() { +FCN_RETURN="" +return 0 +} +__temp_fpgafr() { +FCN_RETURN="" +return 0 +} +__temp_slowadc() { +FCN_RETURN="" +return 0 +} +__temp_sodl() { +FCN_RETURN="" +return 0 +} +__temp_sodr() { +FCN_RETURN="" +return 0 +} +__temp_threshold() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__templist() { +FCN_RETURN="" +return 0 +} +__tempvalues() { +FCN_RETURN="" +return 0 +} +__tengiga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__threshold() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__thresholdnotb() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__timing() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get timinglist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__timinglist() { +FCN_RETURN="" +return 0 +} +__timingsource() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="external internal" +fi +fi +return 0 +} +__top() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__transceiverenable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__trigger() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__triggers() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__triggersl() { +FCN_RETURN="" +return 0 +} +__trimbits() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__trimen() { +FCN_RETURN="" +return 0 +} +__trimval() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__tsamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_frame() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_left() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_right() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__type() { +FCN_RETURN="" +return 0 +} +__udp_cleardst() { +FCN_RETURN="" +return 0 +} +__udp_dstip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstip2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstlist() { +FCN_RETURN="" +return 0 +} +__udp_dstmac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstmac2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstport2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_firstdst() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_numdst() { +FCN_RETURN="" +return 0 +} +__udp_reconfigure() { +FCN_RETURN="" +return 0 +} +__udp_srcip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcip2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcmac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcmac2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_validate() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__update() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatedetectorserver() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatekernel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatemode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__user() { +FCN_RETURN="" +return 0 +} +__v_a() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_b() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_c() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_chip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_d() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_io() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_limit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_comp_adc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_comp_fe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_cs() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_opa_1st() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_opa_fd() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_ref_comp_fe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__versions() { +FCN_RETURN="" +return 0 +} +__veto() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__vetoalg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="10gbe lll none" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hits raw" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="10gbe lll none" +fi +fi +return 0 +} +__vetofile() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetophoton() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetoref() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetostream() { +FCN_RETURN="" +return 0 +} +__virtual() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vm_a() { +FCN_RETURN="" +return 0 +} +__vm_b() { +FCN_RETURN="" +return 0 +} +__vm_c() { +FCN_RETURN="" +return 0 +} +__vm_d() { +FCN_RETURN="" +return 0 +} +__vm_io() { +FCN_RETURN="" +return 0 +} +__zmqhwm() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__zmqip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__zmqport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} + + + COMPREPLY=() + local OPTIONS_NEW="" + + # check if bash or zsh + # _get_comp_words_by_ref is a bash built-in function, we check if it exists + declare -Ff _get_comp_words_by_ref > /dev/null && IS_BASH=1 || IS_BASH=0 + + + # bash interprets the colon character : as a special character and splits the argument in two + # different than what zsh does + # https://stackoverflow.com/a/3224910 + # https://stackoverflow.com/a/12495727 + local cur + local cword words=() + _comp__reassemble_words ":" words cword + cur=${words[cword]} + + # check the action (get or put) + case "${words[0]}" in + "sls_detector_get" | "g" | "detg") + local IS_GET=1 + ;; + *) + local IS_GET=0 + ;; + esac + + # if no command is written, autocomplete with the commands + if [[ ${cword} -eq 1 ]]; then +# local SLS_COMMANDS="trimbits exptime" + local SLS_COMMANDS_NEW="" + + case "$cur" in + [0-9]*:*) + local suggestions=($(compgen -W "${SLS_COMMANDS}" -- "${cur#*:}")) + COMPREPLY=( ${suggestions[*]} ) + ;; + [0-9]*) + COMPREPLY=() + ;; + *) + COMPREPLY=( $( compgen -W "$SLS_COMMANDS -h" -- "$cur" ) );; + + esac + return 0 + fi + + if [[ ${cword} -eq 2 ]] && [[ ${words[1]} == "-h" ]]; then + COMPREPLY=( $( compgen -W "$SLS_COMMANDS" -- "$cur" ) ) + return 0 + fi + + # if a command is written, autocomplete with the options + # call the function for the command + + if [[ "$SLS_COMMANDS" == *"${words[1]##*:}"* ]]; then + __"${words[1]##*:}" + fi + + # if IS_PATH is activated, autocomplete with the path + if [[ ${IS_PATH} -eq 1 ]]; then + COMPREPLY=($(compgen -f -- "${cur}")) + return 0 + fi + + # autocomplete with the options + COMPREPLY=($(compgen -W "${FCN_RETURN}" -- "${cur}")) + + + +} + +complete -F _sd -o filenames sls_detector_get +complete -F _sd -o filenames g +complete -F _sd -o filenames detg + +complete -F _sd -o filenames sls_detector_put +complete -F _sd -o filenames p +complete -F _sd -o filenames detp + +complete -F _sd -o filenames sls_detector +complete -F _sd -o filenames det diff --git a/slsDetectorSoftware/generator/autocomplete/dump.json b/slsDetectorSoftware/generator/autocomplete/dump.json new file mode 100644 index 000000000..d2500d581 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/dump.json @@ -0,0 +1,62035 @@ +{ + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 8539, + "file": "../include/sls/ToString.h", + "line": 271, + "col": 3, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8515, + "line": 270, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3654a48", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 8534, + "line": 270, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8525, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8534, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x3654d08", + "kind": "FunctionDecl", + "loc": { + "offset": 8539, + "line": 271, + "col": 3, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8537, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "T (const std::string &, const std::string &)" + }, + "inner": [ + { + "id": "0x3654b38", + "kind": "ParmVarDecl", + "loc": { + "offset": 8567, + "line": 271, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8548, + "col": 12, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8567, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "t", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "loc": { + "offset": 8589, + "col": 53, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8570, + "col": 34, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8589, + "col": 53, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "unit", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3687658", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8595, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3654fe0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8601, + "line": 272, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8615, + "col": 19, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3654ea0", + "kind": "VarDecl", + "loc": { + "offset": 8608, + "col": 12, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8601, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8614, + "col": 18, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "tval", + "type": { + "qualType": "double" + }, + "init": "list", + "inner": [ + { + "id": "0x3654f80", + "kind": "InitListExpr", + "range": { + "begin": { + "offset": 8612, + "col": 16, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8614, + "col": 18, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3654fc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "castKind": "IntegralToFloating", + "inner": [ + { + "id": "0x3654f08", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0" + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3655488", + "kind": "CXXTryStmt", + "range": { + "begin": { + "offset": 8621, + "line": 273, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36551c0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8625, + "line": 273, + "col": 9, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8660, + "line": 275, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36551a0", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 8635, + "line": 274, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8653, + "col": 27, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "opcode": "=", + "inner": [ + { + "id": "0x3654ff8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8635, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8635, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + }, + { + "id": "0x3655150", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8653, + "col": 27, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3655138", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8647, + "col": 21, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double (*)(const std::string &, std::size_t *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36550a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8647, + "col": 21, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double (const std::string &, std::size_t *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2caf050", + "kind": "FunctionDecl", + "name": "stod", + "type": { + "qualType": "double (const std::string &, std::size_t *)" + } + } + } + ] + }, + { + "id": "0x3655088", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8652, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8652, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654b38", + "kind": "ParmVarDecl", + "name": "t", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3655180", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue" + } + ] + } + ] + } + ] + }, + { + "id": "0x3655468", + "kind": "CXXCatchStmt", + "range": { + "begin": { + "offset": 8662, + "line": 275, + "col": 7, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655290", + "kind": "VarDecl", + "loc": { + "offset": 8698, + "line": 275, + "col": 43, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8669, + "col": 14, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8698, + "col": 43, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "e", + "type": { + "qualType": "const std::invalid_argument &" + } + }, + { + "id": "0x3655450", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8701, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655438", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 8711, + "line": 276, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3655420", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 8711, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36553f0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36553d8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36553b0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x3655390", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3655388", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3655358", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3655340", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3655308", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[33]" + }, + "valueCategory": "lvalue", + "value": "\"Could not convert string to time\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3655560", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8778, + "line": 279, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8805, + "col": 32, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36554b8", + "kind": "UsingDecl", + "loc": { + "offset": 8797, + "col": 24, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8778, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8797, + "col": 24, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "std::chrono::duration" + } + ] + }, + { + "id": "0x3655630", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8811, + "line": 280, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8843, + "col": 37, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655588", + "kind": "UsingDecl", + "loc": { + "offset": 8830, + "col": 24, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8811, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8830, + "col": 24, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "std::chrono::duration_cast" + } + ] + }, + { + "id": "0x3687628", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 8849, + "line": 281, + "col": 5, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x36563f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 8853, + "line": 281, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x36563d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36563b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3655648", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8853, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8853, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x36563a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3655668", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"ns\"" + } + ] + } + ] + }, + { + "id": "0x366ce00", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8867, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8941, + "line": 283, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x366cdf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 8877, + "line": 282, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8934, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x366cdc8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8884, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8934, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3656438", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 8884, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8899, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x366cda0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 8901, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8933, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x366ca28", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x366cd70", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8901, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8933, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x366cb78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36566d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36875f8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 8948, + "line": 283, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x366dbc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 8952, + "line": 283, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x366dba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x366db88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x366ce18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8952, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8952, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x366db70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x366ce38", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"us\"" + } + ] + } + ] + }, + { + "id": "0x3675a60", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8966, + "col": 30, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9041, + "line": 285, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3675a50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 8976, + "line": 284, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9034, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3675a28", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8983, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9034, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x366dc08", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 8983, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8998, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x3675a00", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9000, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9033, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x3675688", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x36759d0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9000, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9033, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36757d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x366dea8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36875c8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 9048, + "line": 285, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x3676820", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 9052, + "line": 285, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3676808", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36767e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3675a78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9052, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9052, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x36767d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3675a98", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"ms\"" + } + ] + } + ] + }, + { + "id": "0x367e6d0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9066, + "col": 30, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9141, + "line": 287, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x367e6c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9076, + "line": 286, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9134, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x367e698", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9083, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9134, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3676868", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9083, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9098, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x367e670", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9100, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9133, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x367e2f8", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x367e640", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9100, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9133, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x367e448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3676b08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3687598", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 9148, + "line": 287, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x367f568", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 9152, + "line": 287, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9178, + "col": 42, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x367f490", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x367f478", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x367f458", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x367e6e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x367f440", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x367e708", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"s\"" + } + ] + } + ] + }, + { + "id": "0x367f518", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9178, + "col": 42, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x367f4e8", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9172, + "col": 36, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "empty", + "isArrow": false, + "referencedMemberDecl": "0x2c94de8", + "inner": [ + { + "id": "0x367f4c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36873f0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9181, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9257, + "line": 289, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36873e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9191, + "line": 288, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9250, + "col": 68, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36873b8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9198, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9250, + "col": 68, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x367f598", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9198, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9213, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x3687390", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9215, + "col": 33, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9249, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration", + "qualType": "std::chrono::duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x3687018", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x3687360", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9215, + "col": 33, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9249, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration", + "qualType": "std::chrono::duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687168", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x367f840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3687580", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9264, + "line": 289, + "col": 12, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687568", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 9274, + "line": 290, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3687550", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 9274, + "line": 290, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687520", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687508", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36874e0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x36874c0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x36874b8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3687488", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687470", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3687418", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[64]" + }, + "valueCategory": "lvalue", + "value": "\"Invalid unit in conversion from string to std::chrono::duration\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 9407, + "file": "../include/sls/ToString.h", + "line": 295, + "col": 25, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9383, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3687690", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 9402, + "line": 295, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9393, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9402, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x3687868", + "kind": "FunctionDecl", + "loc": { + "offset": 9407, + "col": 25, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9405, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "T (const std::string &)" + }, + "inner": [ + { + "id": "0x3687778", + "kind": "ParmVarDecl", + "loc": { + "offset": 9435, + "line": 295, + "col": 53, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9416, + "col": 34, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9435, + "col": 53, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "t", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3688030", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9438, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687b68", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 9444, + "line": 296, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9462, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687a38", + "kind": "VarDecl", + "loc": { + "offset": 9456, + "col": 17, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9444, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9461, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "list", + "inner": [ + { + "id": "0x3687b38", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9456, + "col": 17, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9461, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::basic_string &)" + }, + "list": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687aa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9460, + "col": 21, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9460, + "col": 21, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687778", + "kind": "ParmVarDecl", + "name": "t", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x3687ef0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 9468, + "line": 297, + "col": 5, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9495, + "col": 32, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687bc0", + "kind": "VarDecl", + "loc": { + "offset": 9473, + "col": 10, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9468, + "col": 5, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "unit", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "c", + "inner": [ + { + "id": "0x3687ed8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3687ea8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (std::basic_string &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687e60", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3687d50", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "temp": "0x3687d48", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3687d20", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687d08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "std::string (*)(std::string &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3687c90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "std::string (std::string &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2fb3d48", + "kind": "FunctionDecl", + "name": "RemoveUnit", + "type": { + "qualType": "std::string (std::string &)" + } + } + } + ] + }, + { + "id": "0x3687c70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9491, + "col": 28, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9491, + "col": 28, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687a38", + "kind": "VarDecl", + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3688020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9501, + "line": 298, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9529, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687ff0", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9508, + "col": 12, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9529, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687f30", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9508, + "col": 12, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9518, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "StringTo", + "lookups": [ + { + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + } + ] + }, + { + "id": "0x3687fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9520, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9520, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687a38", + "kind": "VarDecl", + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + }, + { + "id": "0x3687fd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9525, + "col": 29, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9525, + "col": 29, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687bc0", + "kind": "VarDecl", + "name": "unit", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3849458", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::detectorType (const std::string &)" + } + }, + { + "id": "0x3850318", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + } + }, + { + "id": "0x3866a58", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + } + }, + { + "id": "0x386e798", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::timingMode (const std::string &)" + } + }, + { + "id": "0x3873968", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + } + }, + { + "id": "0x3876e78", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + } + }, + { + "id": "0x38794b8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + } + }, + { + "id": "0x387d838", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + } + }, + { + "id": "0x3882a18", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + } + }, + { + "id": "0x7f1964638418", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::burstMode (const std::string &)" + } + }, + { + "id": "0x7f196463c788", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + } + }, + { + "id": "0x7f196463edd8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + } + }, + { + "id": "0x7f1964644df8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::portPosition (const std::string &)" + } + }, + { + "id": "0x38d72a8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + } + }, + { + "id": "0x38dae78", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + } + }, + { + "id": "0x38dd4b8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::gainMode (const std::string &)" + } + }, + { + "id": "0x38e34f8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::polarity (const std::string &)" + } + }, + { + "id": "0x38e5ae8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "uint32_t (const std::string &)" + } + }, + { + "id": "0x38e62f8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "uint64_t (const std::string &)" + } + }, + { + "id": "0x38e6af0", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "int (const std::string &)" + } + }, + { + "id": "0x38e72d8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "bool (const std::string &)" + } + }, + { + "id": "0x38e7b28", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "int64_t (const std::string &)" + } + } + ] +} +{ + "id": "0x3688208", + "kind": "FunctionDecl", + "loc": { + "offset": 9566, + "file": "../include/sls/ToString.h", + "line": 301, + "col": 32, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9535, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9595, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688438", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12detectorTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "inner": [ + { + "id": "0x2f41f40", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "decl": { + "id": "0x2f41ea0", + "kind": "EnumDecl", + "name": "detectorType" + } + } + ] + }, + { + "id": "0x3688100", + "kind": "ParmVarDecl", + "loc": { + "offset": 9594, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9575, + "col": 41, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9594, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3688728", + "kind": "FunctionDecl", + "loc": { + "offset": 9633, + "file": "../include/sls/ToString.h", + "line": 302, + "col": 36, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9598, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9662, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688958", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16detectorSettingsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "inner": [ + { + "id": "0x2f5a2c0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "decl": { + "id": "0x2f5a218", + "kind": "EnumDecl", + "name": "detectorSettings" + } + } + ] + }, + { + "id": "0x3688620", + "kind": "ParmVarDecl", + "loc": { + "offset": 9661, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9642, + "col": 45, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9661, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3688c48", + "kind": "FunctionDecl", + "loc": { + "offset": 9694, + "file": "../include/sls/ToString.h", + "line": 303, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9665, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9723, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688e78", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10speedLevelEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "inner": [ + { + "id": "0x2f5af70", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "decl": { + "id": "0x2f5aec8", + "kind": "EnumDecl", + "name": "speedLevel" + } + } + ] + }, + { + "id": "0x3688b40", + "kind": "ParmVarDecl", + "loc": { + "offset": 9722, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9703, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9722, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3689168", + "kind": "FunctionDecl", + "loc": { + "offset": 9755, + "file": "../include/sls/ToString.h", + "line": 304, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9726, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9784, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3689398", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10timingModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "inner": [ + { + "id": "0x2f57730", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "decl": { + "id": "0x2f57688", + "kind": "EnumDecl", + "name": "timingMode" + } + } + ] + }, + { + "id": "0x3689060", + "kind": "ParmVarDecl", + "loc": { + "offset": 9783, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9764, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9783, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3689688", + "kind": "FunctionDecl", + "loc": { + "offset": 9824, + "file": "../include/sls/ToString.h", + "line": 305, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9787, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9853, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x36898b8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18frameDiscardPolicyEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "inner": [ + { + "id": "0x2f554b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "decl": { + "id": "0x2f55410", + "kind": "EnumDecl", + "name": "frameDiscardPolicy" + } + } + ] + }, + { + "id": "0x3689580", + "kind": "ParmVarDecl", + "loc": { + "offset": 9852, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9833, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9852, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3689ba8", + "kind": "FunctionDecl", + "loc": { + "offset": 9885, + "file": "../include/sls/ToString.h", + "line": 306, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9856, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9914, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3689dd8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10fileFormatEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "inner": [ + { + "id": "0x2f556b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "decl": { + "id": "0x2f55610", + "kind": "EnumDecl", + "name": "fileFormat" + } + } + ] + }, + { + "id": "0x3689aa0", + "kind": "ParmVarDecl", + "loc": { + "offset": 9913, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9894, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9913, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368abf0", + "kind": "FunctionDecl", + "loc": { + "offset": 9954, + "file": "../include/sls/ToString.h", + "line": 307, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9917, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9983, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368ae28", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18externalSignalFlagEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "inner": [ + { + "id": "0x2f57500", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "decl": { + "id": "0x2f57458", + "kind": "EnumDecl", + "name": "externalSignalFlag" + } + } + ] + }, + { + "id": "0x3689fc0", + "kind": "ParmVarDecl", + "loc": { + "offset": 9982, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9963, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9982, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368b118", + "kind": "FunctionDecl", + "loc": { + "offset": 10016, + "file": "../include/sls/ToString.h", + "line": 308, + "col": 31, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9986, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10045, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368b348", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11readoutModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "inner": [ + { + "id": "0x2f5acf0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "decl": { + "id": "0x2f5ac48", + "kind": "EnumDecl", + "name": "readoutMode" + } + } + ] + }, + { + "id": "0x368b010", + "kind": "ParmVarDecl", + "loc": { + "offset": 10044, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10025, + "col": 40, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10044, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368b638", + "kind": "FunctionDecl", + "loc": { + "offset": 10075, + "file": "../include/sls/ToString.h", + "line": 309, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10048, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10104, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368b868", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8dacIndexEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "inner": [ + { + "id": "0x2f57a00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "decl": { + "id": "0x2f57958", + "kind": "EnumDecl", + "name": "dacIndex" + } + } + ] + }, + { + "id": "0x368b530", + "kind": "ParmVarDecl", + "loc": { + "offset": 10103, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10084, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10103, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368bb58", + "kind": "FunctionDecl", + "loc": { + "offset": 10135, + "file": "../include/sls/ToString.h", + "line": 310, + "col": 29, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10107, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10164, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368bd88", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs9burstModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::burstMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "inner": [ + { + "id": "0x2f5b1f0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "decl": { + "id": "0x2f5b148", + "kind": "EnumDecl", + "name": "burstMode" + } + } + ] + }, + { + "id": "0x368ba50", + "kind": "ParmVarDecl", + "loc": { + "offset": 10163, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10144, + "col": 38, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10163, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368c078", + "kind": "FunctionDecl", + "loc": { + "offset": 10202, + "file": "../include/sls/ToString.h", + "line": 311, + "col": 36, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10167, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10231, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368c2a8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16timingSourceTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "inner": [ + { + "id": "0x2f5b470", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "decl": { + "id": "0x2f5b3c8", + "kind": "EnumDecl", + "name": "timingSourceType" + } + } + ] + }, + { + "id": "0x368bf70", + "kind": "ParmVarDecl", + "loc": { + "offset": 10230, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10211, + "col": 45, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10230, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368c598", + "kind": "FunctionDecl", + "loc": { + "offset": 10264, + "file": "../include/sls/ToString.h", + "line": 312, + "col": 31, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10234, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10293, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368c7c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11M3_GainCapsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "inner": [ + { + "id": "0x2f5b5d0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "decl": { + "id": "0x2f5b530", + "kind": "EnumDecl", + "name": "M3_GainCaps" + } + } + ] + }, + { + "id": "0x368c490", + "kind": "ParmVarDecl", + "loc": { + "offset": 10292, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10273, + "col": 40, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10292, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368cab8", + "kind": "FunctionDecl", + "loc": { + "offset": 10327, + "file": "../include/sls/ToString.h", + "line": 313, + "col": 32, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10296, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10356, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368cce8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12portPositionEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::portPosition (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "inner": [ + { + "id": "0x2f5bc00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "decl": { + "id": "0x2f5bb60", + "kind": "EnumDecl", + "name": "portPosition" + } + } + ] + }, + { + "id": "0x368c9b0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10355, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10336, + "col": 41, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10355, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368cfd8", + "kind": "FunctionDecl", + "loc": { + "offset": 10396, + "file": "../include/sls/ToString.h", + "line": 314, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10359, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10425, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368d208", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18streamingInterfaceEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "inner": [ + { + "id": "0x2f5bf90", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "decl": { + "id": "0x2f5bef0", + "kind": "EnumDecl", + "name": "streamingInterface" + } + } + ] + }, + { + "id": "0x368ced0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10424, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10405, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10424, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368d4f8", + "kind": "FunctionDecl", + "loc": { + "offset": 10460, + "file": "../include/sls/ToString.h", + "line": 315, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10428, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10489, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368d728", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs13vetoAlgorithmEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "inner": [ + { + "id": "0x2f5c350", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "decl": { + "id": "0x2f5c2b0", + "kind": "EnumDecl", + "name": "vetoAlgorithm" + } + } + ] + }, + { + "id": "0x368d3f0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10488, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10469, + "col": 42, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10488, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368da18", + "kind": "FunctionDecl", + "loc": { + "offset": 10519, + "file": "../include/sls/ToString.h", + "line": 316, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10492, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10548, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368dc48", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8gainModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::gainMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "inner": [ + { + "id": "0x2f5c4b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "decl": { + "id": "0x2f5c410", + "kind": "EnumDecl", + "name": "gainMode" + } + } + ] + }, + { + "id": "0x368d910", + "kind": "ParmVarDecl", + "loc": { + "offset": 10547, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10528, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10547, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368df38", + "kind": "FunctionDecl", + "loc": { + "offset": 10578, + "file": "../include/sls/ToString.h", + "line": 317, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10551, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10607, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368e168", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8polarityEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::polarity (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "inner": [ + { + "id": "0x2f5c750", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "decl": { + "id": "0x2f5c6b0", + "kind": "EnumDecl", + "name": "polarity" + } + } + ] + }, + { + "id": "0x368de30", + "kind": "ParmVarDecl", + "loc": { + "offset": 10606, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10587, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10606, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368e408", + "kind": "FunctionDecl", + "loc": { + "offset": 10632, + "file": "../include/sls/ToString.h", + "line": 319, + "col": 22, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10611, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10661, + "col": 51, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368e608", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIjEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint32_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned int" + }, + "inner": [ + { + "id": "0x230bbd0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned int" + } + } + ] + }, + { + "id": "0x368e310", + "kind": "ParmVarDecl", + "loc": { + "offset": 10660, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10641, + "col": 31, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10660, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368e8a8", + "kind": "FunctionDecl", + "loc": { + "offset": 10685, + "file": "../include/sls/ToString.h", + "line": 320, + "col": 22, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10664, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10714, + "col": 51, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368eaa8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToImEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned long" + }, + "inner": [ + { + "id": "0x230bbf0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned long" + } + } + ] + }, + { + "id": "0x368e7b0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10713, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10694, + "col": 31, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10713, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368ed50", + "kind": "FunctionDecl", + "loc": { + "offset": 10733, + "file": "../include/sls/ToString.h", + "line": 321, + "col": 17, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10717, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10762, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368ef58", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIiEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "int" + }, + "inner": [ + { + "id": "0x230bb30", + "kind": "BuiltinType", + "type": { + "qualType": "int" + } + } + ] + }, + { + "id": "0x368ec50", + "kind": "ParmVarDecl", + "loc": { + "offset": 10761, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10742, + "col": 26, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10761, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368f1c8", + "kind": "FunctionDecl", + "loc": { + "offset": 10782, + "file": "../include/sls/ToString.h", + "line": 322, + "col": 18, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10765, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10811, + "col": 47, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368f3c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIbEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "bool (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "bool" + }, + "inner": [ + { + "id": "0x230bab0", + "kind": "BuiltinType", + "type": { + "qualType": "bool" + } + } + ] + }, + { + "id": "0x368f100", + "kind": "ParmVarDecl", + "loc": { + "offset": 10810, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10791, + "col": 27, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10810, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x368f668", + "kind": "FunctionDecl", + "loc": { + "offset": 10834, + "file": "../include/sls/ToString.h", + "line": 323, + "col": 21, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10814, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10863, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368f868", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIlEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "long" + }, + "inner": [ + { + "id": "0x230bb50", + "kind": "BuiltinType", + "type": { + "qualType": "long" + } + } + ] + }, + { + "id": "0x368f570", + "kind": "ParmVarDecl", + "loc": { + "offset": 10862, + "col": 49, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10843, + "col": 30, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10862, + "col": 49, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +} +{ + "id": "0x3690758", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 11100, + "file": "../include/sls/ToString.h", + "line": 333, + "col": 16, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11063, + "line": 332, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3690160", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 11082, + "line": 332, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11073, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11082, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x36906b8", + "kind": "FunctionDecl", + "loc": { + "offset": 11100, + "line": 333, + "col": 16, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11085, + "col": 1, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "std::vector (const std::vector &)" + }, + "inner": [ + { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "loc": { + "offset": 11141, + "line": 333, + "col": 57, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11109, + "col": 25, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11141, + "col": 57, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + }, + { + "id": "0x36bd368", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 11150, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3690a40", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11156, + "line": 334, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11177, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36909d8", + "kind": "VarDecl", + "loc": { + "offset": 11171, + "col": 20, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11156, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11171, + "col": 20, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "nrvo": true + } + ] + }, + { + "id": "0x36b69a8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11183, + "line": 335, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11212, + "col": 34, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3690a78", + "kind": "CXXDependentScopeMemberExpr", + "range": { + "begin": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11190, + "col": 12, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "isArrow": false, + "member": "reserve", + "inner": [ + { + "id": "0x3690a58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + }, + { + "id": "0x36b6490", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11211, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::vector::size_type", + "typeAliasDeclId": "0x29007b8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36b6460", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11206, + "col": 28, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "size", + "isArrow": false, + "referencedMemberDecl": "0x36a9e90", + "inner": [ + { + "id": "0x3690ac0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd140", + "kind": "CXXForRangeStmt", + "range": { + "begin": { + "offset": 11219, + "line": 336, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11288, + "line": 337, + "col": 40, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + {}, + { + "id": "0x36b6d50", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11240, + "line": 336, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6b50", + "kind": "VarDecl", + "loc": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__range2", + "type": { + "qualType": "const std::vector &" + }, + "init": "c", + "inner": [ + { + "id": "0x36b69d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + }, + { + "id": "0x36bb028", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6de8", + "kind": "VarDecl", + "loc": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "init": "c", + "inner": [ + { + "id": "0x36babf8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36babc8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (__gnu_cxx::__normal_iterator *, std::vector>> &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36ba968", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36b6f88", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36b6f58", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "begin", + "isArrow": false, + "referencedMemberDecl": "0x36a9440", + "inner": [ + { + "id": "0x36b6d68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6b50", + "kind": "VarDecl", + "name": "__range2", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bb040", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6e90", + "kind": "VarDecl", + "loc": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__end2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "init": "c", + "inner": [ + { + "id": "0x36bb010", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bafe0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (__gnu_cxx::__normal_iterator *, std::vector>> &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36bafc8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36baca0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bac70", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "end", + "isArrow": false, + "referencedMemberDecl": "0x36a9600", + "inner": [ + { + "id": "0x36b6d88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6b50", + "kind": "VarDecl", + "name": "__range2", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bcd60", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x36bcd48", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bccd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36bb9d0", + "kind": "FunctionDecl", + "name": "operator!=", + "type": { + "qualType": "bool (const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + } + } + } + ] + }, + { + "id": "0x36bcca0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const __gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "const __normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bb058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + }, + { + "id": "0x36bccb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const __gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "const __normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bb078", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6e90", + "kind": "VarDecl", + "name": "__end2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + } + ] + }, + { + "id": "0x36bce50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x36bce38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &(*)() noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bcdb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &() noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b8d20", + "kind": "CXXMethodDecl", + "name": "operator++", + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &() noexcept" + } + } + } + ] + }, + { + "id": "0x36bcd98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + }, + { + "id": "0x36b6ac8", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11224, + "col": 10, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11247, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6a60", + "kind": "VarDecl", + "loc": { + "offset": 11236, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11224, + "col": 10, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "s", + "type": { + "qualType": "std::basic_string const &" + }, + "init": "c", + "inner": [ + { + "id": "0x36bcf70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::basic_string" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x36bcf58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference (*)() const noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bcee0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference () const noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b8aa0", + "kind": "CXXMethodDecl", + "name": "operator*", + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference () const noexcept" + } + } + } + ] + }, + { + "id": "0x36bcec8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const __gnu_cxx::__normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bce80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd308", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11257, + "line": 337, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11288, + "col": 40, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bd1c0", + "kind": "CXXDependentScopeMemberExpr", + "range": { + "begin": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11264, + "col": 16, + "tokLen": 9, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "isArrow": false, + "member": "push_back", + "inner": [ + { + "id": "0x36bd1a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + }, + { + "id": "0x36bd2e0", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11274, + "col": 26, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11287, + "col": 39, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bd238", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 11274, + "col": 26, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11284, + "col": 36, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "StringTo", + "lookups": [ + { + "id": "0x3690758", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + } + ] + }, + { + "id": "0x36bd2c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11286, + "col": 38, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11286, + "col": 38, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "std::basic_string const" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6a60", + "kind": "VarDecl", + "name": "s", + "type": { + "qualType": "std::basic_string const &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd350", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 11295, + "line": 338, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36bd330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3849458", + "kind": "FunctionDecl", + "loc": { + "offset": 20783, + "file": "ToString.cpp", + "line": 665, + "col": 32, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 20752, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 21262, + "line": 681, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688208", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12detectorTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "inner": [ + { + "id": "0x2f41f40", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "decl": { + "id": "0x2f41ea0", + "kind": "EnumDecl", + "name": "detectorType" + } + } + ] + }, + { + "id": "0x3849388", + "kind": "ParmVarDecl", + "loc": { + "offset": 20811, + "line": 665, + "col": 60, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 20792, + "col": 41, + "tokLen": 5 + }, + "end": { + "offset": 20811, + "col": 60, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3850148", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 20814, + "col": 63, + "tokLen": 1 + }, + "end": { + "offset": 21262, + "line": 681, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x384a460", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20820, + "line": 666, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20859, + "line": 667, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x384a3b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20824, + "line": 666, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384a398", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20826, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20826, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384a378", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20826, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20826, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3849610", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20824, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20824, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384a360", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20829, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3849630", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20829, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"Eiger\"" + } + ] + } + ] + }, + { + "id": "0x384a450", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20846, + "line": 667, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20859, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x384a420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20853, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20859, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f41fb0", + "kind": "EnumConstantDecl", + "name": "EIGER", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384b2d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20870, + "line": 668, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20912, + "line": 669, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384b220", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20874, + "line": 668, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384b208", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20876, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20876, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384b1e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20876, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20876, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384a480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20874, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20874, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384b1d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20879, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384a4a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20879, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"Gotthard\"" + } + ] + } + ] + }, + { + "id": "0x384b2c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20899, + "line": 669, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20912, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384b290", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20906, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20912, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42000", + "kind": "EnumConstantDecl", + "name": "GOTTHARD", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384c140", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20926, + "line": 670, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20968, + "line": 671, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384c090", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20930, + "line": 670, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384c078", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384c058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384b2f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20930, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384c040", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384b310", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"Jungfrau\"" + } + ] + } + ] + }, + { + "id": "0x384c130", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20955, + "line": 671, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20968, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384c100", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20962, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20968, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42050", + "kind": "EnumConstantDecl", + "name": "JUNGFRAU", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384cfc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20982, + "line": 672, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21029, + "line": 673, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x384cf10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20986, + "line": 672, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384cef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20988, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20988, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ced8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20988, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20988, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384c160", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20986, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20986, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384cec0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20991, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384c180", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20991, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"ChipTestBoard\"" + } + ] + } + ] + }, + { + "id": "0x384cfb0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21016, + "line": 673, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21029, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x384cf80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21023, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21029, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f420a0", + "kind": "EnumConstantDecl", + "name": "CHIPTESTBOARD", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384de30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21048, + "line": 674, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21088, + "line": 675, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x384dd80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21052, + "line": 674, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384dd68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21054, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21054, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384dd48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21054, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21054, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384cfe0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21052, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21052, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384dd30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21057, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384d000", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21057, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"Moench\"" + } + ] + } + ] + }, + { + "id": "0x384de20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21075, + "line": 675, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21088, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x384ddf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21082, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21088, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f420f0", + "kind": "EnumConstantDecl", + "name": "MOENCH", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384eca0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21100, + "line": 676, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21141, + "line": 677, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x384ebf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21104, + "line": 676, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384ebd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21106, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21106, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ebb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21106, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21106, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384de50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21104, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21104, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384eba0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21109, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384de70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21109, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"Mythen3\"" + } + ] + } + ] + }, + { + "id": "0x384ec90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21128, + "line": 677, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21141, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x384ec60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21135, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21141, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42140", + "kind": "EnumConstantDecl", + "name": "MYTHEN3", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384fb20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21154, + "line": 678, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21197, + "line": 679, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x384fa70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21158, + "line": 678, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384fa58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21160, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21160, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384fa38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21160, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21160, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384ecc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21158, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21158, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384fa20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21163, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384ece0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21163, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"Gotthard2\"" + } + ] + } + ] + }, + { + "id": "0x384fb10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21184, + "line": 679, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21197, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x384fae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21191, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21197, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42190", + "kind": "EnumConstantDecl", + "name": "GOTTHARD2", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x3850130", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 21212, + "line": 680, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3850118", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 21212, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38500e8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38500d0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38500a8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3850088", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3850080", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3850050", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3850038", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3850020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3850000", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x384fff8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x384ffc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384ffa8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21256, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 21256, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ff88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21256, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 21256, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x384ff70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21231, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384fb50", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21231, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown detector type \"" + } + ] + }, + { + "id": "0x384fb80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21258, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3850318", + "kind": "FunctionDecl", + "loc": { + "offset": 21300, + "file": "ToString.cpp", + "line": 683, + "col": 36, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 21265, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 22549, + "line": 725, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688728", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16detectorSettingsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "inner": [ + { + "id": "0x2f5a2c0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "decl": { + "id": "0x2f5a218", + "kind": "EnumDecl", + "name": "detectorSettings" + } + } + ] + }, + { + "id": "0x3850240", + "kind": "ParmVarDecl", + "loc": { + "offset": 21328, + "line": 683, + "col": 64, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 21309, + "col": 45, + "tokLen": 5 + }, + "end": { + "offset": 21328, + "col": 64, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3866820", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 21331, + "col": 67, + "tokLen": 1 + }, + "end": { + "offset": 22549, + "line": 725, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3851320", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21337, + "line": 684, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21379, + "line": 685, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3851270", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21341, + "line": 684, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3851258", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21343, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21343, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3851238", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21343, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21343, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38504d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21341, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21341, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3851220", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21346, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38504f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21346, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"standard\"" + } + ] + } + ] + }, + { + "id": "0x3851310", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21366, + "line": 685, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21379, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38512e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21373, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21379, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a2e0", + "kind": "EnumConstantDecl", + "name": "STANDARD", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3855dc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21393, + "line": 686, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21431, + "line": 687, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3855d10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21397, + "line": 686, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3855cf8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21399, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21399, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3855cd8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21399, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21399, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3851340", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21397, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21397, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3855cc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21402, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3851360", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21402, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"fast\"" + } + ] + } + ] + }, + { + "id": "0x3855db0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21418, + "line": 687, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21431, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3855d80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21425, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21431, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a330", + "kind": "EnumConstantDecl", + "name": "FAST", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3856c30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21441, + "line": 688, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21483, + "line": 689, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3856b80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21445, + "line": 688, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3856b68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21447, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21447, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3856b48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21447, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21447, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3855de0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21445, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21445, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3856b30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21450, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3855e00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21450, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"highgain\"" + } + ] + } + ] + }, + { + "id": "0x3856c20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21470, + "line": 689, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21483, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3856bf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21477, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21483, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a380", + "kind": "EnumConstantDecl", + "name": "HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3857ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21497, + "line": 690, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21542, + "line": 691, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3857a00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21501, + "line": 690, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38579e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21503, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21503, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38579c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21503, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21503, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3856c50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21501, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21501, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38579b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21506, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3856c70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21506, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"dynamicgain\"" + } + ] + } + ] + }, + { + "id": "0x3857aa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21529, + "line": 691, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21542, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3857a70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21536, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21542, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a3d0", + "kind": "EnumConstantDecl", + "name": "DYNAMICGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3858920", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21559, + "line": 692, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21600, + "line": 693, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x3858870", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21563, + "line": 692, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3858858", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3858838", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3857ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21563, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21563, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3858820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3857af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"lowgain\"" + } + ] + } + ] + }, + { + "id": "0x3858910", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21587, + "line": 693, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21600, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38588e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21594, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21600, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a420", + "kind": "EnumConstantDecl", + "name": "LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38597a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21613, + "line": 694, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21657, + "line": 695, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38596f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21617, + "line": 694, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38596d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38596b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3858940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21617, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21617, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38596a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21622, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3858960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21622, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"mediumgain\"" + } + ] + } + ] + }, + { + "id": "0x3859790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21644, + "line": 695, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21657, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3859760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21651, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21657, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a470", + "kind": "EnumConstantDecl", + "name": "MEDIUMGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385a620", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21673, + "line": 696, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21719, + "line": 697, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x385a570", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21677, + "line": 696, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385a558", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21679, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21679, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385a538", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21679, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21679, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38597c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21677, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21677, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385a520", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21682, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38597e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21682, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"veryhighgain\"" + } + ] + } + ] + }, + { + "id": "0x385a610", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21706, + "line": 697, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21719, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x385a5e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21713, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21719, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a4c0", + "kind": "EnumConstantDecl", + "name": "VERYHIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385b4a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21737, + "line": 698, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21780, + "line": 699, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x385b3f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21741, + "line": 698, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385b3d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21743, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21743, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385b3b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21743, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21743, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385a640", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21741, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21741, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385b3a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21746, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385a660", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21746, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"highgain0\"" + } + ] + } + ] + }, + { + "id": "0x385b490", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21767, + "line": 699, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21780, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x385b460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21774, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21780, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a510", + "kind": "EnumConstantDecl", + "name": "HIGHGAIN0", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385c310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21795, + "line": 700, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21837, + "line": 701, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385c260", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21799, + "line": 700, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385c248", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21801, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21801, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385c228", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21801, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21801, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385b4c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21799, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21799, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385c210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21804, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385b4e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21804, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"fixgain1\"" + } + ] + } + ] + }, + { + "id": "0x385c300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21824, + "line": 701, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21837, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385c2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21831, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21837, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a560", + "kind": "EnumConstantDecl", + "name": "FIXGAIN1", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385d180", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21851, + "line": 702, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21893, + "line": 703, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385d0d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21855, + "line": 702, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385d0b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385d098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385c330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21855, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21855, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385d080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21860, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385c350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21860, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"fixgain2\"" + } + ] + } + ] + }, + { + "id": "0x385d170", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21880, + "line": 703, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21893, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385d140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21887, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21893, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a5b0", + "kind": "EnumConstantDecl", + "name": "FIXGAIN2", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385e000", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21907, + "line": 704, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21952, + "line": 705, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385df50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21911, + "line": 704, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385df38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385df18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385d1a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21911, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21911, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385df00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21916, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385d1c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21916, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"verylowgain\"" + } + ] + } + ] + }, + { + "id": "0x385dff0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21939, + "line": 705, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21952, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385dfc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21946, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21952, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a600", + "kind": "EnumConstantDecl", + "name": "VERYLOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385ee70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21969, + "line": 706, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22008, + "line": 707, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385edc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21973, + "line": 706, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385eda8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21975, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21975, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385ed88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21975, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21975, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385e020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21973, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21973, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385ed70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21978, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385e040", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21978, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g1_hg\"" + } + ] + } + ] + }, + { + "id": "0x385ee60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21995, + "line": 707, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22008, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385ee30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22002, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22008, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a650", + "kind": "EnumConstantDecl", + "name": "G1_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385fce0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22025, + "line": 708, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22064, + "line": 709, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x385fc30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22029, + "line": 708, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385fc18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22031, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22031, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385fbf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22031, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22031, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385ee90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22029, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22029, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385fbe0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22034, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385eeb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22034, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g1_lg\"" + } + ] + } + ] + }, + { + "id": "0x385fcd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22051, + "line": 709, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22064, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x385fca0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22058, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22064, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a6a0", + "kind": "EnumConstantDecl", + "name": "G1_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3860b50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22080, + "line": 710, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22122, + "line": 711, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x3860aa0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22084, + "line": 710, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3860a88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22086, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22086, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3860a68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22086, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22086, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385fd00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22084, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22084, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3860a50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22089, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385fd20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22089, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_hc_hg\"" + } + ] + } + ] + }, + { + "id": "0x3860b40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22109, + "line": 711, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22122, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x3860b10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22116, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22122, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a6f0", + "kind": "EnumConstantDecl", + "name": "G2_HIGHCAP_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38619c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22147, + "line": 712, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22189, + "line": 713, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3861910", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22151, + "line": 712, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38618f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38618d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3860b70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22151, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22151, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38618c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22156, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3860b90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22156, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_hc_lg\"" + } + ] + } + ] + }, + { + "id": "0x38619b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22176, + "line": 713, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22189, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3861980", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22183, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22189, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a740", + "kind": "EnumConstantDecl", + "name": "G2_HIGHCAP_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3862830", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22213, + "line": 714, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22255, + "line": 715, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3862780", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22217, + "line": 714, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3862768", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22219, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22219, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3862748", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22219, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22219, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38619e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22217, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22217, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3862730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22222, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3861a00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22222, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_lc_hg\"" + } + ] + } + ] + }, + { + "id": "0x3862820", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22242, + "line": 715, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22255, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x38627f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22249, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22255, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a790", + "kind": "EnumConstantDecl", + "name": "G2_LOWCAP_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38636a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22279, + "line": 716, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22321, + "line": 717, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x38635f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22283, + "line": 716, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38635d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22285, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22285, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38635b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22285, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22285, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3862850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22283, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22283, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38635a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22288, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3862870", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22288, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_lc_lg\"" + } + ] + } + ] + }, + { + "id": "0x3863690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22308, + "line": 717, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22321, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x3863660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22315, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22321, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a7e0", + "kind": "EnumConstantDecl", + "name": "G2_LOWCAP_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3864510", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22344, + "line": 718, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22383, + "line": 719, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3864460", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22348, + "line": 718, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3864448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3864428", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38636c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22348, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22348, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3864410", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22353, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38636e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22353, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g4_hg\"" + } + ] + } + ] + }, + { + "id": "0x3864500", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22370, + "line": 719, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22383, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38644d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22377, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22383, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a830", + "kind": "EnumConstantDecl", + "name": "G4_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3865390", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22400, + "line": 720, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22439, + "line": 721, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38652e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22404, + "line": 720, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38652c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38652a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3864530", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22404, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22404, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3865290", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22409, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3864550", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22409, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"gain0\"" + } + ] + } + ] + }, + { + "id": "0x3865380", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22426, + "line": 721, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22439, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3865350", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22433, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22439, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a8d0", + "kind": "EnumConstantDecl", + "name": "GAIN0", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3866200", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22450, + "line": 722, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22489, + "line": 723, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3866150", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22454, + "line": 722, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3866138", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22456, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22456, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3866118", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22456, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22456, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38653b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22454, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22454, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3866100", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22459, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38653d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22459, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g4_lg\"" + } + ] + } + ] + }, + { + "id": "0x38661f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22476, + "line": 723, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22489, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38661c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22483, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22489, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a880", + "kind": "EnumConstantDecl", + "name": "G4_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3866808", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 22505, + "line": 724, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38667f0", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 22505, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38667c0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38667a8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3866780", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3866760", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3866758", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3866728", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3866710", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38666f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38666d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38666d0", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3866698", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3866680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22543, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 22543, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3866660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22543, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 22543, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3866648", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22524, + "col": 24, + "tokLen": 18 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3866230", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22524, + "col": 24, + "tokLen": 18 + } + }, + "type": { + "qualType": "const char[17]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown setting \"" + } + ] + }, + { + "id": "0x3866258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22545, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3866a58", + "kind": "FunctionDecl", + "loc": { + "offset": 22581, + "file": "ToString.cpp", + "line": 727, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 22552, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23106, + "line": 745, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688c48", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10speedLevelEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "inner": [ + { + "id": "0x2f5af70", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "decl": { + "id": "0x2f5aec8", + "kind": "EnumDecl", + "name": "speedLevel" + } + } + ] + }, + { + "id": "0x3866980", + "kind": "ParmVarDecl", + "loc": { + "offset": 22609, + "line": 727, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 22590, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 22609, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x386e5c0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 22612, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 23106, + "line": 745, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3867a70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22618, + "line": 728, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22662, + "line": 729, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38679c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22622, + "line": 728, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38679a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22624, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22624, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3867988", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22624, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22624, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3866c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22622, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22622, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3867970", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22627, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3866c30", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22627, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"full_speed\"" + } + ] + } + ] + }, + { + "id": "0x3867a60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22649, + "line": 729, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22662, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3867a30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22656, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22662, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5af90", + "kind": "EnumConstantDecl", + "name": "FULL_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x38688e0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22678, + "line": 730, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22713, + "line": 731, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3868830", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22682, + "line": 730, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3868818", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22684, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22684, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38687f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22684, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22684, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3867a90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22682, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22682, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38687e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22687, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3867ab0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22687, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"0\"" + } + ] + } + ] + }, + { + "id": "0x38688d0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22700, + "line": 731, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22713, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38688a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22707, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22713, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5af90", + "kind": "EnumConstantDecl", + "name": "FULL_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x3869760", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22729, + "line": 732, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22773, + "line": 733, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38696b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22733, + "line": 732, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3869698", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22735, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22735, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3869678", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22735, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22735, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3868900", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22733, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22733, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3869660", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22738, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3868920", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22738, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"half_speed\"" + } + ] + } + ] + }, + { + "id": "0x3869750", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22760, + "line": 733, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22773, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3869720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22767, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22773, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5afe0", + "kind": "EnumConstantDecl", + "name": "HALF_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386a5d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22789, + "line": 734, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22824, + "line": 735, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x386a520", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22793, + "line": 734, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386a508", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22795, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22795, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386a4e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22795, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22795, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3869780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22793, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22793, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386a4d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22798, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38697a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22798, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"1\"" + } + ] + } + ] + }, + { + "id": "0x386a5c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22811, + "line": 735, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22824, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x386a590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22818, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22824, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5afe0", + "kind": "EnumConstantDecl", + "name": "HALF_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386b450", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22840, + "line": 736, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22887, + "line": 737, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386b3a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22844, + "line": 736, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386b388", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22846, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22846, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386b368", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22846, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22846, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386a5f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22844, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22844, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386b350", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22849, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386a610", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22849, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"quarter_speed\"" + } + ] + } + ] + }, + { + "id": "0x386b440", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22874, + "line": 737, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22887, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386b410", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22881, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22887, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b030", + "kind": "EnumConstantDecl", + "name": "QUARTER_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386c2c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22906, + "line": 738, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22941, + "line": 739, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386c210", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22910, + "line": 738, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386c1f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22912, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22912, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386c1d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22912, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22912, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386b470", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22910, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22910, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386c1c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22915, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386b490", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22915, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"2\"" + } + ] + } + ] + }, + { + "id": "0x386c2b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22928, + "line": 739, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22941, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386c280", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22935, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22941, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b030", + "kind": "EnumConstantDecl", + "name": "QUARTER_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386d130", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22960, + "line": 740, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22997, + "line": 741, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386d080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22964, + "line": 740, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386d068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22966, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22966, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386d048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22966, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22966, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386c2e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22964, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22964, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386d030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22969, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386c300", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22969, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"108\"" + } + ] + } + ] + }, + { + "id": "0x386d120", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22984, + "line": 741, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22997, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386d0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22991, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22997, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b080", + "kind": "EnumConstantDecl", + "name": "G2_108MHZ", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386dfa0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23012, + "line": 742, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23049, + "line": 743, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386def0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23016, + "line": 742, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386ded8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23018, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23018, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386deb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23018, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23018, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386d150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23016, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23016, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386dea0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23021, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386d170", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23021, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"144\"" + } + ] + } + ] + }, + { + "id": "0x386df90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23036, + "line": 743, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23049, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386df60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23043, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23049, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b0d0", + "kind": "EnumConstantDecl", + "name": "G2_144MHZ", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386e5a8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23064, + "line": 744, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x386e590", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23064, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x386e560", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x386e548", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x386e520", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x386e500", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x386e4f8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x386e4c8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x386e4b0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x386e498", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x386e478", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x386e470", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x386e438", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386e420", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23100, + "col": 41, + "tokLen": 1 + }, + "end": { + "offset": 23100, + "col": 41, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386e400", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23100, + "col": 41, + "tokLen": 1 + }, + "end": { + "offset": 23100, + "col": 41, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x386e3e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23083, + "col": 24, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386dfd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23083, + "col": 24, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown speed \"" + } + ] + }, + { + "id": "0x386dff8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23102, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x386e798", + "kind": "FunctionDecl", + "loc": { + "offset": 23138, + "file": "ToString.cpp", + "line": 747, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23109, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23525, + "line": 759, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689168", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10timingModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "inner": [ + { + "id": "0x2f57730", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "decl": { + "id": "0x2f57688", + "kind": "EnumDecl", + "name": "timingMode" + } + } + ] + }, + { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "loc": { + "offset": 23166, + "line": 747, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23147, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 23166, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38737a8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23169, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 23525, + "line": 759, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x386f7a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23175, + "line": 748, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23213, + "line": 749, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x386f6f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23179, + "line": 748, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386f6d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23181, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23181, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386f6b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23181, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23181, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386e950", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23179, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23179, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386f6a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23184, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386e970", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23184, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"auto\"" + } + ] + } + ] + }, + { + "id": "0x386f790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23200, + "line": 749, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23213, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x386f760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23207, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23213, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57750", + "kind": "EnumConstantDecl", + "name": "AUTO_TIMING", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3870610", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23230, + "line": 750, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23271, + "line": 751, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3870560", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23234, + "line": 750, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3870548", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23236, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23236, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3870528", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23236, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23236, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386f7c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23234, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23234, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3870510", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23239, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386f7e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23239, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"trigger\"" + } + ] + } + ] + }, + { + "id": "0x3870600", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23258, + "line": 751, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23271, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38705d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23265, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23271, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f577a0", + "kind": "EnumConstantDecl", + "name": "TRIGGER_EXPOSURE", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3871480", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23293, + "line": 752, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23333, + "line": 753, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38713d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23297, + "line": 752, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38713b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23299, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23299, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3871398", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23299, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23299, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3870630", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23297, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23297, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3871380", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23302, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3870650", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23302, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"gating\"" + } + ] + } + ] + }, + { + "id": "0x3871470", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23320, + "line": 753, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23333, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3871440", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23327, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23333, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f577f0", + "kind": "EnumConstantDecl", + "name": "GATED", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3872300", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23344, + "line": 754, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23391, + "line": 755, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x3872250", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23348, + "line": 754, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3872238", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3872218", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38714a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23348, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23348, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3872200", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23353, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38714c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23353, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"burst_trigger\"" + } + ] + } + ] + }, + { + "id": "0x38722f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23378, + "line": 755, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23391, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38722c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23385, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23391, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57840", + "kind": "EnumConstantDecl", + "name": "BURST_TRIGGER", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3873180", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23410, + "line": 756, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23458, + "line": 757, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38730d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23414, + "line": 756, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38730b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23416, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23416, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3873098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23416, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23416, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3872320", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23414, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23414, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3873080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23419, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3872340", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23419, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_gating\"" + } + ] + } + ] + }, + { + "id": "0x3873170", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23445, + "line": 757, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23458, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x3873140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23452, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23458, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57890", + "kind": "EnumConstantDecl", + "name": "TRIGGER_GATED", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3873790", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23477, + "line": 758, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3873778", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23477, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3873748", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3873730", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3873708", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38736e8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38736e0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38736b0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3873698", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3873680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3873660", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3873658", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3873620", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3873608", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23519, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 23519, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38735e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23519, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 23519, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38735d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23496, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38731b0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23496, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char[21]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown timing mode \"" + } + ] + }, + { + "id": "0x38731e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23521, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3873968", + "kind": "FunctionDecl", + "loc": { + "offset": 23565, + "file": "ToString.cpp", + "line": 761, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23528, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23866, + "line": 769, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689688", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18frameDiscardPolicyEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "inner": [ + { + "id": "0x2f554b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "decl": { + "id": "0x2f55410", + "kind": "EnumDecl", + "name": "frameDiscardPolicy" + } + } + ] + }, + { + "id": "0x3873890", + "kind": "ParmVarDecl", + "loc": { + "offset": 23593, + "line": 761, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23574, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 23593, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3876cd0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23596, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 23866, + "line": 769, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3874980", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23602, + "line": 762, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23645, + "line": 763, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38748d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23606, + "line": 762, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38748b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23608, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23608, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3874898", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23608, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23608, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3873b20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23606, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23606, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3874880", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23611, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3873b40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23611, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"nodiscard\"" + } + ] + } + ] + }, + { + "id": "0x3874970", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23632, + "line": 763, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23645, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3874940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23639, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23645, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f554d0", + "kind": "EnumConstantDecl", + "name": "NO_DISCARD", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x3875820", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23661, + "line": 764, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23707, + "line": 765, + "col": 22, + "tokLen": 20 + } + }, + "inner": [ + { + "id": "0x3875770", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23665, + "line": 764, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3875758", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23667, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23667, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3875738", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23667, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23667, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38749a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23665, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23665, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3875720", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23670, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38749c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23670, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"discardempty\"" + } + ] + } + ] + }, + { + "id": "0x3875810", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23694, + "line": 765, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23707, + "col": 22, + "tokLen": 20 + } + }, + "inner": [ + { + "id": "0x38757e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23701, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23707, + "col": 22, + "tokLen": 20 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55520", + "kind": "EnumConstantDecl", + "name": "DISCARD_EMPTY_FRAMES", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x38766a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23733, + "line": 766, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23781, + "line": 767, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x38765f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23737, + "line": 766, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38765d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23739, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23739, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38765b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23739, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23739, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3875840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23737, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23737, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38765a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23742, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3875860", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23742, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"discardpartial\"" + } + ] + } + ] + }, + { + "id": "0x3876690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23768, + "line": 767, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23781, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x3876660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23775, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23781, + "col": 22, + "tokLen": 22 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55570", + "kind": "EnumConstantDecl", + "name": "DISCARD_PARTIAL_FRAMES", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x3876cb8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23809, + "line": 768, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3876ca0", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23809, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3876c70", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3876c58", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3876c30", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3876c10", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3876c08", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3876bd8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3876bc0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3876ba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3876b88", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3876b80", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3876b48", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3876b30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23860, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 23860, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3876b10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23860, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 23860, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3876af8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23828, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38766d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23828, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char[30]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown frame discard policy \"" + } + ] + }, + { + "id": "0x3876708", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23862, + "col": 58, + "tokLen": 1 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3876e78", + "kind": "FunctionDecl", + "loc": { + "offset": 23898, + "file": "ToString.cpp", + "line": 771, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23869, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24083, + "line": 777, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689ba8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10fileFormatEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "inner": [ + { + "id": "0x2f556b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "decl": { + "id": "0x2f55610", + "kind": "EnumDecl", + "name": "fileFormat" + } + } + ] + }, + { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "loc": { + "offset": 23926, + "line": 771, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23907, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 23926, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3879318", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23929, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 24083, + "line": 777, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3877e80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23935, + "line": 772, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23973, + "line": 773, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3877dd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23939, + "line": 772, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3877db8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23941, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23941, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3877d98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23941, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23941, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3877030", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23939, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23939, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3877d80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23944, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3877050", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23944, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"hdf5\"" + } + ] + } + ] + }, + { + "id": "0x3877e70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23960, + "line": 773, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23973, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3877e40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23967, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23973, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55720", + "kind": "EnumConstantDecl", + "name": "HDF5", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + } + } + } + ] + } + ] + }, + { + "id": "0x3878cf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23983, + "line": 774, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24023, + "line": 775, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3878c40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23987, + "line": 774, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3878c28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23989, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23989, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3878c08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23989, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23989, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3877ea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23987, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23987, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3878bf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23992, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3877ec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23992, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"binary\"" + } + ] + } + ] + }, + { + "id": "0x3878ce0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24010, + "line": 775, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24023, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3878cb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24017, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24023, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f556d0", + "kind": "EnumConstantDecl", + "name": "BINARY", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + } + } + } + ] + } + ] + }, + { + "id": "0x3879300", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24035, + "line": 776, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38792e8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24035, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38792b8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38792a0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3879278", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3879258", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3879250", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3879220", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3879208", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38791f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38791d0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38791c8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3879190", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3879178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24077, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 24077, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3879158", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24077, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 24077, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3879140", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24054, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3878d20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24054, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char[21]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown file format \"" + } + ] + }, + { + "id": "0x3878d50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24079, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38794b8", + "kind": "FunctionDecl", + "loc": { + "offset": 24123, + "file": "ToString.cpp", + "line": 779, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24086, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24517, + "line": 789, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368abf0", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18externalSignalFlagEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "inner": [ + { + "id": "0x2f57500", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "decl": { + "id": "0x2f57458", + "kind": "EnumDecl", + "name": "externalSignalFlag" + } + } + ] + }, + { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "loc": { + "offset": 24151, + "line": 779, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 24132, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 24151, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x387d680", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 24154, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 24517, + "line": 789, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x387a4d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24160, + "line": 780, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24216, + "line": 781, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x387a420", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24164, + "line": 780, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387a408", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24166, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24166, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387a3e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24166, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24166, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3879670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24164, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24164, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387a3d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24169, + "col": 14, + "tokLen": 24 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3879690", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24169, + "col": 14, + "tokLen": 24 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_in_rising_edge\"" + } + ] + } + ] + }, + { + "id": "0x387a4c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24203, + "line": 781, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24216, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x387a490", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24210, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24216, + "col": 22, + "tokLen": 22 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57520", + "kind": "EnumConstantDecl", + "name": "TRIGGER_IN_RISING_EDGE", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387b350", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24244, + "line": 782, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24301, + "line": 783, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x387b2a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24248, + "line": 782, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387b288", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24250, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24250, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387b268", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24250, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24250, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387a4f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24248, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24248, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387b250", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24253, + "col": 14, + "tokLen": 25 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387a510", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24253, + "col": 14, + "tokLen": 25 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char[24]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_in_falling_edge\"" + } + ] + } + ] + }, + { + "id": "0x387b340", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24288, + "line": 783, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24301, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x387b310", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24295, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24301, + "col": 22, + "tokLen": 23 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57570", + "kind": "EnumConstantDecl", + "name": "TRIGGER_IN_FALLING_EDGE", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387c1d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24330, + "line": 784, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24376, + "line": 785, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387c120", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24334, + "line": 784, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387c108", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24336, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24336, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387c0e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24336, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24336, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387b370", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24334, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24334, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387c0d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24339, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387b390", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24339, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"inversion_on\"" + } + ] + } + ] + }, + { + "id": "0x387c1c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24363, + "line": 785, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24376, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387c190", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24370, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24376, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f575c0", + "kind": "EnumConstantDecl", + "name": "INVERSION_ON", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387d050", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24394, + "line": 786, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24441, + "line": 787, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x387cfa0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24398, + "line": 786, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387cf88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24400, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24400, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387cf68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24400, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24400, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387c1f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24398, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24398, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387cf50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24403, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387c210", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24403, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"inversion_off\"" + } + ] + } + ] + }, + { + "id": "0x387d040", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24428, + "line": 787, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24441, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x387d010", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24435, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24441, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57610", + "kind": "EnumConstantDecl", + "name": "INVERSION_OFF", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387d668", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24460, + "line": 788, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x387d650", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24460, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x387d620", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x387d608", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x387d5e0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x387d5c0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x387d5b8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x387d588", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x387d570", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x387d558", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x387d538", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x387d530", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x387d4f8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387d4e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24511, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 24511, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387d4c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24511, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 24511, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x387d4a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24479, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387d080", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24479, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char[30]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown external signal flag \"" + } + ] + }, + { + "id": "0x387d0b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24513, + "col": 58, + "tokLen": 1 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x387d838", + "kind": "FunctionDecl", + "loc": { + "offset": 24550, + "file": "ToString.cpp", + "line": 791, + "col": 31, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24520, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24973, + "line": 803, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368b118", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11readoutModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "inner": [ + { + "id": "0x2f5acf0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "decl": { + "id": "0x2f5ac48", + "kind": "EnumDecl", + "name": "readoutMode" + } + } + ] + }, + { + "id": "0x387d760", + "kind": "ParmVarDecl", + "loc": { + "offset": 24578, + "line": 791, + "col": 59, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 24559, + "col": 40, + "tokLen": 5 + }, + "end": { + "offset": 24578, + "col": 59, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3882858", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 24581, + "col": 62, + "tokLen": 1 + }, + "end": { + "offset": 24973, + "line": 803, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x387e840", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24587, + "line": 792, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24627, + "line": 793, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x387e790", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24591, + "line": 792, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387e778", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24593, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24593, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387e758", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24593, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24593, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387d9f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24591, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24591, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387e740", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24596, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387da10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24596, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"analog\"" + } + ] + } + ] + }, + { + "id": "0x387e830", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24614, + "line": 793, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24627, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x387e800", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24621, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24627, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ad10", + "kind": "EnumConstantDecl", + "name": "ANALOG_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x387f6b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24644, + "line": 794, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24685, + "line": 795, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387f600", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24648, + "line": 794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387f5e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24650, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24650, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387f5c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24650, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24650, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387e860", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24648, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24648, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387f5b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24653, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387e880", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24653, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"digital\"" + } + ] + } + ] + }, + { + "id": "0x387f6a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24672, + "line": 795, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24685, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387f670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24679, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24685, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ad60", + "kind": "EnumConstantDecl", + "name": "DIGITAL_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3880530", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24703, + "line": 796, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24751, + "line": 797, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3880480", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24707, + "line": 796, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3880468", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24709, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24709, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3880448", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24709, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24709, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387f6d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24707, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24707, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3880430", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24712, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387f6f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24712, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"analog_digital\"" + } + ] + } + ] + }, + { + "id": "0x3880520", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24738, + "line": 797, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24751, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x38804f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24745, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24751, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5adb0", + "kind": "EnumConstantDecl", + "name": "ANALOG_AND_DIGITAL", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38813b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24775, + "line": 798, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24820, + "line": 799, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3881300", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24779, + "line": 798, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38812e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24781, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24781, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38812c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24781, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24781, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3880550", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24779, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24779, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38812b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24784, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3880570", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24784, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"transceiver\"" + } + ] + } + ] + }, + { + "id": "0x38813a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24807, + "line": 799, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24820, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3881370", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24814, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24820, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ae00", + "kind": "EnumConstantDecl", + "name": "TRANSCEIVER_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3882230", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24842, + "line": 800, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24895, + "line": 801, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x3882180", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24846, + "line": 800, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3882168", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24848, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24848, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3882148", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24848, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24848, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38813d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24846, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24846, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3882130", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24851, + "col": 14, + "tokLen": 21 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38813f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24851, + "col": 14, + "tokLen": 21 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char[20]" + }, + "valueCategory": "lvalue", + "value": "\"digital_transceiver\"" + } + ] + } + ] + }, + { + "id": "0x3882220", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24882, + "line": 801, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24895, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x38821f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24889, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24895, + "col": 22, + "tokLen": 23 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ae50", + "kind": "EnumConstantDecl", + "name": "DIGITAL_AND_TRANSCEIVER", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3882840", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24924, + "line": 802, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3882828", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24924, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38827f8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38827e0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38827b8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3882798", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3882790", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3882760", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3882748", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3882730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3882710", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3882708", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38826d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38826b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24967, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 24967, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3882698", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24967, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 24967, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3882680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24943, + "col": 24, + "tokLen": 23 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3882260", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24943, + "col": 24, + "tokLen": 23 + } + }, + "type": { + "qualType": "const char[22]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown readout mode \"" + } + ] + }, + { + "id": "0x3882290", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24969, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x3882a18", + "kind": "FunctionDecl", + "loc": { + "offset": 25003, + "file": "ToString.cpp", + "line": 805, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24976, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 30397, + "line": 991, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368b638", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8dacIndexEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "inner": [ + { + "id": "0x2f57a00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "decl": { + "id": "0x2f57958", + "kind": "EnumDecl", + "name": "dacIndex" + } + } + ] + }, + { + "id": "0x3882940", + "kind": "ParmVarDecl", + "loc": { + "offset": 25031, + "line": 805, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 25012, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 25031, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f1964637fa8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 25034, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 30397, + "line": 991, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3884820", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25040, + "line": 806, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25091, + "line": 807, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3884788", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25044, + "line": 806, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3883970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25044, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3883958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25046, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25046, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3883938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25046, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25046, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3882bd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25044, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25044, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3883920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25049, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3882bf0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25049, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 0\"" + } + ] + } + ] + }, + { + "id": "0x3884750", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25060, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3884738", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25062, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25062, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3884718", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25062, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25062, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38839a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25060, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25060, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3884700", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25065, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38839c8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25065, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"0\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3884810", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25078, + "line": 807, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25091, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38847e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25085, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25091, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57a20", + "kind": "EnumConstantDecl", + "name": "DAC_0", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38864d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25102, + "line": 808, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25153, + "line": 809, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3886438", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25106, + "line": 808, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3885620", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25106, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3885608", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25108, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25108, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38855e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25108, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25108, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3884840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25106, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25106, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38855d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25111, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3884860", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25111, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 1\"" + } + ] + } + ] + }, + { + "id": "0x3886400", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25122, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38863e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25124, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25124, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38863c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25124, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25124, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3885658", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25122, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25122, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38863b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25127, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3885678", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25127, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"1\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38864c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25140, + "line": 809, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25153, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3886490", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25147, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25153, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57a70", + "kind": "EnumConstantDecl", + "name": "DAC_1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3888140", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25164, + "line": 810, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25215, + "line": 811, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38880a8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25168, + "line": 810, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3887290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25168, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3887278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25170, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25170, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3887258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25170, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25170, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38864f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25168, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25168, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3887240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25173, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3886510", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25173, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 2\"" + } + ] + } + ] + }, + { + "id": "0x3888070", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25184, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3888058", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25186, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25186, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3888038", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25186, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25186, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38872c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25184, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25184, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3888020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25189, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38872e8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25189, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"2\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3888130", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25202, + "line": 811, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25215, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3888100", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25209, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25215, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ac0", + "kind": "EnumConstantDecl", + "name": "DAC_2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3889db0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25226, + "line": 812, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25277, + "line": 813, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3889d18", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25230, + "line": 812, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3888f00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25230, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3888ee8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25232, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25232, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3888ec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25232, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25232, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3888160", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25230, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25230, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3888eb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25235, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3888180", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25235, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 3\"" + } + ] + } + ] + }, + { + "id": "0x3889ce0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25246, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3889cc8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25248, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25248, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3889ca8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25248, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25248, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3888f38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25246, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25246, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3889c90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25251, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3888f58", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25251, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"3\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3889da0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25264, + "line": 813, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25277, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3889d70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25271, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25277, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57b10", + "kind": "EnumConstantDecl", + "name": "DAC_3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388ba20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25288, + "line": 814, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25339, + "line": 815, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388b988", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25292, + "line": 814, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388ab70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25292, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388ab58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25294, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25294, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388ab38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25294, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25294, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3889dd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25292, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25292, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388ab20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25297, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3889df0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25297, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 4\"" + } + ] + } + ] + }, + { + "id": "0x388b950", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25308, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388b938", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25310, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25310, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388b918", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25310, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25310, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388aba8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25308, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25308, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388b900", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25313, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388abc8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25313, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"4\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388ba10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25326, + "line": 815, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25339, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388b9e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25333, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25339, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57b60", + "kind": "EnumConstantDecl", + "name": "DAC_4", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388d690", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25350, + "line": 816, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25401, + "line": 817, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388d5f8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25354, + "line": 816, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388c7e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25354, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388c7c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25356, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25356, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388c7a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25356, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25356, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388ba40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25354, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25354, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388c790", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25359, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388ba60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25359, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 5\"" + } + ] + } + ] + }, + { + "id": "0x388d5c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25370, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388d5a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25372, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25372, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388d588", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25372, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25372, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388c818", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25370, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25370, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388d570", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25375, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388c838", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25375, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"5\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388d680", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25388, + "line": 817, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25401, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388d650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25395, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25401, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57bb0", + "kind": "EnumConstantDecl", + "name": "DAC_5", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388f300", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25412, + "line": 818, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25463, + "line": 819, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388f268", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25416, + "line": 818, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388e450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25416, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388e438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25418, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25418, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388e418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25418, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25418, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388d6b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25416, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25416, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388e400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25421, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388d6d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25421, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 6\"" + } + ] + } + ] + }, + { + "id": "0x388f230", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25432, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388f218", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25434, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25434, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388f1f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25434, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25434, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388e488", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25432, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25432, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388f1e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25437, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388e4a8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25437, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"6\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388f2f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25450, + "line": 819, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25463, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388f2c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25457, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25463, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57c00", + "kind": "EnumConstantDecl", + "name": "DAC_6", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3890f70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25474, + "line": 820, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25525, + "line": 821, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3890ed8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25478, + "line": 820, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38900c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25478, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38900a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25480, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25480, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3890088", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25480, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25480, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388f320", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25478, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25478, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3890070", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25483, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388f340", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25483, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 7\"" + } + ] + } + ] + }, + { + "id": "0x3890ea0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25494, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3890e88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25496, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25496, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3890e68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25496, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25496, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38900f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25494, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25494, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3890e50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25499, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3890118", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25499, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"7\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3890f60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25512, + "line": 821, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25525, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3890f30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25519, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25525, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57c50", + "kind": "EnumConstantDecl", + "name": "DAC_7", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3892be0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25536, + "line": 822, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25587, + "line": 823, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3892b48", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25540, + "line": 822, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3891d30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25540, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3891d18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25542, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25542, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3891cf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25542, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25542, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3890f90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25540, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25540, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3891ce0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25545, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3890fb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25545, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 8\"" + } + ] + } + ] + }, + { + "id": "0x3892b10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25556, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3892af8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25558, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25558, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3892ad8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25558, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25558, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3891d68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25556, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25556, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3892ac0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25561, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3891d88", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25561, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"8\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3892bd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25574, + "line": 823, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25587, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3892ba0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25581, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25587, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ca0", + "kind": "EnumConstantDecl", + "name": "DAC_8", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3894850", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25598, + "line": 824, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25649, + "line": 825, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38947b8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25602, + "line": 824, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38939a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3893988", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3893968", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3892c00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25602, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3893950", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25607, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3892c20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25607, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 9\"" + } + ] + } + ] + }, + { + "id": "0x3894780", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25618, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3894768", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25620, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25620, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3894748", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25620, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25620, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38939d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25618, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25618, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3894730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25623, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38939f8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25623, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"9\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3894840", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25636, + "line": 825, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25649, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3894810", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25643, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25649, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57cf0", + "kind": "EnumConstantDecl", + "name": "DAC_9", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38964e0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25660, + "line": 826, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25713, + "line": 827, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3896448", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25664, + "line": 826, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3895630", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25664, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3895618", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25666, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25666, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38955f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25666, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25666, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3894870", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25664, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25664, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38955e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25669, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3894890", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25669, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 10\"" + } + ] + } + ] + }, + { + "id": "0x3896410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25681, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38963f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25683, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25683, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38963d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25683, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25683, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3895668", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25681, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25681, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38963c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25686, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3895688", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25686, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"10\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38964d0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25700, + "line": 827, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25713, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38964a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25707, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25713, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57d40", + "kind": "EnumConstantDecl", + "name": "DAC_10", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3898150", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25725, + "line": 828, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25778, + "line": 829, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38980b8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25729, + "line": 828, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38972a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25729, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3897288", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25731, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25731, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3897268", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25731, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25731, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3896500", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25729, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25729, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3897250", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25734, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3896520", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25734, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 11\"" + } + ] + } + ] + }, + { + "id": "0x3898080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25746, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3898068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25748, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25748, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3898048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25748, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25748, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38972d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25746, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25746, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3898030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25751, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38972f8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25751, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"11\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3898140", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25765, + "line": 829, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25778, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3898110", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25772, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25778, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57d90", + "kind": "EnumConstantDecl", + "name": "DAC_11", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3899dc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25790, + "line": 830, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25843, + "line": 831, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3899d28", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25794, + "line": 830, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3898f10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3898ef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25796, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25796, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3898ed8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25796, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25796, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3898170", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25794, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3898ec0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25799, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3898190", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25799, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 12\"" + } + ] + } + ] + }, + { + "id": "0x3899cf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25811, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3899cd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25813, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25813, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3899cb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25813, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25813, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3898f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25811, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25811, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3899ca0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25816, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3898f68", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25816, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"12\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3899db0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25830, + "line": 831, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25843, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3899d80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25837, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25843, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57de0", + "kind": "EnumConstantDecl", + "name": "DAC_12", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389ba30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25855, + "line": 832, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25908, + "line": 833, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389b998", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25859, + "line": 832, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389ab80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25859, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389ab68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25861, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25861, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389ab48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25861, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25861, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3899de0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25859, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25859, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389ab30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25864, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3899e00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25864, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 13\"" + } + ] + } + ] + }, + { + "id": "0x389b960", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25876, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389b948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25878, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25878, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389b928", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25878, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25878, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389abb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25876, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25876, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389b910", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25881, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389abd8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25881, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"13\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389ba20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25895, + "line": 833, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25908, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389b9f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25902, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25908, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57e30", + "kind": "EnumConstantDecl", + "name": "DAC_13", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389d6a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25920, + "line": 834, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25973, + "line": 835, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389d608", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25924, + "line": 834, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389c7f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389c7d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25926, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25926, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389c7b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25926, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25926, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389ba50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25924, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389c7a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25929, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389ba70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25929, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 14\"" + } + ] + } + ] + }, + { + "id": "0x389d5d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25941, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389d5b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25943, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25943, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389d598", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25943, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25943, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389c828", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25941, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25941, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389d580", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25946, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389c848", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25946, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"14\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389d690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25960, + "line": 835, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25973, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389d660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25967, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25973, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57e80", + "kind": "EnumConstantDecl", + "name": "DAC_14", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389f310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25985, + "line": 836, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26038, + "line": 837, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389f278", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25989, + "line": 836, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389e460", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25989, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389e448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25991, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25991, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389e428", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25991, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25991, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389d6c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25989, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25989, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389e410", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25994, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389d6e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25994, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 15\"" + } + ] + } + ] + }, + { + "id": "0x389f240", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26006, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389f228", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26008, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26008, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389f208", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26008, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26008, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389e498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26006, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26006, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389f1f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26011, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389e4b8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26011, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"15\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389f300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26025, + "line": 837, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26038, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389f2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26032, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26038, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ed0", + "kind": "EnumConstantDecl", + "name": "DAC_15", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a0f80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26050, + "line": 838, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26103, + "line": 839, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a0ee8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 26054, + "line": 838, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38a00d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26054, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a00b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26056, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26056, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a0098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26056, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26056, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389f330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26054, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26054, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a0080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26059, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389f350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26059, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 16\"" + } + ] + } + ] + }, + { + "id": "0x38a0eb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26071, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a0e98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26073, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26073, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a0e78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26073, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26073, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a0108", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26071, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26071, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a0e60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26076, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a0128", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26076, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"16\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38a0f70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26090, + "line": 839, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26103, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a0f40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26097, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26103, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57f20", + "kind": "EnumConstantDecl", + "name": "DAC_16", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a2bf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26115, + "line": 840, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26168, + "line": 841, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a2b58", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 26119, + "line": 840, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38a1d40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26119, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a1d28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26121, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26121, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a1d08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26121, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26121, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a0fa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26119, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26119, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a1cf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26124, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a0fc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26124, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 17\"" + } + ] + } + ] + }, + { + "id": "0x38a2b20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26136, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a2b08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26138, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26138, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a2ae8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26138, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26138, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a1d78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26136, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26136, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a2ad0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26141, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a1d98", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26141, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"17\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38a2be0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26155, + "line": 841, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26168, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a2bb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26162, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26168, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57f70", + "kind": "EnumConstantDecl", + "name": "DAC_17", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a3a60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26180, + "line": 842, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26218, + "line": 843, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a39b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26184, + "line": 842, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a3998", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26186, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26186, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a3978", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26186, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26186, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a2c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26184, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26184, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a3960", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26189, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a2c30", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26189, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vsvp\"" + } + ] + } + ] + }, + { + "id": "0x38a3a50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26205, + "line": 843, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26218, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a3a20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26212, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26218, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57fc0", + "kind": "EnumConstantDecl", + "name": "VSVP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a48d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26228, + "line": 844, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26267, + "line": 845, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38a4820", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26232, + "line": 844, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a4808", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26234, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26234, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a47e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26234, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26234, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a3a80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26232, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26232, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a47d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26237, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a3aa0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26237, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vtrim\"" + } + ] + } + ] + }, + { + "id": "0x38a48c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26254, + "line": 845, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26267, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38a4890", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26261, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26267, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58010", + "kind": "EnumConstantDecl", + "name": "VTRIM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a5760", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26278, + "line": 846, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26320, + "line": 847, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a56b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26282, + "line": 846, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a5698", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26284, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26284, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a5678", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26284, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26284, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a48f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26282, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26282, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a5660", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26287, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a4910", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26287, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vrpreamp\"" + } + ] + } + ] + }, + { + "id": "0x38a5750", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26307, + "line": 847, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26320, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a5720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26314, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26320, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58060", + "kind": "EnumConstantDecl", + "name": "VRPREAMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a65d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26334, + "line": 848, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26376, + "line": 849, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a6520", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26338, + "line": 848, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a6508", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26340, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26340, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a64e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26340, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26340, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a5780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26338, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26338, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a64d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26343, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a57a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26343, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vrshaper\"" + } + ] + } + ] + }, + { + "id": "0x38a65c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26363, + "line": 849, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26376, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a6590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26370, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26376, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f580b0", + "kind": "EnumConstantDecl", + "name": "VRSHAPER", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a7440", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26390, + "line": 850, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26428, + "line": 851, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a7390", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26394, + "line": 850, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a7378", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26396, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26396, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a7358", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26396, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26396, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a65f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26394, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26394, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a7340", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26399, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a6610", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26399, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vsvn\"" + } + ] + } + ] + }, + { + "id": "0x38a7430", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26415, + "line": 851, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26428, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a7400", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26422, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26428, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58100", + "kind": "EnumConstantDecl", + "name": "VSVN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a82b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26438, + "line": 852, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26478, + "line": 853, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a8200", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26442, + "line": 852, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a81e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26444, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26444, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a81c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26444, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26444, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a7460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26442, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26442, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a81b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26447, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a7480", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26447, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vtgstv\"" + } + ] + } + ] + }, + { + "id": "0x38a82a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26465, + "line": 853, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26478, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a8270", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26472, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26478, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58150", + "kind": "EnumConstantDecl", + "name": "VTGSTV", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a9120", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26490, + "line": 854, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26531, + "line": 855, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9070", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26494, + "line": 854, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a9058", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26496, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26496, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a9038", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26496, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26496, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a82d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26494, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26494, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a9020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26499, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a82f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26499, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_ll\"" + } + ] + } + ] + }, + { + "id": "0x38a9110", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26518, + "line": 855, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26531, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a90e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26525, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26531, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f581a0", + "kind": "EnumConstantDecl", + "name": "VCMP_LL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a9f90", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26544, + "line": 856, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26585, + "line": 857, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9ee0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26548, + "line": 856, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a9ec8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26550, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26550, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a9ea8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26550, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26550, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a9140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26548, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26548, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a9e90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26553, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a9160", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26553, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_lr\"" + } + ] + } + ] + }, + { + "id": "0x38a9f80", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26572, + "line": 857, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26585, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9f50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26579, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26585, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f581f0", + "kind": "EnumConstantDecl", + "name": "VCMP_LR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38aae00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26598, + "line": 858, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26636, + "line": 859, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38aad50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26602, + "line": 858, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38aad38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38aad18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a9fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26602, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38aad00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26607, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a9fd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26607, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vcal\"" + } + ] + } + ] + }, + { + "id": "0x38aadf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26623, + "line": 859, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26636, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38aadc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26630, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26636, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58240", + "kind": "EnumConstantDecl", + "name": "VCAL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38abc70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26646, + "line": 860, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26687, + "line": 861, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38abbc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26650, + "line": 860, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38abba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26652, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26652, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38abb88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26652, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26652, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38aae20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26650, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26650, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38abb70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26655, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38aae40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26655, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_rl\"" + } + ] + } + ] + }, + { + "id": "0x38abc60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26674, + "line": 861, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26687, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38abc30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26681, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26687, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58290", + "kind": "EnumConstantDecl", + "name": "VCMP_RL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38acae0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26700, + "line": 862, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26740, + "line": 863, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38aca30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26704, + "line": 862, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38aca18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26706, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26706, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ac9f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26706, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26706, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38abc90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26704, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26704, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ac9e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26709, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38abcb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26709, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"rxb_rb\"" + } + ] + } + ] + }, + { + "id": "0x38acad0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26727, + "line": 863, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26740, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38acaa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26734, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26740, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f582e0", + "kind": "EnumConstantDecl", + "name": "RXB_RB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ad950", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26752, + "line": 864, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26792, + "line": 865, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38ad8a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26756, + "line": 864, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ad888", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26758, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26758, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ad868", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26758, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26758, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38acb00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26756, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26756, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ad850", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26761, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38acb20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26761, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"rxb_lb\"" + } + ] + } + ] + }, + { + "id": "0x38ad940", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26779, + "line": 865, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26792, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38ad910", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26786, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26792, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58330", + "kind": "EnumConstantDecl", + "name": "RXB_LB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ae7c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26804, + "line": 866, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26845, + "line": 867, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ae710", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26808, + "line": 866, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ae6f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26810, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26810, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ae6d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26810, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26810, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ad970", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26808, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26808, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ae6c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26813, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ad990", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26813, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_rr\"" + } + ] + } + ] + }, + { + "id": "0x38ae7b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26832, + "line": 867, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26845, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ae780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26839, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26845, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58380", + "kind": "EnumConstantDecl", + "name": "VCMP_RR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38af630", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26858, + "line": 868, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26895, + "line": 869, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38af580", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26862, + "line": 868, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38af568", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26864, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26864, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38af548", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26864, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26864, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ae7e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26862, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26862, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38af530", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26867, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ae800", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26867, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"vcp\"" + } + ] + } + ] + }, + { + "id": "0x38af620", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26882, + "line": 869, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26895, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38af5f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26889, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26895, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f583d0", + "kind": "EnumConstantDecl", + "name": "VCP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b04a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26904, + "line": 870, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26941, + "line": 871, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38b03f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26908, + "line": 870, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b03d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26910, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26910, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b03b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26910, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26910, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38af650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26908, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26908, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b03a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26913, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38af670", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26913, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"vcn\"" + } + ] + } + ] + }, + { + "id": "0x38b0490", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26928, + "line": 871, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26941, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38b0460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26935, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26941, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58420", + "kind": "EnumConstantDecl", + "name": "VCN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b1310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26950, + "line": 872, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26992, + "line": 873, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b1260", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26954, + "line": 872, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b1248", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26956, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26956, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b1228", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26956, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26956, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b04c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26954, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26954, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b1210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26959, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b04e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26959, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vishaper\"" + } + ] + } + ] + }, + { + "id": "0x38b1300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26979, + "line": 873, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26992, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b12d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26986, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26992, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58470", + "kind": "EnumConstantDecl", + "name": "VISHAPER", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b2190", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27006, + "line": 874, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27050, + "line": 875, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38b20e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27010, + "line": 874, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b20c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27012, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27012, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b20a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27012, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27012, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b1330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27010, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27010, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b2090", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27015, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b1350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27015, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vthreshold\"" + } + ] + } + ] + }, + { + "id": "0x38b2180", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27037, + "line": 875, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27050, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38b2150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27044, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27050, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f584c0", + "kind": "EnumConstantDecl", + "name": "VTHRESHOLD", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b3000", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27066, + "line": 876, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27107, + "line": 877, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b2f50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27070, + "line": 876, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b2f38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b2f18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b21b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27070, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27070, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b2f00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27075, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b21d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27075, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vref_ds\"" + } + ] + } + ] + }, + { + "id": "0x38b2ff0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27094, + "line": 877, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27107, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b2fc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27101, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27107, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58560", + "kind": "EnumConstantDecl", + "name": "VREF_DS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b3e80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27120, + "line": 878, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27163, + "line": 879, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b3dd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27124, + "line": 878, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b3db8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27126, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27126, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b3d98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27126, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27126, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b3020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27124, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27124, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b3d80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27129, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b3040", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27129, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcascn_pb\"" + } + ] + } + ] + }, + { + "id": "0x38b3e70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27150, + "line": 879, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27163, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b3e40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27157, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27163, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f585b0", + "kind": "EnumConstantDecl", + "name": "VCASCN_PB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b4d00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27178, + "line": 880, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27221, + "line": 881, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b4c50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27182, + "line": 880, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b4c38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27184, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27184, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b4c18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27184, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27184, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b3ea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27182, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27182, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b4c00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27187, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b3ec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27187, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcascp_pb\"" + } + ] + } + ] + }, + { + "id": "0x38b4cf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27208, + "line": 881, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27221, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b4cc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27215, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27221, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58600", + "kind": "EnumConstantDecl", + "name": "VCASCP_PB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b5b90", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27236, + "line": 882, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27277, + "line": 883, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b5ae0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27240, + "line": 882, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b5ac8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27242, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27242, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b5aa8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27242, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27242, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b4d20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27240, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27240, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b5a90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27245, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b4d40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27245, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vout_cm\"" + } + ] + } + ] + }, + { + "id": "0x38b5b80", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27264, + "line": 883, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27277, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b5b50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27271, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27277, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58650", + "kind": "EnumConstantDecl", + "name": "VOUT_CM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b6a10", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27290, + "line": 884, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27333, + "line": 885, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b6960", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27294, + "line": 884, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b6948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27296, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27296, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b6928", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27296, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27296, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b5bb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27294, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27294, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b6910", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27299, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b5bd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27299, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcasc_out\"" + } + ] + } + ] + }, + { + "id": "0x38b6a00", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27320, + "line": 885, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27333, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b69d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27327, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27333, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f586a0", + "kind": "EnumConstantDecl", + "name": "VCASC_OUT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b7880", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27348, + "line": 886, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27388, + "line": 887, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38b77d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27352, + "line": 886, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b77b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27354, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27354, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b7798", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27354, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27354, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b6a30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27352, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27352, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b7780", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27357, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b6a50", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27357, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vin_cm\"" + } + ] + } + ] + }, + { + "id": "0x38b7870", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27375, + "line": 887, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27388, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38b7840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27382, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27388, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f586f0", + "kind": "EnumConstantDecl", + "name": "VIN_CM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b8700", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27400, + "line": 888, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27443, + "line": 889, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b8650", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27404, + "line": 888, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b8638", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b8618", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b78a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27404, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27404, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b8600", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27409, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b78c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27409, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vref_comp\"" + } + ] + } + ] + }, + { + "id": "0x38b86f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27430, + "line": 889, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27443, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b86c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27437, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27443, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58740", + "kind": "EnumConstantDecl", + "name": "VREF_COMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b9580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27458, + "line": 890, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27501, + "line": 891, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b94d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27462, + "line": 890, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b94b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27464, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27464, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b9498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27464, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27464, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b8720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27462, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27462, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b9480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27467, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b8740", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27467, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"ib_test_c\"" + } + ] + } + ] + }, + { + "id": "0x38b9570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27488, + "line": 891, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27501, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b9540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27495, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27501, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58790", + "kind": "EnumConstantDecl", + "name": "IB_TESTC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ba3f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27515, + "line": 892, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27556, + "line": 893, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ba340", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27519, + "line": 892, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ba328", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27521, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27521, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ba308", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27521, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27521, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b95a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27519, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27519, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ba2f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27524, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b95c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27524, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp\"" + } + ] + } + ] + }, + { + "id": "0x38ba3e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27543, + "line": 893, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27556, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ba3b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27550, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27556, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f587e0", + "kind": "EnumConstantDecl", + "name": "VB_COMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bb260", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27569, + "line": 894, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27611, + "line": 895, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38bb1b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27573, + "line": 894, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bb198", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27575, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27575, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bb178", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27575, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27575, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ba410", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27573, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27573, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bb160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27578, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ba430", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27578, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vdd_prot\"" + } + ] + } + ] + }, + { + "id": "0x38bb250", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27598, + "line": 895, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27611, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38bb220", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27605, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27611, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58830", + "kind": "EnumConstantDecl", + "name": "VDD_PROT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bc0d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27625, + "line": 896, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27666, + "line": 897, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38bc020", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27629, + "line": 896, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bc008", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27631, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27631, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bbfe8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27631, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27631, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bb280", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27629, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27629, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bbfd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27634, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bb2a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27634, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vin_com\"" + } + ] + } + ] + }, + { + "id": "0x38bc0c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27653, + "line": 897, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27666, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38bc090", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27660, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27666, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58880", + "kind": "EnumConstantDecl", + "name": "VIN_COM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bcf50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27679, + "line": 898, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27723, + "line": 899, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bcea0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27683, + "line": 898, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bce88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27685, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27685, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bce68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27685, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27685, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bc0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27683, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27683, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bce50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27688, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bc110", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27688, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_prech\"" + } + ] + } + ] + }, + { + "id": "0x38bcf40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27710, + "line": 899, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27723, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bcf10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27717, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27723, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f588d0", + "kind": "EnumConstantDecl", + "name": "VREF_PRECH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bddd0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27739, + "line": 900, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27782, + "line": 901, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38bdd20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27743, + "line": 900, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bdd08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27745, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27745, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bdce8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27745, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27745, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bcf70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27743, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27743, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bdcd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27748, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bcf90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27748, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vb_pixbuf\"" + } + ] + } + ] + }, + { + "id": "0x38bddc0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27769, + "line": 901, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27782, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38bdd90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27776, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27782, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58920", + "kind": "EnumConstantDecl", + "name": "VB_PIXBUF", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bec40", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27797, + "line": 902, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27836, + "line": 903, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38beb90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27801, + "line": 902, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38beb78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27803, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27803, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38beb58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27803, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27803, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bddf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27801, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27801, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38beb40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27806, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bde10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27806, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vb_ds\"" + } + ] + } + ] + }, + { + "id": "0x38bec30", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27823, + "line": 903, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27836, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38bec00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27830, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27836, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58970", + "kind": "EnumConstantDecl", + "name": "VB_DS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bfac0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27847, + "line": 904, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27891, + "line": 905, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bfa10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27851, + "line": 904, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bf9f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27853, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27853, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bf9d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27853, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27853, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bec60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27851, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27851, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bf9c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27856, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bec80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27856, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_h_adc\"" + } + ] + } + ] + }, + { + "id": "0x38bfab0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27878, + "line": 905, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27891, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bfa80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27885, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27891, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f589c0", + "kind": "EnumConstantDecl", + "name": "VREF_H_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c0940", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27907, + "line": 906, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27951, + "line": 907, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c0890", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27911, + "line": 906, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c0878", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c0858", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bfae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27911, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27911, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c0840", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27916, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bfb00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27916, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp_fe\"" + } + ] + } + ] + }, + { + "id": "0x38c0930", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27938, + "line": 907, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27951, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c0900", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27945, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27951, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58a10", + "kind": "EnumConstantDecl", + "name": "VB_COMP_FE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c17c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27967, + "line": 908, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28012, + "line": 909, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c1710", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27971, + "line": 908, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c16f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27973, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27973, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c16d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27973, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27973, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c0960", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27971, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27971, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c16c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27976, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c0980", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27976, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp_adc\"" + } + ] + } + ] + }, + { + "id": "0x38c17b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27999, + "line": 909, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28012, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c1780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28006, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28012, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58a60", + "kind": "EnumConstantDecl", + "name": "VB_COMP_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c2630", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28029, + "line": 910, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28071, + "line": 911, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c2580", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28033, + "line": 910, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c2568", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28035, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28035, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c2548", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28035, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28035, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c17e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28033, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28033, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c2530", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28038, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c1800", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28038, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_cds\"" + } + ] + } + ] + }, + { + "id": "0x38c2620", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28058, + "line": 911, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28071, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c25f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28065, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28071, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ab0", + "kind": "EnumConstantDecl", + "name": "VCOM_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c34b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28085, + "line": 912, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28130, + "line": 913, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c3400", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28089, + "line": 912, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c33e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c33c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c2650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28089, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28089, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c33b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28094, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c2670", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28094, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"vref_rstore\"" + } + ] + } + ] + }, + { + "id": "0x38c34a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28117, + "line": 913, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28130, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c3470", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28124, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28130, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58b00", + "kind": "EnumConstantDecl", + "name": "VREF_RSTORE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c4330", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28147, + "line": 914, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28191, + "line": 915, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c4280", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28151, + "line": 914, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c4268", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c4248", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c34d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28151, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28151, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c4230", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28156, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c34f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28156, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vb_opa_1st\"" + } + ] + } + ] + }, + { + "id": "0x38c4320", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28178, + "line": 915, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28191, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c42f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28185, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28191, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58b50", + "kind": "EnumConstantDecl", + "name": "VB_OPA_1ST", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c51c8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28207, + "line": 916, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28253, + "line": 917, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x38c5100", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28211, + "line": 916, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c50e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28213, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28213, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c50c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28213, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28213, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c4350", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28211, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28211, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c50b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28216, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c4370", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28216, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"vref_comp_fe\"" + } + ] + } + ] + }, + { + "id": "0x38c51b8", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28240, + "line": 917, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28253, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x38c5188", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28247, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28253, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ba0", + "kind": "EnumConstantDecl", + "name": "VREF_COMP_FE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c6040", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28271, + "line": 918, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28314, + "line": 919, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c5f90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28275, + "line": 918, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c5f78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28277, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28277, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c5f58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28277, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28277, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c51e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28275, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28275, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c5f40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28280, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c5208", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28280, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_adc1\"" + } + ] + } + ] + }, + { + "id": "0x38c6030", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28301, + "line": 919, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28314, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c6000", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28308, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28314, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58bf0", + "kind": "EnumConstantDecl", + "name": "VCOM_ADC1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c6ec0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28329, + "line": 920, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28373, + "line": 921, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c6e10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28333, + "line": 920, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c6df8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28335, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28335, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c6dd8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28335, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28335, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c6060", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28333, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28333, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c6dc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28338, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c6080", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28338, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_l_adc\"" + } + ] + } + ] + }, + { + "id": "0x38c6eb0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28360, + "line": 921, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28373, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c6e80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28367, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28373, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58c40", + "kind": "EnumConstantDecl", + "name": "VREF_L_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c7d30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28389, + "line": 922, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28431, + "line": 923, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c7c80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28393, + "line": 922, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c7c68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28395, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28395, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c7c48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28395, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28395, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c6ee0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28393, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28393, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c7c30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28398, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c6f00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28398, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vref_cds\"" + } + ] + } + ] + }, + { + "id": "0x38c7d20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28418, + "line": 923, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28431, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c7cf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28425, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28431, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58c90", + "kind": "EnumConstantDecl", + "name": "VREF_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c8ba0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28445, + "line": 924, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28484, + "line": 925, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38c8af0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28449, + "line": 924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c8ad8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28451, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28451, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c8ab8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28451, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28451, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c7d50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28449, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28449, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c8aa0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28454, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c7d70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28454, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vb_cs\"" + } + ] + } + ] + }, + { + "id": "0x38c8b90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28471, + "line": 925, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28484, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38c8b60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28478, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28484, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ce0", + "kind": "EnumConstantDecl", + "name": "VB_CS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c9a20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28495, + "line": 926, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28538, + "line": 927, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c9970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28499, + "line": 926, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c9958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28501, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28501, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c9938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28501, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28501, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c8bc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28499, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28499, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c9920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28504, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c8be0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28504, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vb_opa_fd\"" + } + ] + } + ] + }, + { + "id": "0x38c9a10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28525, + "line": 927, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28538, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c99e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28532, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28538, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58d30", + "kind": "EnumConstantDecl", + "name": "VB_OPA_FD", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ca8a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28553, + "line": 928, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28596, + "line": 929, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ca7f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28557, + "line": 928, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ca7d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28559, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28559, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ca7b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28559, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28559, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c9a40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28557, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28557, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ca7a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28562, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c9a60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28562, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_adc2\"" + } + ] + } + ] + }, + { + "id": "0x38ca890", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28583, + "line": 929, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28596, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ca860", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28590, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28596, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58d80", + "kind": "EnumConstantDecl", + "name": "VCOM_ADC2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cb710", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28611, + "line": 930, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28651, + "line": 931, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38cb660", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28615, + "line": 930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cb648", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28617, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28617, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cb628", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28617, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28617, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ca8c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28615, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28615, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cb610", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28620, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ca8e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28620, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcassh\"" + } + ] + } + ] + }, + { + "id": "0x38cb700", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28638, + "line": 931, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28651, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38cb6d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28645, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28651, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58dd0", + "kind": "EnumConstantDecl", + "name": "VCASSH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cc580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28663, + "line": 932, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28701, + "line": 933, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cc4d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28667, + "line": 932, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cc4b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28669, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28669, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cc498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28669, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28669, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cb730", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28667, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28667, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cc480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28672, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cb750", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28672, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth2\"" + } + ] + } + ] + }, + { + "id": "0x38cc570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28688, + "line": 933, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28701, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cc540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28695, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28701, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58e20", + "kind": "EnumConstantDecl", + "name": "VTH2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cd400", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28711, + "line": 934, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28755, + "line": 935, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38cd350", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28715, + "line": 934, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cd338", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28717, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28717, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cd318", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28717, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28717, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cc5a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28715, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28715, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cd300", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28720, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cc5c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28720, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vrshaper_n\"" + } + ] + } + ] + }, + { + "id": "0x38cd3f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28742, + "line": 935, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28755, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38cd3c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28749, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28755, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58e70", + "kind": "EnumConstantDecl", + "name": "VRSHAPER_N", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ce280", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28771, + "line": 936, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28814, + "line": 937, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ce1d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28775, + "line": 936, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ce1b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28777, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28777, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ce198", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28777, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28777, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cd420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28775, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28775, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ce180", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28780, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cd440", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28780, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vipre_out\"" + } + ] + } + ] + }, + { + "id": "0x38ce270", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28801, + "line": 937, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28814, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ce240", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28808, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28814, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ec0", + "kind": "EnumConstantDecl", + "name": "VIPRE_OUT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cf0f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28829, + "line": 938, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28867, + "line": 939, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cf040", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28833, + "line": 938, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cf028", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28835, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28835, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cf008", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28835, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28835, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ce2a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28833, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28833, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ceff0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28838, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ce2c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28838, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth3\"" + } + ] + } + ] + }, + { + "id": "0x38cf0e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28854, + "line": 939, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28867, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cf0b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28861, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28867, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58f10", + "kind": "EnumConstantDecl", + "name": "VTH3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cff60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28877, + "line": 940, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28915, + "line": 941, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cfeb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28881, + "line": 940, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cfe98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28883, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28883, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cfe78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28883, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28883, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cf110", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28881, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28881, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cfe60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28886, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cf130", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28886, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth1\"" + } + ] + } + ] + }, + { + "id": "0x38cff50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28902, + "line": 941, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28915, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cff20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28909, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28915, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58f60", + "kind": "EnumConstantDecl", + "name": "VTH1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d0dd0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28925, + "line": 942, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28964, + "line": 943, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d0d20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28929, + "line": 942, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d0d08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28931, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28931, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d0ce8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28931, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28931, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cff80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28929, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28929, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d0cd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28934, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cffa0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28934, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vicin\"" + } + ] + } + ] + }, + { + "id": "0x38d0dc0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28951, + "line": 943, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28964, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d0d90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28958, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28964, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58fb0", + "kind": "EnumConstantDecl", + "name": "VICIN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d1c40", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28975, + "line": 944, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29013, + "line": 945, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d1b90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28979, + "line": 944, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d1b78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28981, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28981, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d1b58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28981, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28981, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d0df0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28979, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28979, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d1b40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28984, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d0e10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28984, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vcas\"" + } + ] + } + ] + }, + { + "id": "0x38d1c30", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29000, + "line": 945, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29013, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d1c00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29007, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29013, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59000", + "kind": "EnumConstantDecl", + "name": "VCAS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d2ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29023, + "line": 946, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29063, + "line": 947, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d2a00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29027, + "line": 946, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d29e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29029, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29029, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d29c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29029, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29029, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d1c60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29027, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29027, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d29b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29032, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d1c80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29032, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcal_n\"" + } + ] + } + ] + }, + { + "id": "0x38d2aa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29050, + "line": 947, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29063, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d2a70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29057, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29063, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59050", + "kind": "EnumConstantDecl", + "name": "VCAL_N", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d3920", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29075, + "line": 948, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29114, + "line": 949, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d3870", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29079, + "line": 948, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d3858", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29081, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29081, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d3838", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29081, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29081, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d2ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29079, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29079, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d3820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29084, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d2af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29084, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vipre\"" + } + ] + } + ] + }, + { + "id": "0x38d3910", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29101, + "line": 949, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29114, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d38e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29108, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29114, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f590a0", + "kind": "EnumConstantDecl", + "name": "VIPRE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d4790", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29125, + "line": 950, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29165, + "line": 951, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d46e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29129, + "line": 950, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d46c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29131, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29131, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d46a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29131, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29131, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d3940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29129, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29129, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d4690", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29134, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d3960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29134, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcal_p\"" + } + ] + } + ] + }, + { + "id": "0x38d4780", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29152, + "line": 951, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29165, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d4750", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29159, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29165, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f590f0", + "kind": "EnumConstantDecl", + "name": "VCAL_P", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646274c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29177, + "line": 952, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29216, + "line": 953, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964627410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29181, + "line": 952, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646273f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29183, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29183, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646273d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29183, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29183, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d47b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29181, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29181, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646273c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29186, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d47d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29186, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vdcsh\"" + } + ] + } + ] + }, + { + "id": "0x7f19646274b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29203, + "line": 953, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29216, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964627480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29210, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29216, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59140", + "kind": "EnumConstantDecl", + "name": "VDCSH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964628340", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29227, + "line": 954, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29271, + "line": 955, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x7f1964628290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29231, + "line": 954, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964628278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29233, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29233, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964628258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29233, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29233, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646274e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29231, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29231, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964628240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29236, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964627500", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29236, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vbp_colbuf\"" + } + ] + } + ] + }, + { + "id": "0x7f1964628330", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29258, + "line": 955, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29271, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x7f1964628300", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29265, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29271, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59190", + "kind": "EnumConstantDecl", + "name": "VBP_COLBUF", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646291b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29287, + "line": 956, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29327, + "line": 957, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x7f1964629100", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29291, + "line": 956, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646290e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29293, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29293, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646290c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29293, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29293, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964628360", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29291, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29291, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646290b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29296, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964628380", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29296, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vb_sda\"" + } + ] + } + ] + }, + { + "id": "0x7f19646291a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29314, + "line": 957, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29327, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x7f1964629170", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29321, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29327, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f591e0", + "kind": "EnumConstantDecl", + "name": "VB_SDA", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462a030", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29339, + "line": 958, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29382, + "line": 959, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964629f80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29343, + "line": 958, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964629f68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964629f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646291d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29343, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29343, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964629f30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29348, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646291f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29348, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcasc_sfp\"" + } + ] + } + ] + }, + { + "id": "0x7f196462a020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29369, + "line": 959, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29382, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964629ff0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29376, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29382, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59230", + "kind": "EnumConstantDecl", + "name": "VCASC_SFP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462aeb0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29397, + "line": 960, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29440, + "line": 961, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462ae00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29401, + "line": 960, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462ade8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29403, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29403, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462adc8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29403, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29403, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462a050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29401, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29401, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462adb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29406, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462a070", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29406, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vipre_cds\"" + } + ] + } + ] + }, + { + "id": "0x7f196462aea0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29427, + "line": 961, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29440, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462ae70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29434, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29440, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59280", + "kind": "EnumConstantDecl", + "name": "VIPRE_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462bd30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29455, + "line": 962, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29498, + "line": 963, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462bc80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29459, + "line": 962, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462bc68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29461, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29461, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462bc48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29461, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29461, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462aed0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29459, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29459, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462bc30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29464, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462aef0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29464, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"ibias_sfp\"" + } + ] + } + ] + }, + { + "id": "0x7f196462bd20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29485, + "line": 963, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29498, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462bcf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29492, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29498, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f592d0", + "kind": "EnumConstantDecl", + "name": "IBIAS_SFP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462cba0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29513, + "line": 964, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29555, + "line": 965, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462caf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29517, + "line": 964, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462cad8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29519, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29519, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462cab8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29519, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29519, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462bd50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29517, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29517, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462caa0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29522, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462bd70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29522, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"trimbits\"" + } + ] + } + ] + }, + { + "id": "0x7f196462cb90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29542, + "line": 965, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29555, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462cb60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29549, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29555, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59690", + "kind": "EnumConstantDecl", + "name": "TRIMBIT_SCAN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462da20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29573, + "line": 966, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29618, + "line": 967, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462d970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29577, + "line": 966, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462d958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29579, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29579, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462d938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29579, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29579, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462cbc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29577, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29577, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462d920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29582, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462cbe0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29582, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"highvoltage\"" + } + ] + } + ] + }, + { + "id": "0x7f196462da10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29605, + "line": 967, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29618, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462d9e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29612, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29618, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59370", + "kind": "EnumConstantDecl", + "name": "HIGH_VOLTAGE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462e890", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29636, + "line": 968, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29677, + "line": 969, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f196462e7e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29640, + "line": 968, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462e7c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29642, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29642, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462e7a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29642, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29642, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462da40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29640, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29640, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462e790", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29645, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462da60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29645, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"iodelay\"" + } + ] + } + ] + }, + { + "id": "0x7f196462e880", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29664, + "line": 969, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29677, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f196462e850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29671, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29677, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58510", + "kind": "EnumConstantDecl", + "name": "IO_DELAY", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462f700", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29691, + "line": 970, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29733, + "line": 971, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196462f650", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29695, + "line": 970, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462f638", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29697, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29697, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462f618", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29697, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29697, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462e8b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29695, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29695, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462f600", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29700, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462e8d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29700, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"temp_adc\"" + } + ] + } + ] + }, + { + "id": "0x7f196462f6f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29720, + "line": 971, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29733, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196462f6c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29727, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29733, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f593c0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964630580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29754, + "line": 972, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29797, + "line": 973, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646304d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29758, + "line": 972, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646304b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29760, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29760, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964630498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29760, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29760, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462f720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29758, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29758, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964630480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29763, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462f740", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29763, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpga\"" + } + ] + } + ] + }, + { + "id": "0x7f1964630570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29784, + "line": 973, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29797, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964630540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29791, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29797, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59410", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964631400", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29819, + "line": 974, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29865, + "line": 975, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f1964631350", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29823, + "line": 974, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964631338", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29825, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29825, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964631318", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29825, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29825, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646305a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29823, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29823, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964631300", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29828, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646305c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29828, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgaext\"" + } + ] + } + ] + }, + { + "id": "0x7f19646313f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29852, + "line": 975, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29865, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f19646313c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29859, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29865, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59460", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGAEXT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964632280", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29890, + "line": 976, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29933, + "line": 977, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646321d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29894, + "line": 976, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646321b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29896, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29896, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964632198", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29896, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29896, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964631420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29894, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29894, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964632180", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29899, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964631440", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29899, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_10ge\"" + } + ] + } + ] + }, + { + "id": "0x7f1964632270", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29920, + "line": 977, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29933, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964632240", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29927, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29933, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f594b0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_10GE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964633100", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29955, + "line": 978, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29998, + "line": 979, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633050", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29959, + "line": 978, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964633038", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29961, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29961, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964633018", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29961, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29961, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646322a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29959, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29959, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964633000", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29964, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646322c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29964, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_dcdc\"" + } + ] + } + ] + }, + { + "id": "0x7f19646330f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29985, + "line": 979, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29998, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646330c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29992, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29998, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59500", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_DCDC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964633f80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30020, + "line": 980, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30063, + "line": 981, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633ed0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30024, + "line": 980, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964633eb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30026, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30026, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964633e98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30026, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30026, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964633120", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30024, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30024, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964633e80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30029, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964633140", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30029, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_sodl\"" + } + ] + } + ] + }, + { + "id": "0x7f1964633f70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30050, + "line": 981, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30063, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633f40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30057, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30063, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59550", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_SODL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964634e00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30085, + "line": 982, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30128, + "line": 983, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964634d50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30089, + "line": 982, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964634d38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964634d18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964633fa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30089, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30089, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964634d00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30094, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964633fc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30094, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_sodr\"" + } + ] + } + ] + }, + { + "id": "0x7f1964634df0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30115, + "line": 983, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30128, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964634dc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30122, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30128, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f595a0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_SODR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964635c80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30150, + "line": 984, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30195, + "line": 985, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964635bd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30154, + "line": 984, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964635bb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30156, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30156, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964635b98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30156, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30156, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964634e20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30154, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30154, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964635b80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30159, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964634e40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30159, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgafl\"" + } + ] + } + ] + }, + { + "id": "0x7f1964635c70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30182, + "line": 985, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30195, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964635c40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30189, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30195, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f595f0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964636b00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30218, + "line": 986, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30263, + "line": 987, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964636a50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30222, + "line": 986, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964636a38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30224, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30224, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964636a18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30224, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30224, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964635ca0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30222, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30222, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964636a00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30227, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964635cc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30227, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgafr\"" + } + ] + } + ] + }, + { + "id": "0x7f1964636af0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30250, + "line": 987, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30263, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964636ac0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30257, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30263, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59640", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964637980", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30286, + "line": 988, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30332, + "line": 989, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x7f19646378d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30290, + "line": 988, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646378b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30292, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30292, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964637898", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30292, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30292, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964636b20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30290, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30290, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964637880", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30295, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964636b40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30295, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"temp_slowadc\"" + } + ] + } + ] + }, + { + "id": "0x7f1964637970", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30319, + "line": 989, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30332, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x7f1964637940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30326, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30332, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a060", + "kind": "EnumConstantDecl", + "name": "SLOW_ADC_TEMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964637f90", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30351, + "line": 990, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f1964637f78", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30351, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f1964637f48", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964637f30", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f1964637f08", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f1964637ee8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964637ee0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964637eb0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964637e98", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f1964637e80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f1964637e60", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964637e58", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964637e20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964637e08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30391, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 30391, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964637de8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30391, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 30391, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f1964637dd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30370, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646379b0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30370, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char[19]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown dac Index \"" + } + ] + }, + { + "id": "0x7f19646379e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30393, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x7f1964638418", + "kind": "FunctionDecl", + "loc": { + "offset": 30428, + "file": "ToString.cpp", + "line": 993, + "col": 29, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 30400, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 30788, + "line": 1003, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368bb58", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs9burstModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::burstMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "inner": [ + { + "id": "0x2f5b1f0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "decl": { + "id": "0x2f5b148", + "kind": "EnumDecl", + "name": "burstMode" + } + } + ] + }, + { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "loc": { + "offset": 30456, + "line": 993, + "col": 57, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 30437, + "col": 38, + "tokLen": 5 + }, + "end": { + "offset": 30456, + "col": 57, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f196463c5d8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 30459, + "col": 60, + "tokLen": 1 + }, + "end": { + "offset": 30788, + "line": 1003, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f1964639430", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30465, + "line": 994, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30513, + "line": 995, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f1964639380", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30469, + "line": 994, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964639368", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30471, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30471, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964639348", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30471, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30471, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646385d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30469, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30469, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964639330", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30474, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646385f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30474, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"burst_internal\"" + } + ] + } + ] + }, + { + "id": "0x7f1964639420", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30500, + "line": 995, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30513, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f19646393f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30507, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30513, + "col": 22, + "tokLen": 14 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b210", + "kind": "EnumConstantDecl", + "name": "BURST_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463a2b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30533, + "line": 996, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30581, + "line": 997, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f196463a200", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30537, + "line": 996, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463a1e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30539, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30539, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463a1c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30539, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30539, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964639450", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30537, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30537, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463a1b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30542, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964639470", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30542, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"burst_external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463a2a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30568, + "line": 997, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30581, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f196463a270", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30575, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30581, + "col": 22, + "tokLen": 14 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b260", + "kind": "EnumConstantDecl", + "name": "BURST_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463b130", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30601, + "line": 998, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30646, + "line": 999, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463b080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30605, + "line": 998, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463b068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30607, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30607, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463b048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30607, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30607, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463a2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30605, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30605, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463b030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30610, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463a2f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30610, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"cw_internal\"" + } + ] + } + ] + }, + { + "id": "0x7f196463b120", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30633, + "line": 999, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30646, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463b0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30640, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30646, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b2b0", + "kind": "EnumConstantDecl", + "name": "CONTINUOUS_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463bfb0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30671, + "line": 1000, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30716, + "line": 1001, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463bf00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30675, + "line": 1000, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463bee8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30677, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30677, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463bec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30677, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30677, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463b150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30675, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30675, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463beb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30680, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463b170", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30680, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"cw_external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463bfa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30703, + "line": 1001, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30716, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463bf70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30710, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30716, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b300", + "kind": "EnumConstantDecl", + "name": "CONTINUOUS_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463c5c0", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30741, + "line": 1002, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f196463c5a8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30741, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f196463c578", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463c560", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f196463c538", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f196463c518", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463c510", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463c4e0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463c4c8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f196463c4b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f196463c490", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463c488", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463c450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463c438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30782, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 30782, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463c418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30782, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 30782, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f196463c400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30760, + "col": 24, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463bfe0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30760, + "col": 24, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char[20]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown burst mode \"" + } + ] + }, + { + "id": "0x7f196463c010", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30784, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x7f196463c788", + "kind": "FunctionDecl", + "loc": { + "offset": 30826, + "file": "ToString.cpp", + "line": 1005, + "col": 36, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 30791, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31044, + "line": 1011, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368c078", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16timingSourceTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "inner": [ + { + "id": "0x2f5b470", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "decl": { + "id": "0x2f5b3c8", + "kind": "EnumDecl", + "name": "timingSourceType" + } + } + ] + }, + { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "loc": { + "offset": 30854, + "line": 1005, + "col": 64, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 30835, + "col": 45, + "tokLen": 5 + }, + "end": { + "offset": 30854, + "col": 64, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f196463ec30", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 30857, + "col": 67, + "tokLen": 1 + }, + "end": { + "offset": 31044, + "line": 1011, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f196463d790", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30863, + "line": 1006, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30905, + "line": 1007, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463d6e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30867, + "line": 1006, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463d6c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30869, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30869, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463d6a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30869, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30869, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463c940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30867, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30867, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463d690", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30872, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463c960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30872, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"internal\"" + } + ] + } + ] + }, + { + "id": "0x7f196463d780", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30892, + "line": 1007, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30905, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463d750", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30899, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30905, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b490", + "kind": "EnumConstantDecl", + "name": "TIMING_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463e600", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30926, + "line": 1008, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30968, + "line": 1009, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463e550", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30930, + "line": 1008, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463e538", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463e518", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463d7b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30930, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463e500", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463d7d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463e5f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30955, + "line": 1009, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30968, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463e5c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30962, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30968, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b4e0", + "kind": "EnumConstantDecl", + "name": "TIMING_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463ec18", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30989, + "line": 1010, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f196463ec00", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30989, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f196463ebd0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463ebb8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f196463eb90", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f196463eb70", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463eb68", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463eb38", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463eb20", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f196463eb08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f196463eae8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463eae0", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463eaa8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463ea90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31038, + "col": 54, + "tokLen": 1 + }, + "end": { + "offset": 31038, + "col": 54, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463ea70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31038, + "col": 54, + "tokLen": 1 + }, + "end": { + "offset": 31038, + "col": 54, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f196463ea58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31008, + "col": 24, + "tokLen": 29 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463e630", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31008, + "col": 24, + "tokLen": 29 + } + }, + "type": { + "qualType": "const char[28]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown timing source type \"" + } + ] + }, + { + "id": "0x7f196463e668", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31040, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x7f196463edd8", + "kind": "FunctionDecl", + "loc": { + "offset": 31077, + "file": "ToString.cpp", + "line": 1013, + "col": 31, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31047, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31487, + "line": 1027, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368c598", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11M3_GainCapsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "inner": [ + { + "id": "0x2f5b5d0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "decl": { + "id": "0x2f5b530", + "kind": "EnumDecl", + "name": "M3_GainCaps" + } + } + ] + }, + { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "loc": { + "offset": 31105, + "line": 1013, + "col": 59, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31086, + "col": 40, + "tokLen": 5 + }, + "end": { + "offset": 31105, + "col": 59, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f1964644c38", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31108, + "col": 62, + "tokLen": 1 + }, + "end": { + "offset": 31487, + "line": 1027, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f196463fde0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31114, + "line": 1014, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31154, + "line": 1015, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196463fd30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31118, + "line": 1014, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463fd18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31120, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31120, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463fcf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31120, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31120, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463ef90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31118, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31118, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463fce0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31123, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463efb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31123, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"C10pre\"" + } + ] + } + ] + }, + { + "id": "0x7f196463fdd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31141, + "line": 1015, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31154, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196463fda0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31148, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31154, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b670", + "kind": "EnumConstantDecl", + "name": "M3_C10pre", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964640c50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31169, + "line": 1016, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31208, + "line": 1017, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964640ba0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31173, + "line": 1016, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964640b88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31175, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31175, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964640b68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31175, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31175, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463fe00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31173, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31173, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964640b50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31178, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463fe20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31178, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C15sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964640c40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31195, + "line": 1017, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31208, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964640c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31202, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31208, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b740", + "kind": "EnumConstantDecl", + "name": "M3_C15sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964641ac0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31222, + "line": 1018, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31261, + "line": 1019, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964641a10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31226, + "line": 1018, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646419f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31228, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31228, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646419d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31228, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31228, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964640c70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31226, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31226, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646419c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31231, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964640c90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31231, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C30sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964641ab0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31248, + "line": 1019, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31261, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964641a80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31255, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31261, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b810", + "kind": "EnumConstantDecl", + "name": "M3_C30sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964642930", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31275, + "line": 1020, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31314, + "line": 1021, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964642880", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31279, + "line": 1020, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964642868", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31281, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31281, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964642848", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31281, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31281, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964641ae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31279, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31279, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964642830", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31284, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964641b00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31284, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C50sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964642920", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31301, + "line": 1021, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31314, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f19646428f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31308, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31314, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b8e0", + "kind": "EnumConstantDecl", + "name": "M3_C50sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646437a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31328, + "line": 1022, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31370, + "line": 1023, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x7f19646436f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31332, + "line": 1022, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646436d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31334, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31334, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646436b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31334, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31334, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964642950", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31332, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31332, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646436a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31337, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964642970", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31337, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"C225ACsh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964643790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31357, + "line": 1023, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31370, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x7f1964643760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31364, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31370, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b9b0", + "kind": "EnumConstantDecl", + "name": "M3_C225ACsh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964644610", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31387, + "line": 1024, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31427, + "line": 1025, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964644560", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31391, + "line": 1024, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964644548", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31393, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31393, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964644528", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31393, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31393, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646437c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31391, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31391, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964644510", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31396, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646437e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31396, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"C15pre\"" + } + ] + } + ] + }, + { + "id": "0x7f1964644600", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31414, + "line": 1025, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31427, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f19646445d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31421, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31427, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ba80", + "kind": "EnumConstantDecl", + "name": "M3_C15pre", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964644c20", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 31442, + "line": 1026, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f1964644c08", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 31442, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f1964644bd8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964644bc0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f1964644b98", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f1964644b78", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964644b70", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964644b40", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964644b28", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f1964644b10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f1964644af0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964644ae8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964644ab0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964644a98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31481, + "col": 44, + "tokLen": 1 + }, + "end": { + "offset": 31481, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964644a78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31481, + "col": 44, + "tokLen": 1 + }, + "end": { + "offset": 31481, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f1964644a60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31461, + "col": 24, + "tokLen": 19 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964644640", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31461, + "col": 24, + "tokLen": 19 + } + }, + "type": { + "qualType": "const char[18]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown gain cap \"" + } + ] + }, + { + "id": "0x7f1964644670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31483, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x7f1964644df8", + "kind": "FunctionDecl", + "loc": { + "offset": 31521, + "file": "ToString.cpp", + "line": 1029, + "col": 32, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31490, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31804, + "line": 1039, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368cab8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12portPositionEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::portPosition (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "inner": [ + { + "id": "0x2f5bc00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "decl": { + "id": "0x2f5bb60", + "kind": "EnumDecl", + "name": "portPosition" + } + } + ] + }, + { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "loc": { + "offset": 31549, + "line": 1029, + "col": 60, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31530, + "col": 41, + "tokLen": 5 + }, + "end": { + "offset": 31549, + "col": 60, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38d70f8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31552, + "col": 63, + "tokLen": 1 + }, + "end": { + "offset": 31804, + "line": 1039, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f1964645e00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31558, + "line": 1030, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31596, + "line": 1031, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x7f1964645d50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31562, + "line": 1030, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964645d38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31564, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31564, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964645d18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31564, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31564, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964644fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31562, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31562, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964645d00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31567, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964644fd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31567, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"left\"" + } + ] + } + ] + }, + { + "id": "0x7f1964645df0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31583, + "line": 1031, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31596, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x7f1964645dc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31590, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31596, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bc20", + "kind": "EnumConstantDecl", + "name": "LEFT", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964646c70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31606, + "line": 1032, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31645, + "line": 1033, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964646bc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31610, + "line": 1032, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964646ba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31612, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31612, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964646b88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31612, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31612, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964645e20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31610, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31610, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964646b70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31615, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964645e40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31615, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"right\"" + } + ] + } + ] + }, + { + "id": "0x7f1964646c60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31632, + "line": 1033, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31645, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964646c30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31639, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31645, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bc70", + "kind": "EnumConstantDecl", + "name": "RIGHT", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d5c60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31656, + "line": 1034, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31693, + "line": 1035, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38d5bb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31660, + "line": 1034, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d5b98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31662, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31662, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d5b78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31662, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31662, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964646c90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31660, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31660, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d5b60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31665, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964646cb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31665, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"top\"" + } + ] + } + ] + }, + { + "id": "0x38d5c50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31680, + "line": 1035, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31693, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38d5c20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31687, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31693, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bcc0", + "kind": "EnumConstantDecl", + "name": "TOP", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d6ad0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31702, + "line": 1036, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31742, + "line": 1037, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d6a20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31706, + "line": 1036, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d6a08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31708, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31708, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d69e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31708, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31708, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d5c80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31706, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31706, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d69d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31711, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d5ca0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31711, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"bottom\"" + } + ] + } + ] + }, + { + "id": "0x38d6ac0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31729, + "line": 1037, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31742, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d6a90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31736, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31742, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bd10", + "kind": "EnumConstantDecl", + "name": "BOTTOM", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d70e0", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 31754, + "line": 1038, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38d70c8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 31754, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7098", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d7080", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38d7058", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38d7038", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38d7030", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38d7000", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d6fe8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38d6fd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d6fb0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38d6fa8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38d6f70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d6f58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31798, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 31798, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d6f38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31798, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 31798, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38d6f20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31773, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d6b00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31773, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown port position \"" + } + ] + }, + { + "id": "0x38d6b30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31800, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38d72a8", + "kind": "FunctionDecl", + "loc": { + "offset": 31844, + "file": "ToString.cpp", + "line": 1041, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31807, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32267, + "line": 1052, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368cfd8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18streamingInterfaceEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "inner": [ + { + "id": "0x2f5bf90", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "decl": { + "id": "0x2f5bef0", + "kind": "EnumDecl", + "name": "streamingInterface" + } + } + ] + }, + { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "loc": { + "offset": 31872, + "line": 1041, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31853, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 31872, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38dacc0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31875, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 32267, + "line": 1052, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d7560", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 31881, + "line": 1042, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 31899, + "col": 23, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d74a8", + "kind": "VarDecl", + "loc": { + "offset": 31893, + "col": 17, + "tokLen": 2 + }, + "range": { + "begin": { + "offset": 31881, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "c", + "inner": [ + { + "id": "0x38d7530", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31898, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::basic_string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d7510", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31898, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x38d7ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31905, + "line": 1043, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31972, + "line": 1044, + "col": 30, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d77c0", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 31909, + "line": 1043, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38d7650", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31919, + "col": 19, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7620", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31911, + "col": 11, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1fe0", + "inner": [ + { + "id": "0x38d7578", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31909, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38d7608", + "kind": "CharacterLiteral", + "range": { + "begin": { + "offset": 31916, + "col": 16, + "tokLen": 3 + }, + "end": { + "offset": 31916, + "col": 16, + "tokLen": 3 + } + }, + "type": { + "qualType": "char" + }, + "valueCategory": "prvalue", + "value": 44 + }, + { + "id": "0x38d7698", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38d77a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31924, + "col": 24, + "tokLen": 3 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38d7778", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31924, + "col": 24, + "tokLen": 3 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38d7a08", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31951, + "line": 1044, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31972, + "col": 30, + "tokLen": 1 + } + }, + "type": { + "qualType": "std::basic_string" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x38d79d8", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31951, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31954, + "col": 12, + "tokLen": 5 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "erase", + "isArrow": false, + "referencedMemberDecl": "0x2c9ba48", + "inner": [ + { + "id": "0x38d77e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31951, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31951, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d7940", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31971, + "col": 29, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7910", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31963, + "col": 21, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1fe0", + "inner": [ + { + "id": "0x38d7970", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31960, + "col": 18, + "tokLen": 2 + } + }, + "type": { + "qualType": "const std::basic_string" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d7868", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31960, + "col": 18, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + }, + { + "id": "0x38d78f8", + "kind": "CharacterLiteral", + "range": { + "begin": { + "offset": 31968, + "col": 26, + "tokLen": 3 + }, + "end": { + "offset": 31968, + "col": 26, + "tokLen": 3 + } + }, + "type": { + "qualType": "char" + }, + "valueCategory": "prvalue", + "value": 44 + }, + { + "id": "0x38d7988", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38d7a90", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + } + ] + }, + { + "id": "0x38d8950", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31979, + "line": 1045, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32038, + "line": 1046, + "col": 42, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d8888", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31983, + "line": 1045, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d8870", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31986, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 31986, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d8850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31986, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 31986, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d8820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31983, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31983, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d7ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31983, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31983, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d8838", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31989, + "col": 15, + "tokLen": 6 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d7af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31989, + "col": 15, + "tokLen": 6 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"none\"" + } + ] + } + ] + }, + { + "id": "0x38d8940", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32005, + "line": 1046, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32038, + "col": 42, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d8910", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32012, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32038, + "col": 42, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bff0", + "kind": "EnumConstantDecl", + "name": "NONE", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38d97f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32048, + "line": 1047, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32106, + "line": 1048, + "col": 42, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38d9728", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32052, + "line": 1047, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d9710", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32055, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32055, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d96f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32055, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32055, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d96c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32052, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32052, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d8970", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32052, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32052, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d96d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32058, + "col": 15, + "tokLen": 5 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d8990", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32058, + "col": 15, + "tokLen": 5 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"lll\"" + } + ] + } + ] + }, + { + "id": "0x38d97e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32073, + "line": 1048, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32106, + "col": 42, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38d97b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32080, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32106, + "col": 42, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c0c0", + "kind": "EnumConstantDecl", + "name": "LOW_LATENCY_LINK", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38da690", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32128, + "line": 1049, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32188, + "line": 1050, + "col": 42, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38da5c8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32132, + "line": 1049, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38da5b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32135, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32135, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38da590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32135, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32135, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38da560", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32132, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32132, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d9810", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32132, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32132, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38da578", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32138, + "col": 15, + "tokLen": 7 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d9830", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32138, + "col": 15, + "tokLen": 7 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"10gbe\"" + } + ] + } + ] + }, + { + "id": "0x38da680", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32155, + "line": 1050, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32188, + "col": 42, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38da650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32162, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32188, + "col": 42, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c190", + "kind": "EnumConstantDecl", + "name": "ETHERNET_10GB", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38daca8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32207, + "line": 1051, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38dac90", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32207, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38dac60", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dac48", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38dac20", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38dac00", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38dabf8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dabc8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dabb0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38dab98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38dab78", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38dab70", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dab38", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dab20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32261, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32261, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dab00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32261, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32261, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38daae8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32226, + "col": 24, + "tokLen": 34 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38da6c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32226, + "col": 24, + "tokLen": 34 + } + }, + "type": { + "qualType": "const char[33]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown streamingInterface type \"" + } + ] + }, + { + "id": "0x38da6f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32263, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38dae78", + "kind": "FunctionDecl", + "loc": { + "offset": 32302, + "file": "ToString.cpp", + "line": 1054, + "col": 33, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32270, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32492, + "line": 1060, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368d4f8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs13vetoAlgorithmEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "inner": [ + { + "id": "0x2f5c350", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "decl": { + "id": "0x2f5c2b0", + "kind": "EnumDecl", + "name": "vetoAlgorithm" + } + } + ] + }, + { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "loc": { + "offset": 32330, + "line": 1054, + "col": 61, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32311, + "col": 42, + "tokLen": 5 + }, + "end": { + "offset": 32330, + "col": 61, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38dd318", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 32333, + "col": 64, + "tokLen": 1 + }, + "end": { + "offset": 32492, + "line": 1060, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38dbe80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32339, + "line": 1055, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32377, + "line": 1056, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38dbdd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32343, + "line": 1055, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dbdb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dbd98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38db030", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32343, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32343, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38dbd80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32348, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38db050", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32348, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"hits\"" + } + ] + } + ] + }, + { + "id": "0x38dbe70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32364, + "line": 1056, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32377, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38dbe40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32371, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32377, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c370", + "kind": "EnumConstantDecl", + "name": "ALG_HITS", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + } + } + } + ] + } + ] + }, + { + "id": "0x38dccf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32391, + "line": 1057, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32428, + "line": 1058, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38dcc40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32395, + "line": 1057, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dcc28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32397, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32397, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dcc08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32397, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32397, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38dbea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32395, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32395, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38dcbf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32400, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dbec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32400, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"raw\"" + } + ] + } + ] + }, + { + "id": "0x38dcce0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32415, + "line": 1058, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32428, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38dccb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32422, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32428, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c3c0", + "kind": "EnumConstantDecl", + "name": "ALG_RAW", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + } + } + } + ] + } + ] + }, + { + "id": "0x38dd300", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32441, + "line": 1059, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38dd2e8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32441, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38dd2b8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dd2a0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38dd278", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38dd258", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38dd250", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dd220", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dd208", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38dd1f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38dd1d0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38dd1c8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dd190", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dd178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32486, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 32486, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dd158", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32486, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 32486, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38dd140", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32460, + "col": 24, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dcd20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32460, + "col": 24, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char[24]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown veto algorithm \"" + } + ] + }, + { + "id": "0x38dcd50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32488, + "col": 52, + "tokLen": 1 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38dd4b8", + "kind": "FunctionDecl", + "loc": { + "offset": 32522, + "file": "ToString.cpp", + "line": 1062, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32495, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32948, + "line": 1076, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368da18", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8gainModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::gainMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "inner": [ + { + "id": "0x2f5c4b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "decl": { + "id": "0x2f5c410", + "kind": "EnumDecl", + "name": "gainMode" + } + } + ] + }, + { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "loc": { + "offset": 32550, + "line": 1062, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32531, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 32550, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e3338", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 32553, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32948, + "line": 1076, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38de4c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32559, + "line": 1063, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32600, + "line": 1064, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38de410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32563, + "line": 1063, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38de3f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38de3d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38dd670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32563, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32563, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38de3c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dd690", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"dynamic\"" + } + ] + } + ] + }, + { + "id": "0x38de4b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32587, + "line": 1064, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32600, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38de480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32594, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32600, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c4d0", + "kind": "EnumConstantDecl", + "name": "DYNAMIC", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38df340", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32613, + "line": 1065, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32660, + "line": 1066, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38df290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32617, + "line": 1065, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38df278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38df258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38de4e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32617, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32617, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38df240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32622, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38de500", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32622, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"forceswitchg1\"" + } + ] + } + ] + }, + { + "id": "0x38df330", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32647, + "line": 1066, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32660, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38df300", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32654, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32660, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c520", + "kind": "EnumConstantDecl", + "name": "FORCE_SWITCH_G1", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e01c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32681, + "line": 1067, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32728, + "line": 1068, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38e0110", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32685, + "line": 1067, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e00f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32687, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32687, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e00d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32687, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32687, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38df360", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32685, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32685, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e00c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32690, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38df380", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32690, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"forceswitchg2\"" + } + ] + } + ] + }, + { + "id": "0x38e01b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32715, + "line": 1068, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32728, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38e0180", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32722, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32728, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c570", + "kind": "EnumConstantDecl", + "name": "FORCE_SWITCH_G2", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e1030", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32749, + "line": 1069, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32788, + "line": 1070, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e0f80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32753, + "line": 1069, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e0f68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32755, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32755, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e0f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32755, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32755, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e01e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32753, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32753, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e0f30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32758, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e0200", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32758, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg1\"" + } + ] + } + ] + }, + { + "id": "0x38e1020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32775, + "line": 1070, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32788, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e0ff0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32782, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32788, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c5c0", + "kind": "EnumConstantDecl", + "name": "FIX_G1", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e1ea0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32800, + "line": 1071, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32839, + "line": 1072, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e1df0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32804, + "line": 1071, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e1dd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32806, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32806, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e1db8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32806, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32806, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e1050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32804, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32804, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e1da0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32809, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e1070", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32809, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg2\"" + } + ] + } + ] + }, + { + "id": "0x38e1e90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32826, + "line": 1072, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32839, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e1e60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32833, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32839, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c610", + "kind": "EnumConstantDecl", + "name": "FIX_G2", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e2d10", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32851, + "line": 1073, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32890, + "line": 1074, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e2c60", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32855, + "line": 1073, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e2c48", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e2c28", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e1ec0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32855, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32855, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e2c10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32860, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e1ee0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32860, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg0\"" + } + ] + } + ] + }, + { + "id": "0x38e2d00", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32877, + "line": 1074, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32890, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e2cd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32884, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32890, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c660", + "kind": "EnumConstantDecl", + "name": "FIX_G0", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e3320", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32902, + "line": 1075, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e3308", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32902, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e32d8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e32c0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e3298", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38e3278", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e3270", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e3240", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e3228", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38e3210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38e31f0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38e31e8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e31b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e3198", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32942, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 32942, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e3178", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32942, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 32942, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38e3160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32921, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e2d40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32921, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char[19]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown gain mode \"" + } + ] + }, + { + "id": "0x38e2d70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32944, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e34f8", + "kind": "FunctionDecl", + "loc": { + "offset": 32978, + "file": "ToString.cpp", + "line": 1078, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32951, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33167, + "line": 1084, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368df38", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8polarityEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::polarity (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "inner": [ + { + "id": "0x2f5c750", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "decl": { + "id": "0x2f5c6b0", + "kind": "EnumDecl", + "name": "polarity" + } + } + ] + }, + { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "loc": { + "offset": 33006, + "line": 1078, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32987, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 33006, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e5998", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33009, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 33167, + "line": 1084, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e4500", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 33015, + "line": 1079, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 33052, + "line": 1080, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e4450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33019, + "line": 1079, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e4438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33021, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33021, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e4418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33021, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33021, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e36b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33019, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33019, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e4400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33024, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e36d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33024, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"pos\"" + } + ] + } + ] + }, + { + "id": "0x38e44f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33039, + "line": 1080, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33052, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e44c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33046, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33052, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c770", + "kind": "EnumConstantDecl", + "name": "POSITIVE", + "type": { + "qualType": "slsDetectorDefs::polarity" + } + } + } + ] + } + ] + }, + { + "id": "0x38e5370", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 33066, + "line": 1081, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 33103, + "line": 1082, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e52c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33070, + "line": 1081, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e52a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e5288", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e4520", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33070, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33070, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e5270", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33075, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e4540", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33075, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"neg\"" + } + ] + } + ] + }, + { + "id": "0x38e5360", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33090, + "line": 1082, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33103, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e5330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33097, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33103, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c7c0", + "kind": "EnumConstantDecl", + "name": "NEGATIVE", + "type": { + "qualType": "slsDetectorDefs::polarity" + } + } + } + ] + } + ] + }, + { + "id": "0x38e5980", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 33117, + "line": 1083, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e5968", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 33117, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5938", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e5920", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e58f8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38e58d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e58d0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e58a0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e5888", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38e5870", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38e5850", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38e5848", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e5810", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e57f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33161, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33161, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e57d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33161, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33161, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38e57c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33136, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e53a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33136, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown polarity mode \"" + } + ] + }, + { + "id": "0x38e53d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33163, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e5ae8", + "kind": "FunctionDecl", + "loc": { + "offset": 33191, + "file": "ToString.cpp", + "line": 1086, + "col": 22, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33170, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33325, + "line": 1089, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368e408", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIjEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint32_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned int" + }, + "inner": [ + { + "id": "0x230bbd0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned int" + } + } + ] + }, + { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "loc": { + "offset": 33219, + "line": 1086, + "col": 50, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33200, + "col": 31, + "tokLen": 5 + }, + "end": { + "offset": 33219, + "col": 50, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e61b0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33222, + "col": 53, + "tokLen": 1 + }, + "end": { + "offset": 33325, + "line": 1089, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e5fa0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33228, + "line": 1087, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33282, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e5c88", + "kind": "VarDecl", + "loc": { + "offset": 33232, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33228, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e5f70", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5f10", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e5dd0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33250, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5da0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33241, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e5cf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33239, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e5e00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33246, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33246, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e5d80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33246, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33246, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e5e30", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e5ef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33255, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e5ec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33255, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e5f30", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33275, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33275, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e5f50", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33280, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e61a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33288, + "line": 1088, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6188", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned int", + "qualType": "uint32_t", + "typeAliasDeclId": "0x23ae7f8" + }, + "valueCategory": "prvalue", + "castKind": "IntegralCast", + "inner": [ + { + "id": "0x38e6120", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "type": { + "qualType": "unsigned long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6108", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33300, + "col": 17, + "tokLen": 5 + } + }, + "type": { + "qualType": "unsigned long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e6078", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33300, + "col": 17, + "tokLen": 5 + } + }, + "type": { + "qualType": "unsigned long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2ca8d40", + "kind": "FunctionDecl", + "name": "stoul", + "type": { + "qualType": "unsigned long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e6028", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33306, + "col": 23, + "tokLen": 1 + }, + "end": { + "offset": 33306, + "col": 23, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e6158", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33309, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33309, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e6048", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33309, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33309, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6170", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33318, + "col": 35, + "tokLen": 4 + }, + "end": { + "offset": 33318, + "col": 35, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33318, + "col": 35, + "tokLen": 4 + }, + "end": { + "offset": 33318, + "col": 35, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5c88", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e62f8", + "kind": "FunctionDecl", + "loc": { + "offset": 33349, + "file": "ToString.cpp", + "line": 1091, + "col": 22, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33328, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33484, + "line": 1094, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368e8a8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToImEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned long" + }, + "inner": [ + { + "id": "0x230bbf0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned long" + } + } + ] + }, + { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "loc": { + "offset": 33377, + "line": 1091, + "col": 50, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33358, + "col": 31, + "tokLen": 5 + }, + "end": { + "offset": 33377, + "col": 50, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e69a0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33380, + "col": 53, + "tokLen": 1 + }, + "end": { + "offset": 33484, + "line": 1094, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6798", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33386, + "line": 1092, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33440, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6498", + "kind": "VarDecl", + "loc": { + "offset": 33390, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33386, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e6768", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6708", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e65e0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33408, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e65b0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33399, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e6500", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33397, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e6610", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33404, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33404, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e6590", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33404, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33404, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e6628", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e66f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33413, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e66c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33413, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e6728", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33433, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33433, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e6748", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33438, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e6990", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33446, + "line": 1093, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6978", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "uint64_t", + "typeAliasDeclId": "0x23ae860" + }, + "valueCategory": "prvalue", + "castKind": "IntegralCast", + "inner": [ + { + "id": "0x38e6910", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "type": { + "qualType": "unsigned long long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e68f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33458, + "col": 17, + "tokLen": 6 + } + }, + "type": { + "qualType": "unsigned long long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e6870", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33458, + "col": 17, + "tokLen": 6 + } + }, + "type": { + "qualType": "unsigned long long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2caac00", + "kind": "FunctionDecl", + "name": "stoull", + "type": { + "qualType": "unsigned long long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e6820", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33465, + "col": 24, + "tokLen": 1 + }, + "end": { + "offset": 33465, + "col": 24, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e6948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33468, + "col": 27, + "tokLen": 7 + }, + "end": { + "offset": 33468, + "col": 27, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e6840", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33468, + "col": 27, + "tokLen": 7 + }, + "end": { + "offset": 33468, + "col": 27, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6960", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33477, + "col": 36, + "tokLen": 4 + }, + "end": { + "offset": 33477, + "col": 36, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33477, + "col": 36, + "tokLen": 4 + }, + "end": { + "offset": 33477, + "col": 36, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6498", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e6af0", + "kind": "FunctionDecl", + "loc": { + "offset": 33503, + "file": "ToString.cpp", + "line": 1096, + "col": 17, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33487, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33636, + "line": 1099, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368ed50", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIiEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "int" + }, + "inner": [ + { + "id": "0x230bb30", + "kind": "BuiltinType", + "type": { + "qualType": "int" + } + } + ] + }, + { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "loc": { + "offset": 33531, + "line": 1096, + "col": 45, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33512, + "col": 26, + "tokLen": 5 + }, + "end": { + "offset": 33531, + "col": 45, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e7188", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33534, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 33636, + "line": 1099, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6f98", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33540, + "line": 1097, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33594, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6c98", + "kind": "VarDecl", + "loc": { + "offset": 33544, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33540, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e6f68", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6f08", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e6de0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33562, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6db0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33553, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e6d00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33551, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e6e10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33558, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33558, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e6d90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33558, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33558, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e6e28", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6ef0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33567, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6ec0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33567, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e6f28", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33587, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33587, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e6f48", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33592, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e7178", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33600, + "line": 1098, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33633, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7110", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33633, + "col": 38, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e70f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33612, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e7070", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33612, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2c76400", + "kind": "FunctionDecl", + "name": "stoi", + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e7020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33617, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 33617, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e7148", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33620, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 33620, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e7040", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33620, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 33620, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33629, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 33629, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33629, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 33629, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6c98", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e72d8", + "kind": "FunctionDecl", + "loc": { + "offset": 33656, + "file": "ToString.cpp", + "line": 1101, + "col": 18, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33639, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33900, + "line": 1111, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368f1c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIbEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "bool (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "bool" + }, + "inner": [ + { + "id": "0x230bab0", + "kind": "BuiltinType", + "type": { + "qualType": "bool" + } + } + ] + }, + { + "id": "0x38e7210", + "kind": "ParmVarDecl", + "loc": { + "offset": 33684, + "line": 1101, + "col": 46, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33665, + "col": 27, + "tokLen": 5 + }, + "end": { + "offset": 33684, + "col": 46, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e79e0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33687, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33900, + "line": 1111, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7638", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33693, + "line": 1102, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33726, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7478", + "kind": "VarDecl", + "loc": { + "offset": 33697, + "col": 9, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33693, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33725, + "col": 37, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "i", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e75e8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33725, + "col": 37, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e75d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33706, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e75a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33706, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2c76400", + "kind": "FunctionDecl", + "name": "stoi", + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e7550", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33711, + "col": 23, + "tokLen": 1 + }, + "end": { + "offset": 33711, + "col": 23, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7210", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e7620", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33714, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33714, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e7570", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33714, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33714, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7580", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33723, + "col": 35, + "tokLen": 2 + }, + "end": { + "offset": 33723, + "col": 35, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e7688", + "kind": "SwitchStmt", + "range": { + "begin": { + "offset": 33732, + "line": 1103, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33898, + "line": 1110, + "col": 5, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7670", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33740, + "line": 1103, + "col": 13, + "tokLen": 1 + }, + "end": { + "offset": 33740, + "col": 13, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33740, + "col": 13, + "tokLen": 1 + }, + "end": { + "offset": 33740, + "col": 13, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7478", + "kind": "VarDecl", + "name": "i", + "type": { + "qualType": "int" + } + } + } + ] + }, + { + "id": "0x38e79b8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33743, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33898, + "line": 1110, + "col": 5, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e76f0", + "kind": "CaseStmt", + "range": { + "begin": { + "offset": 33749, + "line": 1104, + "col": 5, + "tokLen": 4 + }, + "end": { + "offset": 33772, + "line": 1105, + "col": 16, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38e76d0", + "kind": "ConstantExpr", + "range": { + "begin": { + "offset": 33754, + "line": 1104, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33754, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0", + "inner": [ + { + "id": "0x38e76b0", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33754, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33754, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0" + } + ] + }, + { + "id": "0x38e7728", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33765, + "line": 1105, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33772, + "col": 16, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38e7718", + "kind": "CXXBoolLiteralExpr", + "range": { + "begin": { + "offset": 33772, + "col": 16, + "tokLen": 5 + }, + "end": { + "offset": 33772, + "col": 16, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "value": false + } + ] + } + ] + }, + { + "id": "0x38e7778", + "kind": "CaseStmt", + "range": { + "begin": { + "offset": 33783, + "line": 1106, + "col": 5, + "tokLen": 4 + }, + "end": { + "offset": 33806, + "line": 1107, + "col": 16, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38e7758", + "kind": "ConstantExpr", + "range": { + "begin": { + "offset": 33788, + "line": 1106, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33788, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "1", + "inner": [ + { + "id": "0x38e7738", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33788, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33788, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "1" + } + ] + }, + { + "id": "0x38e77b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33799, + "line": 1107, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33806, + "col": 16, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38e77a0", + "kind": "CXXBoolLiteralExpr", + "range": { + "begin": { + "offset": 33806, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33806, + "col": 16, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "value": true + } + ] + } + ] + }, + { + "id": "0x38e7998", + "kind": "DefaultStmt", + "range": { + "begin": { + "offset": 33816, + "line": 1108, + "col": 5, + "tokLen": 7 + }, + "end": { + "offset": 33891, + "line": 1109, + "col": 67, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7980", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 33833, + "col": 9, + "tokLen": 5 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e7968", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 33833, + "col": 9, + "tokLen": 5 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7938", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e7920", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e78f8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x38e78d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e78d0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e78a0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e7888", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33852, + "col": 28, + "tokLen": 39 + }, + "end": { + "offset": 33852, + "col": 28, + "tokLen": 39 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e7848", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33852, + "col": 28, + "tokLen": 39 + }, + "end": { + "offset": 33852, + "col": 28, + "tokLen": 39 + } + }, + "type": { + "qualType": "const char[38]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown boolean. Expecting be 0 or 1.\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +} +{ + "id": "0x38e7b28", + "kind": "FunctionDecl", + "loc": { + "offset": 33923, + "file": "ToString.cpp", + "line": 1113, + "col": 21, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33903, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 34056, + "line": 1116, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368f668", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIlEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "long" + }, + "inner": [ + { + "id": "0x230bb50", + "kind": "BuiltinType", + "type": { + "qualType": "long" + } + } + ] + }, + { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "loc": { + "offset": 33951, + "line": 1113, + "col": 49, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33932, + "col": 30, + "tokLen": 5 + }, + "end": { + "offset": 33951, + "col": 49, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e81b8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33954, + "col": 52, + "tokLen": 1 + }, + "end": { + "offset": 34056, + "line": 1116, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7fc8", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33960, + "line": 1114, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 34014, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7cc8", + "kind": "VarDecl", + "loc": { + "offset": 33964, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33960, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e7f98", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7f38", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e7e10", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33982, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7de0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33973, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e7d30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33971, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e7e40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33978, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33978, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e7dc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33978, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33978, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e7e58", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7f20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33987, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7ef0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33987, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e7f58", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 34007, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 34007, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e7f78", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 34012, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e81a8", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 34020, + "line": 1115, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 34053, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e8140", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34053, + "col": 38, + "tokLen": 1 + } + }, + "type": { + "qualType": "long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e8128", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34032, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e80a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34032, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2ca7f70", + "kind": "FunctionDecl", + "name": "stol", + "type": { + "qualType": "long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e8050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34037, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 34037, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e8178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34040, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 34040, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e8070", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 34040, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 34040, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e8190", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34049, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 34049, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e8080", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34049, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 34049, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7cc8", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] +} diff --git a/slsDetectorSoftware/generator/autocomplete/fixed.json b/slsDetectorSoftware/generator/autocomplete/fixed.json new file mode 100644 index 000000000..441d25449 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/fixed.json @@ -0,0 +1,62037 @@ +[ +{ + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 8539, + "file": "../include/sls/ToString.h", + "line": 271, + "col": 3, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8515, + "line": 270, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3654a48", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 8534, + "line": 270, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8525, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8534, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x3654d08", + "kind": "FunctionDecl", + "loc": { + "offset": 8539, + "line": 271, + "col": 3, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8537, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "T (const std::string &, const std::string &)" + }, + "inner": [ + { + "id": "0x3654b38", + "kind": "ParmVarDecl", + "loc": { + "offset": 8567, + "line": 271, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8548, + "col": 12, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8567, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "t", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "loc": { + "offset": 8589, + "col": 53, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8570, + "col": 34, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8589, + "col": 53, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "unit", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3687658", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8595, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9380, + "line": 293, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3654fe0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8601, + "line": 272, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8615, + "col": 19, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3654ea0", + "kind": "VarDecl", + "loc": { + "offset": 8608, + "col": 12, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8601, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8614, + "col": 18, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "tval", + "type": { + "qualType": "double" + }, + "init": "list", + "inner": [ + { + "id": "0x3654f80", + "kind": "InitListExpr", + "range": { + "begin": { + "offset": 8612, + "col": 16, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8614, + "col": 18, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3654fc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "castKind": "IntegralToFloating", + "inner": [ + { + "id": "0x3654f08", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8613, + "col": 17, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0" + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3655488", + "kind": "CXXTryStmt", + "range": { + "begin": { + "offset": 8621, + "line": 273, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36551c0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8625, + "line": 273, + "col": 9, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8660, + "line": 275, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36551a0", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 8635, + "line": 274, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8653, + "col": 27, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "opcode": "=", + "inner": [ + { + "id": "0x3654ff8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8635, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8635, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + }, + { + "id": "0x3655150", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8653, + "col": 27, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3655138", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8647, + "col": 21, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double (*)(const std::string &, std::size_t *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36550a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8642, + "col": 16, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8647, + "col": 21, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double (const std::string &, std::size_t *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2caf050", + "kind": "FunctionDecl", + "name": "stod", + "type": { + "qualType": "double (const std::string &, std::size_t *)" + } + } + } + ] + }, + { + "id": "0x3655088", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8652, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8652, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654b38", + "kind": "ParmVarDecl", + "name": "t", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3655180", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue" + } + ] + } + ] + } + ] + }, + { + "id": "0x3655468", + "kind": "CXXCatchStmt", + "range": { + "begin": { + "offset": 8662, + "line": 275, + "col": 7, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655290", + "kind": "VarDecl", + "loc": { + "offset": 8698, + "line": 275, + "col": 43, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8669, + "col": 14, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8698, + "col": 43, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "e", + "type": { + "qualType": "const std::invalid_argument &" + } + }, + { + "id": "0x3655450", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8701, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8771, + "line": 277, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655438", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 8711, + "line": 276, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3655420", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 8711, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36553f0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36553d8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36553b0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x3655390", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3655388", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3655358", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8717, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8764, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3655340", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3655308", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8730, + "col": 28, + "tokLen": 34, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[33]" + }, + "valueCategory": "lvalue", + "value": "\"Could not convert string to time\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3655560", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8778, + "line": 279, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8805, + "col": 32, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36554b8", + "kind": "UsingDecl", + "loc": { + "offset": 8797, + "col": 24, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8778, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8797, + "col": 24, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "std::chrono::duration" + } + ] + }, + { + "id": "0x3655630", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 8811, + "line": 280, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8843, + "col": 37, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3655588", + "kind": "UsingDecl", + "loc": { + "offset": 8830, + "col": 24, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 8811, + "col": 5, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8830, + "col": 24, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "std::chrono::duration_cast" + } + ] + }, + { + "id": "0x3687628", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 8849, + "line": 281, + "col": 5, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x36563f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 8853, + "line": 281, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x36563d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36563b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8858, + "col": 14, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3655648", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8853, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8853, + "col": 9, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x36563a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3655668", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8861, + "col": 17, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"ns\"" + } + ] + } + ] + }, + { + "id": "0x366ce00", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8867, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8941, + "line": 283, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x366cdf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 8877, + "line": 282, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8934, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x366cdc8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8884, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8934, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3656438", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 8884, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8899, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x366cda0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 8901, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8933, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x366ca28", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x366cd70", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 8901, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8933, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x366cb78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36566d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8929, + "col": 61, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36875f8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 8948, + "line": 283, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x366dbc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 8952, + "line": 283, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x366dba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x366db88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8957, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x366ce18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 8952, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8952, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x366db70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x366ce38", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8960, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"us\"" + } + ] + } + ] + }, + { + "id": "0x3675a60", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 8966, + "col": 30, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9041, + "line": 285, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3675a50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 8976, + "line": 284, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9034, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3675a28", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 8983, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9034, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x366dc08", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 8983, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 8998, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x3675a00", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9000, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9033, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x3675688", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x36759d0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9000, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9033, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36757d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x366dea8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9029, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36875c8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 9048, + "line": 285, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x3676820", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 9052, + "line": 285, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3676808", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36767e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9057, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3675a78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9052, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9052, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x36767d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3675a98", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9060, + "col": 24, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"ms\"" + } + ] + } + ] + }, + { + "id": "0x367e6d0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9066, + "col": 30, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9141, + "line": 287, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x367e6c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9076, + "line": 286, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9134, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x367e698", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9083, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9134, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3676868", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9083, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9098, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x367e670", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9100, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9133, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x367e2f8", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x367e640", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9100, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9133, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration>", + "qualType": "duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x367e448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3676b08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9129, + "col": 62, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3687598", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 9148, + "line": 287, + "col": 12, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "hasElse": true, + "inner": [ + { + "id": "0x367f568", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 9152, + "line": 287, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9178, + "col": 42, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x367f490", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x367f478", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x367f458", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9157, + "col": 21, + "tokLen": 2, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x367e6e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9152, + "col": 16, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x367f440", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x367e708", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9160, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"s\"" + } + ] + } + ] + }, + { + "id": "0x367f518", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9178, + "col": 42, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x367f4e8", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9172, + "col": 36, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "empty", + "isArrow": false, + "referencedMemberDecl": "0x2c94de8", + "inner": [ + { + "id": "0x367f4c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9167, + "col": 31, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654bf8", + "kind": "ParmVarDecl", + "name": "unit", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36873f0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9181, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9257, + "line": 289, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36873e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9191, + "line": 288, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9250, + "col": 68, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36873b8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9198, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9250, + "col": 68, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x367f598", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9198, + "col": 16, + "tokLen": 13, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9213, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "duration_cast", + "lookups": [ + { + "id": "0x36555e0", + "kind": "UsingShadowDecl", + "name": "duration_cast" + } + ] + }, + { + "id": "0x3687390", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9215, + "col": 33, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9249, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration", + "qualType": "std::chrono::duration" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x3687018", + "kind": "CXXConstructorDecl", + "name": "duration", + "type": { + "qualType": "void (const double &)" + } + }, + "inner": [ + { + "id": "0x3687360", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9215, + "col": 33, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9249, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::chrono::duration", + "qualType": "std::chrono::duration" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const double &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687168", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const double", + "qualType": "const double" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x367f840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9245, + "col": 63, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "double" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3654ea0", + "kind": "VarDecl", + "name": "tval", + "type": { + "qualType": "double" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3687580", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9264, + "line": 289, + "col": 12, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9378, + "line": 292, + "col": 5, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687568", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 9274, + "line": 290, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3687550", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 9274, + "line": 290, + "col": 9, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687520", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687508", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36874e0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x36874c0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x36874b8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3687488", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9280, + "line": 290, + "col": 15, + "tokLen": 12, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9371, + "line": 291, + "col": 78, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687470", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3687418", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9306, + "col": 13, + "tokLen": 65, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const char[64]" + }, + "valueCategory": "lvalue", + "value": "\"Invalid unit in conversion from string to std::chrono::duration\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 9407, + "file": "../include/sls/ToString.h", + "line": 295, + "col": 25, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9383, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3687690", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 9402, + "line": 295, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9393, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9402, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x3687868", + "kind": "FunctionDecl", + "loc": { + "offset": 9407, + "col": 25, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9405, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "T (const std::string &)" + }, + "inner": [ + { + "id": "0x3687778", + "kind": "ParmVarDecl", + "loc": { + "offset": 9435, + "line": 295, + "col": 53, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9416, + "col": 34, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9435, + "col": 53, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "t", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3688030", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 9438, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9532, + "line": 299, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687b68", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 9444, + "line": 296, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9462, + "col": 23, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687a38", + "kind": "VarDecl", + "loc": { + "offset": 9456, + "col": 17, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9444, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9461, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "list", + "inner": [ + { + "id": "0x3687b38", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9456, + "col": 17, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9461, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::basic_string &)" + }, + "list": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687aa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9460, + "col": 21, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9460, + "col": 21, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687778", + "kind": "ParmVarDecl", + "name": "t", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x3687ef0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 9468, + "line": 297, + "col": 5, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9495, + "col": 32, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687bc0", + "kind": "VarDecl", + "loc": { + "offset": 9473, + "col": 10, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9468, + "col": 5, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "unit", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "c", + "inner": [ + { + "id": "0x3687ed8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3687ea8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (std::basic_string &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3687e60", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3687d50", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "temp": "0x3687d48", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3687d20", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9494, + "col": 31, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687d08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "std::string (*)(std::string &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3687c90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9480, + "col": 17, + "tokLen": 10, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "std::string (std::string &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2fb3d48", + "kind": "FunctionDecl", + "name": "RemoveUnit", + "type": { + "qualType": "std::string (std::string &)" + } + } + } + ] + }, + { + "id": "0x3687c70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9491, + "col": 28, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9491, + "col": 28, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687a38", + "kind": "VarDecl", + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3688020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 9501, + "line": 298, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9529, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3687ff0", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 9508, + "col": 12, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9529, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3687f30", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 9508, + "col": 12, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9518, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "StringTo", + "lookups": [ + { + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + } + ] + }, + { + "id": "0x3687fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9520, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9520, + "col": 24, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687a38", + "kind": "VarDecl", + "name": "tmp", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + }, + { + "id": "0x3687fd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 9525, + "col": 29, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9525, + "col": 29, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3687bc0", + "kind": "VarDecl", + "name": "unit", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x3849458", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::detectorType (const std::string &)" + } + }, + { + "id": "0x3850318", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + } + }, + { + "id": "0x3866a58", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + } + }, + { + "id": "0x386e798", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::timingMode (const std::string &)" + } + }, + { + "id": "0x3873968", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + } + }, + { + "id": "0x3876e78", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + } + }, + { + "id": "0x38794b8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + } + }, + { + "id": "0x387d838", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + } + }, + { + "id": "0x3882a18", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + } + }, + { + "id": "0x7f1964638418", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::burstMode (const std::string &)" + } + }, + { + "id": "0x7f196463c788", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + } + }, + { + "id": "0x7f196463edd8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + } + }, + { + "id": "0x7f1964644df8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::portPosition (const std::string &)" + } + }, + { + "id": "0x38d72a8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + } + }, + { + "id": "0x38dae78", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + } + }, + { + "id": "0x38dd4b8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::gainMode (const std::string &)" + } + }, + { + "id": "0x38e34f8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "defs::polarity (const std::string &)" + } + }, + { + "id": "0x38e5ae8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "uint32_t (const std::string &)" + } + }, + { + "id": "0x38e62f8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "uint64_t (const std::string &)" + } + }, + { + "id": "0x38e6af0", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "int (const std::string &)" + } + }, + { + "id": "0x38e72d8", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "bool (const std::string &)" + } + }, + { + "id": "0x38e7b28", + "kind": "FunctionDecl", + "name": "StringTo", + "type": { + "qualType": "int64_t (const std::string &)" + } + } + ] +}, +{ + "id": "0x3688208", + "kind": "FunctionDecl", + "loc": { + "offset": 9566, + "file": "../include/sls/ToString.h", + "line": 301, + "col": 32, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9535, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9595, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688438", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12detectorTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "inner": [ + { + "id": "0x2f41f40", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "decl": { + "id": "0x2f41ea0", + "kind": "EnumDecl", + "name": "detectorType" + } + } + ] + }, + { + "id": "0x3688100", + "kind": "ParmVarDecl", + "loc": { + "offset": 9594, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9575, + "col": 41, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9594, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3688728", + "kind": "FunctionDecl", + "loc": { + "offset": 9633, + "file": "../include/sls/ToString.h", + "line": 302, + "col": 36, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9598, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9662, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688958", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16detectorSettingsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "inner": [ + { + "id": "0x2f5a2c0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "decl": { + "id": "0x2f5a218", + "kind": "EnumDecl", + "name": "detectorSettings" + } + } + ] + }, + { + "id": "0x3688620", + "kind": "ParmVarDecl", + "loc": { + "offset": 9661, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9642, + "col": 45, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9661, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3688c48", + "kind": "FunctionDecl", + "loc": { + "offset": 9694, + "file": "../include/sls/ToString.h", + "line": 303, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9665, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9723, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3688e78", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10speedLevelEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "inner": [ + { + "id": "0x2f5af70", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "decl": { + "id": "0x2f5aec8", + "kind": "EnumDecl", + "name": "speedLevel" + } + } + ] + }, + { + "id": "0x3688b40", + "kind": "ParmVarDecl", + "loc": { + "offset": 9722, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9703, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9722, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3689168", + "kind": "FunctionDecl", + "loc": { + "offset": 9755, + "file": "../include/sls/ToString.h", + "line": 304, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9726, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9784, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3689398", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10timingModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "inner": [ + { + "id": "0x2f57730", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "decl": { + "id": "0x2f57688", + "kind": "EnumDecl", + "name": "timingMode" + } + } + ] + }, + { + "id": "0x3689060", + "kind": "ParmVarDecl", + "loc": { + "offset": 9783, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9764, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9783, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3689688", + "kind": "FunctionDecl", + "loc": { + "offset": 9824, + "file": "../include/sls/ToString.h", + "line": 305, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9787, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9853, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x36898b8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18frameDiscardPolicyEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "inner": [ + { + "id": "0x2f554b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "decl": { + "id": "0x2f55410", + "kind": "EnumDecl", + "name": "frameDiscardPolicy" + } + } + ] + }, + { + "id": "0x3689580", + "kind": "ParmVarDecl", + "loc": { + "offset": 9852, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9833, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9852, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3689ba8", + "kind": "FunctionDecl", + "loc": { + "offset": 9885, + "file": "../include/sls/ToString.h", + "line": 306, + "col": 30, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9856, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9914, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x3689dd8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10fileFormatEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "inner": [ + { + "id": "0x2f556b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "decl": { + "id": "0x2f55610", + "kind": "EnumDecl", + "name": "fileFormat" + } + } + ] + }, + { + "id": "0x3689aa0", + "kind": "ParmVarDecl", + "loc": { + "offset": 9913, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9894, + "col": 39, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9913, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368abf0", + "kind": "FunctionDecl", + "loc": { + "offset": 9954, + "file": "../include/sls/ToString.h", + "line": 307, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9917, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9983, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368ae28", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18externalSignalFlagEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "inner": [ + { + "id": "0x2f57500", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "decl": { + "id": "0x2f57458", + "kind": "EnumDecl", + "name": "externalSignalFlag" + } + } + ] + }, + { + "id": "0x3689fc0", + "kind": "ParmVarDecl", + "loc": { + "offset": 9982, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9963, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 9982, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368b118", + "kind": "FunctionDecl", + "loc": { + "offset": 10016, + "file": "../include/sls/ToString.h", + "line": 308, + "col": 31, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 9986, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10045, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368b348", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11readoutModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "inner": [ + { + "id": "0x2f5acf0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "decl": { + "id": "0x2f5ac48", + "kind": "EnumDecl", + "name": "readoutMode" + } + } + ] + }, + { + "id": "0x368b010", + "kind": "ParmVarDecl", + "loc": { + "offset": 10044, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10025, + "col": 40, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10044, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368b638", + "kind": "FunctionDecl", + "loc": { + "offset": 10075, + "file": "../include/sls/ToString.h", + "line": 309, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10048, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10104, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368b868", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8dacIndexEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "inner": [ + { + "id": "0x2f57a00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "decl": { + "id": "0x2f57958", + "kind": "EnumDecl", + "name": "dacIndex" + } + } + ] + }, + { + "id": "0x368b530", + "kind": "ParmVarDecl", + "loc": { + "offset": 10103, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10084, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10103, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368bb58", + "kind": "FunctionDecl", + "loc": { + "offset": 10135, + "file": "../include/sls/ToString.h", + "line": 310, + "col": 29, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10107, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10164, + "col": 58, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368bd88", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs9burstModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::burstMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "inner": [ + { + "id": "0x2f5b1f0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "decl": { + "id": "0x2f5b148", + "kind": "EnumDecl", + "name": "burstMode" + } + } + ] + }, + { + "id": "0x368ba50", + "kind": "ParmVarDecl", + "loc": { + "offset": 10163, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10144, + "col": 38, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10163, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368c078", + "kind": "FunctionDecl", + "loc": { + "offset": 10202, + "file": "../include/sls/ToString.h", + "line": 311, + "col": 36, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10167, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10231, + "col": 65, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368c2a8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16timingSourceTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "inner": [ + { + "id": "0x2f5b470", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "decl": { + "id": "0x2f5b3c8", + "kind": "EnumDecl", + "name": "timingSourceType" + } + } + ] + }, + { + "id": "0x368bf70", + "kind": "ParmVarDecl", + "loc": { + "offset": 10230, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10211, + "col": 45, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10230, + "col": 64, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368c598", + "kind": "FunctionDecl", + "loc": { + "offset": 10264, + "file": "../include/sls/ToString.h", + "line": 312, + "col": 31, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10234, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10293, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368c7c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11M3_GainCapsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "inner": [ + { + "id": "0x2f5b5d0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "decl": { + "id": "0x2f5b530", + "kind": "EnumDecl", + "name": "M3_GainCaps" + } + } + ] + }, + { + "id": "0x368c490", + "kind": "ParmVarDecl", + "loc": { + "offset": 10292, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10273, + "col": 40, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10292, + "col": 59, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368cab8", + "kind": "FunctionDecl", + "loc": { + "offset": 10327, + "file": "../include/sls/ToString.h", + "line": 313, + "col": 32, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10296, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10356, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368cce8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12portPositionEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::portPosition (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "inner": [ + { + "id": "0x2f5bc00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "decl": { + "id": "0x2f5bb60", + "kind": "EnumDecl", + "name": "portPosition" + } + } + ] + }, + { + "id": "0x368c9b0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10355, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10336, + "col": 41, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10355, + "col": 60, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368cfd8", + "kind": "FunctionDecl", + "loc": { + "offset": 10396, + "file": "../include/sls/ToString.h", + "line": 314, + "col": 38, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10359, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10425, + "col": 67, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368d208", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18streamingInterfaceEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "inner": [ + { + "id": "0x2f5bf90", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "decl": { + "id": "0x2f5bef0", + "kind": "EnumDecl", + "name": "streamingInterface" + } + } + ] + }, + { + "id": "0x368ced0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10424, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10405, + "col": 47, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10424, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368d4f8", + "kind": "FunctionDecl", + "loc": { + "offset": 10460, + "file": "../include/sls/ToString.h", + "line": 315, + "col": 33, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10428, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10489, + "col": 62, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368d728", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs13vetoAlgorithmEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "inner": [ + { + "id": "0x2f5c350", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "decl": { + "id": "0x2f5c2b0", + "kind": "EnumDecl", + "name": "vetoAlgorithm" + } + } + ] + }, + { + "id": "0x368d3f0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10488, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10469, + "col": 42, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10488, + "col": 61, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368da18", + "kind": "FunctionDecl", + "loc": { + "offset": 10519, + "file": "../include/sls/ToString.h", + "line": 316, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10492, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10548, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368dc48", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8gainModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::gainMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "inner": [ + { + "id": "0x2f5c4b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "decl": { + "id": "0x2f5c410", + "kind": "EnumDecl", + "name": "gainMode" + } + } + ] + }, + { + "id": "0x368d910", + "kind": "ParmVarDecl", + "loc": { + "offset": 10547, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10528, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10547, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368df38", + "kind": "FunctionDecl", + "loc": { + "offset": 10578, + "file": "../include/sls/ToString.h", + "line": 317, + "col": 28, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10551, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10607, + "col": 57, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368e168", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8polarityEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::polarity (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "inner": [ + { + "id": "0x2f5c750", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "decl": { + "id": "0x2f5c6b0", + "kind": "EnumDecl", + "name": "polarity" + } + } + ] + }, + { + "id": "0x368de30", + "kind": "ParmVarDecl", + "loc": { + "offset": 10606, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10587, + "col": 37, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10606, + "col": 56, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368e408", + "kind": "FunctionDecl", + "loc": { + "offset": 10632, + "file": "../include/sls/ToString.h", + "line": 319, + "col": 22, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10611, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10661, + "col": 51, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368e608", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIjEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint32_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned int" + }, + "inner": [ + { + "id": "0x230bbd0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned int" + } + } + ] + }, + { + "id": "0x368e310", + "kind": "ParmVarDecl", + "loc": { + "offset": 10660, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10641, + "col": 31, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10660, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368e8a8", + "kind": "FunctionDecl", + "loc": { + "offset": 10685, + "file": "../include/sls/ToString.h", + "line": 320, + "col": 22, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10664, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10714, + "col": 51, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368eaa8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToImEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned long" + }, + "inner": [ + { + "id": "0x230bbf0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned long" + } + } + ] + }, + { + "id": "0x368e7b0", + "kind": "ParmVarDecl", + "loc": { + "offset": 10713, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10694, + "col": 31, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10713, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368ed50", + "kind": "FunctionDecl", + "loc": { + "offset": 10733, + "file": "../include/sls/ToString.h", + "line": 321, + "col": 17, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10717, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10762, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368ef58", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIiEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "int" + }, + "inner": [ + { + "id": "0x230bb30", + "kind": "BuiltinType", + "type": { + "qualType": "int" + } + } + ] + }, + { + "id": "0x368ec50", + "kind": "ParmVarDecl", + "loc": { + "offset": 10761, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10742, + "col": 26, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10761, + "col": 45, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368f1c8", + "kind": "FunctionDecl", + "loc": { + "offset": 10782, + "file": "../include/sls/ToString.h", + "line": 322, + "col": 18, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10765, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10811, + "col": 47, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368f3c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIbEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "bool (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "bool" + }, + "inner": [ + { + "id": "0x230bab0", + "kind": "BuiltinType", + "type": { + "qualType": "bool" + } + } + ] + }, + { + "id": "0x368f100", + "kind": "ParmVarDecl", + "loc": { + "offset": 10810, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10791, + "col": 27, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10810, + "col": 46, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x368f668", + "kind": "FunctionDecl", + "loc": { + "offset": 10834, + "file": "../include/sls/ToString.h", + "line": 323, + "col": 21, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10814, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10863, + "col": 50, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "previousDecl": "0x368f868", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIlEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "long" + }, + "inner": [ + { + "id": "0x230bb50", + "kind": "BuiltinType", + "type": { + "qualType": "long" + } + } + ] + }, + { + "id": "0x368f570", + "kind": "ParmVarDecl", + "loc": { + "offset": 10862, + "col": 49, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 10843, + "col": 30, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 10862, + "col": 49, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + ] +}, +{ + "id": "0x3690758", + "kind": "FunctionTemplateDecl", + "loc": { + "offset": 11100, + "file": "../include/sls/ToString.h", + "line": 333, + "col": 16, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11063, + "line": 332, + "col": 1, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "inner": [ + { + "id": "0x3690160", + "kind": "TemplateTypeParmDecl", + "loc": { + "offset": 11082, + "line": 332, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11073, + "col": 11, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11082, + "col": 20, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "T", + "tagUsed": "typename", + "depth": 0, + "index": 0 + }, + { + "id": "0x36906b8", + "kind": "FunctionDecl", + "loc": { + "offset": 11100, + "line": 333, + "col": 16, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11085, + "col": 1, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "name": "StringTo", + "type": { + "qualType": "std::vector (const std::vector &)" + }, + "inner": [ + { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "loc": { + "offset": 11141, + "line": 333, + "col": 57, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11109, + "col": 25, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11141, + "col": 57, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + }, + { + "id": "0x36bd368", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 11150, + "col": 66, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11310, + "line": 339, + "col": 1, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x3690a40", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11156, + "line": 334, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11177, + "col": 26, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36909d8", + "kind": "VarDecl", + "loc": { + "offset": 11171, + "col": 20, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11156, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11171, + "col": 20, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "nrvo": true + } + ] + }, + { + "id": "0x36b69a8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11183, + "line": 335, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11212, + "col": 34, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3690a78", + "kind": "CXXDependentScopeMemberExpr", + "range": { + "begin": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11190, + "col": 12, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "isArrow": false, + "member": "reserve", + "inner": [ + { + "id": "0x3690a58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11183, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + }, + { + "id": "0x36b6490", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11211, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::vector::size_type", + "typeAliasDeclId": "0x29007b8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36b6460", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11206, + "col": 28, + "tokLen": 4, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "size", + "isArrow": false, + "referencedMemberDecl": "0x36a9e90", + "inner": [ + { + "id": "0x3690ac0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11198, + "col": 20, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd140", + "kind": "CXXForRangeStmt", + "range": { + "begin": { + "offset": 11219, + "line": 336, + "col": 5, + "tokLen": 3, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11288, + "line": 337, + "col": 40, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + {}, + { + "id": "0x36b6d50", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11240, + "line": 336, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6b50", + "kind": "VarDecl", + "loc": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__range2", + "type": { + "qualType": "const std::vector &" + }, + "init": "c", + "inner": [ + { + "id": "0x36b69d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11240, + "col": 26, + "tokLen": 7, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36905a0", + "kind": "ParmVarDecl", + "name": "strings", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + }, + { + "id": "0x36bb028", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6de8", + "kind": "VarDecl", + "loc": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "init": "c", + "inner": [ + { + "id": "0x36babf8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36babc8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (__gnu_cxx::__normal_iterator *, std::vector>> &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36ba968", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36b6f88", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36b6f58", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "begin", + "isArrow": false, + "referencedMemberDecl": "0x36a9440", + "inner": [ + { + "id": "0x36b6d68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6b50", + "kind": "VarDecl", + "name": "__range2", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bb040", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6e90", + "kind": "VarDecl", + "loc": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isImplicit": true, + "isReferenced": true, + "name": "__end2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "init": "c", + "inner": [ + { + "id": "0x36bb010", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bafe0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (__gnu_cxx::__normal_iterator *, std::vector>> &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x36bafc8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x36baca0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bac70", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "end", + "isArrow": false, + "referencedMemberDecl": "0x36a9600", + "inner": [ + { + "id": "0x36b6d88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::vector>", + "qualType": "const std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6b50", + "kind": "VarDecl", + "name": "__range2", + "type": { + "qualType": "const std::vector &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bcd60", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x36bcd48", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (*)(const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bccd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "bool (const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36bb9d0", + "kind": "FunctionDecl", + "name": "operator!=", + "type": { + "qualType": "bool (const __normal_iterator *, std::vector>> &, const __normal_iterator *, std::vector>> &) noexcept" + } + } + } + ] + }, + { + "id": "0x36bcca0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const __gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "const __normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bb058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + }, + { + "id": "0x36bccb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const __gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "const __normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bb078", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6e90", + "kind": "VarDecl", + "name": "__end2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + } + ] + }, + { + "id": "0x36bce50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x36bce38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &(*)() noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bcdb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &() noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b8d20", + "kind": "CXXMethodDecl", + "name": "operator++", + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>> &() noexcept" + } + } + } + ] + }, + { + "id": "0x36bcd98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + }, + { + "id": "0x36b6ac8", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 11224, + "col": 10, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11247, + "col": 33, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36b6a60", + "kind": "VarDecl", + "loc": { + "offset": 11236, + "col": 22, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "range": { + "begin": { + "offset": 11224, + "col": 10, + "tokLen": 5, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "isReferenced": true, + "name": "s", + "type": { + "qualType": "std::basic_string const &" + }, + "init": "c", + "inner": [ + { + "id": "0x36bcf70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::basic_string" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x36bcf58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference (*)() const noexcept" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x36bcee0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference () const noexcept" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b8aa0", + "kind": "CXXMethodDecl", + "name": "operator*", + "type": { + "qualType": "__gnu_cxx::__normal_iterator *, std::vector>>::reference () const noexcept" + } + } + } + ] + }, + { + "id": "0x36bcec8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "const __gnu_cxx::__normal_iterator *, std::vector>>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x36bce80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11238, + "col": 24, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6de8", + "kind": "VarDecl", + "name": "__begin2", + "type": { + "desugaredQualType": "__gnu_cxx::__normal_iterator *, std::vector>>", + "qualType": "std::vector>::const_iterator", + "typeAliasDeclId": "0x36a3be8" + } + } + } + ] + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd308", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11257, + "line": 337, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11288, + "col": 40, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bd1c0", + "kind": "CXXDependentScopeMemberExpr", + "range": { + "begin": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11264, + "col": 16, + "tokLen": 9, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "isArrow": false, + "member": "push_back", + "inner": [ + { + "id": "0x36bd1a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11257, + "col": 9, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + }, + { + "id": "0x36bd2e0", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 11274, + "col": 26, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11287, + "col": 39, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x36bd238", + "kind": "UnresolvedLookupExpr", + "range": { + "begin": { + "offset": 11274, + "col": 26, + "tokLen": 8, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11284, + "col": 36, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "lvalue", + "usesADL": true, + "name": "StringTo", + "lookups": [ + { + "id": "0x3690758", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3687908", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + }, + { + "id": "0x3654da8", + "kind": "FunctionTemplateDecl", + "name": "StringTo" + } + ] + }, + { + "id": "0x36bd2c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11286, + "col": 38, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11286, + "col": 38, + "tokLen": 1, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "std::basic_string const" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36b6a60", + "kind": "VarDecl", + "name": "s", + "type": { + "qualType": "std::basic_string const &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x36bd350", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 11295, + "line": 338, + "col": 5, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "inner": [ + { + "id": "0x36bd330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + }, + "end": { + "offset": 11302, + "col": 12, + "tokLen": 6, + "includedFrom": { + "file": "ToString.cpp" + } + } + }, + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x36909d8", + "kind": "VarDecl", + "name": "result", + "type": { + "desugaredQualType": "vector", + "qualType": "std::vector" + } + } + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3849458", + "kind": "FunctionDecl", + "loc": { + "offset": 20783, + "file": "ToString.cpp", + "line": 665, + "col": 32, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 20752, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 21262, + "line": 681, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688208", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12detectorTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "inner": [ + { + "id": "0x2f41f40", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "decl": { + "id": "0x2f41ea0", + "kind": "EnumDecl", + "name": "detectorType" + } + } + ] + }, + { + "id": "0x3849388", + "kind": "ParmVarDecl", + "loc": { + "offset": 20811, + "line": 665, + "col": 60, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 20792, + "col": 41, + "tokLen": 5 + }, + "end": { + "offset": 20811, + "col": 60, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3850148", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 20814, + "col": 63, + "tokLen": 1 + }, + "end": { + "offset": 21262, + "line": 681, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x384a460", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20820, + "line": 666, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20859, + "line": 667, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x384a3b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20824, + "line": 666, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384a398", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20826, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20826, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384a378", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20826, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20826, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3849610", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20824, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20824, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384a360", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20829, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3849630", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20829, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 20829, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"Eiger\"" + } + ] + } + ] + }, + { + "id": "0x384a450", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20846, + "line": 667, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20859, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x384a420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20853, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20859, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f41fb0", + "kind": "EnumConstantDecl", + "name": "EIGER", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384b2d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20870, + "line": 668, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20912, + "line": 669, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384b220", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20874, + "line": 668, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384b208", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20876, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20876, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384b1e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20876, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20876, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384a480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20874, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20874, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384b1d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20879, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384a4a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20879, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20879, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"Gotthard\"" + } + ] + } + ] + }, + { + "id": "0x384b2c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20899, + "line": 669, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20912, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384b290", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20906, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20912, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42000", + "kind": "EnumConstantDecl", + "name": "GOTTHARD", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384c140", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20926, + "line": 670, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 20968, + "line": 671, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384c090", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20930, + "line": 670, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384c078", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384c058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384b2f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20930, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384c040", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384b310", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 20935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"Jungfrau\"" + } + ] + } + ] + }, + { + "id": "0x384c130", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 20955, + "line": 671, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 20968, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x384c100", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20962, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 20968, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42050", + "kind": "EnumConstantDecl", + "name": "JUNGFRAU", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384cfc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 20982, + "line": 672, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21029, + "line": 673, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x384cf10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 20986, + "line": 672, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384cef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20988, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20988, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ced8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20988, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 20988, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384c160", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 20986, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 20986, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384cec0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 20991, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384c180", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 20991, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 20991, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"ChipTestBoard\"" + } + ] + } + ] + }, + { + "id": "0x384cfb0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21016, + "line": 673, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21029, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x384cf80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21023, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21029, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f420a0", + "kind": "EnumConstantDecl", + "name": "CHIPTESTBOARD", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384de30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21048, + "line": 674, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21088, + "line": 675, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x384dd80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21052, + "line": 674, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384dd68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21054, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21054, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384dd48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21054, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21054, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384cfe0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21052, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21052, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384dd30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21057, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384d000", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21057, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 21057, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"Moench\"" + } + ] + } + ] + }, + { + "id": "0x384de20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21075, + "line": 675, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21088, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x384ddf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21082, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21088, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f420f0", + "kind": "EnumConstantDecl", + "name": "MOENCH", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384eca0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21100, + "line": 676, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21141, + "line": 677, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x384ebf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21104, + "line": 676, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384ebd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21106, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21106, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ebb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21106, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21106, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384de50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21104, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21104, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384eba0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21109, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384de70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21109, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21109, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"Mythen3\"" + } + ] + } + ] + }, + { + "id": "0x384ec90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21128, + "line": 677, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21141, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x384ec60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21135, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21141, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42140", + "kind": "EnumConstantDecl", + "name": "MYTHEN3", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x384fb20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21154, + "line": 678, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21197, + "line": 679, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x384fa70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21158, + "line": 678, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384fa58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21160, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21160, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384fa38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21160, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21160, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x384ecc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21158, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21158, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x384fa20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21163, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384ece0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21163, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21163, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"Gotthard2\"" + } + ] + } + ] + }, + { + "id": "0x384fb10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21184, + "line": 679, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21197, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x384fae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21191, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21197, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f42190", + "kind": "EnumConstantDecl", + "name": "GOTTHARD2", + "type": { + "qualType": "slsDetectorDefs::detectorType" + } + } + } + ] + } + ] + }, + { + "id": "0x3850130", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 21212, + "line": 680, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3850118", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 21212, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38500e8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38500d0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38500a8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3850088", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3850080", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3850050", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 21218, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 21259, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3850038", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3850020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3850000", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x384fff8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x384ffc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x384ffa8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21256, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 21256, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x384ff88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21256, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 21256, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x384ff70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21231, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x384fb50", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21231, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 21231, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown detector type \"" + } + ] + }, + { + "id": "0x384fb80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21258, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 21258, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3849388", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3850318", + "kind": "FunctionDecl", + "loc": { + "offset": 21300, + "file": "ToString.cpp", + "line": 683, + "col": 36, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 21265, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 22549, + "line": 725, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688728", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16detectorSettingsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::detectorSettings (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "inner": [ + { + "id": "0x2f5a2c0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "decl": { + "id": "0x2f5a218", + "kind": "EnumDecl", + "name": "detectorSettings" + } + } + ] + }, + { + "id": "0x3850240", + "kind": "ParmVarDecl", + "loc": { + "offset": 21328, + "line": 683, + "col": 64, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 21309, + "col": 45, + "tokLen": 5 + }, + "end": { + "offset": 21328, + "col": 64, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3866820", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 21331, + "col": 67, + "tokLen": 1 + }, + "end": { + "offset": 22549, + "line": 725, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3851320", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21337, + "line": 684, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21379, + "line": 685, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3851270", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21341, + "line": 684, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3851258", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21343, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21343, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3851238", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21343, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21343, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38504d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21341, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21341, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3851220", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21346, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38504f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21346, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21346, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"standard\"" + } + ] + } + ] + }, + { + "id": "0x3851310", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21366, + "line": 685, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21379, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38512e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21373, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21379, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a2e0", + "kind": "EnumConstantDecl", + "name": "STANDARD", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3855dc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21393, + "line": 686, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21431, + "line": 687, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3855d10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21397, + "line": 686, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3855cf8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21399, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21399, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3855cd8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21399, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21399, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3851340", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21397, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21397, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3855cc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21402, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3851360", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21402, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 21402, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"fast\"" + } + ] + } + ] + }, + { + "id": "0x3855db0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21418, + "line": 687, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21431, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3855d80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21425, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21431, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a330", + "kind": "EnumConstantDecl", + "name": "FAST", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3856c30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21441, + "line": 688, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21483, + "line": 689, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3856b80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21445, + "line": 688, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3856b68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21447, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21447, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3856b48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21447, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21447, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3855de0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21445, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21445, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3856b30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21450, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3855e00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21450, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21450, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"highgain\"" + } + ] + } + ] + }, + { + "id": "0x3856c20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21470, + "line": 689, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21483, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x3856bf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21477, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21483, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a380", + "kind": "EnumConstantDecl", + "name": "HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3857ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21497, + "line": 690, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21542, + "line": 691, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3857a00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21501, + "line": 690, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38579e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21503, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21503, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38579c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21503, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21503, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3856c50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21501, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21501, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38579b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21506, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3856c70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21506, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21506, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"dynamicgain\"" + } + ] + } + ] + }, + { + "id": "0x3857aa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21529, + "line": 691, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21542, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3857a70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21536, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21542, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a3d0", + "kind": "EnumConstantDecl", + "name": "DYNAMICGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3858920", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21559, + "line": 692, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21600, + "line": 693, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x3858870", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21563, + "line": 692, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3858858", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3858838", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3857ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21563, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21563, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3858820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3857af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 21568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"lowgain\"" + } + ] + } + ] + }, + { + "id": "0x3858910", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21587, + "line": 693, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21600, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38588e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21594, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21600, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a420", + "kind": "EnumConstantDecl", + "name": "LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38597a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21613, + "line": 694, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21657, + "line": 695, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38596f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21617, + "line": 694, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38596d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38596b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3858940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21617, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21617, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38596a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21622, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3858960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21622, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 21622, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"mediumgain\"" + } + ] + } + ] + }, + { + "id": "0x3859790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21644, + "line": 695, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21657, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3859760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21651, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21657, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a470", + "kind": "EnumConstantDecl", + "name": "MEDIUMGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385a620", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21673, + "line": 696, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21719, + "line": 697, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x385a570", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21677, + "line": 696, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385a558", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21679, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21679, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385a538", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21679, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21679, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38597c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21677, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21677, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385a520", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21682, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38597e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21682, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 21682, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"veryhighgain\"" + } + ] + } + ] + }, + { + "id": "0x385a610", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21706, + "line": 697, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21719, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x385a5e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21713, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21719, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a4c0", + "kind": "EnumConstantDecl", + "name": "VERYHIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385b4a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21737, + "line": 698, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21780, + "line": 699, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x385b3f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21741, + "line": 698, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385b3d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21743, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21743, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385b3b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21743, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21743, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385a640", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21741, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21741, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385b3a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21746, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385a660", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21746, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 21746, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"highgain0\"" + } + ] + } + ] + }, + { + "id": "0x385b490", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21767, + "line": 699, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21780, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x385b460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21774, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21780, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a510", + "kind": "EnumConstantDecl", + "name": "HIGHGAIN0", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385c310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21795, + "line": 700, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21837, + "line": 701, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385c260", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21799, + "line": 700, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385c248", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21801, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21801, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385c228", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21801, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21801, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385b4c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21799, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21799, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385c210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21804, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385b4e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21804, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21804, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"fixgain1\"" + } + ] + } + ] + }, + { + "id": "0x385c300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21824, + "line": 701, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21837, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385c2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21831, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21837, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a560", + "kind": "EnumConstantDecl", + "name": "FIXGAIN1", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385d180", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21851, + "line": 702, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21893, + "line": 703, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385d0d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21855, + "line": 702, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385d0b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385d098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385c330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21855, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21855, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385d080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21860, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385c350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21860, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 21860, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"fixgain2\"" + } + ] + } + ] + }, + { + "id": "0x385d170", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21880, + "line": 703, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21893, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x385d140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21887, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21893, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a5b0", + "kind": "EnumConstantDecl", + "name": "FIXGAIN2", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385e000", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21907, + "line": 704, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 21952, + "line": 705, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385df50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21911, + "line": 704, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385df38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385df18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385d1a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21911, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21911, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385df00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21916, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385d1c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21916, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 21916, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"verylowgain\"" + } + ] + } + ] + }, + { + "id": "0x385dff0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21939, + "line": 705, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 21952, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385dfc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21946, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 21952, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a600", + "kind": "EnumConstantDecl", + "name": "VERYLOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385ee70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 21969, + "line": 706, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22008, + "line": 707, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385edc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 21973, + "line": 706, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385eda8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21975, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21975, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385ed88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21975, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 21975, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385e020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 21973, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 21973, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385ed70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 21978, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385e040", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 21978, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 21978, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g1_hg\"" + } + ] + } + ] + }, + { + "id": "0x385ee60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 21995, + "line": 707, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22008, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x385ee30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22002, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22008, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a650", + "kind": "EnumConstantDecl", + "name": "G1_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x385fce0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22025, + "line": 708, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22064, + "line": 709, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x385fc30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22029, + "line": 708, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x385fc18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22031, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22031, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x385fbf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22031, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22031, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385ee90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22029, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22029, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x385fbe0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22034, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385eeb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22034, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22034, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g1_lg\"" + } + ] + } + ] + }, + { + "id": "0x385fcd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22051, + "line": 709, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22064, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x385fca0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22058, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22064, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a6a0", + "kind": "EnumConstantDecl", + "name": "G1_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3860b50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22080, + "line": 710, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22122, + "line": 711, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x3860aa0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22084, + "line": 710, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3860a88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22086, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22086, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3860a68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22086, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22086, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x385fd00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22084, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22084, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3860a50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22089, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x385fd20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22089, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22089, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_hc_hg\"" + } + ] + } + ] + }, + { + "id": "0x3860b40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22109, + "line": 711, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22122, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x3860b10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22116, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22122, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a6f0", + "kind": "EnumConstantDecl", + "name": "G2_HIGHCAP_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38619c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22147, + "line": 712, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22189, + "line": 713, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3861910", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22151, + "line": 712, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38618f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38618d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3860b70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22151, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22151, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38618c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22156, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3860b90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22156, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22156, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_hc_lg\"" + } + ] + } + ] + }, + { + "id": "0x38619b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22176, + "line": 713, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22189, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3861980", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22183, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22189, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a740", + "kind": "EnumConstantDecl", + "name": "G2_HIGHCAP_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3862830", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22213, + "line": 714, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22255, + "line": 715, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3862780", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22217, + "line": 714, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3862768", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22219, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22219, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3862748", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22219, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22219, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38619e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22217, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22217, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3862730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22222, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3861a00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22222, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22222, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_lc_hg\"" + } + ] + } + ] + }, + { + "id": "0x3862820", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22242, + "line": 715, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22255, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x38627f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22249, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22255, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a790", + "kind": "EnumConstantDecl", + "name": "G2_LOWCAP_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x38636a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22279, + "line": 716, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22321, + "line": 717, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x38635f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22283, + "line": 716, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38635d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22285, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22285, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38635b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22285, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22285, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3862850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22283, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22283, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38635a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22288, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3862870", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22288, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 22288, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"g2_lc_lg\"" + } + ] + } + ] + }, + { + "id": "0x3863690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22308, + "line": 717, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22321, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x3863660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22315, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22321, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a7e0", + "kind": "EnumConstantDecl", + "name": "G2_LOWCAP_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3864510", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22344, + "line": 718, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22383, + "line": 719, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x3864460", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22348, + "line": 718, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3864448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3864428", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38636c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22348, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22348, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3864410", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22353, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38636e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22353, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22353, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g4_hg\"" + } + ] + } + ] + }, + { + "id": "0x3864500", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22370, + "line": 719, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22383, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38644d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22377, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22383, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a830", + "kind": "EnumConstantDecl", + "name": "G4_HIGHGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3865390", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22400, + "line": 720, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22439, + "line": 721, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38652e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22404, + "line": 720, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38652c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38652a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3864530", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22404, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22404, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3865290", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22409, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3864550", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22409, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22409, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"gain0\"" + } + ] + } + ] + }, + { + "id": "0x3865380", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22426, + "line": 721, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22439, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3865350", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22433, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22439, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a8d0", + "kind": "EnumConstantDecl", + "name": "GAIN0", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3866200", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22450, + "line": 722, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22489, + "line": 723, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3866150", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22454, + "line": 722, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3866138", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22456, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22456, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3866118", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22456, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22456, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38653b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22454, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22454, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3866100", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22459, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38653d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22459, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 22459, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"g4_lg\"" + } + ] + } + ] + }, + { + "id": "0x38661f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22476, + "line": 723, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22489, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38661c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22483, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22489, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a880", + "kind": "EnumConstantDecl", + "name": "G4_LOWGAIN", + "type": { + "qualType": "slsDetectorDefs::detectorSettings" + } + } + } + ] + } + ] + }, + { + "id": "0x3866808", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 22505, + "line": 724, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38667f0", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 22505, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38667c0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38667a8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3866780", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3866760", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3866758", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3866728", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 22511, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 22546, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3866710", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38666f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38666d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38666d0", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3866698", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3866680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22543, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 22543, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3866660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22543, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 22543, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3866648", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22524, + "col": 24, + "tokLen": 18 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3866230", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22524, + "col": 24, + "tokLen": 18 + }, + "end": { + "offset": 22524, + "col": 24, + "tokLen": 18 + } + }, + "type": { + "qualType": "const char[17]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown setting \"" + } + ] + }, + { + "id": "0x3866258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22545, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 22545, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3850240", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3866a58", + "kind": "FunctionDecl", + "loc": { + "offset": 22581, + "file": "ToString.cpp", + "line": 727, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 22552, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23106, + "line": 745, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3688c48", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10speedLevelEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::speedLevel (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "inner": [ + { + "id": "0x2f5af70", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "decl": { + "id": "0x2f5aec8", + "kind": "EnumDecl", + "name": "speedLevel" + } + } + ] + }, + { + "id": "0x3866980", + "kind": "ParmVarDecl", + "loc": { + "offset": 22609, + "line": 727, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 22590, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 22609, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x386e5c0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 22612, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 23106, + "line": 745, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3867a70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22618, + "line": 728, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22662, + "line": 729, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38679c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22622, + "line": 728, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38679a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22624, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22624, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3867988", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22624, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22624, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3866c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22622, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22622, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3867970", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22627, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3866c30", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22627, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22627, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"full_speed\"" + } + ] + } + ] + }, + { + "id": "0x3867a60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22649, + "line": 729, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22662, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3867a30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22656, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22662, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5af90", + "kind": "EnumConstantDecl", + "name": "FULL_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x38688e0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22678, + "line": 730, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22713, + "line": 731, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3868830", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22682, + "line": 730, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3868818", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22684, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22684, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38687f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22684, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22684, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3867a90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22682, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22682, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38687e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22687, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3867ab0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22687, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22687, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"0\"" + } + ] + } + ] + }, + { + "id": "0x38688d0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22700, + "line": 731, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22713, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38688a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22707, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22713, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5af90", + "kind": "EnumConstantDecl", + "name": "FULL_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x3869760", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22729, + "line": 732, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22773, + "line": 733, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38696b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22733, + "line": 732, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3869698", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22735, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22735, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3869678", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22735, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22735, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3868900", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22733, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22733, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3869660", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22738, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3868920", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22738, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 22738, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"half_speed\"" + } + ] + } + ] + }, + { + "id": "0x3869750", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22760, + "line": 733, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22773, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3869720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22767, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22773, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5afe0", + "kind": "EnumConstantDecl", + "name": "HALF_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386a5d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22789, + "line": 734, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22824, + "line": 735, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x386a520", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22793, + "line": 734, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386a508", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22795, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22795, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386a4e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22795, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22795, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3869780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22793, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22793, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386a4d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22798, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38697a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22798, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22798, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"1\"" + } + ] + } + ] + }, + { + "id": "0x386a5c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22811, + "line": 735, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22824, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x386a590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22818, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22824, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5afe0", + "kind": "EnumConstantDecl", + "name": "HALF_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386b450", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22840, + "line": 736, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22887, + "line": 737, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386b3a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22844, + "line": 736, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386b388", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22846, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22846, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386b368", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22846, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22846, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386a5f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22844, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22844, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386b350", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22849, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386a610", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22849, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 22849, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"quarter_speed\"" + } + ] + } + ] + }, + { + "id": "0x386b440", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22874, + "line": 737, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22887, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386b410", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22881, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22887, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b030", + "kind": "EnumConstantDecl", + "name": "QUARTER_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386c2c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22906, + "line": 738, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22941, + "line": 739, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386c210", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22910, + "line": 738, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386c1f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22912, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22912, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386c1d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22912, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22912, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386b470", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22910, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22910, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386c1c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22915, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386b490", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22915, + "col": 14, + "tokLen": 3 + }, + "end": { + "offset": 22915, + "col": 14, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"2\"" + } + ] + } + ] + }, + { + "id": "0x386c2b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22928, + "line": 739, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22941, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x386c280", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22935, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22941, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b030", + "kind": "EnumConstantDecl", + "name": "QUARTER_SPEED", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386d130", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 22960, + "line": 740, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 22997, + "line": 741, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386d080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 22964, + "line": 740, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386d068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22966, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22966, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386d048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22966, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 22966, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386c2e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22964, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 22964, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386d030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 22969, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386c300", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 22969, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 22969, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"108\"" + } + ] + } + ] + }, + { + "id": "0x386d120", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 22984, + "line": 741, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 22997, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386d0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 22991, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 22997, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b080", + "kind": "EnumConstantDecl", + "name": "G2_108MHZ", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386dfa0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23012, + "line": 742, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23049, + "line": 743, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386def0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23016, + "line": 742, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386ded8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23018, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23018, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386deb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23018, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23018, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386d150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23016, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23016, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386dea0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23021, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386d170", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23021, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 23021, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"144\"" + } + ] + } + ] + }, + { + "id": "0x386df90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23036, + "line": 743, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23049, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x386df60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23043, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23049, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::speedLevel" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b0d0", + "kind": "EnumConstantDecl", + "name": "G2_144MHZ", + "type": { + "qualType": "slsDetectorDefs::speedLevel" + } + } + } + ] + } + ] + }, + { + "id": "0x386e5a8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23064, + "line": 744, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x386e590", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23064, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x386e560", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x386e548", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x386e520", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x386e500", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x386e4f8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x386e4c8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23070, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23103, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x386e4b0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x386e498", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x386e478", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x386e470", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x386e438", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386e420", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23100, + "col": 41, + "tokLen": 1 + }, + "end": { + "offset": 23100, + "col": 41, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386e400", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23100, + "col": 41, + "tokLen": 1 + }, + "end": { + "offset": 23100, + "col": 41, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x386e3e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23083, + "col": 24, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386dfd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23083, + "col": 24, + "tokLen": 16 + }, + "end": { + "offset": 23083, + "col": 24, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown speed \"" + } + ] + }, + { + "id": "0x386dff8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23102, + "col": 43, + "tokLen": 1 + }, + "end": { + "offset": 23102, + "col": 43, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3866980", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x386e798", + "kind": "FunctionDecl", + "loc": { + "offset": 23138, + "file": "ToString.cpp", + "line": 747, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23109, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23525, + "line": 759, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689168", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10timingModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "inner": [ + { + "id": "0x2f57730", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "decl": { + "id": "0x2f57688", + "kind": "EnumDecl", + "name": "timingMode" + } + } + ] + }, + { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "loc": { + "offset": 23166, + "line": 747, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23147, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 23166, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38737a8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23169, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 23525, + "line": 759, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x386f7a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23175, + "line": 748, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23213, + "line": 749, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x386f6f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23179, + "line": 748, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x386f6d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23181, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23181, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x386f6b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23181, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23181, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386e950", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23179, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23179, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x386f6a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23184, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386e970", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23184, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23184, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"auto\"" + } + ] + } + ] + }, + { + "id": "0x386f790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23200, + "line": 749, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23213, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x386f760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23207, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23213, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57750", + "kind": "EnumConstantDecl", + "name": "AUTO_TIMING", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3870610", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23230, + "line": 750, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23271, + "line": 751, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3870560", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23234, + "line": 750, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3870548", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23236, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23236, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3870528", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23236, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23236, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x386f7c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23234, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23234, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3870510", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23239, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x386f7e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23239, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 23239, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"trigger\"" + } + ] + } + ] + }, + { + "id": "0x3870600", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23258, + "line": 751, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23271, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38705d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23265, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23271, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f577a0", + "kind": "EnumConstantDecl", + "name": "TRIGGER_EXPOSURE", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3871480", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23293, + "line": 752, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23333, + "line": 753, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38713d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23297, + "line": 752, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38713b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23299, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23299, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3871398", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23299, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23299, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3870630", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23297, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23297, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3871380", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23302, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3870650", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23302, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23302, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"gating\"" + } + ] + } + ] + }, + { + "id": "0x3871470", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23320, + "line": 753, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23333, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3871440", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23327, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23333, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f577f0", + "kind": "EnumConstantDecl", + "name": "GATED", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3872300", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23344, + "line": 754, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23391, + "line": 755, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x3872250", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23348, + "line": 754, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3872238", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3872218", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23350, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23350, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38714a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23348, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23348, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3872200", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23353, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38714c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23353, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 23353, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"burst_trigger\"" + } + ] + } + ] + }, + { + "id": "0x38722f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23378, + "line": 755, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23391, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38722c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23385, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23391, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57840", + "kind": "EnumConstantDecl", + "name": "BURST_TRIGGER", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3873180", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23410, + "line": 756, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23458, + "line": 757, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38730d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23414, + "line": 756, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38730b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23416, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23416, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3873098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23416, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23416, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3872320", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23414, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23414, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3873080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23419, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3872340", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23419, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23419, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_gating\"" + } + ] + } + ] + }, + { + "id": "0x3873170", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23445, + "line": 757, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23458, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x3873140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23452, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23458, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57890", + "kind": "EnumConstantDecl", + "name": "TRIGGER_GATED", + "type": { + "qualType": "slsDetectorDefs::timingMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3873790", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23477, + "line": 758, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3873778", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23477, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3873748", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3873730", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3873708", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38736e8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38736e0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38736b0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23483, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23522, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3873698", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3873680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3873660", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3873658", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3873620", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3873608", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23519, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 23519, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38735e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23519, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 23519, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38735d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23496, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38731b0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23496, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 23496, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char[21]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown timing mode \"" + } + ] + }, + { + "id": "0x38731e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23521, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 23521, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x386e6c0", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3873968", + "kind": "FunctionDecl", + "loc": { + "offset": 23565, + "file": "ToString.cpp", + "line": 761, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23528, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 23866, + "line": 769, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689688", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18frameDiscardPolicyEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::frameDiscardPolicy (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "inner": [ + { + "id": "0x2f554b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "decl": { + "id": "0x2f55410", + "kind": "EnumDecl", + "name": "frameDiscardPolicy" + } + } + ] + }, + { + "id": "0x3873890", + "kind": "ParmVarDecl", + "loc": { + "offset": 23593, + "line": 761, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23574, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 23593, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3876cd0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23596, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 23866, + "line": 769, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3874980", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23602, + "line": 762, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23645, + "line": 763, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38748d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23606, + "line": 762, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38748b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23608, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23608, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3874898", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23608, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23608, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3873b20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23606, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23606, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3874880", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23611, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3873b40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23611, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 23611, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"nodiscard\"" + } + ] + } + ] + }, + { + "id": "0x3874970", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23632, + "line": 763, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23645, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x3874940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23639, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23645, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f554d0", + "kind": "EnumConstantDecl", + "name": "NO_DISCARD", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x3875820", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23661, + "line": 764, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23707, + "line": 765, + "col": 22, + "tokLen": 20 + } + }, + "inner": [ + { + "id": "0x3875770", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23665, + "line": 764, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3875758", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23667, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23667, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3875738", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23667, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23667, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38749a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23665, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23665, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3875720", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23670, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38749c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23670, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 23670, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"discardempty\"" + } + ] + } + ] + }, + { + "id": "0x3875810", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23694, + "line": 765, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23707, + "col": 22, + "tokLen": 20 + } + }, + "inner": [ + { + "id": "0x38757e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23701, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23707, + "col": 22, + "tokLen": 20 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55520", + "kind": "EnumConstantDecl", + "name": "DISCARD_EMPTY_FRAMES", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x38766a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23733, + "line": 766, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23781, + "line": 767, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x38765f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23737, + "line": 766, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38765d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23739, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23739, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38765b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23739, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23739, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3875840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23737, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23737, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38765a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23742, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3875860", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23742, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 23742, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"discardpartial\"" + } + ] + } + ] + }, + { + "id": "0x3876690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23768, + "line": 767, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23781, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x3876660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23775, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23781, + "col": 22, + "tokLen": 22 + } + }, + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55570", + "kind": "EnumConstantDecl", + "name": "DISCARD_PARTIAL_FRAMES", + "type": { + "qualType": "slsDetectorDefs::frameDiscardPolicy" + } + } + } + ] + } + ] + }, + { + "id": "0x3876cb8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 23809, + "line": 768, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3876ca0", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 23809, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x3876c70", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3876c58", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3876c30", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3876c10", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3876c08", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3876bd8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 23815, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 23863, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3876bc0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3876ba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3876b88", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3876b80", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3876b48", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3876b30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23860, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 23860, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3876b10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23860, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 23860, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3876af8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23828, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38766d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23828, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 23828, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char[30]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown frame discard policy \"" + } + ] + }, + { + "id": "0x3876708", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23862, + "col": 58, + "tokLen": 1 + }, + "end": { + "offset": 23862, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3873890", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3876e78", + "kind": "FunctionDecl", + "loc": { + "offset": 23898, + "file": "ToString.cpp", + "line": 771, + "col": 30, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 23869, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24083, + "line": 777, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x3689ba8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs10fileFormatEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::fileFormat (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "inner": [ + { + "id": "0x2f556b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "decl": { + "id": "0x2f55610", + "kind": "EnumDecl", + "name": "fileFormat" + } + } + ] + }, + { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "loc": { + "offset": 23926, + "line": 771, + "col": 58, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 23907, + "col": 39, + "tokLen": 5 + }, + "end": { + "offset": 23926, + "col": 58, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3879318", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 23929, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 24083, + "line": 777, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3877e80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23935, + "line": 772, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 23973, + "line": 773, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3877dd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23939, + "line": 772, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3877db8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23941, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23941, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3877d98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23941, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23941, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3877030", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23939, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23939, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3877d80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23944, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3877050", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23944, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 23944, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"hdf5\"" + } + ] + } + ] + }, + { + "id": "0x3877e70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 23960, + "line": 773, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 23973, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x3877e40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23967, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 23973, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f55720", + "kind": "EnumConstantDecl", + "name": "HDF5", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + } + } + } + ] + } + ] + }, + { + "id": "0x3878cf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 23983, + "line": 774, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24023, + "line": 775, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3878c40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 23987, + "line": 774, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3878c28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23989, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23989, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3878c08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23989, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 23989, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3877ea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 23987, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 23987, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3878bf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 23992, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3877ec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 23992, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 23992, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"binary\"" + } + ] + } + ] + }, + { + "id": "0x3878ce0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24010, + "line": 775, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24023, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3878cb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24017, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24023, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::fileFormat" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f556d0", + "kind": "EnumConstantDecl", + "name": "BINARY", + "type": { + "qualType": "slsDetectorDefs::fileFormat" + } + } + } + ] + } + ] + }, + { + "id": "0x3879300", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24035, + "line": 776, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38792e8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24035, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38792b8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38792a0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x3879278", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3879258", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3879250", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3879220", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24041, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24080, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3879208", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38791f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38791d0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38791c8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3879190", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3879178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24077, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 24077, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3879158", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24077, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 24077, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3879140", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24054, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3878d20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24054, + "col": 24, + "tokLen": 22 + }, + "end": { + "offset": 24054, + "col": 24, + "tokLen": 22 + } + }, + "type": { + "qualType": "const char[21]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown file format \"" + } + ] + }, + { + "id": "0x3878d50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24079, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 24079, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3876da8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38794b8", + "kind": "FunctionDecl", + "loc": { + "offset": 24123, + "file": "ToString.cpp", + "line": 779, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24086, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24517, + "line": 789, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368abf0", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18externalSignalFlagEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::externalSignalFlag (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "inner": [ + { + "id": "0x2f57500", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "decl": { + "id": "0x2f57458", + "kind": "EnumDecl", + "name": "externalSignalFlag" + } + } + ] + }, + { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "loc": { + "offset": 24151, + "line": 779, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 24132, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 24151, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x387d680", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 24154, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 24517, + "line": 789, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x387a4d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24160, + "line": 780, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24216, + "line": 781, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x387a420", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24164, + "line": 780, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387a408", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24166, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24166, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387a3e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24166, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24166, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3879670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24164, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24164, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387a3d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24169, + "col": 14, + "tokLen": 24 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3879690", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24169, + "col": 14, + "tokLen": 24 + }, + "end": { + "offset": 24169, + "col": 14, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_in_rising_edge\"" + } + ] + } + ] + }, + { + "id": "0x387a4c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24203, + "line": 781, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24216, + "col": 22, + "tokLen": 22 + } + }, + "inner": [ + { + "id": "0x387a490", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24210, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24216, + "col": 22, + "tokLen": 22 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57520", + "kind": "EnumConstantDecl", + "name": "TRIGGER_IN_RISING_EDGE", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387b350", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24244, + "line": 782, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24301, + "line": 783, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x387b2a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24248, + "line": 782, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387b288", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24250, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24250, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387b268", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24250, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24250, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387a4f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24248, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24248, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387b250", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24253, + "col": 14, + "tokLen": 25 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387a510", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24253, + "col": 14, + "tokLen": 25 + }, + "end": { + "offset": 24253, + "col": 14, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char[24]" + }, + "valueCategory": "lvalue", + "value": "\"trigger_in_falling_edge\"" + } + ] + } + ] + }, + { + "id": "0x387b340", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24288, + "line": 783, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24301, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x387b310", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24295, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24301, + "col": 22, + "tokLen": 23 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57570", + "kind": "EnumConstantDecl", + "name": "TRIGGER_IN_FALLING_EDGE", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387c1d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24330, + "line": 784, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24376, + "line": 785, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387c120", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24334, + "line": 784, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387c108", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24336, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24336, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387c0e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24336, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24336, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387b370", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24334, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24334, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387c0d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24339, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387b390", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24339, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 24339, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"inversion_on\"" + } + ] + } + ] + }, + { + "id": "0x387c1c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24363, + "line": 785, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24376, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387c190", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24370, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24376, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f575c0", + "kind": "EnumConstantDecl", + "name": "INVERSION_ON", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387d050", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24394, + "line": 786, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24441, + "line": 787, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x387cfa0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24398, + "line": 786, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387cf88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24400, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24400, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387cf68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24400, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24400, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387c1f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24398, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24398, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387cf50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24403, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387c210", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24403, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 24403, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"inversion_off\"" + } + ] + } + ] + }, + { + "id": "0x387d040", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24428, + "line": 787, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24441, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x387d010", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24435, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24441, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57610", + "kind": "EnumConstantDecl", + "name": "INVERSION_OFF", + "type": { + "qualType": "slsDetectorDefs::externalSignalFlag" + } + } + } + ] + } + ] + }, + { + "id": "0x387d668", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24460, + "line": 788, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x387d650", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24460, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x387d620", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x387d608", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x387d5e0", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x387d5c0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x387d5b8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x387d588", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24466, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24514, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x387d570", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x387d558", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x387d538", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x387d530", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x387d4f8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387d4e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24511, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 24511, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387d4c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24511, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 24511, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x387d4a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24479, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387d080", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24479, + "col": 24, + "tokLen": 31 + }, + "end": { + "offset": 24479, + "col": 24, + "tokLen": 31 + } + }, + "type": { + "qualType": "const char[30]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown external signal flag \"" + } + ] + }, + { + "id": "0x387d0b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24513, + "col": 58, + "tokLen": 1 + }, + "end": { + "offset": 24513, + "col": 58, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38793e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x387d838", + "kind": "FunctionDecl", + "loc": { + "offset": 24550, + "file": "ToString.cpp", + "line": 791, + "col": 31, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24520, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 24973, + "line": 803, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368b118", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11readoutModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::readoutMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "inner": [ + { + "id": "0x2f5acf0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "decl": { + "id": "0x2f5ac48", + "kind": "EnumDecl", + "name": "readoutMode" + } + } + ] + }, + { + "id": "0x387d760", + "kind": "ParmVarDecl", + "loc": { + "offset": 24578, + "line": 791, + "col": 59, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 24559, + "col": 40, + "tokLen": 5 + }, + "end": { + "offset": 24578, + "col": 59, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x3882858", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 24581, + "col": 62, + "tokLen": 1 + }, + "end": { + "offset": 24973, + "line": 803, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x387e840", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24587, + "line": 792, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24627, + "line": 793, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x387e790", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24591, + "line": 792, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387e778", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24593, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24593, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387e758", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24593, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24593, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387d9f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24591, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24591, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387e740", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24596, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387da10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24596, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 24596, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"analog\"" + } + ] + } + ] + }, + { + "id": "0x387e830", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24614, + "line": 793, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24627, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x387e800", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24621, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24627, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ad10", + "kind": "EnumConstantDecl", + "name": "ANALOG_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x387f6b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24644, + "line": 794, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24685, + "line": 795, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387f600", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24648, + "line": 794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x387f5e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24650, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24650, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x387f5c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24650, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24650, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387e860", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24648, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24648, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x387f5b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24653, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387e880", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24653, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 24653, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"digital\"" + } + ] + } + ] + }, + { + "id": "0x387f6a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24672, + "line": 795, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24685, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x387f670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24679, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24685, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ad60", + "kind": "EnumConstantDecl", + "name": "DIGITAL_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3880530", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24703, + "line": 796, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24751, + "line": 797, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x3880480", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24707, + "line": 796, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3880468", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24709, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24709, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3880448", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24709, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24709, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x387f6d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24707, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24707, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3880430", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24712, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x387f6f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24712, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 24712, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"analog_digital\"" + } + ] + } + ] + }, + { + "id": "0x3880520", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24738, + "line": 797, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24751, + "col": 22, + "tokLen": 18 + } + }, + "inner": [ + { + "id": "0x38804f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24745, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24751, + "col": 22, + "tokLen": 18 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5adb0", + "kind": "EnumConstantDecl", + "name": "ANALOG_AND_DIGITAL", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38813b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24775, + "line": 798, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24820, + "line": 799, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3881300", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24779, + "line": 798, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38812e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24781, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24781, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38812c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24781, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24781, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3880550", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24779, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24779, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38812b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24784, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3880570", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24784, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 24784, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"transceiver\"" + } + ] + } + ] + }, + { + "id": "0x38813a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24807, + "line": 799, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24820, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x3881370", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24814, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24820, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ae00", + "kind": "EnumConstantDecl", + "name": "TRANSCEIVER_ONLY", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3882230", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 24842, + "line": 800, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 24895, + "line": 801, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x3882180", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24846, + "line": 800, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3882168", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24848, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24848, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3882148", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24848, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 24848, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38813d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24846, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 24846, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3882130", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24851, + "col": 14, + "tokLen": 21 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38813f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24851, + "col": 14, + "tokLen": 21 + }, + "end": { + "offset": 24851, + "col": 14, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char[20]" + }, + "valueCategory": "lvalue", + "value": "\"digital_transceiver\"" + } + ] + } + ] + }, + { + "id": "0x3882220", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 24882, + "line": 801, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 24895, + "col": 22, + "tokLen": 23 + } + }, + "inner": [ + { + "id": "0x38821f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24889, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 24895, + "col": 22, + "tokLen": 23 + } + }, + "type": { + "qualType": "slsDetectorDefs::readoutMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ae50", + "kind": "EnumConstantDecl", + "name": "DIGITAL_AND_TRANSCEIVER", + "type": { + "qualType": "slsDetectorDefs::readoutMode" + } + } + } + ] + } + ] + }, + { + "id": "0x3882840", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 24924, + "line": 802, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x3882828", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 24924, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38827f8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38827e0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38827b8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x3882798", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x3882790", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x3882760", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 24930, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 24970, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x3882748", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x3882730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x3882710", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x3882708", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38826d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38826b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24967, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 24967, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3882698", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24967, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 24967, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x3882680", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24943, + "col": 24, + "tokLen": 23 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3882260", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 24943, + "col": 24, + "tokLen": 23 + }, + "end": { + "offset": 24943, + "col": 24, + "tokLen": 23 + } + }, + "type": { + "qualType": "const char[22]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown readout mode \"" + } + ] + }, + { + "id": "0x3882290", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 24969, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 24969, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x387d760", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x3882a18", + "kind": "FunctionDecl", + "loc": { + "offset": 25003, + "file": "ToString.cpp", + "line": 805, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 24976, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 30397, + "line": 991, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368b638", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8dacIndexEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::dacIndex (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "inner": [ + { + "id": "0x2f57a00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "decl": { + "id": "0x2f57958", + "kind": "EnumDecl", + "name": "dacIndex" + } + } + ] + }, + { + "id": "0x3882940", + "kind": "ParmVarDecl", + "loc": { + "offset": 25031, + "line": 805, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 25012, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 25031, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f1964637fa8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 25034, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 30397, + "line": 991, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x3884820", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25040, + "line": 806, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25091, + "line": 807, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3884788", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25044, + "line": 806, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3883970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25044, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3883958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25046, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25046, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3883938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25046, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25046, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3882bd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25044, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25044, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3883920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25049, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3882bf0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25049, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25049, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 0\"" + } + ] + } + ] + }, + { + "id": "0x3884750", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25060, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3884738", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25062, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25062, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3884718", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25062, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25062, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38839a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25060, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25060, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3884700", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25065, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38839c8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25065, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25065, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"0\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3884810", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25078, + "line": 807, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25091, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38847e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25085, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25091, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57a20", + "kind": "EnumConstantDecl", + "name": "DAC_0", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38864d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25102, + "line": 808, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25153, + "line": 809, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3886438", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25106, + "line": 808, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3885620", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25106, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3885608", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25108, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25108, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38855e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25108, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25108, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3884840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25106, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25106, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38855d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25111, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3884860", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25111, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25111, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 1\"" + } + ] + } + ] + }, + { + "id": "0x3886400", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25122, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38863e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25124, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25124, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38863c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25124, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25124, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3885658", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25122, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25122, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38863b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25127, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3885678", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25127, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25127, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"1\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38864c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25140, + "line": 809, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25153, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3886490", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25147, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25153, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57a70", + "kind": "EnumConstantDecl", + "name": "DAC_1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3888140", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25164, + "line": 810, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25215, + "line": 811, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38880a8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25168, + "line": 810, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3887290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25168, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3887278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25170, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25170, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3887258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25170, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25170, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38864f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25168, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25168, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3887240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25173, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3886510", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25173, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25173, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 2\"" + } + ] + } + ] + }, + { + "id": "0x3888070", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25184, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3888058", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25186, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25186, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3888038", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25186, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25186, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38872c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25184, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25184, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3888020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25189, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38872e8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25189, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25189, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"2\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3888130", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25202, + "line": 811, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25215, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3888100", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25209, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25215, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ac0", + "kind": "EnumConstantDecl", + "name": "DAC_2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3889db0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25226, + "line": 812, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25277, + "line": 813, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3889d18", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25230, + "line": 812, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3888f00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25230, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3888ee8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25232, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25232, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3888ec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25232, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25232, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3888160", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25230, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25230, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3888eb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25235, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3888180", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25235, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25235, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 3\"" + } + ] + } + ] + }, + { + "id": "0x3889ce0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25246, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3889cc8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25248, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25248, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3889ca8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25248, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25248, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3888f38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25246, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25246, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3889c90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25251, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3888f58", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25251, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25251, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"3\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3889da0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25264, + "line": 813, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25277, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3889d70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25271, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25277, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57b10", + "kind": "EnumConstantDecl", + "name": "DAC_3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388ba20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25288, + "line": 814, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25339, + "line": 815, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388b988", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25292, + "line": 814, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388ab70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25292, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388ab58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25294, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25294, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388ab38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25294, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25294, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3889dd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25292, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25292, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388ab20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25297, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3889df0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25297, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25297, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 4\"" + } + ] + } + ] + }, + { + "id": "0x388b950", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25308, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388b938", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25310, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25310, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388b918", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25310, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25310, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388aba8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25308, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25308, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388b900", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25313, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388abc8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25313, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25313, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"4\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388ba10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25326, + "line": 815, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25339, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388b9e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25333, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25339, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57b60", + "kind": "EnumConstantDecl", + "name": "DAC_4", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388d690", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25350, + "line": 816, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25401, + "line": 817, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388d5f8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25354, + "line": 816, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388c7e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25354, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388c7c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25356, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25356, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388c7a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25356, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25356, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388ba40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25354, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25354, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388c790", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25359, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388ba60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25359, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25359, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 5\"" + } + ] + } + ] + }, + { + "id": "0x388d5c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25370, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388d5a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25372, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25372, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388d588", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25372, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25372, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388c818", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25370, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25370, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388d570", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25375, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388c838", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25375, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25375, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"5\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388d680", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25388, + "line": 817, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25401, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388d650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25395, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25401, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57bb0", + "kind": "EnumConstantDecl", + "name": "DAC_5", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x388f300", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25412, + "line": 818, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25463, + "line": 819, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388f268", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25416, + "line": 818, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x388e450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25416, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388e438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25418, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25418, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388e418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25418, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25418, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388d6b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25416, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25416, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388e400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25421, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388d6d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25421, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25421, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 6\"" + } + ] + } + ] + }, + { + "id": "0x388f230", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25432, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x388f218", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25434, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25434, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x388f1f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25434, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25434, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388e488", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25432, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25432, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x388f1e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25437, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388e4a8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25437, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25437, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"6\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x388f2f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25450, + "line": 819, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25463, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x388f2c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25457, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25463, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57c00", + "kind": "EnumConstantDecl", + "name": "DAC_6", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3890f70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25474, + "line": 820, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25525, + "line": 821, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3890ed8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25478, + "line": 820, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38900c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25478, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38900a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25480, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25480, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3890088", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25480, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25480, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x388f320", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25478, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25478, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3890070", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25483, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x388f340", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25483, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25483, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 7\"" + } + ] + } + ] + }, + { + "id": "0x3890ea0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25494, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3890e88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25496, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25496, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3890e68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25496, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25496, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38900f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25494, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25494, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3890e50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25499, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3890118", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25499, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25499, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"7\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3890f60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25512, + "line": 821, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25525, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3890f30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25519, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25525, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57c50", + "kind": "EnumConstantDecl", + "name": "DAC_7", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3892be0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25536, + "line": 822, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25587, + "line": 823, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3892b48", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25540, + "line": 822, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3891d30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25540, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3891d18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25542, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25542, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3891cf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25542, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25542, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3890f90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25540, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25540, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3891ce0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25545, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3890fb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25545, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25545, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 8\"" + } + ] + } + ] + }, + { + "id": "0x3892b10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25556, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3892af8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25558, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25558, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3892ad8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25558, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25558, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3891d68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25556, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25556, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3892ac0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25561, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3891d88", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25561, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25561, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"8\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3892bd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25574, + "line": 823, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25587, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3892ba0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25581, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25587, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ca0", + "kind": "EnumConstantDecl", + "name": "DAC_8", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3894850", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25598, + "line": 824, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25649, + "line": 825, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38947b8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25602, + "line": 824, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38939a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3893988", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3893968", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3892c00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25602, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3893950", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25607, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3892c20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25607, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 25607, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"dac 9\"" + } + ] + } + ] + }, + { + "id": "0x3894780", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25618, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3894768", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25620, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25620, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3894748", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25620, + "col": 27, + "tokLen": 2 + }, + "end": { + "offset": 25620, + "col": 27, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38939d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25618, + "col": 25, + "tokLen": 1 + }, + "end": { + "offset": 25618, + "col": 25, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3894730", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25623, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38939f8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25623, + "col": 30, + "tokLen": 3 + }, + "end": { + "offset": 25623, + "col": 30, + "tokLen": 3 + } + }, + "type": { + "qualType": "const char[2]" + }, + "valueCategory": "lvalue", + "value": "\"9\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3894840", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25636, + "line": 825, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25649, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x3894810", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25643, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25649, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57cf0", + "kind": "EnumConstantDecl", + "name": "DAC_9", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38964e0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25660, + "line": 826, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25713, + "line": 827, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3896448", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25664, + "line": 826, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3895630", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25664, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3895618", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25666, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25666, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38955f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25666, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25666, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3894870", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25664, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25664, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38955e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25669, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3894890", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25669, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25669, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 10\"" + } + ] + } + ] + }, + { + "id": "0x3896410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25681, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38963f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25683, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25683, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38963d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25683, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25683, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3895668", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25681, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25681, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38963c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25686, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3895688", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25686, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25686, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"10\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38964d0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25700, + "line": 827, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25713, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38964a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25707, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25713, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57d40", + "kind": "EnumConstantDecl", + "name": "DAC_10", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3898150", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25725, + "line": 828, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25778, + "line": 829, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38980b8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25729, + "line": 828, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38972a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25729, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3897288", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25731, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25731, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3897268", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25731, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25731, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3896500", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25729, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25729, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3897250", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25734, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3896520", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25734, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25734, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 11\"" + } + ] + } + ] + }, + { + "id": "0x3898080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25746, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3898068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25748, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25748, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3898048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25748, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25748, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38972d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25746, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25746, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3898030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25751, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38972f8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25751, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25751, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"11\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3898140", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25765, + "line": 829, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25778, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3898110", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25772, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25778, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57d90", + "kind": "EnumConstantDecl", + "name": "DAC_11", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x3899dc0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25790, + "line": 830, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25843, + "line": 831, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3899d28", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25794, + "line": 830, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x3898f10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3898ef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25796, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25796, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3898ed8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25796, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25796, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3898170", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25794, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25794, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3898ec0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25799, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3898190", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25799, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25799, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 12\"" + } + ] + } + ] + }, + { + "id": "0x3899cf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25811, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x3899cd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25813, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25813, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x3899cb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25813, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25813, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3898f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25811, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25811, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x3899ca0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25816, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3898f68", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25816, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25816, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"12\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x3899db0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25830, + "line": 831, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25843, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x3899d80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25837, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25843, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57de0", + "kind": "EnumConstantDecl", + "name": "DAC_12", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389ba30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25855, + "line": 832, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25908, + "line": 833, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389b998", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25859, + "line": 832, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389ab80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25859, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389ab68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25861, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25861, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389ab48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25861, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25861, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x3899de0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25859, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25859, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389ab30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25864, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x3899e00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25864, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25864, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 13\"" + } + ] + } + ] + }, + { + "id": "0x389b960", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25876, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389b948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25878, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25878, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389b928", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25878, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25878, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389abb8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25876, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25876, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389b910", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25881, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389abd8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25881, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25881, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"13\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389ba20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25895, + "line": 833, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25908, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389b9f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25902, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25908, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57e30", + "kind": "EnumConstantDecl", + "name": "DAC_13", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389d6a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25920, + "line": 834, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 25973, + "line": 835, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389d608", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25924, + "line": 834, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389c7f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389c7d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25926, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25926, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389c7b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25926, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25926, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389ba50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25924, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389c7a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25929, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389ba70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25929, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25929, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 14\"" + } + ] + } + ] + }, + { + "id": "0x389d5d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25941, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389d5b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25943, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25943, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389d598", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25943, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 25943, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389c828", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25941, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 25941, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389d580", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25946, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389c848", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25946, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 25946, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"14\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389d690", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 25960, + "line": 835, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 25973, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389d660", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25967, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 25973, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57e80", + "kind": "EnumConstantDecl", + "name": "DAC_14", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x389f310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 25985, + "line": 836, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26038, + "line": 837, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389f278", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 25989, + "line": 836, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x389e460", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 25989, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389e448", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25991, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25991, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389e428", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25991, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 25991, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389d6c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 25989, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 25989, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389e410", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 25994, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389d6e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 25994, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 25994, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 15\"" + } + ] + } + ] + }, + { + "id": "0x389f240", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26006, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x389f228", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26008, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26008, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x389f208", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26008, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26008, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389e498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26006, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26006, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x389f1f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26011, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389e4b8", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26011, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26011, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"15\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x389f300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26025, + "line": 837, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26038, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x389f2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26032, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26038, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57ed0", + "kind": "EnumConstantDecl", + "name": "DAC_15", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a0f80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26050, + "line": 838, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26103, + "line": 839, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a0ee8", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 26054, + "line": 838, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38a00d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26054, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a00b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26056, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26056, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a0098", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26056, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26056, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x389f330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26054, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26054, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a0080", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26059, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x389f350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26059, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26059, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 16\"" + } + ] + } + ] + }, + { + "id": "0x38a0eb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26071, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a0e98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26073, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26073, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a0e78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26073, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26073, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a0108", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26071, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26071, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a0e60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26076, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a0128", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26076, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26076, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"16\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38a0f70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26090, + "line": 839, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26103, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a0f40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26097, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26103, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57f20", + "kind": "EnumConstantDecl", + "name": "DAC_16", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a2bf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26115, + "line": 840, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26168, + "line": 841, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a2b58", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 26119, + "line": 840, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "||", + "inner": [ + { + "id": "0x38a1d40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26119, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a1d28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26121, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26121, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a1d08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26121, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26121, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a0fa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26119, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26119, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a1cf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26124, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a0fc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26124, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26124, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"dac 17\"" + } + ] + } + ] + }, + { + "id": "0x38a2b20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26136, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a2b08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26138, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26138, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a2ae8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26138, + "col": 28, + "tokLen": 2 + }, + "end": { + "offset": 26138, + "col": 28, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a1d78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26136, + "col": 26, + "tokLen": 1 + }, + "end": { + "offset": 26136, + "col": 26, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a2ad0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26141, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a1d98", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26141, + "col": 31, + "tokLen": 4 + }, + "end": { + "offset": 26141, + "col": 31, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"17\"" + } + ] + } + ] + } + ] + }, + { + "id": "0x38a2be0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26155, + "line": 841, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26168, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a2bb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26162, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26168, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57f70", + "kind": "EnumConstantDecl", + "name": "DAC_17", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a3a60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26180, + "line": 842, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26218, + "line": 843, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a39b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26184, + "line": 842, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a3998", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26186, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26186, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a3978", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26186, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26186, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a2c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26184, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26184, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a3960", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26189, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a2c30", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26189, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26189, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vsvp\"" + } + ] + } + ] + }, + { + "id": "0x38a3a50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26205, + "line": 843, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26218, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a3a20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26212, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26218, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f57fc0", + "kind": "EnumConstantDecl", + "name": "VSVP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a48d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26228, + "line": 844, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26267, + "line": 845, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38a4820", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26232, + "line": 844, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a4808", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26234, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26234, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a47e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26234, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26234, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a3a80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26232, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26232, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a47d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26237, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a3aa0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26237, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 26237, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vtrim\"" + } + ] + } + ] + }, + { + "id": "0x38a48c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26254, + "line": 845, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26267, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38a4890", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26261, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26267, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58010", + "kind": "EnumConstantDecl", + "name": "VTRIM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a5760", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26278, + "line": 846, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26320, + "line": 847, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a56b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26282, + "line": 846, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a5698", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26284, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26284, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a5678", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26284, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26284, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a48f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26282, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26282, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a5660", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26287, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a4910", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26287, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26287, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vrpreamp\"" + } + ] + } + ] + }, + { + "id": "0x38a5750", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26307, + "line": 847, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26320, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a5720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26314, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26320, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58060", + "kind": "EnumConstantDecl", + "name": "VRPREAMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a65d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26334, + "line": 848, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26376, + "line": 849, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a6520", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26338, + "line": 848, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a6508", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26340, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26340, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a64e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26340, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26340, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a5780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26338, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26338, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a64d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26343, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a57a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26343, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26343, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vrshaper\"" + } + ] + } + ] + }, + { + "id": "0x38a65c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26363, + "line": 849, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26376, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38a6590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26370, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26376, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f580b0", + "kind": "EnumConstantDecl", + "name": "VRSHAPER", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a7440", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26390, + "line": 850, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26428, + "line": 851, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a7390", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26394, + "line": 850, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a7378", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26396, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26396, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a7358", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26396, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26396, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a65f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26394, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26394, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a7340", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26399, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a6610", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26399, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26399, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vsvn\"" + } + ] + } + ] + }, + { + "id": "0x38a7430", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26415, + "line": 851, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26428, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38a7400", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26422, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26428, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58100", + "kind": "EnumConstantDecl", + "name": "VSVN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a82b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26438, + "line": 852, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26478, + "line": 853, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a8200", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26442, + "line": 852, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a81e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26444, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26444, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a81c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26444, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26444, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a7460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26442, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26442, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a81b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26447, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a7480", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26447, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26447, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vtgstv\"" + } + ] + } + ] + }, + { + "id": "0x38a82a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26465, + "line": 853, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26478, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38a8270", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26472, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26478, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58150", + "kind": "EnumConstantDecl", + "name": "VTGSTV", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a9120", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26490, + "line": 854, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26531, + "line": 855, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9070", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26494, + "line": 854, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a9058", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26496, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26496, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a9038", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26496, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26496, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a82d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26494, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26494, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a9020", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26499, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a82f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26499, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26499, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_ll\"" + } + ] + } + ] + }, + { + "id": "0x38a9110", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26518, + "line": 855, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26531, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a90e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26525, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26531, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f581a0", + "kind": "EnumConstantDecl", + "name": "VCMP_LL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38a9f90", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26544, + "line": 856, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26585, + "line": 857, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9ee0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26548, + "line": 856, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38a9ec8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26550, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26550, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38a9ea8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26550, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26550, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a9140", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26548, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26548, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38a9e90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26553, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a9160", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26553, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26553, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_lr\"" + } + ] + } + ] + }, + { + "id": "0x38a9f80", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26572, + "line": 857, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26585, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38a9f50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26579, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26585, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f581f0", + "kind": "EnumConstantDecl", + "name": "VCMP_LR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38aae00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26598, + "line": 858, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26636, + "line": 859, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38aad50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26602, + "line": 858, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38aad38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38aad18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26604, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26604, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38a9fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26602, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26602, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38aad00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26607, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38a9fd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26607, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 26607, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vcal\"" + } + ] + } + ] + }, + { + "id": "0x38aadf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26623, + "line": 859, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26636, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38aadc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26630, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26636, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58240", + "kind": "EnumConstantDecl", + "name": "VCAL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38abc70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26646, + "line": 860, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26687, + "line": 861, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38abbc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26650, + "line": 860, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38abba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26652, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26652, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38abb88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26652, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26652, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38aae20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26650, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26650, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38abb70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26655, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38aae40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26655, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26655, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_rl\"" + } + ] + } + ] + }, + { + "id": "0x38abc60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26674, + "line": 861, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26687, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38abc30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26681, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26687, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58290", + "kind": "EnumConstantDecl", + "name": "VCMP_RL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38acae0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26700, + "line": 862, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26740, + "line": 863, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38aca30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26704, + "line": 862, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38aca18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26706, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26706, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ac9f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26706, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26706, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38abc90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26704, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26704, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ac9e0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26709, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38abcb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26709, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26709, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"rxb_rb\"" + } + ] + } + ] + }, + { + "id": "0x38acad0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26727, + "line": 863, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26740, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38acaa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26734, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26740, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f582e0", + "kind": "EnumConstantDecl", + "name": "RXB_RB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ad950", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26752, + "line": 864, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26792, + "line": 865, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38ad8a0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26756, + "line": 864, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ad888", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26758, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26758, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ad868", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26758, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26758, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38acb00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26756, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26756, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ad850", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26761, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38acb20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26761, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 26761, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"rxb_lb\"" + } + ] + } + ] + }, + { + "id": "0x38ad940", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26779, + "line": 865, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26792, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38ad910", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26786, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26792, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58330", + "kind": "EnumConstantDecl", + "name": "RXB_LB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ae7c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26804, + "line": 866, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26845, + "line": 867, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ae710", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26808, + "line": 866, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ae6f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26810, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26810, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ae6d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26810, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26810, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ad970", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26808, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26808, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ae6c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26813, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ad990", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26813, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 26813, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vcmp_rr\"" + } + ] + } + ] + }, + { + "id": "0x38ae7b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26832, + "line": 867, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26845, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ae780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26839, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26845, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58380", + "kind": "EnumConstantDecl", + "name": "VCMP_RR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38af630", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26858, + "line": 868, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26895, + "line": 869, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38af580", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26862, + "line": 868, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38af568", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26864, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26864, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38af548", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26864, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26864, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ae7e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26862, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26862, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38af530", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26867, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ae800", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26867, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26867, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"vcp\"" + } + ] + } + ] + }, + { + "id": "0x38af620", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26882, + "line": 869, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26895, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38af5f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26889, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26895, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f583d0", + "kind": "EnumConstantDecl", + "name": "VCP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b04a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26904, + "line": 870, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26941, + "line": 871, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38b03f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26908, + "line": 870, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b03d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26910, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26910, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b03b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26910, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26910, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38af650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26908, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26908, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b03a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26913, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38af670", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26913, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 26913, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"vcn\"" + } + ] + } + ] + }, + { + "id": "0x38b0490", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26928, + "line": 871, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26941, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38b0460", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26935, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26941, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58420", + "kind": "EnumConstantDecl", + "name": "VCN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b1310", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 26950, + "line": 872, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 26992, + "line": 873, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b1260", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 26954, + "line": 872, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b1248", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26956, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26956, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b1228", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26956, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 26956, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b04c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26954, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 26954, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b1210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 26959, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b04e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 26959, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 26959, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vishaper\"" + } + ] + } + ] + }, + { + "id": "0x38b1300", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 26979, + "line": 873, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 26992, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b12d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 26986, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 26992, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58470", + "kind": "EnumConstantDecl", + "name": "VISHAPER", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b2190", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27006, + "line": 874, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27050, + "line": 875, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38b20e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27010, + "line": 874, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b20c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27012, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27012, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b20a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27012, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27012, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b1330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27010, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27010, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b2090", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27015, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b1350", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27015, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27015, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vthreshold\"" + } + ] + } + ] + }, + { + "id": "0x38b2180", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27037, + "line": 875, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27050, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38b2150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27044, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27050, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f584c0", + "kind": "EnumConstantDecl", + "name": "VTHRESHOLD", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b3000", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27066, + "line": 876, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27107, + "line": 877, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b2f50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27070, + "line": 876, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b2f38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b2f18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b21b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27070, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27070, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b2f00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27075, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b21d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27075, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27075, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vref_ds\"" + } + ] + } + ] + }, + { + "id": "0x38b2ff0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27094, + "line": 877, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27107, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b2fc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27101, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27107, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58560", + "kind": "EnumConstantDecl", + "name": "VREF_DS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b3e80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27120, + "line": 878, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27163, + "line": 879, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b3dd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27124, + "line": 878, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b3db8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27126, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27126, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b3d98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27126, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27126, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b3020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27124, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27124, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b3d80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27129, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b3040", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27129, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27129, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcascn_pb\"" + } + ] + } + ] + }, + { + "id": "0x38b3e70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27150, + "line": 879, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27163, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b3e40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27157, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27163, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f585b0", + "kind": "EnumConstantDecl", + "name": "VCASCN_PB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b4d00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27178, + "line": 880, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27221, + "line": 881, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b4c50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27182, + "line": 880, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b4c38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27184, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27184, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b4c18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27184, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27184, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b3ea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27182, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27182, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b4c00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27187, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b3ec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27187, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27187, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcascp_pb\"" + } + ] + } + ] + }, + { + "id": "0x38b4cf0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27208, + "line": 881, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27221, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b4cc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27215, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27221, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58600", + "kind": "EnumConstantDecl", + "name": "VCASCP_PB", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b5b90", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27236, + "line": 882, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27277, + "line": 883, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b5ae0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27240, + "line": 882, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b5ac8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27242, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27242, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b5aa8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27242, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27242, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b4d20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27240, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27240, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b5a90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27245, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b4d40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27245, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27245, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vout_cm\"" + } + ] + } + ] + }, + { + "id": "0x38b5b80", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27264, + "line": 883, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27277, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38b5b50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27271, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27277, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58650", + "kind": "EnumConstantDecl", + "name": "VOUT_CM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b6a10", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27290, + "line": 884, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27333, + "line": 885, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b6960", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27294, + "line": 884, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b6948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27296, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27296, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b6928", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27296, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27296, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b5bb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27294, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27294, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b6910", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27299, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b5bd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27299, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27299, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcasc_out\"" + } + ] + } + ] + }, + { + "id": "0x38b6a00", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27320, + "line": 885, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27333, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b69d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27327, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27333, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f586a0", + "kind": "EnumConstantDecl", + "name": "VCASC_OUT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b7880", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27348, + "line": 886, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27388, + "line": 887, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38b77d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27352, + "line": 886, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b77b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27354, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27354, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b7798", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27354, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27354, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b6a30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27352, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27352, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b7780", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27357, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b6a50", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27357, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 27357, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vin_cm\"" + } + ] + } + ] + }, + { + "id": "0x38b7870", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27375, + "line": 887, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27388, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38b7840", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27382, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27388, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f586f0", + "kind": "EnumConstantDecl", + "name": "VIN_CM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b8700", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27400, + "line": 888, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27443, + "line": 889, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b8650", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27404, + "line": 888, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b8638", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b8618", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27406, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27406, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b78a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27404, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27404, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b8600", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27409, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b78c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27409, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27409, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vref_comp\"" + } + ] + } + ] + }, + { + "id": "0x38b86f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27430, + "line": 889, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27443, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38b86c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27437, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27443, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58740", + "kind": "EnumConstantDecl", + "name": "VREF_COMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38b9580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27458, + "line": 890, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27501, + "line": 891, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b94d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27462, + "line": 890, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38b94b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27464, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27464, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38b9498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27464, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27464, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b8720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27462, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27462, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38b9480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27467, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b8740", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27467, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27467, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"ib_test_c\"" + } + ] + } + ] + }, + { + "id": "0x38b9570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27488, + "line": 891, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27501, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38b9540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27495, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27501, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58790", + "kind": "EnumConstantDecl", + "name": "IB_TESTC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ba3f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27515, + "line": 892, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27556, + "line": 893, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ba340", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27519, + "line": 892, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ba328", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27521, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27521, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ba308", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27521, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27521, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38b95a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27519, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27519, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ba2f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27524, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38b95c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27524, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27524, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp\"" + } + ] + } + ] + }, + { + "id": "0x38ba3e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27543, + "line": 893, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27556, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38ba3b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27550, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27556, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f587e0", + "kind": "EnumConstantDecl", + "name": "VB_COMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bb260", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27569, + "line": 894, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27611, + "line": 895, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38bb1b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27573, + "line": 894, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bb198", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27575, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27575, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bb178", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27575, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27575, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ba410", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27573, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27573, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bb160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27578, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ba430", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27578, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 27578, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vdd_prot\"" + } + ] + } + ] + }, + { + "id": "0x38bb250", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27598, + "line": 895, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27611, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38bb220", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27605, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27611, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58830", + "kind": "EnumConstantDecl", + "name": "VDD_PROT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bc0d0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27625, + "line": 896, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27666, + "line": 897, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38bc020", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27629, + "line": 896, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bc008", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27631, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27631, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bbfe8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27631, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27631, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bb280", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27629, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27629, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bbfd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27634, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bb2a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27634, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 27634, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"vin_com\"" + } + ] + } + ] + }, + { + "id": "0x38bc0c0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27653, + "line": 897, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27666, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38bc090", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27660, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27666, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58880", + "kind": "EnumConstantDecl", + "name": "VIN_COM", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bcf50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27679, + "line": 898, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27723, + "line": 899, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bcea0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27683, + "line": 898, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bce88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27685, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27685, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bce68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27685, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27685, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bc0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27683, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27683, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bce50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27688, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bc110", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27688, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27688, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_prech\"" + } + ] + } + ] + }, + { + "id": "0x38bcf40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27710, + "line": 899, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27723, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bcf10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27717, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27723, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f588d0", + "kind": "EnumConstantDecl", + "name": "VREF_PRECH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bddd0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27739, + "line": 900, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27782, + "line": 901, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38bdd20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27743, + "line": 900, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bdd08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27745, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27745, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bdce8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27745, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27745, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bcf70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27743, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27743, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bdcd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27748, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bcf90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27748, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 27748, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vb_pixbuf\"" + } + ] + } + ] + }, + { + "id": "0x38bddc0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27769, + "line": 901, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27782, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38bdd90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27776, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27782, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58920", + "kind": "EnumConstantDecl", + "name": "VB_PIXBUF", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bec40", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27797, + "line": 902, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27836, + "line": 903, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38beb90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27801, + "line": 902, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38beb78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27803, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27803, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38beb58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27803, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27803, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bddf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27801, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27801, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38beb40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27806, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bde10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27806, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 27806, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vb_ds\"" + } + ] + } + ] + }, + { + "id": "0x38bec30", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27823, + "line": 903, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27836, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38bec00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27830, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27836, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58970", + "kind": "EnumConstantDecl", + "name": "VB_DS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38bfac0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27847, + "line": 904, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27891, + "line": 905, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bfa10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27851, + "line": 904, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38bf9f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27853, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27853, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38bf9d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27853, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27853, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bec60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27851, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27851, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38bf9c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27856, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bec80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27856, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27856, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_h_adc\"" + } + ] + } + ] + }, + { + "id": "0x38bfab0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27878, + "line": 905, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27891, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38bfa80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27885, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27891, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f589c0", + "kind": "EnumConstantDecl", + "name": "VREF_H_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c0940", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27907, + "line": 906, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 27951, + "line": 907, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c0890", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27911, + "line": 906, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c0878", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c0858", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27913, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27913, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38bfae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27911, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27911, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c0840", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27916, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38bfb00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27916, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 27916, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp_fe\"" + } + ] + } + ] + }, + { + "id": "0x38c0930", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27938, + "line": 907, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 27951, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c0900", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27945, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 27951, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58a10", + "kind": "EnumConstantDecl", + "name": "VB_COMP_FE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c17c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 27967, + "line": 908, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28012, + "line": 909, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c1710", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 27971, + "line": 908, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c16f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27973, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27973, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c16d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27973, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 27973, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c0960", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 27971, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 27971, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c16c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 27976, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c0980", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 27976, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 27976, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"vb_comp_adc\"" + } + ] + } + ] + }, + { + "id": "0x38c17b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 27999, + "line": 909, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28012, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c1780", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28006, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28012, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58a60", + "kind": "EnumConstantDecl", + "name": "VB_COMP_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c2630", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28029, + "line": 910, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28071, + "line": 911, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c2580", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28033, + "line": 910, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c2568", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28035, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28035, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c2548", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28035, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28035, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c17e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28033, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28033, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c2530", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28038, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c1800", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28038, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28038, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_cds\"" + } + ] + } + ] + }, + { + "id": "0x38c2620", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28058, + "line": 911, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28071, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c25f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28065, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28071, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ab0", + "kind": "EnumConstantDecl", + "name": "VCOM_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c34b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28085, + "line": 912, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28130, + "line": 913, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c3400", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28089, + "line": 912, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c33e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c33c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c2650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28089, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28089, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c33b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28094, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c2670", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28094, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 28094, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"vref_rstore\"" + } + ] + } + ] + }, + { + "id": "0x38c34a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28117, + "line": 913, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28130, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x38c3470", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28124, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28130, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58b00", + "kind": "EnumConstantDecl", + "name": "VREF_RSTORE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c4330", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28147, + "line": 914, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28191, + "line": 915, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c4280", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28151, + "line": 914, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c4268", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c4248", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28153, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28153, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c34d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28151, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28151, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c4230", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28156, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c34f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28156, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28156, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vb_opa_1st\"" + } + ] + } + ] + }, + { + "id": "0x38c4320", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28178, + "line": 915, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28191, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c42f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28185, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28191, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58b50", + "kind": "EnumConstantDecl", + "name": "VB_OPA_1ST", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c51c8", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28207, + "line": 916, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28253, + "line": 917, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x38c5100", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28211, + "line": 916, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c50e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28213, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28213, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c50c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28213, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28213, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c4350", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28211, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28211, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c50b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28216, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c4370", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28216, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 28216, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"vref_comp_fe\"" + } + ] + } + ] + }, + { + "id": "0x38c51b8", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28240, + "line": 917, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28253, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x38c5188", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28247, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28253, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ba0", + "kind": "EnumConstantDecl", + "name": "VREF_COMP_FE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c6040", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28271, + "line": 918, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28314, + "line": 919, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c5f90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28275, + "line": 918, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c5f78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28277, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28277, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c5f58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28277, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28277, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c51e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28275, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28275, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c5f40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28280, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c5208", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28280, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28280, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_adc1\"" + } + ] + } + ] + }, + { + "id": "0x38c6030", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28301, + "line": 919, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28314, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c6000", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28308, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28314, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58bf0", + "kind": "EnumConstantDecl", + "name": "VCOM_ADC1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c6ec0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28329, + "line": 920, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28373, + "line": 921, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c6e10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28333, + "line": 920, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c6df8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28335, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28335, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c6dd8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28335, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28335, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c6060", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28333, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28333, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c6dc0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28338, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c6080", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28338, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28338, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vref_l_adc\"" + } + ] + } + ] + }, + { + "id": "0x38c6eb0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28360, + "line": 921, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28373, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38c6e80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28367, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28373, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58c40", + "kind": "EnumConstantDecl", + "name": "VREF_L_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c7d30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28389, + "line": 922, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28431, + "line": 923, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c7c80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28393, + "line": 922, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c7c68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28395, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28395, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c7c48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28395, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28395, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c6ee0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28393, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28393, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c7c30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28398, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c6f00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28398, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 28398, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"vref_cds\"" + } + ] + } + ] + }, + { + "id": "0x38c7d20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28418, + "line": 923, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28431, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38c7cf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28425, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28431, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58c90", + "kind": "EnumConstantDecl", + "name": "VREF_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c8ba0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28445, + "line": 924, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28484, + "line": 925, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38c8af0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28449, + "line": 924, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c8ad8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28451, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28451, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c8ab8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28451, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28451, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c7d50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28449, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28449, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c8aa0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28454, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c7d70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28454, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28454, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vb_cs\"" + } + ] + } + ] + }, + { + "id": "0x38c8b90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28471, + "line": 925, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28484, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38c8b60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28478, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28484, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ce0", + "kind": "EnumConstantDecl", + "name": "VB_CS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38c9a20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28495, + "line": 926, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28538, + "line": 927, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c9970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28499, + "line": 926, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38c9958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28501, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28501, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38c9938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28501, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28501, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c8bc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28499, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28499, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38c9920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28504, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c8be0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28504, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28504, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vb_opa_fd\"" + } + ] + } + ] + }, + { + "id": "0x38c9a10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28525, + "line": 927, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28538, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38c99e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28532, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28538, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58d30", + "kind": "EnumConstantDecl", + "name": "VB_OPA_FD", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ca8a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28553, + "line": 928, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28596, + "line": 929, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ca7f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28557, + "line": 928, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ca7d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28559, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28559, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ca7b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28559, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28559, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38c9a40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28557, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28557, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ca7a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28562, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38c9a60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28562, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28562, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcom_adc2\"" + } + ] + } + ] + }, + { + "id": "0x38ca890", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28583, + "line": 929, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28596, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ca860", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28590, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28596, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58d80", + "kind": "EnumConstantDecl", + "name": "VCOM_ADC2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cb710", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28611, + "line": 930, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28651, + "line": 931, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38cb660", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28615, + "line": 930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cb648", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28617, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28617, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cb628", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28617, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28617, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ca8c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28615, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28615, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cb610", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28620, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ca8e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28620, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 28620, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcassh\"" + } + ] + } + ] + }, + { + "id": "0x38cb700", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28638, + "line": 931, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28651, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38cb6d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28645, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28651, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58dd0", + "kind": "EnumConstantDecl", + "name": "VCASSH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cc580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28663, + "line": 932, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28701, + "line": 933, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cc4d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28667, + "line": 932, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cc4b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28669, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28669, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cc498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28669, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28669, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cb730", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28667, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28667, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cc480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28672, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cb750", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28672, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28672, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth2\"" + } + ] + } + ] + }, + { + "id": "0x38cc570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28688, + "line": 933, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28701, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cc540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28695, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28701, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58e20", + "kind": "EnumConstantDecl", + "name": "VTH2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cd400", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28711, + "line": 934, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28755, + "line": 935, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38cd350", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28715, + "line": 934, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cd338", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28717, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28717, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cd318", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28717, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28717, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cc5a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28715, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28715, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cd300", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28720, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cc5c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28720, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 28720, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vrshaper_n\"" + } + ] + } + ] + }, + { + "id": "0x38cd3f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28742, + "line": 935, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28755, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x38cd3c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28749, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28755, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58e70", + "kind": "EnumConstantDecl", + "name": "VRSHAPER_N", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38ce280", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28771, + "line": 936, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28814, + "line": 937, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ce1d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28775, + "line": 936, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38ce1b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28777, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28777, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38ce198", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28777, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28777, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cd420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28775, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28775, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ce180", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28780, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cd440", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28780, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 28780, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vipre_out\"" + } + ] + } + ] + }, + { + "id": "0x38ce270", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28801, + "line": 937, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28814, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x38ce240", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28808, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28814, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58ec0", + "kind": "EnumConstantDecl", + "name": "VIPRE_OUT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cf0f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28829, + "line": 938, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28867, + "line": 939, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cf040", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28833, + "line": 938, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cf028", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28835, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28835, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cf008", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28835, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28835, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38ce2a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28833, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28833, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38ceff0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28838, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38ce2c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28838, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28838, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth3\"" + } + ] + } + ] + }, + { + "id": "0x38cf0e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28854, + "line": 939, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28867, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cf0b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28861, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28867, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58f10", + "kind": "EnumConstantDecl", + "name": "VTH3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38cff60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28877, + "line": 940, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28915, + "line": 941, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cfeb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28881, + "line": 940, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38cfe98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28883, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28883, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38cfe78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28883, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28883, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cf110", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28881, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28881, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38cfe60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28886, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cf130", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28886, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28886, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vth1\"" + } + ] + } + ] + }, + { + "id": "0x38cff50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28902, + "line": 941, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28915, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38cff20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28909, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28915, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58f60", + "kind": "EnumConstantDecl", + "name": "VTH1", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d0dd0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28925, + "line": 942, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 28964, + "line": 943, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d0d20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28929, + "line": 942, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d0d08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28931, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28931, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d0ce8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28931, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28931, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38cff80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28929, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28929, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d0cd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28934, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38cffa0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28934, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 28934, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vicin\"" + } + ] + } + ] + }, + { + "id": "0x38d0dc0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 28951, + "line": 943, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 28964, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d0d90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28958, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 28964, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58fb0", + "kind": "EnumConstantDecl", + "name": "VICIN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d1c40", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 28975, + "line": 944, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29013, + "line": 945, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d1b90", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 28979, + "line": 944, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d1b78", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28981, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28981, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d1b58", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28981, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 28981, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d0df0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 28979, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 28979, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d1b40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 28984, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d0e10", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 28984, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 28984, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"vcas\"" + } + ] + } + ] + }, + { + "id": "0x38d1c30", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29000, + "line": 945, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29013, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d1c00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29007, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29013, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59000", + "kind": "EnumConstantDecl", + "name": "VCAS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d2ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29023, + "line": 946, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29063, + "line": 947, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d2a00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29027, + "line": 946, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d29e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29029, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29029, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d29c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29029, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29029, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d1c60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29027, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29027, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d29b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29032, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d1c80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29032, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29032, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcal_n\"" + } + ] + } + ] + }, + { + "id": "0x38d2aa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29050, + "line": 947, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29063, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d2a70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29057, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29063, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59050", + "kind": "EnumConstantDecl", + "name": "VCAL_N", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d3920", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29075, + "line": 948, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29114, + "line": 949, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d3870", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29079, + "line": 948, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d3858", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29081, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29081, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d3838", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29081, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29081, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d2ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29079, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29079, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d3820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29084, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d2af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29084, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29084, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vipre\"" + } + ] + } + ] + }, + { + "id": "0x38d3910", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29101, + "line": 949, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29114, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38d38e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29108, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29114, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f590a0", + "kind": "EnumConstantDecl", + "name": "VIPRE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x38d4790", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29125, + "line": 950, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29165, + "line": 951, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d46e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29129, + "line": 950, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d46c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29131, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29131, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d46a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29131, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29131, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d3940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29129, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29129, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d4690", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29134, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d3960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29134, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29134, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vcal_p\"" + } + ] + } + ] + }, + { + "id": "0x38d4780", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29152, + "line": 951, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29165, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d4750", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29159, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29165, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f590f0", + "kind": "EnumConstantDecl", + "name": "VCAL_P", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646274c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29177, + "line": 952, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29216, + "line": 953, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964627410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29181, + "line": 952, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646273f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29183, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29183, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646273d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29183, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29183, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d47b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29181, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29181, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646273c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29186, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d47d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29186, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 29186, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"vdcsh\"" + } + ] + } + ] + }, + { + "id": "0x7f19646274b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29203, + "line": 953, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29216, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964627480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29210, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29216, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59140", + "kind": "EnumConstantDecl", + "name": "VDCSH", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964628340", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29227, + "line": 954, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29271, + "line": 955, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x7f1964628290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29231, + "line": 954, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964628278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29233, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29233, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964628258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29233, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29233, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646274e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29231, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29231, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964628240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29236, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964627500", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29236, + "col": 14, + "tokLen": 12 + }, + "end": { + "offset": 29236, + "col": 14, + "tokLen": 12 + } + }, + "type": { + "qualType": "const char[11]" + }, + "valueCategory": "lvalue", + "value": "\"vbp_colbuf\"" + } + ] + } + ] + }, + { + "id": "0x7f1964628330", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29258, + "line": 955, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29271, + "col": 22, + "tokLen": 10 + } + }, + "inner": [ + { + "id": "0x7f1964628300", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29265, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29271, + "col": 22, + "tokLen": 10 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59190", + "kind": "EnumConstantDecl", + "name": "VBP_COLBUF", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646291b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29287, + "line": 956, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29327, + "line": 957, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x7f1964629100", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29291, + "line": 956, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646290e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29293, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29293, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646290c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29293, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29293, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964628360", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29291, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29291, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646290b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29296, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964628380", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29296, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 29296, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"vb_sda\"" + } + ] + } + ] + }, + { + "id": "0x7f19646291a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29314, + "line": 957, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29327, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x7f1964629170", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29321, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29327, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f591e0", + "kind": "EnumConstantDecl", + "name": "VB_SDA", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462a030", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29339, + "line": 958, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29382, + "line": 959, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964629f80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29343, + "line": 958, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964629f68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964629f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646291d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29343, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29343, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964629f30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29348, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646291f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29348, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29348, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vcasc_sfp\"" + } + ] + } + ] + }, + { + "id": "0x7f196462a020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29369, + "line": 959, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29382, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964629ff0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29376, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29382, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59230", + "kind": "EnumConstantDecl", + "name": "VCASC_SFP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462aeb0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29397, + "line": 960, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29440, + "line": 961, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462ae00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29401, + "line": 960, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462ade8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29403, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29403, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462adc8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29403, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29403, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462a050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29401, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29401, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462adb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29406, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462a070", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29406, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29406, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"vipre_cds\"" + } + ] + } + ] + }, + { + "id": "0x7f196462aea0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29427, + "line": 961, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29440, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462ae70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29434, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29440, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59280", + "kind": "EnumConstantDecl", + "name": "VIPRE_CDS", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462bd30", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29455, + "line": 962, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29498, + "line": 963, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462bc80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29459, + "line": 962, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462bc68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29461, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29461, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462bc48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29461, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29461, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462aed0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29459, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29459, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462bc30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29464, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462aef0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29464, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29464, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"ibias_sfp\"" + } + ] + } + ] + }, + { + "id": "0x7f196462bd20", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29485, + "line": 963, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29498, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196462bcf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29492, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29498, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f592d0", + "kind": "EnumConstantDecl", + "name": "IBIAS_SFP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462cba0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29513, + "line": 964, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29555, + "line": 965, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462caf0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29517, + "line": 964, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462cad8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29519, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29519, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462cab8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29519, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29519, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462bd50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29517, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29517, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462caa0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29522, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462bd70", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29522, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29522, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"trimbits\"" + } + ] + } + ] + }, + { + "id": "0x7f196462cb90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29542, + "line": 965, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29555, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462cb60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29549, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29555, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59690", + "kind": "EnumConstantDecl", + "name": "TRIMBIT_SCAN", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462da20", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29573, + "line": 966, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29618, + "line": 967, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462d970", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29577, + "line": 966, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462d958", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29579, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29579, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462d938", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29579, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29579, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462cbc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29577, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29577, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462d920", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29582, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462cbe0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29582, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 29582, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"highvoltage\"" + } + ] + } + ] + }, + { + "id": "0x7f196462da10", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29605, + "line": 967, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29618, + "col": 22, + "tokLen": 12 + } + }, + "inner": [ + { + "id": "0x7f196462d9e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29612, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29618, + "col": 22, + "tokLen": 12 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59370", + "kind": "EnumConstantDecl", + "name": "HIGH_VOLTAGE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462e890", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29636, + "line": 968, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29677, + "line": 969, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f196462e7e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29640, + "line": 968, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462e7c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29642, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29642, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462e7a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29642, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29642, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462da40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29640, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29640, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462e790", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29645, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462da60", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29645, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 29645, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"iodelay\"" + } + ] + } + ] + }, + { + "id": "0x7f196462e880", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29664, + "line": 969, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29677, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f196462e850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29671, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29677, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f58510", + "kind": "EnumConstantDecl", + "name": "IO_DELAY", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196462f700", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29691, + "line": 970, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29733, + "line": 971, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196462f650", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29695, + "line": 970, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196462f638", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29697, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29697, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196462f618", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29697, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29697, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462e8b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29695, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29695, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196462f600", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29700, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462e8d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29700, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 29700, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"temp_adc\"" + } + ] + } + ] + }, + { + "id": "0x7f196462f6f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29720, + "line": 971, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29733, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196462f6c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29727, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29733, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f593c0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_ADC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964630580", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29754, + "line": 972, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29797, + "line": 973, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646304d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29758, + "line": 972, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646304b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29760, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29760, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964630498", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29760, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29760, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196462f720", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29758, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29758, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964630480", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29763, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196462f740", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29763, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29763, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpga\"" + } + ] + } + ] + }, + { + "id": "0x7f1964630570", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29784, + "line": 973, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29797, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964630540", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29791, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29797, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59410", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964631400", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29819, + "line": 974, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29865, + "line": 975, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f1964631350", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29823, + "line": 974, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964631338", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29825, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29825, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964631318", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29825, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29825, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646305a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29823, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29823, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964631300", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29828, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646305c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29828, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 29828, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgaext\"" + } + ] + } + ] + }, + { + "id": "0x7f19646313f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29852, + "line": 975, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29865, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f19646313c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29859, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29865, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59460", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGAEXT", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964632280", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29890, + "line": 976, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29933, + "line": 977, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646321d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29894, + "line": 976, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646321b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29896, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29896, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964632198", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29896, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29896, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964631420", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29894, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29894, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964632180", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29899, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964631440", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29899, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29899, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_10ge\"" + } + ] + } + ] + }, + { + "id": "0x7f1964632270", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29920, + "line": 977, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29933, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964632240", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29927, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29933, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f594b0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_10GE", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964633100", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 29955, + "line": 978, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 29998, + "line": 979, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633050", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 29959, + "line": 978, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964633038", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29961, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29961, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964633018", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29961, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 29961, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646322a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29959, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 29959, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964633000", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 29964, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646322c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 29964, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 29964, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_dcdc\"" + } + ] + } + ] + }, + { + "id": "0x7f19646330f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 29985, + "line": 979, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 29998, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f19646330c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 29992, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 29998, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59500", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_DCDC", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964633f80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30020, + "line": 980, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30063, + "line": 981, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633ed0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30024, + "line": 980, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964633eb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30026, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30026, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964633e98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30026, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30026, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964633120", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30024, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30024, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964633e80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30029, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964633140", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30029, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30029, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_sodl\"" + } + ] + } + ] + }, + { + "id": "0x7f1964633f70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30050, + "line": 981, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30063, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964633f40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30057, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30063, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59550", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_SODL", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964634e00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30085, + "line": 982, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30128, + "line": 983, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964634d50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30089, + "line": 982, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964634d38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964634d18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30091, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30091, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964633fa0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30089, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30089, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964634d00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30094, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964633fc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30094, + "col": 14, + "tokLen": 11 + }, + "end": { + "offset": 30094, + "col": 14, + "tokLen": 11 + } + }, + "type": { + "qualType": "const char[10]" + }, + "valueCategory": "lvalue", + "value": "\"temp_sodr\"" + } + ] + } + ] + }, + { + "id": "0x7f1964634df0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30115, + "line": 983, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30128, + "col": 22, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x7f1964634dc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30122, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30128, + "col": 22, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f595a0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_SODR", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964635c80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30150, + "line": 984, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30195, + "line": 985, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964635bd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30154, + "line": 984, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964635bb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30156, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30156, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964635b98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30156, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30156, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964634e20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30154, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30154, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964635b80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30159, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964634e40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30159, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30159, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgafl\"" + } + ] + } + ] + }, + { + "id": "0x7f1964635c70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30182, + "line": 985, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30195, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964635c40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30189, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30195, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f595f0", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA2", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964636b00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30218, + "line": 986, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30263, + "line": 987, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964636a50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30222, + "line": 986, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964636a38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30224, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30224, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964636a18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30224, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30224, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964635ca0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30222, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30222, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964636a00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30227, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964635cc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30227, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30227, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"temp_fpgafr\"" + } + ] + } + ] + }, + { + "id": "0x7f1964636af0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30250, + "line": 987, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30263, + "col": 22, + "tokLen": 17 + } + }, + "inner": [ + { + "id": "0x7f1964636ac0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30257, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30263, + "col": 22, + "tokLen": 17 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f59640", + "kind": "EnumConstantDecl", + "name": "TEMPERATURE_FPGA3", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964637980", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30286, + "line": 988, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30332, + "line": 989, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x7f19646378d0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30290, + "line": 988, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646378b8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30292, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30292, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964637898", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30292, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30292, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964636b20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30290, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30290, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964637880", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30295, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964636b40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30295, + "col": 14, + "tokLen": 14 + }, + "end": { + "offset": 30295, + "col": 14, + "tokLen": 14 + } + }, + "type": { + "qualType": "const char[13]" + }, + "valueCategory": "lvalue", + "value": "\"temp_slowadc\"" + } + ] + } + ] + }, + { + "id": "0x7f1964637970", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30319, + "line": 989, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30332, + "col": 22, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x7f1964637940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30326, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30332, + "col": 22, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::dacIndex" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5a060", + "kind": "EnumConstantDecl", + "name": "SLOW_ADC_TEMP", + "type": { + "qualType": "slsDetectorDefs::dacIndex" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964637f90", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30351, + "line": 990, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f1964637f78", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30351, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f1964637f48", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964637f30", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f1964637f08", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f1964637ee8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964637ee0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964637eb0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30357, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30394, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964637e98", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f1964637e80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f1964637e60", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964637e58", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964637e20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964637e08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30391, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 30391, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964637de8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30391, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 30391, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f1964637dd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30370, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646379b0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30370, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 30370, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char[19]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown dac Index \"" + } + ] + }, + { + "id": "0x7f19646379e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30393, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 30393, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3882940", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x7f1964638418", + "kind": "FunctionDecl", + "loc": { + "offset": 30428, + "file": "ToString.cpp", + "line": 993, + "col": 29, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 30400, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 30788, + "line": 1003, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368bb58", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs9burstModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::burstMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "inner": [ + { + "id": "0x2f5b1f0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "decl": { + "id": "0x2f5b148", + "kind": "EnumDecl", + "name": "burstMode" + } + } + ] + }, + { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "loc": { + "offset": 30456, + "line": 993, + "col": 57, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 30437, + "col": 38, + "tokLen": 5 + }, + "end": { + "offset": 30456, + "col": 57, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f196463c5d8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 30459, + "col": 60, + "tokLen": 1 + }, + "end": { + "offset": 30788, + "line": 1003, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f1964639430", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30465, + "line": 994, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30513, + "line": 995, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f1964639380", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30469, + "line": 994, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964639368", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30471, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30471, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964639348", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30471, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30471, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646385d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30469, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30469, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964639330", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30474, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646385f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30474, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30474, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"burst_internal\"" + } + ] + } + ] + }, + { + "id": "0x7f1964639420", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30500, + "line": 995, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30513, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f19646393f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30507, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30513, + "col": 22, + "tokLen": 14 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b210", + "kind": "EnumConstantDecl", + "name": "BURST_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463a2b0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30533, + "line": 996, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30581, + "line": 997, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f196463a200", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30537, + "line": 996, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463a1e8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30539, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30539, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463a1c8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30539, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30539, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964639450", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30537, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30537, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463a1b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30542, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964639470", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30542, + "col": 14, + "tokLen": 16 + }, + "end": { + "offset": 30542, + "col": 14, + "tokLen": 16 + } + }, + "type": { + "qualType": "const char[15]" + }, + "valueCategory": "lvalue", + "value": "\"burst_external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463a2a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30568, + "line": 997, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30581, + "col": 22, + "tokLen": 14 + } + }, + "inner": [ + { + "id": "0x7f196463a270", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30575, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30581, + "col": 22, + "tokLen": 14 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b260", + "kind": "EnumConstantDecl", + "name": "BURST_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463b130", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30601, + "line": 998, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30646, + "line": 999, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463b080", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30605, + "line": 998, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463b068", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30607, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30607, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463b048", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30607, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30607, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463a2d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30605, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30605, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463b030", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30610, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463a2f0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30610, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30610, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"cw_internal\"" + } + ] + } + ] + }, + { + "id": "0x7f196463b120", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30633, + "line": 999, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30646, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463b0f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30640, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30646, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b2b0", + "kind": "EnumConstantDecl", + "name": "CONTINUOUS_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463bfb0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30671, + "line": 1000, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30716, + "line": 1001, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463bf00", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30675, + "line": 1000, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463bee8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30677, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30677, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463bec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30677, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30677, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463b150", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30675, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30675, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463beb0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30680, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463b170", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30680, + "col": 14, + "tokLen": 13 + }, + "end": { + "offset": 30680, + "col": 14, + "tokLen": 13 + } + }, + "type": { + "qualType": "const char[12]" + }, + "valueCategory": "lvalue", + "value": "\"cw_external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463bfa0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30703, + "line": 1001, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30716, + "col": 22, + "tokLen": 19 + } + }, + "inner": [ + { + "id": "0x7f196463bf70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30710, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30716, + "col": 22, + "tokLen": 19 + } + }, + "type": { + "qualType": "slsDetectorDefs::burstMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b300", + "kind": "EnumConstantDecl", + "name": "CONTINUOUS_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::burstMode" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463c5c0", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30741, + "line": 1002, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f196463c5a8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30741, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f196463c578", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463c560", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f196463c538", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f196463c518", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463c510", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463c4e0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30747, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 30785, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463c4c8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f196463c4b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f196463c490", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463c488", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463c450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463c438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30782, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 30782, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463c418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30782, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 30782, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f196463c400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30760, + "col": 24, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463bfe0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30760, + "col": 24, + "tokLen": 21 + }, + "end": { + "offset": 30760, + "col": 24, + "tokLen": 21 + } + }, + "type": { + "qualType": "const char[20]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown burst mode \"" + } + ] + }, + { + "id": "0x7f196463c010", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30784, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 30784, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964638348", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x7f196463c788", + "kind": "FunctionDecl", + "loc": { + "offset": 30826, + "file": "ToString.cpp", + "line": 1005, + "col": 36, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 30791, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31044, + "line": 1011, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368c078", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs16timingSourceTypeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::timingSourceType (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "inner": [ + { + "id": "0x2f5b470", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "decl": { + "id": "0x2f5b3c8", + "kind": "EnumDecl", + "name": "timingSourceType" + } + } + ] + }, + { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "loc": { + "offset": 30854, + "line": 1005, + "col": 64, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 30835, + "col": 45, + "tokLen": 5 + }, + "end": { + "offset": 30854, + "col": 64, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f196463ec30", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 30857, + "col": 67, + "tokLen": 1 + }, + "end": { + "offset": 31044, + "line": 1011, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f196463d790", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30863, + "line": 1006, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30905, + "line": 1007, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463d6e0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30867, + "line": 1006, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463d6c8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30869, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30869, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463d6a8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30869, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30869, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463c940", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30867, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30867, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463d690", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30872, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463c960", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30872, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30872, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"internal\"" + } + ] + } + ] + }, + { + "id": "0x7f196463d780", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30892, + "line": 1007, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30905, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463d750", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30899, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30905, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b490", + "kind": "EnumConstantDecl", + "name": "TIMING_INTERNAL", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463e600", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 30926, + "line": 1008, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 30968, + "line": 1009, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463e550", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 30930, + "line": 1008, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463e538", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463e518", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30932, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 30932, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463d7b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30930, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 30930, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463e500", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 30935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463d7d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 30935, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 30935, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"external\"" + } + ] + } + ] + }, + { + "id": "0x7f196463e5f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 30955, + "line": 1009, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 30968, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x7f196463e5c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 30962, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 30968, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b4e0", + "kind": "EnumConstantDecl", + "name": "TIMING_EXTERNAL", + "type": { + "qualType": "slsDetectorDefs::timingSourceType" + } + } + } + ] + } + ] + }, + { + "id": "0x7f196463ec18", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 30989, + "line": 1010, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f196463ec00", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 30989, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f196463ebd0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463ebb8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f196463eb90", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f196463eb70", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463eb68", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463eb38", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 30995, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31041, + "col": 57, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f196463eb20", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f196463eb08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f196463eae8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f196463eae0", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f196463eaa8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463ea90", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31038, + "col": 54, + "tokLen": 1 + }, + "end": { + "offset": 31038, + "col": 54, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463ea70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31038, + "col": 54, + "tokLen": 1 + }, + "end": { + "offset": 31038, + "col": 54, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f196463ea58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31008, + "col": 24, + "tokLen": 29 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463e630", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31008, + "col": 24, + "tokLen": 29 + }, + "end": { + "offset": 31008, + "col": 24, + "tokLen": 29 + } + }, + "type": { + "qualType": "const char[28]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown timing source type \"" + } + ] + }, + { + "id": "0x7f196463e668", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31040, + "col": 56, + "tokLen": 1 + }, + "end": { + "offset": 31040, + "col": 56, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463c6b8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x7f196463edd8", + "kind": "FunctionDecl", + "loc": { + "offset": 31077, + "file": "ToString.cpp", + "line": 1013, + "col": 31, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31047, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31487, + "line": 1027, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368c598", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs11M3_GainCapsEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::M3_GainCaps (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "inner": [ + { + "id": "0x2f5b5d0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "decl": { + "id": "0x2f5b530", + "kind": "EnumDecl", + "name": "M3_GainCaps" + } + } + ] + }, + { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "loc": { + "offset": 31105, + "line": 1013, + "col": 59, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31086, + "col": 40, + "tokLen": 5 + }, + "end": { + "offset": 31105, + "col": 59, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x7f1964644c38", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31108, + "col": 62, + "tokLen": 1 + }, + "end": { + "offset": 31487, + "line": 1027, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f196463fde0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31114, + "line": 1014, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31154, + "line": 1015, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196463fd30", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31118, + "line": 1014, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f196463fd18", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31120, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31120, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f196463fcf8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31120, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31120, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463ef90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31118, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31118, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f196463fce0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31123, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463efb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31123, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31123, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"C10pre\"" + } + ] + } + ] + }, + { + "id": "0x7f196463fdd0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31141, + "line": 1015, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31154, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f196463fda0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31148, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31154, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b670", + "kind": "EnumConstantDecl", + "name": "M3_C10pre", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964640c50", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31169, + "line": 1016, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31208, + "line": 1017, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964640ba0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31173, + "line": 1016, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964640b88", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31175, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31175, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964640b68", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31175, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31175, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f196463fe00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31173, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31173, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964640b50", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31178, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f196463fe20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31178, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31178, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C15sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964640c40", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31195, + "line": 1017, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31208, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964640c10", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31202, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31208, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b740", + "kind": "EnumConstantDecl", + "name": "M3_C15sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964641ac0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31222, + "line": 1018, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31261, + "line": 1019, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964641a10", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31226, + "line": 1018, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646419f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31228, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31228, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646419d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31228, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31228, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964640c70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31226, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31226, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646419c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31231, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964640c90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31231, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31231, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C30sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964641ab0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31248, + "line": 1019, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31261, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964641a80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31255, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31261, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b810", + "kind": "EnumConstantDecl", + "name": "M3_C30sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964642930", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31275, + "line": 1020, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31314, + "line": 1021, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f1964642880", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31279, + "line": 1020, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964642868", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31281, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31281, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964642848", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31281, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31281, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964641ae0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31279, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31279, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964642830", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31284, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964641b00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31284, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31284, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"C50sh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964642920", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31301, + "line": 1021, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31314, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x7f19646428f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31308, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31314, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b8e0", + "kind": "EnumConstantDecl", + "name": "M3_C50sh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f19646437a0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31328, + "line": 1022, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31370, + "line": 1023, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x7f19646436f0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31332, + "line": 1022, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f19646436d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31334, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31334, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f19646436b8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31334, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31334, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964642950", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31332, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31332, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f19646436a0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31337, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964642970", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31337, + "col": 14, + "tokLen": 10 + }, + "end": { + "offset": 31337, + "col": 14, + "tokLen": 10 + } + }, + "type": { + "qualType": "const char[9]" + }, + "valueCategory": "lvalue", + "value": "\"C225ACsh\"" + } + ] + } + ] + }, + { + "id": "0x7f1964643790", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31357, + "line": 1023, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31370, + "col": 22, + "tokLen": 11 + } + }, + "inner": [ + { + "id": "0x7f1964643760", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31364, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31370, + "col": 22, + "tokLen": 11 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5b9b0", + "kind": "EnumConstantDecl", + "name": "M3_C225ACsh", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964644610", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31387, + "line": 1024, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31427, + "line": 1025, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f1964644560", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31391, + "line": 1024, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964644548", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31393, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31393, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964644528", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31393, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31393, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f19646437c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31391, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31391, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964644510", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31396, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f19646437e0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31396, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31396, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"C15pre\"" + } + ] + } + ] + }, + { + "id": "0x7f1964644600", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31414, + "line": 1025, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31427, + "col": 22, + "tokLen": 9 + } + }, + "inner": [ + { + "id": "0x7f19646445d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31421, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31427, + "col": 22, + "tokLen": 9 + } + }, + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5ba80", + "kind": "EnumConstantDecl", + "name": "M3_C15pre", + "type": { + "qualType": "slsDetectorDefs::M3_GainCaps" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964644c20", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 31442, + "line": 1026, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x7f1964644c08", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 31442, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x7f1964644bd8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964644bc0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x7f1964644b98", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x7f1964644b78", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964644b70", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964644b40", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31448, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31484, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x7f1964644b28", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x7f1964644b10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x7f1964644af0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x7f1964644ae8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x7f1964644ab0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964644a98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31481, + "col": 44, + "tokLen": 1 + }, + "end": { + "offset": 31481, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964644a78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31481, + "col": 44, + "tokLen": 1 + }, + "end": { + "offset": 31481, + "col": 44, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x7f1964644a60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31461, + "col": 24, + "tokLen": 19 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964644640", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31461, + "col": 24, + "tokLen": 19 + }, + "end": { + "offset": 31461, + "col": 24, + "tokLen": 19 + } + }, + "type": { + "qualType": "const char[18]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown gain cap \"" + } + ] + }, + { + "id": "0x7f1964644670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31483, + "col": 46, + "tokLen": 1 + }, + "end": { + "offset": 31483, + "col": 46, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f196463ed00", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x7f1964644df8", + "kind": "FunctionDecl", + "loc": { + "offset": 31521, + "file": "ToString.cpp", + "line": 1029, + "col": 32, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31490, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 31804, + "line": 1039, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368cab8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs12portPositionEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::portPosition (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "inner": [ + { + "id": "0x2f5bc00", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "decl": { + "id": "0x2f5bb60", + "kind": "EnumDecl", + "name": "portPosition" + } + } + ] + }, + { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "loc": { + "offset": 31549, + "line": 1029, + "col": 60, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31530, + "col": 41, + "tokLen": 5 + }, + "end": { + "offset": 31549, + "col": 60, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38d70f8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31552, + "col": 63, + "tokLen": 1 + }, + "end": { + "offset": 31804, + "line": 1039, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x7f1964645e00", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31558, + "line": 1030, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31596, + "line": 1031, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x7f1964645d50", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31562, + "line": 1030, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964645d38", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31564, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31564, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964645d18", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31564, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31564, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964644fb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31562, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31562, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964645d00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31567, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964644fd0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31567, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 31567, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"left\"" + } + ] + } + ] + }, + { + "id": "0x7f1964645df0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31583, + "line": 1031, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31596, + "col": 22, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x7f1964645dc0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31590, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31596, + "col": 22, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bc20", + "kind": "EnumConstantDecl", + "name": "LEFT", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x7f1964646c70", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31606, + "line": 1032, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31645, + "line": 1033, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964646bc0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31610, + "line": 1032, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x7f1964646ba8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31612, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31612, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x7f1964646b88", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31612, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31612, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964645e20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31610, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31610, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x7f1964646b70", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31615, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964645e40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31615, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 31615, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"right\"" + } + ] + } + ] + }, + { + "id": "0x7f1964646c60", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31632, + "line": 1033, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31645, + "col": 22, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x7f1964646c30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31639, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31645, + "col": 22, + "tokLen": 5 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bc70", + "kind": "EnumConstantDecl", + "name": "RIGHT", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d5c60", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31656, + "line": 1034, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31693, + "line": 1035, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38d5bb0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31660, + "line": 1034, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d5b98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31662, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31662, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d5b78", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31662, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31662, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x7f1964646c90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31660, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31660, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d5b60", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31665, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x7f1964646cb0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31665, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 31665, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"top\"" + } + ] + } + ] + }, + { + "id": "0x38d5c50", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31680, + "line": 1035, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31693, + "col": 22, + "tokLen": 3 + } + }, + "inner": [ + { + "id": "0x38d5c20", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31687, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31693, + "col": 22, + "tokLen": 3 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bcc0", + "kind": "EnumConstantDecl", + "name": "TOP", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d6ad0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31702, + "line": 1036, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31742, + "line": 1037, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d6a20", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31706, + "line": 1036, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d6a08", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31708, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31708, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d69e8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31708, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 31708, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d5c80", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31706, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31706, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38d69d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31711, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d5ca0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31711, + "col": 14, + "tokLen": 8 + }, + "end": { + "offset": 31711, + "col": 14, + "tokLen": 8 + } + }, + "type": { + "qualType": "const char[7]" + }, + "valueCategory": "lvalue", + "value": "\"bottom\"" + } + ] + } + ] + }, + { + "id": "0x38d6ac0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 31729, + "line": 1037, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 31742, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38d6a90", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31736, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 31742, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::portPosition" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bd10", + "kind": "EnumConstantDecl", + "name": "BOTTOM", + "type": { + "qualType": "slsDetectorDefs::portPosition" + } + } + } + ] + } + ] + }, + { + "id": "0x38d70e0", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 31754, + "line": 1038, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38d70c8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 31754, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7098", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d7080", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38d7058", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38d7038", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38d7030", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38d7000", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31760, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 31801, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d6fe8", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38d6fd0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d6fb0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38d6fa8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38d6f70", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d6f58", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31798, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 31798, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d6f38", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31798, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 31798, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38d6f20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31773, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d6b00", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31773, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 31773, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown port position \"" + } + ] + }, + { + "id": "0x38d6b30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31800, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 31800, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x7f1964644d28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38d72a8", + "kind": "FunctionDecl", + "loc": { + "offset": 31844, + "file": "ToString.cpp", + "line": 1041, + "col": 38, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 31807, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32267, + "line": 1052, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368cfd8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs18streamingInterfaceEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::streamingInterface (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "inner": [ + { + "id": "0x2f5bf90", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "decl": { + "id": "0x2f5bef0", + "kind": "EnumDecl", + "name": "streamingInterface" + } + } + ] + }, + { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "loc": { + "offset": 31872, + "line": 1041, + "col": 66, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 31853, + "col": 47, + "tokLen": 5 + }, + "end": { + "offset": 31872, + "col": 66, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38dacc0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 31875, + "col": 69, + "tokLen": 1 + }, + "end": { + "offset": 32267, + "line": 1052, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d7560", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 31881, + "line": 1042, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 31899, + "col": 23, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d74a8", + "kind": "VarDecl", + "loc": { + "offset": 31893, + "col": 17, + "tokLen": 2 + }, + "range": { + "begin": { + "offset": 31881, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "init": "c", + "inner": [ + { + "id": "0x38d7530", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 31898, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::basic_string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38d7510", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31898, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 31898, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + }, + { + "id": "0x38d7ab0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31905, + "line": 1043, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 31972, + "line": 1044, + "col": 30, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38d77c0", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 31909, + "line": 1043, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38d7650", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31919, + "col": 19, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7620", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31911, + "col": 11, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1fe0", + "inner": [ + { + "id": "0x38d7578", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31909, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 31909, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38d7608", + "kind": "CharacterLiteral", + "range": { + "begin": { + "offset": 31916, + "col": 16, + "tokLen": 3 + }, + "end": { + "offset": 31916, + "col": 16, + "tokLen": 3 + } + }, + "type": { + "qualType": "char" + }, + "valueCategory": "prvalue", + "value": 44 + }, + { + "id": "0x38d7698", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38d77a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31924, + "col": 24, + "tokLen": 3 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38d7778", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31924, + "col": 24, + "tokLen": 3 + }, + "end": { + "offset": 31937, + "col": 37, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38d7a08", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31951, + "line": 1044, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31972, + "col": 30, + "tokLen": 1 + } + }, + "type": { + "qualType": "std::basic_string" + }, + "valueCategory": "lvalue", + "inner": [ + { + "id": "0x38d79d8", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31951, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31954, + "col": 12, + "tokLen": 5 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "erase", + "isArrow": false, + "referencedMemberDecl": "0x2c9ba48", + "inner": [ + { + "id": "0x38d77e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31951, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31951, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d7940", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31971, + "col": 29, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38d7910", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31963, + "col": 21, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1fe0", + "inner": [ + { + "id": "0x38d7970", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31960, + "col": 18, + "tokLen": 2 + } + }, + "type": { + "qualType": "const std::basic_string" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d7868", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31960, + "col": 18, + "tokLen": 2 + }, + "end": { + "offset": 31960, + "col": 18, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + } + ] + }, + { + "id": "0x38d78f8", + "kind": "CharacterLiteral", + "range": { + "begin": { + "offset": 31968, + "col": 26, + "tokLen": 3 + }, + "end": { + "offset": 31968, + "col": 26, + "tokLen": 3 + } + }, + "type": { + "qualType": "char" + }, + "valueCategory": "prvalue", + "value": 44 + }, + { + "id": "0x38d7988", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38d7a90", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + } + ] + }, + { + "id": "0x38d8950", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 31979, + "line": 1045, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32038, + "line": 1046, + "col": 42, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d8888", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 31983, + "line": 1045, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d8870", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31986, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 31986, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d8850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31986, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 31986, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d8820", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31983, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31983, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d7ad0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 31983, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 31983, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d8838", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 31989, + "col": 15, + "tokLen": 6 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d7af0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 31989, + "col": 15, + "tokLen": 6 + }, + "end": { + "offset": 31989, + "col": 15, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"none\"" + } + ] + } + ] + }, + { + "id": "0x38d8940", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32005, + "line": 1046, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32038, + "col": 42, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38d8910", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32012, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32038, + "col": 42, + "tokLen": 4 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5bff0", + "kind": "EnumConstantDecl", + "name": "NONE", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38d97f0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32048, + "line": 1047, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32106, + "line": 1048, + "col": 42, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38d9728", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32052, + "line": 1047, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38d9710", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32055, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32055, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38d96f0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32055, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32055, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38d96c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32052, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32052, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d8970", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32052, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32052, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38d96d8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32058, + "col": 15, + "tokLen": 5 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d8990", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32058, + "col": 15, + "tokLen": 5 + }, + "end": { + "offset": 32058, + "col": 15, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"lll\"" + } + ] + } + ] + }, + { + "id": "0x38d97e0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32073, + "line": 1048, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32106, + "col": 42, + "tokLen": 16 + } + }, + "inner": [ + { + "id": "0x38d97b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32080, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32106, + "col": 42, + "tokLen": 16 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c0c0", + "kind": "EnumConstantDecl", + "name": "LOW_LATENCY_LINK", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38da690", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32128, + "line": 1049, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32188, + "line": 1050, + "col": 42, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38da5c8", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32132, + "line": 1049, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38da5b0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32135, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32135, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38da590", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32135, + "col": 12, + "tokLen": 2 + }, + "end": { + "offset": 32135, + "col": 12, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38da560", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32132, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32132, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38d9810", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32132, + "col": 9, + "tokLen": 2 + }, + "end": { + "offset": 32132, + "col": 9, + "tokLen": 2 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d74a8", + "kind": "VarDecl", + "name": "rs", + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "std::string", + "typeAliasDeclId": "0x2a12a80" + } + } + } + ] + }, + { + "id": "0x38da578", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32138, + "col": 15, + "tokLen": 7 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38d9830", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32138, + "col": 15, + "tokLen": 7 + }, + "end": { + "offset": 32138, + "col": 15, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"10gbe\"" + } + ] + } + ] + }, + { + "id": "0x38da680", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32155, + "line": 1050, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32188, + "col": 42, + "tokLen": 13 + } + }, + "inner": [ + { + "id": "0x38da650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32162, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32188, + "col": 42, + "tokLen": 13 + } + }, + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c190", + "kind": "EnumConstantDecl", + "name": "ETHERNET_10GB", + "type": { + "qualType": "slsDetectorDefs::streamingInterface" + } + } + } + ] + } + ] + }, + { + "id": "0x38daca8", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32207, + "line": 1051, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38dac90", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32207, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38dac60", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dac48", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38dac20", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38dac00", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38dabf8", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dabc8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32213, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32264, + "col": 62, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dabb0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38dab98", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38dab78", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38dab70", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dab38", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dab20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32261, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32261, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dab00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32261, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32261, + "col": 59, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38daae8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32226, + "col": 24, + "tokLen": 34 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38da6c0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32226, + "col": 24, + "tokLen": 34 + }, + "end": { + "offset": 32226, + "col": 24, + "tokLen": 34 + } + }, + "type": { + "qualType": "const char[33]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown streamingInterface type \"" + } + ] + }, + { + "id": "0x38da6f8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32263, + "col": 61, + "tokLen": 1 + }, + "end": { + "offset": 32263, + "col": 61, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38d71d8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38dae78", + "kind": "FunctionDecl", + "loc": { + "offset": 32302, + "file": "ToString.cpp", + "line": 1054, + "col": 33, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32270, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32492, + "line": 1060, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368d4f8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs13vetoAlgorithmEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::vetoAlgorithm (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "inner": [ + { + "id": "0x2f5c350", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "decl": { + "id": "0x2f5c2b0", + "kind": "EnumDecl", + "name": "vetoAlgorithm" + } + } + ] + }, + { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "loc": { + "offset": 32330, + "line": 1054, + "col": 61, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32311, + "col": 42, + "tokLen": 5 + }, + "end": { + "offset": 32330, + "col": 61, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38dd318", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 32333, + "col": 64, + "tokLen": 1 + }, + "end": { + "offset": 32492, + "line": 1060, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38dbe80", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32339, + "line": 1055, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32377, + "line": 1056, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38dbdd0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32343, + "line": 1055, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dbdb8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dbd98", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32345, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32345, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38db030", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32343, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32343, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38dbd80", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32348, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38db050", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32348, + "col": 14, + "tokLen": 6 + }, + "end": { + "offset": 32348, + "col": 14, + "tokLen": 6 + } + }, + "type": { + "qualType": "const char[5]" + }, + "valueCategory": "lvalue", + "value": "\"hits\"" + } + ] + } + ] + }, + { + "id": "0x38dbe70", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32364, + "line": 1056, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32377, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38dbe40", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32371, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32377, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c370", + "kind": "EnumConstantDecl", + "name": "ALG_HITS", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + } + } + } + ] + } + ] + }, + { + "id": "0x38dccf0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32391, + "line": 1057, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32428, + "line": 1058, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38dcc40", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32395, + "line": 1057, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dcc28", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32397, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32397, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dcc08", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32397, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32397, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38dbea0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32395, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32395, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38dcbf0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32400, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dbec0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32400, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 32400, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"raw\"" + } + ] + } + ] + }, + { + "id": "0x38dcce0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32415, + "line": 1058, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32428, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38dccb0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32422, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32428, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c3c0", + "kind": "EnumConstantDecl", + "name": "ALG_RAW", + "type": { + "qualType": "slsDetectorDefs::vetoAlgorithm" + } + } + } + ] + } + ] + }, + { + "id": "0x38dd300", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32441, + "line": 1059, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38dd2e8", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32441, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38dd2b8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dd2a0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38dd278", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38dd258", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38dd250", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dd220", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32447, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32489, + "col": 53, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38dd208", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38dd1f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38dd1d0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38dd1c8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38dd190", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38dd178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32486, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 32486, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38dd158", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32486, + "col": 50, + "tokLen": 1 + }, + "end": { + "offset": 32486, + "col": 50, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38dd140", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32460, + "col": 24, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dcd20", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32460, + "col": 24, + "tokLen": 25 + }, + "end": { + "offset": 32460, + "col": 24, + "tokLen": 25 + } + }, + "type": { + "qualType": "const char[24]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown veto algorithm \"" + } + ] + }, + { + "id": "0x38dcd50", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32488, + "col": 52, + "tokLen": 1 + }, + "end": { + "offset": 32488, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dada8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38dd4b8", + "kind": "FunctionDecl", + "loc": { + "offset": 32522, + "file": "ToString.cpp", + "line": 1062, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32495, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 32948, + "line": 1076, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368da18", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8gainModeEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::gainMode (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "inner": [ + { + "id": "0x2f5c4b0", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "decl": { + "id": "0x2f5c410", + "kind": "EnumDecl", + "name": "gainMode" + } + } + ] + }, + { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "loc": { + "offset": 32550, + "line": 1062, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32531, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 32550, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e3338", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 32553, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 32948, + "line": 1076, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38de4c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32559, + "line": 1063, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32600, + "line": 1064, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38de410", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32563, + "line": 1063, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38de3f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38de3d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32565, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32565, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38dd670", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32563, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32563, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38de3c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38dd690", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32568, + "col": 14, + "tokLen": 9 + }, + "end": { + "offset": 32568, + "col": 14, + "tokLen": 9 + } + }, + "type": { + "qualType": "const char[8]" + }, + "valueCategory": "lvalue", + "value": "\"dynamic\"" + } + ] + } + ] + }, + { + "id": "0x38de4b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32587, + "line": 1064, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32600, + "col": 22, + "tokLen": 7 + } + }, + "inner": [ + { + "id": "0x38de480", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32594, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32600, + "col": 22, + "tokLen": 7 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c4d0", + "kind": "EnumConstantDecl", + "name": "DYNAMIC", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38df340", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32613, + "line": 1065, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32660, + "line": 1066, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38df290", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32617, + "line": 1065, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38df278", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38df258", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32619, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32619, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38de4e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32617, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32617, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38df240", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32622, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38de500", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32622, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32622, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"forceswitchg1\"" + } + ] + } + ] + }, + { + "id": "0x38df330", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32647, + "line": 1066, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32660, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38df300", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32654, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32660, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c520", + "kind": "EnumConstantDecl", + "name": "FORCE_SWITCH_G1", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e01c0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32681, + "line": 1067, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32728, + "line": 1068, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38e0110", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32685, + "line": 1067, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e00f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32687, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32687, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e00d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32687, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32687, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38df360", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32685, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32685, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e00c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32690, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38df380", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32690, + "col": 14, + "tokLen": 15 + }, + "end": { + "offset": 32690, + "col": 14, + "tokLen": 15 + } + }, + "type": { + "qualType": "const char[14]" + }, + "valueCategory": "lvalue", + "value": "\"forceswitchg2\"" + } + ] + } + ] + }, + { + "id": "0x38e01b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32715, + "line": 1068, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32728, + "col": 22, + "tokLen": 15 + } + }, + "inner": [ + { + "id": "0x38e0180", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32722, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32728, + "col": 22, + "tokLen": 15 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c570", + "kind": "EnumConstantDecl", + "name": "FORCE_SWITCH_G2", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e1030", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32749, + "line": 1069, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32788, + "line": 1070, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e0f80", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32753, + "line": 1069, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e0f68", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32755, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32755, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e0f48", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32755, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32755, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e01e0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32753, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32753, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e0f30", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32758, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e0200", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32758, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32758, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg1\"" + } + ] + } + ] + }, + { + "id": "0x38e1020", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32775, + "line": 1070, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32788, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e0ff0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32782, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32788, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c5c0", + "kind": "EnumConstantDecl", + "name": "FIX_G1", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e1ea0", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32800, + "line": 1071, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32839, + "line": 1072, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e1df0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32804, + "line": 1071, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e1dd8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32806, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32806, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e1db8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32806, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32806, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e1050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32804, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32804, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e1da0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32809, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e1070", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32809, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32809, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg2\"" + } + ] + } + ] + }, + { + "id": "0x38e1e90", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32826, + "line": 1072, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32839, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e1e60", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32833, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32839, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c610", + "kind": "EnumConstantDecl", + "name": "FIX_G2", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e2d10", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 32851, + "line": 1073, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 32890, + "line": 1074, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e2c60", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32855, + "line": 1073, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e2c48", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e2c28", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32857, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 32857, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e1ec0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32855, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 32855, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e2c10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32860, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e1ee0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32860, + "col": 14, + "tokLen": 7 + }, + "end": { + "offset": 32860, + "col": 14, + "tokLen": 7 + } + }, + "type": { + "qualType": "const char[6]" + }, + "valueCategory": "lvalue", + "value": "\"fixg0\"" + } + ] + } + ] + }, + { + "id": "0x38e2d00", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 32877, + "line": 1074, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 32890, + "col": 22, + "tokLen": 6 + } + }, + "inner": [ + { + "id": "0x38e2cd0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32884, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 32890, + "col": 22, + "tokLen": 6 + } + }, + "type": { + "qualType": "slsDetectorDefs::gainMode" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c660", + "kind": "EnumConstantDecl", + "name": "FIX_G0", + "type": { + "qualType": "slsDetectorDefs::gainMode" + } + } + } + ] + } + ] + }, + { + "id": "0x38e3320", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 32902, + "line": 1075, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e3308", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 32902, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e32d8", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e32c0", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e3298", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38e3278", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e3270", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e3240", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 32908, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 32945, + "col": 48, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e3228", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38e3210", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38e31f0", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38e31e8", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e31b0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e3198", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32942, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 32942, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e3178", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32942, + "col": 45, + "tokLen": 1 + }, + "end": { + "offset": 32942, + "col": 45, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38e3160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32921, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e2d40", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 32921, + "col": 24, + "tokLen": 20 + }, + "end": { + "offset": 32921, + "col": 24, + "tokLen": 20 + } + }, + "type": { + "qualType": "const char[19]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown gain mode \"" + } + ] + }, + { + "id": "0x38e2d70", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 32944, + "col": 47, + "tokLen": 1 + }, + "end": { + "offset": 32944, + "col": 47, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38dd3e8", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e34f8", + "kind": "FunctionDecl", + "loc": { + "offset": 32978, + "file": "ToString.cpp", + "line": 1078, + "col": 28, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 32951, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33167, + "line": 1084, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368df38", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIN15slsDetectorDefs8polarityEEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "defs::polarity (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "inner": [ + { + "id": "0x2f5c750", + "kind": "EnumType", + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "decl": { + "id": "0x2f5c6b0", + "kind": "EnumDecl", + "name": "polarity" + } + } + ] + }, + { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "loc": { + "offset": 33006, + "line": 1078, + "col": 56, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 32987, + "col": 37, + "tokLen": 5 + }, + "end": { + "offset": 33006, + "col": 56, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e5998", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33009, + "col": 59, + "tokLen": 1 + }, + "end": { + "offset": 33167, + "line": 1084, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e4500", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 33015, + "line": 1079, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 33052, + "line": 1080, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e4450", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33019, + "line": 1079, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e4438", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33021, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33021, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e4418", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33021, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33021, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e36b0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33019, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33019, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e4400", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33024, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e36d0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33024, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33024, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"pos\"" + } + ] + } + ] + }, + { + "id": "0x38e44f0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33039, + "line": 1080, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33052, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e44c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33046, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33052, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c770", + "kind": "EnumConstantDecl", + "name": "POSITIVE", + "type": { + "qualType": "slsDetectorDefs::polarity" + } + } + } + ] + } + ] + }, + { + "id": "0x38e5370", + "kind": "IfStmt", + "range": { + "begin": { + "offset": 33066, + "line": 1081, + "col": 5, + "tokLen": 2 + }, + "end": { + "offset": 33103, + "line": 1082, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e52c0", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33070, + "line": 1081, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e52a8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (*)(const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e5288", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33072, + "col": 11, + "tokLen": 2 + }, + "end": { + "offset": 33072, + "col": 11, + "tokLen": 2 + } + }, + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x3605608", + "kind": "FunctionDecl", + "name": "operator==", + "type": { + "qualType": "bool (const basic_string, std::allocator> &, const char *)" + } + } + } + ] + }, + { + "id": "0x38e4520", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33070, + "col": 9, + "tokLen": 1 + }, + "end": { + "offset": 33070, + "col": 9, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e5270", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33075, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e4540", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33075, + "col": 14, + "tokLen": 5 + }, + "end": { + "offset": 33075, + "col": 14, + "tokLen": 5 + } + }, + "type": { + "qualType": "const char[4]" + }, + "valueCategory": "lvalue", + "value": "\"neg\"" + } + ] + } + ] + }, + { + "id": "0x38e5360", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33090, + "line": 1082, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33103, + "col": 22, + "tokLen": 8 + } + }, + "inner": [ + { + "id": "0x38e5330", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33097, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33103, + "col": 22, + "tokLen": 8 + } + }, + "type": { + "qualType": "slsDetectorDefs::polarity" + }, + "valueCategory": "prvalue", + "referencedDecl": { + "id": "0x2f5c7c0", + "kind": "EnumConstantDecl", + "name": "NEGATIVE", + "type": { + "qualType": "slsDetectorDefs::polarity" + } + } + } + ] + } + ] + }, + { + "id": "0x38e5980", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 33117, + "line": 1083, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e5968", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 33117, + "col": 5, + "tokLen": 5 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5938", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e5920", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e58f8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da8350", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const std::string &)" + } + }, + "inner": [ + { + "id": "0x38e58d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e58d0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e58a0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33123, + "col": 11, + "tokLen": 12 + }, + "end": { + "offset": 33164, + "col": 52, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const std::string &)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e5888", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "lvalue", + "storageDuration": "full expression", + "boundToLValueRef": true, + "inner": [ + { + "id": "0x38e5870", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "castKind": "NoOp", + "inner": [ + { + "id": "0x38e5850", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "temp": "0x38e5848", + "dtor": { + "id": "0x2c92d00", + "kind": "CXXDestructorDecl", + "name": "~basic_string", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e5810", + "kind": "CXXOperatorCallExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "std::basic_string", + "qualType": "basic_string, std::allocator>" + }, + "valueCategory": "prvalue", + "adl": true, + "inner": [ + { + "id": "0x38e57f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33161, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33161, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (*)(const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e57d8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33161, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33161, + "col": 49, + "tokLen": 1 + } + }, + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2faab58", + "kind": "FunctionDecl", + "name": "operator+", + "type": { + "qualType": "basic_string, std::allocator> (const char *, const basic_string, std::allocator> &)" + } + } + } + ] + }, + { + "id": "0x38e57c0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33136, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e53a0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33136, + "col": 24, + "tokLen": 24 + }, + "end": { + "offset": 33136, + "col": 24, + "tokLen": 24 + } + }, + "type": { + "qualType": "const char[23]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown polarity mode \"" + } + ] + }, + { + "id": "0x38e53d0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33163, + "col": 51, + "tokLen": 1 + }, + "end": { + "offset": 33163, + "col": 51, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e3428", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e5ae8", + "kind": "FunctionDecl", + "loc": { + "offset": 33191, + "file": "ToString.cpp", + "line": 1086, + "col": 22, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33170, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33325, + "line": 1089, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368e408", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIjEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint32_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned int" + }, + "inner": [ + { + "id": "0x230bbd0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned int" + } + } + ] + }, + { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "loc": { + "offset": 33219, + "line": 1086, + "col": 50, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33200, + "col": 31, + "tokLen": 5 + }, + "end": { + "offset": 33219, + "col": 50, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e61b0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33222, + "col": 53, + "tokLen": 1 + }, + "end": { + "offset": 33325, + "line": 1089, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e5fa0", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33228, + "line": 1087, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33282, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e5c88", + "kind": "VarDecl", + "loc": { + "offset": 33232, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33228, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e5f70", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5f10", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e5dd0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33250, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e5da0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33241, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e5cf0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33239, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33239, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e5e00", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33246, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33246, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e5d80", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33246, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33246, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e5e30", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e5ef8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33255, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e5ec8", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33255, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33268, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e5f30", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33275, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33275, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e5f50", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33280, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33280, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e61a0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33288, + "line": 1088, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6188", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned int", + "qualType": "uint32_t", + "typeAliasDeclId": "0x23ae7f8" + }, + "valueCategory": "prvalue", + "castKind": "IntegralCast", + "inner": [ + { + "id": "0x38e6120", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33322, + "col": 39, + "tokLen": 1 + } + }, + "type": { + "qualType": "unsigned long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6108", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33300, + "col": 17, + "tokLen": 5 + } + }, + "type": { + "qualType": "unsigned long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e6078", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33295, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33300, + "col": 17, + "tokLen": 5 + } + }, + "type": { + "qualType": "unsigned long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2ca8d40", + "kind": "FunctionDecl", + "name": "stoul", + "type": { + "qualType": "unsigned long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e6028", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33306, + "col": 23, + "tokLen": 1 + }, + "end": { + "offset": 33306, + "col": 23, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e6158", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33309, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33309, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e6048", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33309, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33309, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6170", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33318, + "col": 35, + "tokLen": 4 + }, + "end": { + "offset": 33318, + "col": 35, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6058", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33318, + "col": 35, + "tokLen": 4 + }, + "end": { + "offset": 33318, + "col": 35, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e5c88", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e62f8", + "kind": "FunctionDecl", + "loc": { + "offset": 33349, + "file": "ToString.cpp", + "line": 1091, + "col": 22, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33328, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33484, + "line": 1094, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368e8a8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToImEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "uint64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "unsigned long" + }, + "inner": [ + { + "id": "0x230bbf0", + "kind": "BuiltinType", + "type": { + "qualType": "unsigned long" + } + } + ] + }, + { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "loc": { + "offset": 33377, + "line": 1091, + "col": 50, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33358, + "col": 31, + "tokLen": 5 + }, + "end": { + "offset": 33377, + "col": 50, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e69a0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33380, + "col": 53, + "tokLen": 1 + }, + "end": { + "offset": 33484, + "line": 1094, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6798", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33386, + "line": 1092, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33440, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6498", + "kind": "VarDecl", + "loc": { + "offset": 33390, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33386, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e6768", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6708", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e65e0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33408, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e65b0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33399, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e6500", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33397, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33397, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e6610", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33404, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33404, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e6590", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33404, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33404, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e6628", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e66f0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33413, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e66c0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33413, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33426, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e6728", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33433, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33433, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e6748", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33438, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33438, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e6990", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33446, + "line": 1093, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6978", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "uint64_t", + "typeAliasDeclId": "0x23ae860" + }, + "valueCategory": "prvalue", + "castKind": "IntegralCast", + "inner": [ + { + "id": "0x38e6910", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33481, + "col": 40, + "tokLen": 1 + } + }, + "type": { + "qualType": "unsigned long long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e68f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33458, + "col": 17, + "tokLen": 6 + } + }, + "type": { + "qualType": "unsigned long long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e6870", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33453, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33458, + "col": 17, + "tokLen": 6 + } + }, + "type": { + "qualType": "unsigned long long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2caac00", + "kind": "FunctionDecl", + "name": "stoull", + "type": { + "qualType": "unsigned long long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e6820", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33465, + "col": 24, + "tokLen": 1 + }, + "end": { + "offset": 33465, + "col": 24, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6238", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e6948", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33468, + "col": 27, + "tokLen": 7 + }, + "end": { + "offset": 33468, + "col": 27, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e6840", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33468, + "col": 27, + "tokLen": 7 + }, + "end": { + "offset": 33468, + "col": 27, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6960", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33477, + "col": 36, + "tokLen": 4 + }, + "end": { + "offset": 33477, + "col": 36, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6850", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33477, + "col": 36, + "tokLen": 4 + }, + "end": { + "offset": 33477, + "col": 36, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6498", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e6af0", + "kind": "FunctionDecl", + "loc": { + "offset": 33503, + "file": "ToString.cpp", + "line": 1096, + "col": 17, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33487, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33636, + "line": 1099, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368ed50", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIiEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "int" + }, + "inner": [ + { + "id": "0x230bb30", + "kind": "BuiltinType", + "type": { + "qualType": "int" + } + } + ] + }, + { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "loc": { + "offset": 33531, + "line": 1096, + "col": 45, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33512, + "col": 26, + "tokLen": 5 + }, + "end": { + "offset": 33531, + "col": 45, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e7188", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33534, + "col": 48, + "tokLen": 1 + }, + "end": { + "offset": 33636, + "line": 1099, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6f98", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33540, + "line": 1097, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33594, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e6c98", + "kind": "VarDecl", + "loc": { + "offset": 33544, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33540, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e6f68", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6f08", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e6de0", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33562, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e6db0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33553, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e6d00", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33551, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33551, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e6e10", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33558, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33558, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e6d90", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33558, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33558, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e6e28", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e6ef0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33567, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e6ec0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33567, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 33580, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e6f28", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33587, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 33587, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e6f48", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33592, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 33592, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e7178", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33600, + "line": 1098, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33633, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7110", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33633, + "col": 38, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e70f8", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33612, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e7070", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33607, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 33612, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2c76400", + "kind": "FunctionDecl", + "name": "stoi", + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e7020", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33617, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 33617, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6a28", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e7148", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33620, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 33620, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e7040", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33620, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 33620, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7160", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33629, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 33629, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33629, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 33629, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e6c98", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e72d8", + "kind": "FunctionDecl", + "loc": { + "offset": 33656, + "file": "ToString.cpp", + "line": 1101, + "col": 18, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33639, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 33900, + "line": 1111, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368f1c8", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIbEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "bool (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "bool" + }, + "inner": [ + { + "id": "0x230bab0", + "kind": "BuiltinType", + "type": { + "qualType": "bool" + } + } + ] + }, + { + "id": "0x38e7210", + "kind": "ParmVarDecl", + "loc": { + "offset": 33684, + "line": 1101, + "col": 46, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33665, + "col": 27, + "tokLen": 5 + }, + "end": { + "offset": 33684, + "col": 46, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e79e0", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33687, + "col": 49, + "tokLen": 1 + }, + "end": { + "offset": 33900, + "line": 1111, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7638", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33693, + "line": 1102, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33726, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7478", + "kind": "VarDecl", + "loc": { + "offset": 33697, + "col": 9, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33693, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 33725, + "col": 37, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "i", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e75e8", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33725, + "col": 37, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e75d0", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33706, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e75a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33701, + "col": 13, + "tokLen": 3 + }, + "end": { + "offset": 33706, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2c76400", + "kind": "FunctionDecl", + "name": "stoi", + "type": { + "qualType": "int (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e7550", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33711, + "col": 23, + "tokLen": 1 + }, + "end": { + "offset": 33711, + "col": 23, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7210", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e7620", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33714, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33714, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e7570", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 33714, + "col": 26, + "tokLen": 7 + }, + "end": { + "offset": 33714, + "col": 26, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7580", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33723, + "col": 35, + "tokLen": 2 + }, + "end": { + "offset": 33723, + "col": 35, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e7688", + "kind": "SwitchStmt", + "range": { + "begin": { + "offset": 33732, + "line": 1103, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 33898, + "line": 1110, + "col": 5, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7670", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33740, + "line": 1103, + "col": 13, + "tokLen": 1 + }, + "end": { + "offset": 33740, + "col": 13, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7650", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33740, + "col": 13, + "tokLen": 1 + }, + "end": { + "offset": 33740, + "col": 13, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7478", + "kind": "VarDecl", + "name": "i", + "type": { + "qualType": "int" + } + } + } + ] + }, + { + "id": "0x38e79b8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33743, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33898, + "line": 1110, + "col": 5, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e76f0", + "kind": "CaseStmt", + "range": { + "begin": { + "offset": 33749, + "line": 1104, + "col": 5, + "tokLen": 4 + }, + "end": { + "offset": 33772, + "line": 1105, + "col": 16, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38e76d0", + "kind": "ConstantExpr", + "range": { + "begin": { + "offset": 33754, + "line": 1104, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33754, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0", + "inner": [ + { + "id": "0x38e76b0", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33754, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33754, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "0" + } + ] + }, + { + "id": "0x38e7728", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33765, + "line": 1105, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33772, + "col": 16, + "tokLen": 5 + } + }, + "inner": [ + { + "id": "0x38e7718", + "kind": "CXXBoolLiteralExpr", + "range": { + "begin": { + "offset": 33772, + "col": 16, + "tokLen": 5 + }, + "end": { + "offset": 33772, + "col": 16, + "tokLen": 5 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "value": false + } + ] + } + ] + }, + { + "id": "0x38e7778", + "kind": "CaseStmt", + "range": { + "begin": { + "offset": 33783, + "line": 1106, + "col": 5, + "tokLen": 4 + }, + "end": { + "offset": 33806, + "line": 1107, + "col": 16, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38e7758", + "kind": "ConstantExpr", + "range": { + "begin": { + "offset": 33788, + "line": 1106, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33788, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "1", + "inner": [ + { + "id": "0x38e7738", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 33788, + "col": 10, + "tokLen": 1 + }, + "end": { + "offset": 33788, + "col": 10, + "tokLen": 1 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "1" + } + ] + }, + { + "id": "0x38e77b0", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 33799, + "line": 1107, + "col": 9, + "tokLen": 6 + }, + "end": { + "offset": 33806, + "col": 16, + "tokLen": 4 + } + }, + "inner": [ + { + "id": "0x38e77a0", + "kind": "CXXBoolLiteralExpr", + "range": { + "begin": { + "offset": 33806, + "col": 16, + "tokLen": 4 + }, + "end": { + "offset": 33806, + "col": 16, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "value": true + } + ] + } + ] + }, + { + "id": "0x38e7998", + "kind": "DefaultStmt", + "range": { + "begin": { + "offset": 33816, + "line": 1108, + "col": 5, + "tokLen": 7 + }, + "end": { + "offset": 33891, + "line": 1109, + "col": 67, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7980", + "kind": "ExprWithCleanups", + "range": { + "begin": { + "offset": 33833, + "col": 9, + "tokLen": 5 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "cleanupsHaveSideEffects": true, + "inner": [ + { + "id": "0x38e7968", + "kind": "CXXThrowExpr", + "range": { + "begin": { + "offset": 33833, + "col": 9, + "tokLen": 5 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "void" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7938", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (sls::RuntimeError &&) noexcept" + }, + "elidable": true, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e7920", + "kind": "MaterializeTemporaryExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "xvalue", + "storageDuration": "full expression", + "inner": [ + { + "id": "0x38e78f8", + "kind": "CXXFunctionalCastExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "castKind": "ConstructorConversion", + "conversionFunc": { + "id": "0x2da84b8", + "kind": "CXXConstructorDecl", + "name": "RuntimeError", + "type": { + "qualType": "void (const char *)" + } + }, + "inner": [ + { + "id": "0x38e78d8", + "kind": "CXXBindTemporaryExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "temp": "0x38e78d0", + "dtor": { + "id": "0x2da8c50", + "kind": "CXXDestructorDecl", + "name": "~RuntimeError", + "type": { + "qualType": "void () noexcept" + } + }, + "inner": [ + { + "id": "0x38e78a0", + "kind": "CXXConstructExpr", + "range": { + "begin": { + "offset": 33839, + "col": 15, + "tokLen": 12 + }, + "end": { + "offset": 33891, + "col": 67, + "tokLen": 1 + } + }, + "type": { + "qualType": "sls::RuntimeError" + }, + "valueCategory": "prvalue", + "ctorType": { + "qualType": "void (const char *)" + }, + "hadMultipleCandidates": true, + "constructionKind": "complete", + "inner": [ + { + "id": "0x38e7888", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33852, + "col": 28, + "tokLen": 39 + }, + "end": { + "offset": 33852, + "col": 28, + "tokLen": 39 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e7848", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33852, + "col": 28, + "tokLen": 39 + }, + "end": { + "offset": 33852, + "col": 28, + "tokLen": 39 + } + }, + "type": { + "qualType": "const char[38]" + }, + "valueCategory": "lvalue", + "value": "\"Unknown boolean. Expecting be 0 or 1.\"" + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] + } + ] +}, +{ + "id": "0x38e7b28", + "kind": "FunctionDecl", + "loc": { + "offset": 33923, + "file": "ToString.cpp", + "line": 1113, + "col": 21, + "tokLen": 8 + }, + "range": { + "begin": { + "offset": 33903, + "col": 1, + "tokLen": 8 + }, + "end": { + "offset": 34056, + "line": 1116, + "col": 1, + "tokLen": 1 + } + }, + "previousDecl": "0x368f668", + "name": "StringTo", + "mangledName": "_ZN3sls8StringToIlEET_RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", + "type": { + "qualType": "int64_t (const std::string &)" + }, + "inner": [ + { + "kind": "TemplateArgument", + "type": { + "qualType": "long" + }, + "inner": [ + { + "id": "0x230bb50", + "kind": "BuiltinType", + "type": { + "qualType": "long" + } + } + ] + }, + { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "loc": { + "offset": 33951, + "line": 1113, + "col": 49, + "tokLen": 1 + }, + "range": { + "begin": { + "offset": 33932, + "col": 30, + "tokLen": 5 + }, + "end": { + "offset": 33951, + "col": 49, + "tokLen": 1 + } + }, + "isUsed": true, + "name": "s", + "type": { + "qualType": "const std::string &" + } + }, + { + "id": "0x38e81b8", + "kind": "CompoundStmt", + "range": { + "begin": { + "offset": 33954, + "col": 52, + "tokLen": 1 + }, + "end": { + "offset": 34056, + "line": 1116, + "col": 1, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7fc8", + "kind": "DeclStmt", + "range": { + "begin": { + "offset": 33960, + "line": 1114, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 34014, + "col": 59, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e7cc8", + "kind": "VarDecl", + "loc": { + "offset": 33964, + "col": 9, + "tokLen": 4 + }, + "range": { + "begin": { + "offset": 33960, + "col": 5, + "tokLen": 3 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "isUsed": true, + "name": "base", + "type": { + "qualType": "int" + }, + "init": "c", + "inner": [ + { + "id": "0x38e7f98", + "kind": "ConditionalOperator", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7f38", + "kind": "BinaryOperator", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "qualType": "bool" + }, + "valueCategory": "prvalue", + "opcode": "!=", + "inner": [ + { + "id": "0x38e7e10", + "kind": "CXXMemberCallExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33982, + "col": 27, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e7de0", + "kind": "MemberExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33973, + "col": 18, + "tokLen": 4 + } + }, + "type": { + "qualType": "" + }, + "valueCategory": "prvalue", + "name": "find", + "isArrow": false, + "referencedMemberDecl": "0x2ca1d70", + "inner": [ + { + "id": "0x38e7d30", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33971, + "col": 16, + "tokLen": 1 + }, + "end": { + "offset": 33971, + "col": 16, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + } + ] + }, + { + "id": "0x38e7e40", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33978, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33978, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char *" + }, + "valueCategory": "prvalue", + "castKind": "ArrayToPointerDecay", + "inner": [ + { + "id": "0x38e7dc0", + "kind": "StringLiteral", + "range": { + "begin": { + "offset": 33978, + "col": 23, + "tokLen": 4 + }, + "end": { + "offset": 33978, + "col": 23, + "tokLen": 4 + } + }, + "type": { + "qualType": "const char[3]" + }, + "valueCategory": "lvalue", + "value": "\"0x\"" + } + ] + }, + { + "id": "0x38e7e58", + "kind": "CXXDefaultArgExpr", + "range": { + "begin": {}, + "end": {} + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "std::basic_string::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e7f20", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 33987, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "unsigned long", + "qualType": "typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e7ef0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 33987, + "col": 32, + "tokLen": 3 + }, + "end": { + "offset": 34000, + "col": 45, + "tokLen": 4 + } + }, + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x31f4700", + "kind": "VarDecl", + "name": "npos", + "type": { + "desugaredQualType": "const unsigned long", + "qualType": "const typename basic_string, allocator>::size_type", + "typeAliasDeclId": "0x2c82e40" + } + }, + "nonOdrUseReason": "constant" + } + ] + } + ] + }, + { + "id": "0x38e7f58", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 34007, + "col": 52, + "tokLen": 2 + }, + "end": { + "offset": 34007, + "col": 52, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "16" + }, + { + "id": "0x38e7f78", + "kind": "IntegerLiteral", + "range": { + "begin": { + "offset": 34012, + "col": 57, + "tokLen": 2 + }, + "end": { + "offset": 34012, + "col": 57, + "tokLen": 2 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "value": "10" + } + ] + } + ] + } + ] + }, + { + "id": "0x38e81a8", + "kind": "ReturnStmt", + "range": { + "begin": { + "offset": 34020, + "line": 1115, + "col": 5, + "tokLen": 6 + }, + "end": { + "offset": 34053, + "col": 38, + "tokLen": 1 + } + }, + "inner": [ + { + "id": "0x38e8140", + "kind": "CallExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34053, + "col": 38, + "tokLen": 1 + } + }, + "type": { + "qualType": "long" + }, + "valueCategory": "prvalue", + "inner": [ + { + "id": "0x38e8128", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34032, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "long (*)(const std::string &, std::size_t *, int)" + }, + "valueCategory": "prvalue", + "castKind": "FunctionToPointerDecay", + "inner": [ + { + "id": "0x38e80a0", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34027, + "col": 12, + "tokLen": 3 + }, + "end": { + "offset": 34032, + "col": 17, + "tokLen": 4 + } + }, + "type": { + "qualType": "long (const std::string &, std::size_t *, int)" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x2ca7f70", + "kind": "FunctionDecl", + "name": "stol", + "type": { + "qualType": "long (const std::string &, std::size_t *, int)" + } + } + } + ] + }, + { + "id": "0x38e8050", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34037, + "col": 22, + "tokLen": 1 + }, + "end": { + "offset": 34037, + "col": 22, + "tokLen": 1 + } + }, + "type": { + "desugaredQualType": "const std::basic_string", + "qualType": "const std::string", + "typeAliasDeclId": "0x2a12a80" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7a68", + "kind": "ParmVarDecl", + "name": "s", + "type": { + "qualType": "const std::string &" + } + } + }, + { + "id": "0x38e8178", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34040, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 34040, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::size_t *" + }, + "valueCategory": "prvalue", + "castKind": "NullToPointer", + "inner": [ + { + "id": "0x38e8070", + "kind": "CXXNullPtrLiteralExpr", + "range": { + "begin": { + "offset": 34040, + "col": 25, + "tokLen": 7 + }, + "end": { + "offset": 34040, + "col": 25, + "tokLen": 7 + } + }, + "type": { + "qualType": "std::nullptr_t" + }, + "valueCategory": "prvalue" + } + ] + }, + { + "id": "0x38e8190", + "kind": "ImplicitCastExpr", + "range": { + "begin": { + "offset": 34049, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 34049, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "prvalue", + "castKind": "LValueToRValue", + "inner": [ + { + "id": "0x38e8080", + "kind": "DeclRefExpr", + "range": { + "begin": { + "offset": 34049, + "col": 34, + "tokLen": 4 + }, + "end": { + "offset": 34049, + "col": 34, + "tokLen": 4 + } + }, + "type": { + "qualType": "int" + }, + "valueCategory": "lvalue", + "referencedDecl": { + "id": "0x38e7cc8", + "kind": "VarDecl", + "name": "base", + "type": { + "qualType": "int" + } + } + } + ] + } + ] + } + ] + } + ] + } + ] +} +] \ No newline at end of file diff --git a/slsDetectorSoftware/generator/autocomplete/slsdet-completion.bash b/slsDetectorSoftware/generator/autocomplete/slsdet-completion.bash new file mode 100644 index 000000000..2ae81a4b8 --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/slsdet-completion.bash @@ -0,0 +1,177 @@ +#### simpler version of autocomplete.sh to understand the logic +#### each command has its own function when called it will produce the possible values for autocompletion + + +_sd() { + + # Reassemble command line words, excluding specified characters from the + # list of word completion separators (COMP_WORDBREAKS). + # @param $1 chars Characters out of $COMP_WORDBREAKS which should + # NOT be considered word breaks. This is useful for things like scp where + # we want to return host:path and not only path, so we would pass the + # colon (:) as $1 here. + # @param $2 words Name of variable to return words to + # @param $3 cword Name of variable to return cword to + # + _comp__reassemble_words() +{ + local exclude="" i j line ref + # Exclude word separator characters? + if [[ $1 ]]; then + # Yes, exclude word separator characters; + # Exclude only those characters, which were really included + exclude="[${1//[^$COMP_WORDBREAKS]/}]" + fi + + # Default to cword unchanged + printf -v "$3" %s "$COMP_CWORD" + # Are characters excluded which were former included? + if [[ $exclude ]]; then + # Yes, list of word completion separators has shrunk; + line=$COMP_LINE + # Re-assemble words to complete + for ((i = 0, j = 0; i < ${#COMP_WORDS[@]}; i++, j++)); do + # Is current word not word 0 (the command itself) and is word not + # empty and is word made up of just word separator characters to + # be excluded and is current word not preceded by whitespace in + # original line? + while [[ $i -gt 0 && ${COMP_WORDS[i]} == +($exclude) ]]; do + # Is word separator not preceded by whitespace in original line + # and are we not going to append to word 0 (the command + # itself), then append to current word. + [[ $line != [[:blank:]]* ]] && ((j >= 2)) && ((j--)) + # Append word separator to current or new word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + # Remove optional whitespace + word separator from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate next word if available, else end *both* while and + # for loop + if ((i < ${#COMP_WORDS[@]} - 1)); then + ((i++)) + else + break 2 + fi + # Start new word if word separator in original line is + # followed by whitespace. + [[ $line == [[:blank:]]* ]] && ((j++)) + done + # Append word to current word + ref="$2[$j]" + printf -v "$ref" %s "${!ref-}${COMP_WORDS[i]}" + # Remove optional whitespace + word from line copy + line=${line#*"${COMP_WORDS[i]}"} + # Indicate new cword + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + done + ((i == COMP_CWORD)) && printf -v "$3" %s "$j" + else + # No, list of word completions separators hasn't changed; + for i in "${!COMP_WORDS[@]}"; do + printf -v "$2[i]" %s "${COMP_WORDS[i]}" + done + fi +} + + + + __exptime(){ + if [ "${IS_GET}" == "1" ]; then + if [ "${cword}" == "2" ]; then + FCN_RETURN="s ms us ns" + fi + else + if [ "${cword}" == "2" ]; then + FCN_RETURN="" + fi + + if [ "${cword}" == "3" ]; then + FCN_RETURN="s ms us ns" + fi + + fi + } + + # trimbits will activate IS_PATH and signal that its input is a path + __trimbits(){ + if [ "${IS_GET}" == "1" ]; then + if [ "${cword}" == "2" ]; then + FCN_RETURN="" + IS_PATH=1 + fi + else + if [ "${cword}" == "2" ]; then + FCN_RETURN="" + IS_PATH=1 + fi + fi + } + + local cword words=() + _comp__reassemble_words ":" words cword + local FCN_RETURN="" + local IS_PATH=0 + COMPREPLY=() + local OPTIONS_NEW="" +# _get_comp_words_by_ref -n : cur + local cur=${words[cword]} + # check the action (get or put) + if [ "${words[0]}" == "sls_detector_get" ]; then + local IS_GET=1 + else + local IS_GET=0 + fi + + + # if no command is written, autocomplete with the commands + if [[ ${cword} -eq 1 ]]; then + local SLS_COMMANDS="trimbits exptime" + local SLS_COMMANDS_NEW="" + + case "$cur" in + [0-9]*:*) + local suggestions=($(compgen -W "${SLS_COMMANDS}" -- "${cur#*:}")) + COMPREPLY=( ${suggestions[*]} ) + ;; + [0-9]*) + COMPREPLY=() + ;; + *) + COMPREPLY=( $( compgen -W "$SLS_COMMANDS -h" -- "$cur" ) );; + + esac + return 0 + fi + + # if a command is written, autocomplete with the options + # call the function for the command + __"${words[1]##*:}" + + # if IS_PATH is activated, autocomplete with the path + if [[ ${IS_PATH} -eq 1 ]]; then + COMPREPLY=($(compgen -f -- "${cur}")) + return 0 + fi + + # autocomplete with the options + COMPREPLY=($(compgen -W "${FCN_RETURN}" -- "${cur}")) + + + +} + +complete -F _sd -o filenames sls_detector_put +complete -F _sd -o filenames sls_detector_get + +complete -F _sd -o filenames g +complete -F _sd -o filenames p + +complete -F _sd -o filenames detg +complete -F _sd -o filenames detp + + +complete -F _sd -o filenames sls_detector +complete -F _sd -o filenames det + diff --git a/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.in.sh b/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.in.sh new file mode 100644 index 000000000..cbf8fad6b --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.in.sh @@ -0,0 +1,77 @@ +# GENERATED FILE - DO NOT EDIT +# ANY CHANGES TO THIS FILE WILL BE OVERWRITTEN + +_sd() { + + + # -- THIS LINE WILL BE REPLACED WITH GENERATED CODE -- + + + local FCN_RETURN="" + local IS_PATH=0 + COMPREPLY=() + local OPTIONS_NEW="" + words=("${COMP_WORDS[@]}") + cword=$COMP_CWORD + + local cur=${words[cword]} + # check the action (get or put) + case "${words[0]}" in + "sls_detector_get" | "g" | "detg") + local IS_GET=1 + ;; + *) + local IS_GET=0 + ;; + esac + + # if no command is written, autocomplete with the commands + if [[ ${cword} -eq 1 ]]; then + + case "$cur" in + [0-9]*) + for i in $SLS_COMMANDS; do + SLS_COMMANDS_NEW="${SLS_COMMANDS_NEW} ${cur%%:*}:$i" + done + COMPREPLY=( $( compgen -W "${SLS_COMMANDS_NEW}" -- "$cur" ) );; + *) + COMPREPLY=( $( compgen -W "$SLS_COMMANDS -h" -- "$cur" ) );; + esac + return 0 + fi + + if [[ ${cword} -eq 2 ]] && [[ ${words[1]} == "-h" ]]; then + COMPREPLY=( $( compgen -W "$SLS_COMMANDS" -- "$cur" ) ) + return 0 + fi + + # if a command is written, autocomplete with the options + # call the function for the command + + if [[ "$SLS_COMMANDS" == *"${words[1]##*:}"* ]]; then + __"${words[1]##*:}" + fi + + # if IS_PATH is activated, autocomplete with the path + if [[ ${IS_PATH} -eq 1 ]]; then + COMPREPLY=($(compgen -f -- "${cur}")) + return 0 + fi + + # autocomplete with the options + COMPREPLY=($(compgen -W "${FCN_RETURN}" -- "${cur}")) + + + +} + +complete -F _sd -o filenames sls_detector_get +complete -F _sd -o filenames g +complete -F _sd -o filenames detg + +complete -F _sd -o filenames sls_detector_put +complete -F _sd -o filenames p +complete -F _sd -o filenames detp + +complete -F _sd -o filenames sls_detector +complete -F _sd -o filenames det diff --git a/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.sh b/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.sh new file mode 100644 index 000000000..0ac10863c --- /dev/null +++ b/slsDetectorSoftware/generator/autocomplete/zsh_autocomplete.sh @@ -0,0 +1,3165 @@ +# GENERATED FILE - DO NOT EDIT +# ANY CHANGES TO THIS FILE WILL BE OVERWRITTEN + +_sd() { + + +local SLS_COMMANDS=" acquire activate adcclk adcenable adcenable10g adcindex adcinvert adclist adcname adcphase adcpipeline adcreg adcvpp apulse asamples autocompdisable badchannels blockingtrigger burstmode burstperiod bursts burstsl bustest cdsgain chipversion clearbit clearbusy clearroi clientversion clkdiv clkfreq clkphase column compdisabletime confadc config counters currentsource dac dacindex daclist dacname dacvalues datastream dbitclk dbitphase dbitpipeline defaultdac defaultpattern delay delayl detectorserverversion detsize diodelay dpulse dr drlist dsamples execcommand exptime exptime1 exptime2 exptime3 exptimel extrastoragecells extsampling extsamplingsrc extsig fformat filtercells filterresistor findex firmwaretest firmwareversion fliprows flowcontrol10g fmaster fname foverwrite fpath framecounter frames framesl frametime free fwrite gaincaps gainmode gappixels gatedelay gatedelay1 gatedelay2 gatedelay3 gates getbit hardwareversion highvoltage hostname im_a im_b im_c im_d im_io imagetest initialchecks inj_ch interpolation interruptsubframe kernelversion lastclient led lock master maxadcphaseshift maxclkphaseshift maxdbitphaseshift measuredperiod measuredsubperiod moduleid nextframenumber nmod numinterfaces overflow packageversion parallel parameters partialreset patfname patioctrl patlimits patloop patloop0 patloop1 patloop2 patmask patnloop patnloop0 patnloop1 patnloop2 patsetbit patternX patternstart patwait patwait0 patwait1 patwait2 patwaittime patwaittime0 patwaittime1 patwaittime2 patword pedestalmode period periodl polarity port powerchip powerindex powerlist powername powervalues programfpga pulse pulsechip pulsenmove pumpprobe quad ratecorr readnrows readout readoutspeed readoutspeedlist rebootcontroller reg resetdacs resetfpga roi romode row runclk runtime rx_arping rx_clearroi rx_dbitlist rx_dbitoffset rx_discardpolicy rx_fifodepth rx_frameindex rx_framescaught rx_framesperfile rx_hostname rx_jsonaddheader rx_jsonpara rx_lastclient rx_lock rx_missingpackets rx_padding rx_printconfig rx_realudpsocksize rx_roi rx_silent rx_start rx_status rx_stop rx_tcpport rx_threads rx_udpsocksize rx_version rx_zmqfreq rx_zmqhwm rx_zmqip rx_zmqport rx_zmqstartfnum rx_zmqstream samples savepattern scan scanerrmsg selinterface serialnumber setbit settings settingslist settingspath signalindex signallist signalname slowadc slowadcindex slowadclist slowadcname slowadcvalues start status stop stopport storagecell_delay storagecell_start subdeadtime subexptime sync syncclk temp_10ge temp_adc temp_control temp_dcdc temp_event temp_fpga temp_fpgaext temp_fpgafl temp_fpgafr temp_slowadc temp_sodl temp_sodr temp_threshold templist tempvalues tengiga threshold thresholdnotb timing timinglist timingsource top transceiverenable trigger triggers triggersl trimbits trimen trimval tsamples txdelay txdelay_frame txdelay_left txdelay_right type udp_cleardst udp_dstip udp_dstip2 udp_dstlist udp_dstmac udp_dstmac2 udp_dstport udp_dstport2 udp_firstdst udp_numdst udp_reconfigure udp_srcip udp_srcip2 udp_srcmac udp_srcmac2 udp_validate update updatedetectorserver updatekernel updatemode user v_a v_b v_c v_chip v_d v_io v_limit vchip_comp_adc vchip_comp_fe vchip_cs vchip_opa_1st vchip_opa_fd vchip_ref_comp_fe versions veto vetoalg vetofile vetophoton vetoref vetostream virtual vm_a vm_b vm_c vm_d vm_io zmqhwm zmqip zmqport " +__acquire() { +FCN_RETURN="" +return 0 +} +__activate() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__adcclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcenable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcenable10g() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcinvert() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adclist() { +FCN_RETURN="" +return 0 +} +__adcname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__adcpipeline() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcreg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__adcvpp() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__apulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__asamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__autocompdisable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__badchannels() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__blockingtrigger() { +FCN_RETURN="" +return 0 +} +__burstmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="burst_external burst_internal cw_external cw_internal" +fi +fi +return 0 +} +__burstperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__bursts() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__burstsl() { +FCN_RETURN="" +return 0 +} +__bustest() { +FCN_RETURN="" +return 0 +} +__cdsgain() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__chipversion() { +FCN_RETURN="" +return 0 +} +__clearbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clearbusy() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clearroi() { +FCN_RETURN="" +return 0 +} +__clientversion() { +FCN_RETURN="" +return 0 +} +__clkdiv() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clkfreq() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__clkphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__column() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__compdisabletime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__confadc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__config() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__counters() { +FCN_RETURN="" +return 0 +} +__currentsource() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="fix nofix" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="low normal" +fi +fi +return 0 +} +__dac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="mV mv" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__dacindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__daclist() { +FCN_RETURN="" +return 0 +} +__dacname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dacvalues() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="mV mv" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="mV mv" +fi +fi +return 0 +} +__datastream() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="bottom left right top" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="bottom left right top" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__dbitclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dbitphase() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="deg" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="deg" +fi +fi +return 0 +} +__dbitpipeline() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__defaultdac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__defaultpattern() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__delay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__delayl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__detectorserverversion() { +FCN_RETURN="" +return 0 +} +__detsize() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__diodelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__dpulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__dr() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__drlist() { +FCN_RETURN="" +return 0 +} +__dsamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__execcommand() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__exptime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime1() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptime3() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__exptimel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__extrastoragecells() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__extsampling() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__extsamplingsrc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__extsig() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="inversion_off inversion_on trigger_in_falling_edge trigger_in_rising_edge" +fi +fi +return 0 +} +__fformat() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="binary hdf5" +fi +fi +return 0 +} +__filtercells() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__filterresistor() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__findex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__firmwaretest() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__firmwareversion() { +FCN_RETURN="" +return 0 +} +__fliprows() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__flowcontrol10g() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fmaster() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__foverwrite() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__fpath() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__framecounter() { +FCN_RETURN="" +return 0 +} +__frames() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__framesl() { +FCN_RETURN="" +return 0 +} +__frametime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__free() { +FCN_RETURN="" +return 0 +} +__fwrite() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__gaincaps() { +FCN_RETURN="" +return 0 +} +__gainmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="dynamic fixg0 fixg1 fixg2 forceswitchg1 forceswitchg2" +fi +fi +return 0 +} +__gappixels() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__gatedelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay1() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gatedelay3() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__gates() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__getbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__hardwareversion() { +FCN_RETURN="" +return 0 +} +__highvoltage() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__hostname() { +FCN_RETURN="" +return 0 +} +__im_a() { +FCN_RETURN="" +return 0 +} +__im_b() { +FCN_RETURN="" +return 0 +} +__im_c() { +FCN_RETURN="" +return 0 +} +__im_d() { +FCN_RETURN="" +return 0 +} +__im_io() { +FCN_RETURN="" +return 0 +} +__imagetest() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__initialchecks() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__inj_ch() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__interpolation() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__interruptsubframe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__kernelversion() { +FCN_RETURN="" +return 0 +} +__lastclient() { +FCN_RETURN="" +return 0 +} +__led() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__lock() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__master() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__maxadcphaseshift() { +FCN_RETURN="" +return 0 +} +__maxclkphaseshift() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__maxdbitphaseshift() { +FCN_RETURN="" +return 0 +} +__measuredperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__measuredsubperiod() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__moduleid() { +FCN_RETURN="" +return 0 +} +__nextframenumber() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__nmod() { +FCN_RETURN="" +return 0 +} +__numinterfaces() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__overflow() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__packageversion() { +FCN_RETURN="" +return 0 +} +__parallel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__parameters() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__partialreset() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__patfname() { +FCN_RETURN="" +return 0 +} +__patioctrl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patlimits() { +FCN_RETURN="" +return 0 +} +__patloop() { +FCN_RETURN="" +return 0 +} +__patloop0() { +FCN_RETURN="" +return 0 +} +__patloop1() { +FCN_RETURN="" +return 0 +} +__patloop2() { +FCN_RETURN="" +return 0 +} +__patmask() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patnloop() { +FCN_RETURN="" +return 0 +} +__patnloop0() { +FCN_RETURN="" +return 0 +} +__patnloop1() { +FCN_RETURN="" +return 0 +} +__patnloop2() { +FCN_RETURN="" +return 0 +} +__patsetbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patternX() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patternstart() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__patwait() { +FCN_RETURN="" +return 0 +} +__patwait0() { +FCN_RETURN="" +return 0 +} +__patwait1() { +FCN_RETURN="" +return 0 +} +__patwait2() { +FCN_RETURN="" +return 0 +} +__patwaittime() { +FCN_RETURN="" +return 0 +} +__patwaittime0() { +FCN_RETURN="" +return 0 +} +__patwaittime1() { +FCN_RETURN="" +return 0 +} +__patwaittime2() { +FCN_RETURN="" +return 0 +} +__patword() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pedestalmode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN=" 0" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__period() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__periodl() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__polarity() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="neg pos" +fi +fi +return 0 +} +__port() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powerchip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__powerindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powerlist() { +FCN_RETURN="" +return 0 +} +__powername() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__powervalues() { +FCN_RETURN="" +return 0 +} +__programfpga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="--force-delete-normal-file" +fi +fi +return 0 +} +__pulse() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="--force-delete-normal-file" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pulsechip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pulsenmove() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__pumpprobe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__quad() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__ratecorr() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readnrows() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readout() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__readoutspeed() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1 108 144 2 full_speed half_speed quarter_speed" +fi +fi +return 0 +} +__readoutspeedlist() { +FCN_RETURN="" +return 0 +} +__rebootcontroller() { +FCN_RETURN="" +return 0 +} +__reg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__resetdacs() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hard" +fi +fi +return 0 +} +__resetfpga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hard" +fi +fi +return 0 +} +__roi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__romode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="analog analog_digital digital digital_transceiver transceiver" +fi +fi +return 0 +} +__row() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__runclk() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__runtime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__rx_arping() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_clearroi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_dbitlist() { +FCN_RETURN="" +return 0 +} +__rx_dbitoffset() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_discardpolicy() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="discardempty discardpartial nodiscard" +fi +fi +return 0 +} +__rx_fifodepth() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_frameindex() { +FCN_RETURN="" +return 0 +} +__rx_framescaught() { +FCN_RETURN="" +return 0 +} +__rx_framesperfile() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_hostname() { +FCN_RETURN="" +return 0 +} +__rx_jsonaddheader() { +FCN_RETURN="" +return 0 +} +__rx_jsonpara() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_lastclient() { +FCN_RETURN="" +return 0 +} +__rx_lock() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_missingpackets() { +FCN_RETURN="" +return 0 +} +__rx_padding() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_printconfig() { +FCN_RETURN="" +return 0 +} +__rx_realudpsocksize() { +FCN_RETURN="" +return 0 +} +__rx_roi() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_silent() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_start() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__rx_status() { +FCN_RETURN="" +return 0 +} +__rx_stop() { +FCN_RETURN="" +return 0 +} +__rx_tcpport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_threads() { +FCN_RETURN="" +return 0 +} +__rx_udpsocksize() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_version() { +FCN_RETURN="" +return 0 +} +__rx_zmqfreq() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqhwm() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqstartfnum() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__rx_zmqstream() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__samples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__savepattern() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__scan() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "6" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__scanerrmsg() { +FCN_RETURN="" +return 0 +} +__selinterface() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__serialnumber() { +FCN_RETURN="" +return 0 +} +__setbit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__settings() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__settingslist() { +FCN_RETURN="" +return 0 +} +__settingspath() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__signalindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__signallist() { +FCN_RETURN="" +return 0 +} +__signalname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadcindex() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadclist() { +FCN_RETURN="" +return 0 +} +__slowadcname() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get daclist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__slowadcvalues() { +FCN_RETURN="" +return 0 +} +__start() { +FCN_RETURN="" +return 0 +} +__status() { +FCN_RETURN="" +return 0 +} +__stop() { +FCN_RETURN="" +return 0 +} +__stopport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__storagecell_delay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__storagecell_start() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__subdeadtime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__subexptime() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="ms ns s us" +fi +fi +return 0 +} +__sync() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__syncclk() { +FCN_RETURN="" +return 0 +} +__temp_10ge() { +FCN_RETURN="" +return 0 +} +__temp_adc() { +FCN_RETURN="" +return 0 +} +__temp_control() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__temp_dcdc() { +FCN_RETURN="" +return 0 +} +__temp_event() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__temp_fpga() { +FCN_RETURN="" +return 0 +} +__temp_fpgaext() { +FCN_RETURN="" +return 0 +} +__temp_fpgafl() { +FCN_RETURN="" +return 0 +} +__temp_fpgafr() { +FCN_RETURN="" +return 0 +} +__temp_slowadc() { +FCN_RETURN="" +return 0 +} +__temp_sodl() { +FCN_RETURN="" +return 0 +} +__temp_sodr() { +FCN_RETURN="" +return 0 +} +__temp_threshold() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__templist() { +FCN_RETURN="" +return 0 +} +__tempvalues() { +FCN_RETURN="" +return 0 +} +__tengiga() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__threshold() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__thresholdnotb() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="`sls_detector_get settingslist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__timing() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="`sls_detector_get timinglist | sed -e 's/.*\[\(.*\)\].*/\1/' | sed 's/,//g'`" +fi +fi +return 0 +} +__timinglist() { +FCN_RETURN="" +return 0 +} +__timingsource() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="external internal" +fi +fi +return 0 +} +__top() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__transceiverenable() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__trigger() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__triggers() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__triggersl() { +FCN_RETURN="" +return 0 +} +__trimbits() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__trimen() { +FCN_RETURN="" +return 0 +} +__trimval() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__tsamples() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_frame() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_left() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__txdelay_right() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__type() { +FCN_RETURN="" +return 0 +} +__udp_cleardst() { +FCN_RETURN="" +return 0 +} +__udp_dstip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstip2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstlist() { +FCN_RETURN="" +return 0 +} +__udp_dstmac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstmac2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_dstport2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_firstdst() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_numdst() { +FCN_RETURN="" +return 0 +} +__udp_reconfigure() { +FCN_RETURN="" +return 0 +} +__udp_srcip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcip2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcmac() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_srcmac2() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__udp_validate() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__update() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatedetectorserver() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatekernel() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +IS_PATH=1 +fi +fi +return 0 +} +__updatemode() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__user() { +FCN_RETURN="" +return 0 +} +__v_a() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_b() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_c() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_chip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_d() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_io() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__v_limit() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_comp_adc() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_comp_fe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_cs() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_opa_1st() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_opa_fd() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vchip_ref_comp_fe() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__versions() { +FCN_RETURN="" +return 0 +} +__veto() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="0 1" +fi +fi +return 0 +} +__vetoalg() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="10gbe lll none" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="hits raw" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="10gbe lll none" +fi +fi +return 0 +} +__vetofile() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetophoton() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 1 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "4" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "5" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetoref() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vetostream() { +FCN_RETURN="" +return 0 +} +__virtual() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +if [[ "${cword}" == "3" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__vm_a() { +FCN_RETURN="" +return 0 +} +__vm_b() { +FCN_RETURN="" +return 0 +} +__vm_c() { +FCN_RETURN="" +return 0 +} +__vm_d() { +FCN_RETURN="" +return 0 +} +__vm_io() { +FCN_RETURN="" +return 0 +} +__zmqhwm() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__zmqip() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} +__zmqport() { +FCN_RETURN="" +if [[ ${IS_GET} -eq 0 ]]; then +if [[ "${cword}" == "2" ]]; then +FCN_RETURN="" +fi +fi +return 0 +} + + + local FCN_RETURN="" + local IS_PATH=0 + COMPREPLY=() + local OPTIONS_NEW="" + words=("${COMP_WORDS[@]}") + cword=$COMP_CWORD + + local cur=${words[cword]} + # check the action (get or put) + case "${words[0]}" in + "sls_detector_get" | "g" | "detg") + local IS_GET=1 + ;; + *) + local IS_GET=0 + ;; + esac + + # if no command is written, autocomplete with the commands + if [[ ${cword} -eq 1 ]]; then + + case "$cur" in + [0-9]*) + for i in $SLS_COMMANDS; do + SLS_COMMANDS_NEW="${SLS_COMMANDS_NEW} ${cur%%:*}:$i" + done + COMPREPLY=( $( compgen -W "${SLS_COMMANDS_NEW}" -- "$cur" ) );; + *) + COMPREPLY=( $( compgen -W "$SLS_COMMANDS -h" -- "$cur" ) );; + esac + return 0 + fi + + if [[ ${cword} -eq 2 ]] && [[ ${words[1]} == "-h" ]]; then + COMPREPLY=( $( compgen -W "$SLS_COMMANDS" -- "$cur" ) ) + return 0 + fi + + # if a command is written, autocomplete with the options + # call the function for the command + + if [[ "$SLS_COMMANDS" == *"${words[1]##*:}"* ]]; then + __"${words[1]##*:}" + fi + + # if IS_PATH is activated, autocomplete with the path + if [[ ${IS_PATH} -eq 1 ]]; then + COMPREPLY=($(compgen -f -- "${cur}")) + return 0 + fi + + # autocomplete with the options + COMPREPLY=($(compgen -W "${FCN_RETURN}" -- "${cur}")) + + + +} + +complete -F _sd -o filenames sls_detector_get +complete -F _sd -o filenames g +complete -F _sd -o filenames detg + +complete -F _sd -o filenames sls_detector_put +complete -F _sd -o filenames p +complete -F _sd -o filenames detp + +complete -F _sd -o filenames sls_detector +complete -F _sd -o filenames det diff --git a/slsDetectorSoftware/generator/commands.yaml b/slsDetectorSoftware/generator/commands.yaml new file mode 100644 index 000000000..68f3ca907 --- /dev/null +++ b/slsDetectorSoftware/generator/commands.yaml @@ -0,0 +1,4278 @@ +--- +# detectors: MYTHEN3 + +################# TEMPLATES ################# +TIME_COMMAND: + infer_action: true + help: "" + template: true + actions: + GET: + require_det_id: true + function: '' + args: + - argc: 0 + output: [ OutString(t) ] + - argc: 1 + arg_types: [ special::time_unit ] + output: [ "OutString(t , args[0])" ] + PUT: + function: '' + require_det_id: true + input: [ converted_time ] + input_types: [ time::ns ] + args: + - argc: 1 + arg_types: [ std::string ] + + separate_time_units: + input: 'args[0]' + output: [ converted_time, unit ] + output: [ 'args[0]' ] + - argc: 2 + arg_types: [ int, special::time_unit ] + + convert_to_time: + input: [ 'args[0]', 'args[1]' ] + output: converted_time + output: [ 'args[0]', 'args[1]' ] + +TIME_GET_COMMAND: + infer_action: true + help: "" + template: true + actions: + GET: + require_det_id: true + function: '' + args: + - argc: 0 + output: [ OutString(t) ] + - argc: 1 + arg_types: [ special::time_unit ] + output: [ "OutString(t , args[0])" ] + +STRING_COMMAND: + infer_action: true + help: "" + template: true + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + PUT: + function: '' + output: [ 'args.front()' ] + input: [ 'args[0]' ] + input_types: [ std::string ] + require_det_id: true + cast_input: [ false ] + argc: 1 + +INTEGER_COMMAND_HEX_WIDTH16: + infer_action: true + help: "" + template: true + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ "OutStringHex(t, 16)" ] + PUT: + require_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ uint64_t ] + output: [ "ToStringHex(arg0, 16)" ] + +INTEGER_COMMAND_HEX: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ "OutStringHex(t)" ] + PUT: + require_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ uint32_t ] + output: [ "args.front()" ] + +INTEGER_COMMAND_VEC_ID: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + PUT: + require_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ int ] + output: [ 'args.front()' ] + +INTEGER_COMMAND_VEC_ID_GET: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + PUT: + require_det_id: true + convert_det_id: false + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ int ] + output: [ 'args.front()' ] + +INTEGER_COMMAND_SET_NOID_GET_ID: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + PUT: + check_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ int ] + output: [ 'args.front()' ] + +INTEGER_COMMAND_NOID: + template: true + infer_action: true + help: "" + actions: + GET: + check_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + PUT: + check_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ true ] + input_types: [ int ] + output: [ 'args.front()' ] + +INTEGER_IND_COMMAND: + template: true + infer_action: true + help: "" + actions: + GET: + # extra variable to store the index + require_det_id: true + function: '' + argc: 0 + input: [ 'INDEX' ] + input_types: [ int ] + cast_input: [ false ] + output: [ OutString(t) ] + PUT: + # extra variable to store the index + function: '' + require_det_id: true + argc: 1 + input: [ 'INDEX', 'args[0]' ] + input_types: [ int, int ] + cast_input: [ false, true ] + output: [ 'args.front()' ] + +INTEGER_USER_IND_COMMAND: + template: true + infer_action: true + help: "" + actions: + GET: + # extra variable to store the index + require_det_id: true + function: '' + argc: 1 + input: [ 'INDEX', 'args[0]' ] + cast_input: [ false, true ] + input_types: [ int, int ] + output: [ 'args[0]', "' '", OutStringHex(t) ] + PUT: + # extra variable to store the index + function: '' + require_det_id: true + argc: 2 + input: [ 'INDEX', 'args[0]', 'args[1]' ] + cast_input: [ false, true, true ] + input_types: [ int, int , int ] + output: [ 'args[0]', "' '", 'args[1]' ] + +EXECUTE_SET_COMMAND_NOID: + template: true + infer_action: true + help: "" + actions: + PUT: + check_det_id: true + function: '' + output: [ '"successful"' ] + argc: 0 + +EXECUTE_SET_COMMAND: + template: true + infer_action: true + help: "" + actions: + PUT: + require_det_id: true + function: '' + output: [ '"successful"' ] + argc: 0 + +EXECUTE_SET_COMMAND_NOID_1ARG: + template: true + infer_action: true + help: "" + actions: + PUT: + check_det_id: true + function: '' + argc: 1 + input: [ 'args[0]' ] + cast_input: [ false ] + arg_types: [special::path] + input_types: [ std::string ] + output: [ 'args.front()' ] + +GET_COMMAND: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + output: [ OutString(t) ] + +GET_COMMAND_NOID: + template: true + infer_action: true + help: "" + actions: + GET: + function: '' + argc: 0 + output: [ ToString(t) ] + +GET_IND_COMMAND: + template: true + infer_action: true + help: "" + actions: + GET: + require_det_id: true + function: '' + argc: 0 + input: [ 'VAL' ] + cast_input: [ false ] + input_types: [ int ] + output: [ OutString(t) ] + +CTB_NAMED_LIST: + template: true + infer_action: true + actions: + GET: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + check_det_id: true + argc: 0 + output: [ 'ToString(t)' ] + PUT: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + - condition: 'cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type != defs::XILINX_CHIPTESTBOARD' + message: '"This detector already has fixed dac names. Cannot change them."' + check_det_id: true + input: [ 'args' ] + argc: -1 # unknown number of args + input_types: [ std::string ] + output: [ 'ToString(args)' ] + +CTB_SINGLE_DACNAME: + template: true + infer_action: true + actions: + GET: + extra_variables: + - name: index + type: defs::dacIndex + value: 0 + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + check_det_id: true + argc: 1 + input: [ "static_cast(StringTo(args[0]) + index)" ] + input_types: [ defs::dacIndex ] + output: [ 'args[0]',"' '", 't' ] + + PUT: + extra_variables: + - name: index + type: defs::dacIndex + value: 0 + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + check_det_id: true + argc: 2 + input: [ "static_cast(StringTo(args[0]) + index)","args[1]" ] + input_types: [ defs::dacIndex , std::string ] + output: [ 'ToString(args)' ] + +CTB_GET_DACINDEX: + template: true + infer_action: true + actions: + GET: + extra_variables: + - name: index + type: defs::dacIndex + value: 0 + + check_det_id: true + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + argc: 1 + input: [ 'args[0]' ] + input_types: [ std::string ] + output: [ 'ToString(static_cast(t) - index)' ] + +CTB_SINGLE_NAME: + template: true + infer_action: true + actions: + GET: + check_det_id: true + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + argc: 1 + input: [ "args[0]" ] + cast_input: [ true ] + input_types: [ int ] + output: [ 'args[0]',"' '", 't' ] + PUT: + check_det_id: true + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + argc: 2 + cast_input: [ true, false ] + input: [ "args[0]","args[1]" ] + input_types: [ int , std::string ] + output: [ 'ToString(args)' ] + +CTB_GET_INDEX: + template: true + infer_action: true + actions: + GET: + check_det_id: true + exceptions: + - condition: 'det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD' + message: 'cmd + " only allowed for CTB."' + argc: 1 + input: [ 'args[0]' ] + input_types: [ std::string ] + output: [ 'static_cast(t)' ] + + +################# COMMANDS ################################## +################# TIME_COMMAND ############# + +period: + help: "[duration] [(optional unit) ns|us|ms|s]\n\tPeriod between frames" + inherit_actions: TIME_COMMAND + actions: + GET: + function: getPeriod + PUT: + function: setPeriod + +delay: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb][Moench] Delay after trigger" + inherit_actions: TIME_COMMAND + actions: + GET: + function: getDelayAfterTrigger + PUT: + function: setDelayAfterTrigger + +subexptime: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Exposure time of EIGER subframes in 32 bit mode." + inherit_actions: TIME_COMMAND + actions: + GET: + function: getSubExptime + PUT: + function: setSubExptime + +subdeadtime: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Dead time of EIGER subframes in 32 bit mode. Subperiod = subexptime + subdeadtime." + inherit_actions: TIME_COMMAND + actions: + GET: + function: getSubDeadTime + PUT: + function: setSubDeadTime + +compdisabletime: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Jungfrau] Time before end of exposure when comparator is disabled. It is only possible for chipv1.1." + inherit_actions: TIME_COMMAND + actions: + GET: + function: getComparatorDisableTime + PUT: + function: setComparatorDisableTime + +storagecell_delay: + help: "[duration (0-1638375 ns)] [(optional unit) ns|us|ms|s]\n\t[Jungfrau] Additional time delay between 2 consecutive exposures in burst mode (resolution of 25ns). Only applicable for chipv1.0. For advanced users only." + inherit_actions: TIME_COMMAND + actions: + GET: + function: getStorageCellDelay + PUT: + function: setStorageCellDelay + +burstperiod: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Gotthard2] Period between 2 bursts. Only in burst mode and auto timing mode." + inherit_actions: TIME_COMMAND + actions: + GET: + function: getBurstPeriod + PUT: + function: setBurstPeriod + +################# TIME_GET_COMMAND ############# +delayl: + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Delay Left in Acquisition. \n\t[Gotthard2] only in continuous mode." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getDelayAfterTriggerLeft + +periodl: + help: "\n\t[Gotthard][Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Period left for current frame. \n\t[Gotthard2] only in continuous mode." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getPeriodLeft + +measuredperiod: + help: "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured frame period between last frame and previous one. Can be measured with minimum 2 frames in an acquisition." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getMeasuredPeriod + +measuredsubperiod: + help: "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured sub frame period between last sub frame and previous one." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getMeasuredSubFramePeriod + +exptimel: + help: "[(optional unit) ns|us|ms|s]\n\t[Gotthard] Exposure time left for current frame. " + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getExptimeLeft + +runtime: + help: "[(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Time from detector start up.\n\t[Gotthard2] not in burst and auto mode." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getActualTime + +frametime: + help: "[(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Timestamp at a frame start.\n\t[Gotthard2] not in burst and auto mode." + inherit_actions: TIME_GET_COMMAND + actions: + GET: + function: getMeasurementTime + +################# STRING_COMMAND ################# +settingspath: + help: "[path]\n\t[Eiger][Mythen3] Directory where settings files are loaded from/to." + inherit_actions: STRING_COMMAND + actions: + GET: + function: getSettingsPath + PUT: + function: setSettingsPath + arg_types: [ special::path ] + +fpath: + help: "[path]\n\tDirectory where output data files are written in receiver. Default is '/'. \n\tIf path does not exist, it will try to create it." + inherit_actions: STRING_COMMAND + actions: + GET: + function: getFilePath + PUT: + function: setFilePath + arg_types: [ special::path ] + +fname: + help: "[name]\n\tFile name prefix for output data file. Default is run. File name: [file name prefix]_d[detector index]_f[sub file index]_[acquisition/file index].raw." + inherit_actions: STRING_COMMAND + actions: + GET: + function: getFileNamePrefix + PUT: + function: setFileNamePrefix + +################# INTEGER_COMMAND_HEX_WIDTH16 ################# +patioctrl: + help: "[64 bit mask]\n\t[Ctb] 64 bit mask defining input (0) and output (1) signals." + inherit_actions: INTEGER_COMMAND_HEX_WIDTH16 + actions: + GET: + function: getPatternIOControl + PUT: + function: setPatternIOControl + +patmask: + help: "[64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] Selects the bits that will have a pattern mask applied to the selected patmask for every pattern." + inherit_actions: INTEGER_COMMAND_HEX_WIDTH16 + actions: + GET: + function: getPatternMask + PUT: + function: setPatternMask + +patsetbit: + help: "[64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] Sets the mask applied to every pattern to the selected bits." + inherit_actions: INTEGER_COMMAND_HEX_WIDTH16 + actions: + GET: + function: getPatternBitMask + PUT: + function: setPatternBitMask + +################# INTEGER_COMMAND_HEX ################# +adcenable: + help: "[bitmask]\n\t[Ctb] ADC Enable Mask for 1Gb Enable for each 32 ADC channel." + inherit_actions: INTEGER_COMMAND_HEX + actions: + GET: + function: getADCEnableMask + PUT: + function: setADCEnableMask + +adcenable10g: + help: "[bitmask]\n\t[Ctb] ADC Enable Mask for 10Gb mode for each 32 ADC channel. However, if any of a consecutive 4 bits are enabled, the complete 4 bits are enabled." + inherit_actions: INTEGER_COMMAND_HEX + actions: + GET: + function: getTenGigaADCEnableMask + PUT: + function: setTenGigaADCEnableMask + +transceiverenable: + help: "[bitmask]\n\t[Ctb] Transceiver Enable Mask. Enable for each 4 Transceiver channel." + inherit_actions: INTEGER_COMMAND_HEX + actions: + GET: + function: getTransceiverEnableMask + PUT: + function: setTransceiverEnableMask + +adcinvert: + help: "[bitmask]\n\t[Ctb][Jungfrau][Moench] ADC Inversion Mask.\n\t[Jungfrau][Moench] Inversions on top of the default mask." + inherit_actions: INTEGER_COMMAND_HEX + actions: + GET: + function: getADCInvert + PUT: + function: setADCInvert + +################# INTEGER_COMMAND_VEC_ID ################# +settings: + help: "[standard, fast, highgain, dynamicgain, lowgain, mediumgain, veryhighgain, highgain0, fixgain1, fixgain2, forceswitchg1, forceswitchg2, verylowgain, g1_hg, g1_lg, g2_hc_hg, g2_hc_lg, g2_lc_hg, g2_lc_lg, g4_hg, g4_lg, gain0]\n\t Detector Settings\n\t[Jungfrau] - [ gain0 | highgain0]\n\t[Gotthard] - [dynamicgain | highgain | lowgain | mediumgain | veryhighgain]\n\t[Gotthard] Also loads default dacs on to the detector.\n\t[Gotthard2] - [dynamicgain | fixgain1 | fixgain2]\n\t[Mythen3] - [standard | fast | highgain] Also changes vrshaper and vrpreamp. \n\t[Eiger] Use threshold or thresholdnotb. \n\t[Eiger] threshold and settings loaded from file found in settingspath. \n\t[Moench] - [g1_hg | g1_lg | g2_hc_hg | g2_hc_lg | g2_lc_hg | g2_lc_lg | g4_hg | g4_lg]" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getSettings + PUT: + function: setSettings + input_types: [ defs::detectorSettings ] + +trimval: + help: "[n_trimval]\n\t[Eiger][Mythen3] All trimbits set to this value. Returns -1 if all trimbits are different values." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getAllTrimbits + PUT: + function: setAllTrimbits + +fliprows: + help: "[0, 1]\n\t[Eiger] flips rows paramater sent to slsreceiver to stream as json parameter to flip rows in gui \n\t[Jungfrau][Moench] flips rows in the detector itself. For bottom module and number of interfaces must be set to 2. slsReceiver and slsDetectorGui does not handle." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFlipRows + PUT: + function: setFlipRows + input_types: [ bool ] + +row: + inherit_actions: INTEGER_COMMAND_VEC_ID + help: "[value]\n\tSet Detector row (udp header) to value. \n\tGui uses it to rearrange for complete image" + actions: + GET: + function: getRow + PUT: + function: setRow + +column: + help: "[value]\n\tSet Detector column (udp header) to value. \n\tGui uses it to rearrange for complete image" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getColumn + PUT: + function: setColumn + +timing: + help: "[auto|trigger|gating|burst_trigger]\n\tTiming Mode of detector.\n\t[Jungfrau][Moench][Gotthard][Ctb][Gotthard2][Xilinx Ctb] [auto|trigger]\n\t[Mythen3] [auto|trigger|gating|trigger_gating]\n\t[Eiger] [auto|trigger|gating|burst_trigger]" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTimingMode + PUT: + function: setTimingMode + input_types: [ defs::timingMode ] + +highvoltage: + help: "[n_value]\n\tHigh voltage to the sensor in Voltage. \n\t[Gotthard] [0|90|110|120|150|180|200] \n\t[Eiger][Mythen3][Gotthard2] 0-200 \n\t[Jungfrau][Moench][Ctb] [0|60-200]" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getHighVoltage + PUT: + function: setHighVoltage + +powerchip: + help: "[0, 1]\n\t[Jungfrau][Moench][Mythen3][Gotthard2] Power the chip. \n\t[Jungfrau][Moench] Default is 0. Get will return power status. Can be off if temperature event occured (temperature over temp_threshold with temp_control enabled. Will configure chip (only chip v1.1)\n\t[Mythen3][Gotthard2] Default is 1. If module not connected or wrong module, powerchip will fail." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getPowerChip + PUT: + function: setPowerChip + input_types: [ bool ] + +imagetest: + help: "[0, 1]\n\t[Gotthard] 1 adds channel intensity with precalculated values when taking an acquisition. Default is 0.\n\t[Eiger][Jungfrau][Moench] Only for Virtual servers. If 0, each pixel intensity incremented by 1. If 1, all pixels almost saturated." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getImageTestMode + PUT: + function: setImageTestMode + input_types: [ bool ] + +parallel: + help: "[0, 1]\n\t[Eiger][Mythen3][Gotthard2][Moench] Enable or disable parallel mode.\n\t[Mythen3] If exptime is too short, the acquisition will return ERROR status and take fewer frames than expected.\n\t[Mythen3][Eiger][Moench] Default: Non parallel.\n\t[Gotthard2] Default: Parallel. Non parallel mode works only in continuous mode." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getParallelMode + PUT: + function: setParallelMode + input_types: [ bool ] + +filterresistor: + help: "[value] [Gotthard2][Jungfrau] Set filter resistor. Increasing values for increasing resistance.\n\t[Gotthard2] Options: [0|1|2|3]. Default is 0.\n\t[Jungfrau] Options: [0|1]. Default is 1." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFilterResistor + PUT: + function: setFilterResistor + +dbitpipeline: + help: "[n_value]\n\t[Ctb][Gotthard2] Pipeline of the clock for latching digital bits.\n\t[Gotthard2] Options: 0-7\n\t[Ctb] Options: 0-255" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDBITPipeline + PUT: + function: setDBITPipeline + +readnrows: + help: "\n\t[1-256]\n\t\t[Eiger] Number of rows to readout per half module starting from the centre. Options: 0 - 256. 256 is default. The permissible values depend on dynamic range and 10Gbe enabled.\n\t[8-512 (multiple of 8)]\n\t\t[Jungfrau] Number of rows per module starting from the centre. Options: 8 - 512, must be multiples of 8. Default is 512.\n\t\t[Moench] Number of rows per module starting from the centre. Options:16 - 400, must be multiples of 16. Default is 400." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getReadNRows + PUT: + function: setReadNRows + +nextframenumber: + help: "[n_value]\n\t[Eiger][Jungfrau][Moench][Ctb] Next frame number. Stopping acquisition might result in different frame numbers for different modules." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNextFrameNumber + PUT: + function: setNextFrameNumber + input_types: [ uint64_t ] + +numinterfaces: + help: "[1, 2]\n\t[Jungfrau][Moench] Number of udp interfaces to stream data from detector. Default: 1.\n\tAlso enables second interface in receiver for listening (Writes a file per interface if writing enabled).\n\tAlso restarts client and receiver zmq sockets if zmq streaming enabled.\n\t[Eiger] Only gets with result 2." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberofUDPInterfaces + PUT: + function: setNumberofUDPInterfaces + +selinterface: + help: "[0, 1]\n\t[Jungfrau][Moench] The udp interface to stream data from detector. Effective only when number of interfaces is 1. Default: 0 (outer)" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getSelectedUDPInterface + PUT: + function: selectUDPInterface + input_types: [ bool ] + +udp_firstdst: + help: "\n[0 - 31 (or number of udp destinations)]\n\t[Jungfrau][Moench][Gotthard2]\n[0-63]\n\t[Mythen3]\n\n\t One can set which is the first destination that the detector will stream images out from in a round robin fashion. The entry must not have been empty. Default: 0" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFirstUDPDestination + PUT: + function: setFirstUDPDestination + +udp_srcmac: + help: "[x:x:x:x:x:x]\n\tMac address of the detector (source) udp interface. \n\t[Eiger] Do not set as detector will replace with its own DHCP Mac (1G) or DHCP Mac + 1 (10G)." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getSourceUDPMAC + PUT: + function: setSourceUDPMAC + input_types: [ MacAddr ] + input: [ 'MacAddr(args[0])' ] + cast_input: [ false ] + +udp_srcmac2: + help: "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the top half or inner (source) udp interface. " + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getSourceUDPMAC2 + PUT: + function: setSourceUDPMAC2 + input_types: [ MacAddr ] + input: [ 'MacAddr(args[0])' ] + cast_input: [ false ] + +udp_dstmac: + help: "[x:x:x:x:x:x]\n\tMac address of the receiver (destination) udp interface. Not mandatory to set as udp_dstip retrieves it from slsReceiver process, but must be set if you use a custom receiver (not slsReceiver). Use router mac if router between detector and receiver." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDestinationUDPMAC + PUT: + function: setDestinationUDPMAC + input_types: [ MacAddr ] + input: [ 'MacAddr(args[0])' ] + cast_input: [ false ] + +udp_dstmac2: + help: "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the receiver (destination) udp interface 2. Not mandatory to set as udp_dstip2 retrieves it from slsReceiver process but must be set if you use a custom receiver (not slsReceiver). \n\t [Jungfrau][Moench] top half or inner interface \n\t [Gotthard2] veto debugging. Use router mac if router between detector and receiver." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDestinationUDPMAC2 + PUT: + function: setDestinationUDPMAC2 + input_types: [ MacAddr ] + input: [ 'MacAddr(args[0])' ] + cast_input: [ false ] + +tengiga: + help: "[0, 1]\n\t[Eiger][Ctb][Mythen3] 10GbE Enable." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTenGiga + PUT: + function: setTenGiga + input_types: [ bool ] + +flowcontrol10g: + help: "[0, 1]\n\t[Eiger][Jungfrau][Moench] 10GbE Flow Control." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTenGigaFlowControl + PUT: + function: setTenGigaFlowControl + input_types: [ bool ] + +txdelay_frame: + help: "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Transmission delay of first udp packet being streamed out of the module.\n\t[Jungfrau][Moench] [0-31] Each value represents 1 ms\n\t[Eiger] Additional delay to txdelay_left and txdelay_right. Each value represents 10ns. Typical value is 50000.\n\t[Mythen3] [0-16777215] Each value represents 8 ns (125 MHz clock), max is 134 ms." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTransmissionDelayFrame + PUT: + function: setTransmissionDelayFrame + +txdelay_left: + help: "[n_delay]\n\t[Eiger] Transmission delay of first packet in an image being streamed out of the module's left UDP port. Each value represents 10ns. Typical value is 50000." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTransmissionDelayLeft + PUT: + function: setTransmissionDelayLeft + +txdelay_right: + help: "[n_delay]\n\t[Eiger] Transmission delay of first packet in an image being streamed out of the module's right UDP port. Each value represents 10ns. Typical value is 50000." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTransmissionDelayRight + PUT: + function: setTransmissionDelayRight + +rx_fifodepth: + help: "[n_frames]\n\tSet the number of frames in the receiver fifo depth (buffer between listener and writer threads)." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxFifoDepth + PUT: + function: setRxFifoDepth + +rx_silent: + help: "[0, 1]\n\tSwitch on or off receiver text output during acquisition." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxSilentMode + PUT: + function: setRxSilentMode + input_types: [ bool ] + +rx_discardpolicy: + help: "[nodiscard (default)|discardempty|discardpartial(fastest)]\n\tFrame discard policy of receiver. nodiscard does not discard frames, discardempty discards empty frames, discardpartial discards partial frames." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxFrameDiscardPolicy + PUT: + function: setRxFrameDiscardPolicy + input_types: [ defs::frameDiscardPolicy ] + +rx_padding: + help: "[0, 1]\n\tPartial frames padding enable in the receiver. Default: enabled. Disabling is fastest." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getPartialFramesPadding + PUT: + function: setPartialFramesPadding + input_types: [ bool ] + +rx_udpsocksize: + help: "[n_size]\n\tUDP socket buffer size in receiver. Tune rmem_default and rmem_max accordingly. Max value is INT_MAX/2." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxUDPSocketBufferSize + PUT: + function: setRxUDPSocketBufferSize + +rx_lock: + help: "[0, 1]\n\tLock receiver to one client IP, 1 locks, 0 unlocks. Default is unlocked." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxLock + PUT: + function: setRxLock + input_types: [ bool ] + +rx_arping: + help: "[0, 1]\n\tStarts a thread in slsReceiver to arping the interface it is listening to every minute. Useful in 10G mode." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxArping + PUT: + function: setRxArping + input_types: [ bool ] + +fformat: + help: "[binary|hdf5]\n\tFile format of data file. For HDF5, package must be compiled with HDF5 flags. Default is binary." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFileFormat + PUT: + function: setFileFormat + input_types: [ defs::fileFormat ] + +findex: + help: "[n_value]\n\tFile or Acquisition index." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getAcquisitionIndex + PUT: + function: setAcquisitionIndex + input_types: [ uint64_t ] + +fwrite: + help: "[0, 1]\n\tEnable or disable receiver file write. Default is 1." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFileWrite + PUT: + function: setFileWrite + input_types: [ bool ] + +foverwrite: + help: "[0, 1]\n\tEnable or disable file overwriting. Default is 1." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFileOverWrite + PUT: + function: setFileOverWrite + input_types: [ bool ] + +rx_framesperfile: + help: "[n_frames]\n\tNumber of frames per file in receiver in an acquisition. Default depends on detector type. 0 is infinite or all frames in single file." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getFramesPerFile + PUT: + function: setFramesPerFile + +rx_zmqstream: + help: "[0, 1]\n\tEnable/ disable data streaming from receiver via zmq (eg. to GUI or to another process for further processing). This creates/ destroys zmq streamer threads in receiver. \n\tSwitching to Gui automatically enables data streaming in receiver. \n\tSwitching back to command line acquire will require disabling data streaming in receiver for fast applications. " + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxZmqDataStream + PUT: + function: setRxZmqDataStream + input_types: [ bool ] + +rx_zmqfreq: + help: "[nth frame]\n\tFrequency of frames streamed out from receiver via zmq\n\tDefault: 1, Means every frame is streamed out. \n\tIf 2, every second frame is streamed out. \n\tIf 0, streaming timer is the timeout, after which current frame is sent out. (default timeout is 500 ms). Usually used for gui purposes." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxZmqFrequency + PUT: + function: setRxZmqFrequency + +rx_zmqstartfnum: + help: "[fnum]\n\tThe starting frame index to stream out. 0 by default, which streams the first frame in an acquisition, and then depending on the rx zmq frequency/ timer" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxZmqStartingFrame + PUT: + function: setRxZmqStartingFrame + +rx_zmqip: + help: "[x.x.x.x]\n\tZmq Ip Address from which data is to be streamed out of the receiver. Also restarts receiver zmq streaming if enabled. Default is from rx_hostname. Modified only when using an intermediate process between receiver." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxZmqIP + PUT: + function: setRxZmqIP + input_types: [ IpAddr ] + input: [ 'IpAddr(args[0])' ] + cast_input: [ false ] + +zmqip: + help: "[x.x.x.x]\n\tIp Address to listen to zmq data streamed out from receiver or intermediate process. Default connects to receiver zmq Ip Address (from rx_hostname). Modified only when using an intermediate process between receiver and client(gui). Also restarts client zmq streaming if enabled." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getClientZmqIp + PUT: + function: setClientZmqIp + input_types: [ IpAddr ] + input: [ 'IpAddr(args[0])' ] + cast_input: [ false ] + +overflow: + help: "[0, 1]\n\t[Eiger] Enable or disable show overflow flag in 32 bit mode. Default is disabled." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getOverFlowMode + PUT: + function: setOverFlowMode + input_types: [ bool ] + +interruptsubframe: + help: "[0, 1]\n\t[Eiger] 1 interrupts last subframe at required exposure time. 0 will wait for last sub frame to finish exposing. 0 is default." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getInterruptSubframe + PUT: + function: setInterruptSubframe + input_types: [ bool ] + +activate: + help: "[0, 1] \n\t[Eiger] 1 is default. 0 deactivates readout and does not send data." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getActive + PUT: + function: setActive + input_types: [ bool ] + +partialreset: + help: "[0, 1]\n\t[Eiger] Sets up detector to do partial or complete reset at start of acquisition. 0 complete reset, 1 partial reset. Default is complete reset. Advanced function!" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getPartialReset + PUT: + function: setPartialReset + input_types: [ bool ] + +top: + help: "[0, 1]\n\t[Eiger] Sets half module to top (1), else bottom." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTop + PUT: + function: setTop + input_types: [ bool ] + +temp_threshold: + help: "[n_temp (in degrees)]\n\t[Jungfrau][Moench] Threshold temperature in degrees. If temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getThresholdTemperature + PUT: + function: setThresholdTemperature + +temp_control: + help: "[0, 1]\n\t[Jungfrau][Moench] Temperature control enable. Default is 0 (disabled). If temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTemperatureControl + PUT: + function: setTemperatureControl + input_types: [ bool ] + +autocompdisable: + help: "[0, 1]\n\t[Jungfrau] Auto comparator disable mode. By default, the on-chip gain switching is active during the entire exposure.This mode disables the on - chip gain switching comparator automatically after 93.75% (only for chipv1.0) of exposure time (only for longer than 100us). It is possible to set the duration for chipv1.1 using compdisabletime command.\n\tDefault is 0 or this mode disabled(comparator enabled throughout). 1 enables mode. 0 disables mode. " + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getAutoComparatorDisable + PUT: + function: setAutoComparatorDisable + input_types: [ bool ] + +storagecell_start: + help: "[0-max]\n\t[Jungfrau] Storage cell that stores the first acquisition of the series. max is 15 (default) for chipv1.0 and 3 (default) for chipv1.1. For advanced users only." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getStorageCellStart + PUT: + function: setStorageCellStart + +gainmode: + help: "[dynamicgain|forceswitchg1|forceswitchg2|fixg1|fixg2|fixg0]\n\t[Jungfrau] Gain mode.\n\tCAUTION: Do not use fixg0 without caution, you can damage the detector!!!" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getGainMode + PUT: + function: setGainMode + input_types: [ defs::gainMode ] + +filtercells: + help: "[0-12]\n\t[Jungfrau] Set Filter Cell. Only for chipv1.1. Advanced user Command" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberOfFilterCells + PUT: + function: setNumberOfFilterCells + +cdsgain: + help: "[0, 1]\n\t[Gotthard2] Enable or disable CDS gain. Default is disabled." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getCDSGain + PUT: + function: setCDSGain + input_types: [ bool ] + +timingsource: + help: "[internal|external]\n\t[Gotthard2] Timing source. Internal is crystal and external is system timing. Default is internal." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getTimingSource + PUT: + function: setTimingSource + input_types: [ defs::timingSourceType ] + +veto: + help: "[0, 1]\n\t[Gotthard2] Enable or disable veto data data from chip. Default is 0." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getVeto + PUT: + function: setVeto + input_types: [ bool ] + +gates: + help: "[n_gates]\n\t[Mythen3] Number of external gates in gating or trigger_gating mode (external gating)." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberOfGates + PUT: + function: setNumberOfGates + +polarity: + help: "[pos|neg]\n\t[Mythen3] Sets negative or positive polarity. Default is positive" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getPolarity + PUT: + function: setPolarity + input_types: [ defs::polarity ] + +interpolation: + help: "[0, 1]\n\t[Mythen3] Enables or disables interpolation. Default is disabled. Interpolation mode enables all counters and disables vth3. Disabling sets back counter mask and vth3." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getInterpolation + PUT: + function: setInterpolation + input_types: [ bool ] + +pumpprobe: + help: "[0, 1]\n\t[Mythen3] Enables or disables pump probe mode. Default is disabled. Pump probe mode only enables vth2. Disabling sets back to previous value." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getPumpProbe + PUT: + function: setPumpProbe + input_types: [ bool ] + +apulse: + help: "[0, 1]\n\t[Mythen3] Enables or disables analog pulsing. Default is disabled" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getAnalogPulsing + PUT: + function: setAnalogPulsing + input_types: [ bool ] + +dpulse: + help: "[0, 1]\n\t[Mythen3] Enables or disables digital pulsing. Default is disabled" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDigitalPulsing + PUT: + function: setDigitalPulsing + input_types: [ bool ] + +asamples: + help: "[n_samples]\n\t[Ctb] Number of analog samples expected." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberOfAnalogSamples + PUT: + function: setNumberOfAnalogSamples + +adcclk: + help: "[n_clk in MHz]\n\t[Ctb] ADC clock frequency in MHz." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getADCClock + PUT: + function: setADCClock + +runclk: + help: "[n_clk in MHz]\n\t[Ctb] Run clock in MHz." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRUNClock + PUT: + function: setRUNClock + +dsamples: + help: "[n_value]\n\t[Ctb] Number of digital samples expected." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberOfDigitalSamples + PUT: + function: setNumberOfDigitalSamples + +tsamples: + help: "[n_value]\n\t[Ctb] Number of transceiver samples expected." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getNumberOfTransceiverSamples + PUT: + function: setNumberOfTransceiverSamples + +romode: + help: "[analog|digital|analog_digital|transceiver|digital_transceiver]\n\t[Ctb] Readout mode. Default is analog." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getReadoutMode + PUT: + function: setReadoutMode + input_types: [ defs::readoutMode ] + +dbitclk: + help: "[n_clk in MHz]\n\t[Ctb] Clock for latching the digital bits in MHz." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDBITClock + PUT: + function: setDBITClock + +extsampling: + help: "[0, 1]\n\t[Ctb] Enable for external sampling signal for digital data to signal by extsampling src command. For advanced users only." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getExternalSampling + PUT: + function: setExternalSampling + input_types: [ bool ] + +extsamplingsrc: + help: "[0-63]\n\t[Ctb] Sampling source signal for digital data. For advanced users only." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getExternalSamplingSource + PUT: + function: setExternalSamplingSource + +rx_dbitoffset: + help: "[n_bytes]\n\t[Ctb] Offset in bytes in digital data to skip in receiver." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getRxDbitOffset + PUT: + function: setRxDbitOffset + +led: + help: "[0, 1]\n\t[Ctb] Switches on/off all LEDs." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getLEDEnable + PUT: + function: setLEDEnable + input_types: [ bool ] + +adcpipeline: + help: "[n_value]\n\t[Ctb][Moench] Pipeline for ADC clock." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getADCPipeline + PUT: + function: setADCPipeline + +updatemode: + help: "[0|1]\n\tRestart the detector server in update mode or not. This is useful when server-firmware compatibility is at its worst and server cannot start up normally" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getUpdateMode + PUT: + function: setUpdateMode + +port: + help: "[n]\n\tPort number of the control server on detector for detector-client tcp interface. Default is 1952. Normally unchanged. Set different ports for virtual servers on same pc." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getControlPort + PUT: + input_types: [ uint16_t ] + function: setControlPort + +stopport: + help: "[n]\n\tPort number of the stop server on detector for detector-client tcp interface. Default is 1953. Normally unchanged." + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getStopPort + PUT: + input_types: [ uint16_t ] + function: setStopPort + +lock: + help: "[0, 1]\n\tLock detector to one IP, 1: locks. Default is unlocked" + inherit_actions: INTEGER_COMMAND_VEC_ID + actions: + GET: + function: getDetectorLock + PUT: + function: setDetectorLock + input_types: [ bool ] + +################# INTEGER_COMMAND_VEC_ID_GET ################# + +master: + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + help: "[0, 1]\n\t[Eiger][Gotthard2][Jungfrau][Moench] Sets (half) module to master and other(s) to slaves.\n\t[Gotthard][Gotthard2][Mythen3][Eiger][Jungfrau][Moench] Gets if the current (half) module is master." + actions: + GET: + function: getMaster + PUT: + function: setMaster + input_types: [ bool ] + +udp_dstport: + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + help: "[n]\n\tPort number of the receiver (destination) udp interface. Default is 50001. \n\tIf multi command, ports for each module is calculated (incremented by 1 if no 2nd interface)" + actions: + GET: + function: getDestinationUDPPort + PUT: + input_types: [ uint16_t ] + function: setDestinationUDPPort + +udp_dstport2: + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + help: "[n]\n\t[Jungfrau][Moench][Eiger][Gotthard2] Port number of the receiver (destination) udp interface 2. Default is 50002. \n\tIf multi command, ports for each module is calculated (incremented by 2) \n\t[Jungfrau][Moench] top half or inner interface \n\t[Eiger] right half \n\t[Gotthard2] veto debugging" + actions: + GET: + function: getDestinationUDPPort2 + PUT: + input_types: [ uint16_t ] + function: setDestinationUDPPort2 + +rx_tcpport: + help: "[port]\n\tTCP port for client-receiver communication. Default is 1954. Must be different if multiple receivers on same pc. Must be first command to set a receiver parameter. Multi command will automatically increment for individual modules." + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + actions: + GET: + function: getRxPort + PUT: + input_types: [ uint16_t ] + function: setRxPort + +rx_zmqport: + help: "[port]\n\tZmq port for data to be streamed out of the receiver. Also restarts receiver zmq streaming if enabled. Default is 30001. Modified only when using an intermediate process between receiver and client(gui). Must be different for every detector (and udp port). Multi command will automatically increment for individual modules." + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + actions: + GET: + function: getRxZmqPort + PUT: + input_types: [ uint16_t ] + function: setRxZmqPort + +zmqport: + help: "[port]\n\tZmq port in client(gui) or intermediate process for data to be streamed to from receiver. Default connects to receiver zmq streaming out port (30001). Modified only when using an intermediate process between receiver and client(gui). Also restarts client zmq streaming if enabled. Must be different for every detector (and udp port). Multi command will automatically increment for individual modules." + inherit_actions: INTEGER_COMMAND_VEC_ID_GET + actions: + GET: + function: getClientZmqPort + PUT: + input_types: [ uint16_t ] + function: setClientZmqPort + +################# INTEGER_COMMAND_SET_NOID_GET_ID ############ +sync: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[0, 1]\n\t[Jungfrau][Moench] Enables or disables synchronization between modules. Sync mode requires at least one master configured. Also requires flatband cabling between master and slave with termination board." + actions: + GET: + function: getSynchronization + PUT: + function: setSynchronization + input_types: [ bool ] + +frames: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[n_frames]\n\tNumber of frames per acquisition. In trigger mode, number of frames per trigger. \n\tCannot be set in modular level. \n\tIn scan mode, number of frames is set to number of steps.\n\t[Gotthard2] Burst mode has a maximum of 2720 frames." + actions: + GET: + function: getNumberOfFrames + PUT: + function: setNumberOfFrames + input_types: [ int64_t ] + +triggers: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[n_triggers]\n\tNumber of triggers per aquire. Set timing mode to use triggers." + actions: + GET: + function: getNumberOfTriggers + PUT: + function: setNumberOfTriggers + input_types: [ int64_t ] + +dr: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[value]\n\tDynamic Range or number of bits per pixel in detector.\n\t[Eiger] Options: 4, 8, 12, 16, 32. If set to 32, also sets clkdivider to 2, else to 0.\n\t[Mythen3] Options: 8, 16, 32\n\t[Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2][Xilinx Ctb] 16" + actions: + GET: + function: getDynamicRange + PUT: + function: setDynamicRange + +rx_zmqhwm: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[n_value]\n\tReceiver's zmq send high water mark. Default is the zmq library's default (1000). This is a high number and can be set to 2 for gui purposes. One must also set the client's receive high water mark to similar value. Final effect is sum of them. Also restarts receiver zmq streaming if enabled. Can set to -1 to set default value." + actions: + GET: + function: getRxZmqHwm + PUT: + function: setRxZmqHwm + +extrastoragecells: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[0-15]\n\t[Jungfrau] Only for chipv1.0. Number of additional storage cells. Default is 0. For advanced users only. \n\tThe #images = #frames x #triggers x (#extrastoragecells + 1)." + actions: + GET: + function: getNumberOfAdditionalStorageCells + PUT: + function: setNumberOfAdditionalStorageCells + +bursts: + inherit_actions: INTEGER_COMMAND_SET_NOID_GET_ID + help: "[n_bursts]\n\t[Gotthard2] Number of bursts per aquire. Only in auto timing mode and burst mode. Use timing command to set timing mode and burstmode command to set burst mode." + actions: + GET: + function: getNumberOfBursts + PUT: + function: setNumberOfBursts + input_types: [ int64_t ] + +################# INTEGER_COMMAND_NOID ####################### +fmaster: + inherit_actions: INTEGER_COMMAND_NOID + help: "[0, 1]\n\tEnable or disable receiver master file. Default is 1." + actions: + GET: + function: getMasterFileWrite + PUT: + function: setMasterFileWrite + input_types: [ bool ] + +################# INTEGER_IND_COMMAND ####################### +v_limit: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Soft limit for power supplies (ctb only) and DACS in mV." + actions: + GET: + function: getPower + input: [ 'defs::V_LIMIT' ] + PUT: + function: setPower + input: [ 'defs::V_LIMIT', 'args[0]' ] + +v_a: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply a in mV." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_A' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_A', 'args[0]' ] + +v_b: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply b in mV." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_B' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_B', 'args[0]' ] + +v_c: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply c in mV." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_C' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_C', 'args[0]' ] + +v_d: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply d in mV." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_D' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_D', 'args[0]' ] + +v_io: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply io in mV. Minimum 1200 mV. Must be the first power regulator to be set after fpga reset (on-board detector server start up)." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_IO' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_IO', 'args[0]' ] + +v_chip: + inherit_actions: INTEGER_IND_COMMAND + help: "[n_value]\n\t[Ctb] Power supply chip in mV. Do not use it unless you are completely sure you will not fry the board." + actions: + GET: + function: getPower + input: [ 'defs::V_POWER_CHIP' ] + PUT: + function: setPower + input: [ 'defs::V_POWER_CHIP', 'args[0]' ] + +################# INTEGER_USER_IND_COMMAND ################### +vchip_comp_fe: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac for comparator current of analogue front end." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VB_COMP_FE', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VB_COMP_FE', 'args[0]', 'args[1]' ] + +vchip_opa_1st: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac for opa current for driving the other DACs in chip." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VB_OPA_1ST', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VB_OPA_1ST', 'args[0]', 'args[1]' ] + +vchip_opa_fd: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac current for CDS opa stage." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VB_OPA_FD', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VB_OPA_FD', 'args[0]', 'args[1]' ] + +vchip_comp_adc: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac for comparator current of ADC." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VB_COMP_ADC', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VB_COMP_ADC', 'args[0]', 'args[1]' ] + +vchip_ref_comp_fe: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac for reference voltage of the comparator of analogue front end." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VREF_COMP_FE', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VREF_COMP_FE', 'args[0]', 'args[1]' ] + +vchip_cs: + inherit_actions: INTEGER_USER_IND_COMMAND + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac for current injection into preamplifier." + actions: + GET: + function: getOnChipDAC + input: [ 'defs::VB_CS', 'args[0]' ] + PUT: + function: setOnChipDAC + input: [ 'defs::VB_CS', 'args[0]', 'args[1]' ] + +################# EXECUTE_SET_COMMAND_NOID ####################### +clearbusy: + inherit_actions: EXECUTE_SET_COMMAND_NOID + help: "\n\tIf acquisition aborted during acquire command, use this to clear acquiring flag in shared memory before starting next acquisition" + actions: + PUT: + function: clearAcquiringFlag + +rx_start: + inherit_actions: EXECUTE_SET_COMMAND_NOID + help: "\n\tStarts receiver listener for detector data packets and create a data file (if file write enabled)." + actions: + PUT: + function: startReceiver + +rx_stop: + inherit_actions: EXECUTE_SET_COMMAND_NOID + help: "\n\tStops receiver listener for detector data packets and closes current data file (if file write enabled)." + actions: + PUT: + function: stopReceiver + +readout: + inherit_actions: EXECUTE_SET_COMMAND_NOID + help: "\n\t[Mythen3] Starts detector readout. Status changes to TRANSMITTING and automatically returns to idle at the end of readout." + actions: + PUT: + function: startDetectorReadout + +rx_clearroi: + inherit_actions: EXECUTE_SET_COMMAND_NOID + help: "Resets Region of interest in receiver. Default is all channels/pixels enabled." + actions: + PUT: + function: clearRxROI + +################# EXECUTE_SET_COMMAND ######################## +start: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\tStarts detector acquisition. Status changes to RUNNING or WAITING and automatically returns to idle at the end of acquisition. If the acquisition was abruptly stopped, some detectors come back to STOPPED." + actions: + PUT: + function: startDetector + +stop: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\tAbort detector acquisition. Status changes to IDLE or STOPPED. Goes to stop server." + actions: + PUT: + function: stopDetector + +udp_cleardst: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\tClears udp destination details on the detector." + actions: + PUT: + function: clearUDPDestinations + +udp_reconfigure: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\tReconfigures Detector with UDP destination. More for debugging as the configuration is done automatically when the detector has sufficient UDP details." + actions: + PUT: + function: reconfigureUDPDestination + +udp_validate: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\tValidates that UDP configuration in the detector is valid. If not configured, it will throw with error message requesting missing udp information." + actions: + PUT: + function: validateUDPConfiguration + +clearroi: + inherit_actions: EXECUTE_SET_COMMAND + help: "[Gotthard] Resets Region of interest in detector. All channels enabled. Default is all channels enabled." + actions: + PUT: + function: clearROI + +defaultpattern: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Mythen3] Loads and runs default pattern in pattern generator. It is to go back to initial settings." + actions: + PUT: + function: loadDefaultPattern + +patternstart: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Mythen3] Starts Pattern" + actions: + PUT: + function: startPattern + +resetfpga: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Jungfrau][Moench][Ctb] Reset FPGA." + actions: + PUT: + function: resetFPGA + +rebootcontroller: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Jungfrau][Moench][Ctb][Gotthard][Mythen3][Gotthard2] Reboot controller of detector." + actions: + PUT: + function: rebootController + +firmwaretest: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Firmware test, ie. reads a read fixed pattern from a register." + actions: + PUT: + function: executeFirmwareTest + +bustest: + inherit_actions: EXECUTE_SET_COMMAND + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Bus test, ie. Writes different values in a R/W register and confirms the writes to check bus.\n\tAdvanced User function!" + actions: + PUT: + function: executeBusTest + +################# EXECUTE_SET_COMMAND_NOID_1ARG ############## +config: + inherit_actions: EXECUTE_SET_COMMAND_NOID_1ARG + help: "\n\tFrees shared memory before loading configuration file. Set up once." + actions: + PUT: + function: loadConfig + +parameters: + inherit_actions: EXECUTE_SET_COMMAND_NOID_1ARG + help: "\n\tSets detector measurement parameters to those contained in fname. Set up per measurement." + actions: + PUT: + function: loadParameters + +savepattern: + inherit_actions: EXECUTE_SET_COMMAND_NOID_1ARG + help: "\n\t[Ctb][Mythen3][Xilinx Ctb] Saves pattern to file (ascii). \n\t[Ctb] Also executes pattern." + actions: + PUT: + function: savePattern + +################# GET_COMMAND ################################ +detectorserverversion: + inherit_actions: GET_COMMAND + help: "\n\tOn-board detector server software version" + actions: + GET: + function: getDetectorServerVersion + +hardwareversion: + inherit_actions: GET_COMMAND + help: "\n\tHardware version of detector. \n\t[Eiger] Hardware version of front FPGA on detector." + actions: + GET: + function: getHardwareVersion + +kernelversion: + inherit_actions: GET_COMMAND + help: "\n\tGet kernel version on the detector including time and date." + actions: + GET: + function: getKernelVersion + +rx_version: + inherit_actions: GET_COMMAND + help: "\n\tReceiver version" + actions: + GET: + function: getReceiverVersion + +moduleid: + inherit_actions: GET_COMMAND + help: "\n\t[Gotthard2][Eiger][Mythen3][Jungfrau][Moench] 16 bit value (ideally unique) that is streamed out in the UDP header of the detector. Picked up from a file on the module." + actions: + GET: + function: getModuleId + +type: + inherit_actions: GET_COMMAND + help: "\n\tReturns detector type. Can be Eiger, Jungfrau, Gotthard, Moench, Mythen3, Gotthard2, ChipTestBoard, Xilinx_ChipTestBoard" + actions: + GET: + function: getDetectorType + +framesl: + inherit_actions: GET_COMMAND + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number of frames left in acquisition. \n\t[Gotthard2] only in continuous auto mode." + actions: + GET: + function: getNumberOfFramesLeft + +triggersl: + inherit_actions: GET_COMMAND + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number of triggers left in acquisition. Only when external trigger used." + actions: + GET: + function: getNumberOfTriggersLeft + +maxadcphaseshift: + inherit_actions: GET_COMMAND + help: "\n\t[Jungfrau][Moench][Ctb] Absolute maximum Phase shift of ADC clock." + actions: + GET: + function: getMaxADCPhaseShift + +maxdbitphaseshift: + inherit_actions: GET_COMMAND + help: "\n\t[Ctb][Jungfrau] Absolute maximum Phase shift of of the clock to latch digital bits." + actions: + GET: + function: getMaxDBITPhaseShift + +rx_framescaught: + inherit_actions: GET_COMMAND + help: "\n\tNumber of frames caught by each port in receiver." + actions: + GET: + function: getFramesCaught + +rx_missingpackets: + inherit_actions: GET_COMMAND + help: "\n\tNumber of missing packets for receiver. If negative, they are packets in excess." + actions: + GET: + function: getNumMissingPackets + +rx_frameindex: + inherit_actions: GET_COMMAND + help: "\n\tCurrent frame index received for each port in receiver during acquisition." + actions: + GET: + function: getRxCurrentFrameIndex + +scanerrmsg: + inherit_actions: GET_COMMAND + help: "\n\tGets Scan error message if scan ended in error for non blocking acquisitions." + actions: + GET: + function: getScanErrorMessage + +udp_numdst: + inherit_actions: GET_COMMAND + help: "\n\t[Jungfrau][Moench][Eiger][Mythen3][Gotthard2] One can enter upto 32 (64 for Mythen3) destinations that the detector will stream images out in a round robin fashion. This is get only command. Default: 1" + actions: + GET: + function: getNumberofUDPDestinations + +rx_printconfig: + inherit_actions: GET_COMMAND + help: "\n\tPrints the receiver configuration." + actions: + GET: + function: printRxConfiguration + +rx_realudpsocksize: + inherit_actions: GET_COMMAND + help: "\n\tActual udp socket buffer size. Double the size of rx_udpsocksize due to kernel bookkeeping." + actions: + GET: + function: getRxRealUDPSocketBufferSize + +rx_lastclient: + inherit_actions: GET_COMMAND + help: "\n\tClient IP Address that last communicated with the receiver." + actions: + GET: + function: getRxLastClientIP + +rx_threads: + inherit_actions: GET_COMMAND + help: "\n\tGet kernel thread ids from the receiver in order of [parent, tcp, listener 0, processor 0, streamer 0, listener 1, processor 1, streamer 1, arping]. If no streamer yet or there is no second interface, it gives 0 in its place." + actions: + GET: + function: getRxThreadIds + +chipversion: + inherit_actions: GET_COMMAND + help: "\n\t[Jungfrau] Returns chip version. Can be 1.0 or 1.1" + actions: + GET: + function: getChipVersion + +burstsl: + inherit_actions: GET_COMMAND + help: "\n\t[Gotthard2] Number of bursts left in acquisition. Only in burst auto mode." + actions: + GET: + function: getNumberOfBurstsLeft + +syncclk: + inherit_actions: GET_COMMAND + help: "[n_clk in MHz]\n\t[Ctb] Sync clock in MHz." + actions: + GET: + function: getSYNCClock + +patfname: + inherit_actions: GET_COMMAND + help: "\n\t[Ctb][Mythen3][Xilinx Ctb] Gets the pattern file name including path of the last pattern uploaded. Returns an empty if nothing was uploaded or via a server default file" + actions: + GET: + function: getPatterFileName + +lastclient: + inherit_actions: GET_COMMAND + help: "\n\tClient IP Address that last communicated with the detector." + actions: + GET: + function: getLastClientIP + +framecounter: + inherit_actions: GET_COMMAND + help: "\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Number of frames from start run control.\n\t[Gotthard2] only in continuous mode." + actions: + GET: + function: getNumberOfFramesFromStart + +################# GET_COMMAND_HEX ############################ +serialnumber: + inherit_actions: GET_COMMAND + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb]\nSerial number of detector." + actions: + GET: + function: getSerialNumber + output: [ "OutStringHex(t)" ] + +################# GET_COMMAND_NOID ########################### +nmod: + inherit_actions: GET_COMMAND_NOID + help: "\n\tNumber of modules in shared memory." + actions: + GET: + function: size + +settingslist: + inherit_actions: GET_COMMAND_NOID + help: "\n\tList of settings implemented for this detector." + actions: + GET: + function: getSettingsList + +drlist: + inherit_actions: GET_COMMAND_NOID + help: "\n\tGets the list of dynamic ranges for this detector." + actions: + GET: + function: getDynamicRangeList + +timinglist: + inherit_actions: GET_COMMAND_NOID + help: "\n\tGets the list of timing modes for this detector." + actions: + GET: + function: getTimingModeList + +readoutspeedlist: + inherit_actions: GET_COMMAND_NOID + help: "\n\tList of readout speed levels implemented for this detector." + actions: + GET: + function: getReadoutSpeedList + +templist: + inherit_actions: GET_COMMAND_NOID + help: "\n\tList of temperature commands implemented for this detector." + actions: + GET: + function: getTemperatureList + +################# GET_IND_COMMAND ############################ +temp_adc: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Jungfrau][Moench][Gotthard] ADC Temperature" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_ADC' ] + output: [ OutString(t), '" °C"' ] + +temp_fpga: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger][Jungfrau][Moench][Gotthard][Mythen3][Gotthard2] FPGA Temperature" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_FPGA' ] + output: [ OutString(t), '" °C"' ] + +temp_fpgaext: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature close to the FPGA" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_FPGAEXT' ] + output: [ OutString(t), '" °C"' ] + +temp_10ge: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature close to the 10GbE" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_10GE' ] + output: [ OutString(t), '" °C"' ] + +temp_dcdc: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature close to the dc dc converter" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_DCDC' ] + output: [ OutString(t), '" °C"' ] + +temp_sodl: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature close to the left so-dimm memory" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_SODL' ] + output: [ OutString(t), '" °C"' ] + +temp_sodr: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature close to the right so-dimm memory" + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_SODR' ] + output: [ OutString(t), '" °C"' ] + +temp_fpgafl: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature of the left front end board fpga." + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_FPGA2' ] + output: [ OutString(t), '" °C"' ] + +temp_fpgafr: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Eiger]Temperature of the right front end board fpga." + actions: + GET: + function: getTemperature + input: [ 'defs::TEMPERATURE_FPGA3' ] + output: [ OutString(t), '" °C"' ] + +temp_slowadc: + inherit_actions: GET_IND_COMMAND + help: "[n_value]\n\t[Ctb]Temperature of the slow adc" + actions: + GET: + function: getTemperature + input: [ 'defs::SLOW_ADC_TEMP' ] + output: [ OutString(t), '" °C"' ] + +vm_a: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured voltage of power supply a in mV." + actions: + GET: + function: getMeasuredPower + input: [ 'defs::V_POWER_A' ] + +vm_b: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured voltage of power supply b in mV." + actions: + GET: + function: getMeasuredPower + input: [ 'defs::V_POWER_B' ] + +vm_c: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured voltage of power supply c in mV." + actions: + GET: + function: getMeasuredPower + input: [ 'defs::V_POWER_C' ] + +vm_d: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured voltage of power supply d in mV." + actions: + GET: + function: getMeasuredPower + input: [ 'defs::V_POWER_D' ] + +vm_io: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured voltage of power supply io in mV." + actions: + GET: + function: getMeasuredPower + input: [ 'defs::V_POWER_IO' ] + +im_a: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured current of power supply a in mA." + actions: + GET: + function: getMeasuredCurrent + input: [ 'defs::I_POWER_A' ] + +im_b: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured current of power supply b in mA." + actions: + GET: + function: getMeasuredCurrent + input: [ 'defs::I_POWER_B' ] + +im_c: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured current of power supply c in mA." + actions: + GET: + function: getMeasuredCurrent + input: [ 'defs::I_POWER_C' ] + +im_d: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured current of power supply d in mA." + actions: + GET: + function: getMeasuredCurrent + input: [ 'defs::I_POWER_D' ] + +im_io: + inherit_actions: GET_IND_COMMAND + help: "\n\t[Ctb] Measured current of power supply io in mA." + actions: + GET: + function: getMeasuredCurrent + input: [ 'defs::I_POWER_IO' ] + +################# CTB_NAMED_LIST ############################# +daclist: + inherit_actions: CTB_NAMED_LIST + help: "[dacname1 dacname2 .. dacname18] \n\t\t[Ctb][Xilinx_Ctb] Set the list of dac names for this detector.\n\t\t[All] Gets the list of dac names for every dac for this detector." + actions: + GET: + function: getDacNames + PUT: + function: setDacNames + +adclist: + inherit_actions: CTB_NAMED_LIST + help: "[adcname1 adcname2 .. adcname32] \n\t\t[Ctb][Xilinx_Ctb] Set the list of adc names for this board." + actions: + GET: + function: getAdcNames + PUT: + function: setAdcNames + +signallist: + inherit_actions: CTB_NAMED_LIST + help: "[signalname1 signalname2 .. signalname63] \n\t\t[Ctb][Xilinx_Ctb] Set the list of signal names for this board." + actions: + GET: + function: getSignalNames + PUT: + function: setSignalNames + +powerlist: + inherit_actions: CTB_NAMED_LIST + help: "[powername1 powername2 .. powername4] \n\t\t[Ctb][Xilinx_Ctb] Set the list of power names for this board." + actions: + GET: + function: getPowerNames + PUT: + function: setPowerNames + +slowadclist: + inherit_actions: CTB_NAMED_LIST + help: "[slowadcname1 slowadcname2 .. slowadcname7] \n\t\t[Ctb][Xilinx_Ctb] Set the list of slowadc names for this board." + actions: + GET: + function: getSlowADCNames + PUT: + function: setSlowADCNames + +################# CTB_VALUES ################################ +powervalues: + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get values of all powers." + actions: + GET: + argc: 0 + ctb_output_list: + GETFCNLIST: getPowerList + GETFCNNAME: getPowerNames + GETFCN: getPower + suffix: "mV" + printable_name: "*name_it++" + +slowadcvalues: + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get values of all slow adcs." + actions: + GET: + argc: 0 + ctb_output_list: + GETFCNLIST: getSlowADCList + GETFCNNAME: getSlowADCNames + GETFCN: getSlowADC + suffix: "mV" + printable_name: "*name_it++" + +tempvalues: + help: "\n\tGets the values for every temperature for this detector." + actions: + GET: + argc: 0 + ctb_output_list: + GETFCNLIST: getTemperatureList + GETFCNNAME: "" + GETFCN: getTemperature + suffix: "°C" + printable_name: "*it" + +################# CTB_SINGLE_DACNAME ######################## +dacname: + inherit_actions: CTB_SINGLE_DACNAME + help: "[0-17][name] \n\t\t[Ctb][Xilinx_Ctb] Set the dac at the given position to the given name." + actions: + GET: + function: getDacName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + PUT: + function: setDacName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + +powername: + inherit_actions: CTB_SINGLE_DACNAME + help: "[0-4][name] \n\t\t[Ctb][Xilinx_Ctb] Set the power at the given position to the given name." + actions: + GET: + function: getPowerName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + PUT: + function: setPowerName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + +slowadcname: + inherit_actions: CTB_SINGLE_DACNAME + help: "[0-7][name] \n\t\t[Ctb][Xilinx_Ctb] Set the slowadc at the given position to the given name." + actions: + GET: + function: getSlowADCName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + PUT: + function: setSlowADCName + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + +################# CTB_GET_DACINDEX ########################## +dacindex: + inherit_actions: CTB_GET_DACINDEX + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the dac index for the given name." + actions: + GET: + function: getDacIndex + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + +powerindex: + inherit_actions: CTB_GET_DACINDEX + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the power index for the given name." + actions: + GET: + function: getPowerIndex + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + +slowadcindex: + inherit_actions: CTB_GET_DACINDEX + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the slowadc index for the given name." + actions: + GET: + function: getSlowADCIndex + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + +################# CTB_SINGLE_NAME ########################### +adcname: + inherit_actions: CTB_SINGLE_NAME + help: "[0-31][name] \n\t\t[Ctb][Xilinx_Ctb] Set the adc at the given position to the given name." + actions: + GET: + function: getAdcName + PUT: + function: setAdcName + +signalname: + inherit_actions: CTB_SINGLE_NAME + help: "[0-63][name] \n\t\t[Ctb][Xilinx_Ctb] Set the signal at the given position to the given name." + actions: + GET: + function: getSignalName + PUT: + function: setSignalName + +################# CTB_GET_INDEX ############################# +adcindex: + inherit_actions: CTB_GET_INDEX + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the adc index for the given name." + actions: + GET: + function: getAdcIndex + +signalindex: + inherit_actions: CTB_GET_INDEX + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the signal index for the given name." + actions: + GET: + function: getSignalIndex + + +######################### description only commands ############################# +## code is generated for these commands +free: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 0 + +hostname: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + arg_types: [ std::string ] + +acquire: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 0 + +versions: + is_description: true + actions: + GET: + argc: 0 + +threshold: + is_description: true + actions: + GET: + argc: 0 + PUT: + args: + - argc: 1 + arg_types: [ int ] + - argc: 2 + arg_types: [ int, defs::detectorSettings ] + - argc: 3 + arg_types: [ int,int,int ] + - argc: 4 + arg_types: [ int ,int,int,defs::detectorSettings] + +thresholdnotb: + is_description: true + duplicate_function: true + function_alias: threshold + actions: + GET: + argc: 0 + PUT: + args: + - argc: 1 + arg_types: [ int ] + - argc: 2 + arg_types: [ int, defs::detectorSettings ] + - argc: 3 + arg_types: [ int,int,int ] + - argc: 4 + arg_types: [ int ,int,int,defs::detectorSettings ] + +trimen: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +badchannels: + is_description: true + actions: + GET: + argc: 1 + arg_types: [ std::string ] + PUT: + argc: -1 + +udp_srcip: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ std::string ] + +udp_srcip2: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ std::string ] + +udp_dstip: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ std::string ] + +udp_dstip2: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ std::string ] + +rx_hostname: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +rx_roi: + is_description: true + actions: + GET: + argc: 0 + PUT: + args: + - argc: 2 + arg_types: [ int, int ] + - argc: 4 + arg_types: [ int, int, int, int ] + +ratecorr: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ int ] + +burstmode: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ defs::burstMode ] + +vetostream: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +counters: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +samples: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: 1 + arg_types: [ int ] + +slowadc: + is_description: true + actions: + GET: + argc: 1 + arg_types: [ int ] + +rx_dbitlist: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +rx_jsonaddheader: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + +execcommand: + is_description: true + actions: + PUT: + argc: -1 + +dacvalues: + is_description: true + actions: + GET: + args: + - argc: 0 + - argc: 1 + arg_types: [ special::mv ] + +currentsource: + is_description: true + actions: + GET: + argc: 0 + PUT: + args: + - argc: 1 + arg_types: [ bool ] + - argc: 3 + arg_types: [ bool, special::currentSourceFix, int ] + - argc: 4 + arg_types: [bool, special::currentSourceFix, int, special::currentSourceLow ] + +gaincaps: + is_description: true + actions: + GET: + argc: 0 + PUT: + argc: -1 + arg_types: [ defs::defs::M3_GainCaps ] + +################# special commands ########################## + +virtual: + function_alias: virtualFunction + help: "[n_servers] [starting_port_number]\n\tConnecs to n virtual server at local host starting at specific control port. Every virtual server will have a stop port (control port + 1)" + actions: + PUT: + function: setVirtualDetectorServers + argc: 2 + check_det_id: true + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, uint16_t ] + cast_input: [ true, true ] + output: [ 'ToString(args)' ] + +packageversion: + help: "\n\tPackage version." + actions: + GET: + argc: 0 + function: getPackageVersion + output: [ t ] + +clientversion: + help: "\n\tClient software version" + actions: + GET: + argc: 0 + function: getClientVersion + output: [ t ] + +firmwareversion: + help: "\n\tFirmware version of detector in format [0xYYMMDD] or an increasing 2 digit number for Eiger." + actions: + GET: + argc: 0 + require_det_id: true + function: getFirmwareVersion + output: [ OutStringHex(t) ] + detectors: + EIGER: + output: [ OutString(t) ] + +detsize: + help: "[nx] [ny]\n\tDetector size, ie. Number of channels in x and y dim. This is used to calculate module coordinates included in UDP data. \n\tBy default, it adds module in y dimension for 2d detectors and in x dimension for 1d detectors packet header." + actions: + GET: + argc: 0 + function: getDetectorSize + output: [ t ] + PUT: + argc: 2 + function: setDetectorSize + input: [ 'defs::xy(StringTo(args[0]),StringTo(args[1]))' ] + input_types: [ defs::xy ] + arg_types: [int, int] + output: [ 'ToString(args)' ] + +trimbits: + infer_action: true + help: "[fname]\n\t[Eiger][Mythen3] Put will load the trimbit file to detector. If no extension specified, serial number of each module is attached. Get will save the trimbits from the detector to file with serial number added to file name." + actions: + GET: + argc: 1 + require_det_id: true + store_result_in_t: false + function: saveTrimbits + input: [ 'args[0]' ] + input_types: [ std::string ] + arg_types: [special::path] + output: [ "args[0]" ] + PUT: + argc: 1 + require_det_id: true + function: loadTrimbits + input: [ 'args[0]' ] + input_types: [ std::string ] + arg_types: [special::path] + output: [ "args[0]" ] + +gappixels: + help: "[0, 1]\n\t[Eiger][Jungfrau][Moench] Include Gap pixels in client data call back in Detecor api. Will not be in detector streaming, receiver file or streaming. Default is 0. " + actions: + GET: + argc: 0 + check_det_id: true + function: getGapPixelsinCallback + output: [ t ] + PUT: + argc: 1 + check_det_id: true + function: setGapPixelsinCallback + input: [ 'args[0]' ] + input_types: [ bool ] + cast_input: [ true ] + output: [ args.front() ] + +Exptime: + template: true + infer_action: true # infer action based on actions' argc (they must be unique if true) + actions: + GET: + require_det_id: true + function: '' + args: + - argc: 0 + output: [ OutString(t) ] + - argc: 1 + arg_types: [ special::time_unit ] + output: [ "OutString(t , args[0])" ] + PUT: + require_det_id: true + function: '' + input: [ converted_time ] + input_types: [ time::ns ] + args: + - argc: 1 + arg_types: [ std::string ] + separate_time_units: + input: 'args[0]' + output: [ converted_time, unit ] + output: [ 'args[0]' ] + - argc: 2 + arg_types: [ int, special::time_unit ] + convert_to_time: + input: [ 'args[0]', 'args[1]' ] + output: converted_time + output: [ 'args[0]', 'args[1]' ] + +exptime: + inherit_actions: Exptime + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Ctb] Exposure time\n\t[Mythen3] Exposure time of all gate signals in auto and trigger mode (internal gating). To specify gate index, use exptime1, exptime2, exptime3." + actions: + GET: + function: getExptime + detectors: + MYTHEN3: + function: getExptimeForAllGates + PUT: + function: setExptime + +exptime1: + inherit_actions: Exptime + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 1 in auto and trigger mode (internal gating)." + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getExptime + input: [ gateIndex ] + input_types: [ int ] + PUT: + extra_variables: + - name: gateIndex + type: int + value: 0 + function: setExptime + input: [ gateIndex,converted_time ] + input_types: [ int, time::ns ] + +exptime2: + inherit_actions: exptime1 + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 2 in auto and trigger mode (internal gating)." + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 1 + PUT: + extra_variables: + - name: gateIndex + type: int + value: 1 + +exptime3: + inherit_actions: exptime1 + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 3 in auto and trigger mode (internal gating)." + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 2 + PUT: + extra_variables: + - name: gateIndex + type: int + value: 2 + +readoutspeed: + help: "\n\t[0 or full_speed|1 or half_speed|2 or quarter_speed]\n\t[Eiger][Jungfrau][Moench] Readout speed of chip.\n\t[Eiger][Moench] Default speed is full_speed.\n\t[Jungfrau] Default speed is half_speed. full_speed option only available from v2.0 boards and is recommended to set number of interfaces to 2. Also overwrites adcphase to recommended default.\n\t [144|108]\n\t\t[Gotthard2] Readout speed of chip in MHz. Default is 108." + actions: + GET: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'det_type == defs::CHIPTESTBOARD || det_type == defs::XILINX_CHIPTESTBOARD' + message: '"ReadoutSpeed not implemented. Did you mean runclk?"' + argc: 0 + require_det_id: true + function: getReadoutSpeed + output: [ OutString(t) ] + PUT: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'det_type == defs::CHIPTESTBOARD || det_type == defs::XILINX_CHIPTESTBOARD' + message: '"ReadoutSpeed not implemented. Did you mean runclk?"' + argc: 1 + require_det_id: true + function: setReadoutSpeed + input: [ 'args[0]' ] + input_types: [ defs::speedLevel ] + cast_input: [ true ] + output: [ 'ToString(StringTo(args[0]))' ] + +adcphase: + infer_action: true + help: "[n_value] [(optional)deg]\n\t[Jungfrau][Moench][Ctb][Gotthard] Phase shift of ADC clock. \n\t[Jungfrau][Moench] Absolute phase shift. If deg used, then shift in degrees. Changing Speed also resets adcphase to recommended defaults.\n\t[Ctb] Absolute phase shift. If deg used, then shift in degrees. Changing adcclk also resets adcphase and sets it to previous values.\n\t[Gotthard] Relative phase shift. Cannot get" + actions: + GET: + require_det_id: true + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2' + message: '"adcphase not implemented for this detector"' + args: + - argc: 0 + function: getADCPhase + output: [ OutString(t) ] + - argc: 1 + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2' + message: '"adcphase not implemented for this detector"' + - condition: 'args[0] != "deg"' + message: '"Unknown adcphase argument " + args[0] + ". Did you mean deg? "' + function: getADCPhaseInDegrees + arg_types: [ special::deg ] + output: [ OutString(t), '" deg"' ] + + PUT: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2' + message: '"adcphase not implemented for this detector"' + require_det_id: true + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + + args: + - argc: 1 + function: setADCPhase + output: [ 'args.front()' ] + - argc: 2 + arg_types: [ int, special::deg ] + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2' + message: '"adcphase not implemented for this detector"' + - condition: 'args[1] != "deg"' + message: '"Unknown adcphase 2nd argument " + args[1] + ". Did you mean deg?"' + + function: setADCPhaseInDegrees + output: [ 'args[0]',"' '", 'args[1]' ] + +dbitphase: + help: "[n_value] [(optional)deg]\n\t[Ctb][Jungfrau] Phase shift of clock to latch digital bits. Absolute phase shift. If deg used, then shift in degrees. \n\t[Ctb]Changing dbitclk also resets dbitphase and sets to previous values." + actions: + GET: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2 || det_type == defs::MOENCH' + message: '"dbitphase not implemented for this detector"' + require_det_id: true + args: + - argc: 0 + function: getDBITPhase + output: [ OutString(t) ] + - argc: 1 + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2 || det_type == defs::MOENCH' + message: '"dbitphase not implemented for this detector"' + - condition: 'args[0] != "deg"' + message: '"Unknown dbitphase argument " + args[0] + ". Did you mean deg? "' + function: getDBITPhaseInDegrees + arg_types: [ special::deg ] + output: [ OutString(t), '" deg"' ] + PUT: + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2 || det_type == defs::MOENCH' + message: '"dbitphase not implemented for this detector"' + require_det_id: true + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + args: + - argc: 1 + function: setDBITPhase + output: [ 'args.front()' ] + - argc: 2 + exceptions: + - condition: 'det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2 || det_type == defs::MOENCH' + message: '"dbitphase not implemented for this detector"' + - condition: 'args[1] != "deg"' + message: '"Unknown dbitphase 2nd argument " + args[1] + ". Did you mean deg? "' + function: setDBITPhaseInDegrees + arg_types: [ int, special::deg ] + output: [ 'args[0]',"' '", 'args[1]' ] + +clkfreq: + help: "[n_clock (0-5)] [freq_in_Hz]\n\t[Gotthard2][Mythen3] Frequency of clock n_clock in Hz. Use clkdiv to set frequency." + actions: + GET: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkfreq not implemented for this detector."' + argc: 1 + require_det_id: true + function: getClockFrequency + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ OutString(t) ] + +clkphase: + help: "[n_clock (0-5)] [phase] [deg (optional)]\n\t[Gotthard2][Mythen3] Phase of clock n_clock. If deg, then phase shift in degrees, else absolute phase shift values." + actions: + GET: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkphase not implemented for this detector."' + require_det_id: true + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ OutString(t) ] + args: + - argc: 1 + function: getClockPhase + - argc: 2 + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkphase not implemented for this detector."' + - condition: 'args[1] != "deg"' + message: '"Cannot scan argument" + args[1] + ". Did you mean deg?"' + arg_types: [ int , special::deg ] + function: getClockPhaseinDegrees + output: [ OutString(t), '" deg"' ] + PUT: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkphase not implemented for this detector."' + require_det_id: true + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, int ] + cast_input: [ true, true ] + args: + - argc: 2 + function: setClockPhase + output: [ 'args[1]' ] + - argc: 3 + arg_types: [int, int , special::deg ] + + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkphase not implemented for this detector."' + - condition: 'args[2] != "deg"' + message: '"Cannot scan argument" + args[2] + ". Did you mean deg?"' + function: setClockPhaseinDegrees + output: [ 'args[1]', '" "', 'args[2]' ] + +maxclkphaseshift: + help: "[n_clock (0-5)]\n\t[Gotthard2][Mythen3] Absolute Maximum Phase shift of clock n_clock." + actions: + GET: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"maxclkphaseshift not implemented for this detector."' + require_det_id: true + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ OutString(t) ] + argc: 1 + function: getMaxClockPhaseShift + +clkdiv: + help: "[n_clock (0-5)] [n_divider]\n\t[Gotthard2][Mythen3] Clock Divider of clock n_clock. Must be greater than 1." + actions: + GET: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkdiv not implemented for this detector."' + require_det_id: true + function: getClockDivider + argc: 1 + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ 'args[0]', "' '", OutString(t) ] + PUT: + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + exceptions: + - condition: 'type != defs::GOTTHARD2 && type != defs::MYTHEN3' + message: '"clkdiv not implemented for this detector."' + require_det_id: true + function: setClockDivider + argc: 2 + arg_types: [ int, int ] + input: [ 'args[0]', 'args[1]'] + input_types: [ int, int ] + cast_input: [ true, true ] + output: [ 'args[0]', "' '", 'args[1]' ] + +extsig: + help: "[n_signal] [signal_type]\n\t[Gotthard][Mythen3] External signal mode for trigger timing mode.\n\t[Gotthard] [0] [trigger_in_rising_edge|trigger_in_falling_edge]\n\t[Mythen3] [0-7] [trigger_in_rising_edge|trigger_in_falling_edge|inversion_on|inversion_off]\n\t where 0 is master input trigger signal, 1-3 is master input gate signals, 4 is busy out signal and 5-7 is master output gate signals." + actions: + GET: + argc: 1 + require_det_id: true + function: getExternalSignalFlags + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ "args[0]","' '", OutString(t) ] + PUT: + argc: 2 + require_det_id: true + function: setExternalSignalFlags + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, defs::externalSignalFlag ] + cast_input: [ true, true ] + output: [ 'args[0]', "' '", 'args[1]' ] + +dac: + help: "code: return GetHelpDacWrapper(cmd, args);\n" # this is a special case + actions: + GET: + exceptions: + - condition: "is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD" + message: '"Dac indices can only be used for chip test board. Use daclist to get list of dac names for current detector."' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: "((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) : StringTo(args[0])" + function: getDAC + require_det_id: true + input_types: [ defs::dacIndex, bool ] + cast_input: [ false, true ] + args: + - argc: 1 + arg_types: [defs::dacIndex] + input: [ dacIndex, '"0"' ] + output: [ 'args[0]', "' '", OutString(t) ] + - argc: 2 + exceptions: + - condition: "is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD" + message: '"Dac indices can only be used for chip test board. Use daclist to get list of dac names for current detector."' + - condition: 'args[1] != "mv" && args[1] != "mV"' + message: '"Unknown argument " + args[1] + ". Did you mean mV?"' + arg_types: [defs::dacIndex, special::mv] + input: [ dacIndex, '"1"' ] + output: [ 'args[0]', "' '" , OutString(t), '" mV"' ] + PUT: + exceptions: + - condition: "is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD" + message: '"Dac indices can only be used for chip test board. Use daclist to get list of dac names for current detector."' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: "((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) : StringTo(args[0])" + function: setDAC + require_det_id: true + input_types: [ defs::dacIndex, int, bool ] + cast_input: [ false, true, true ] + args: + - argc: 2 + arg_types: [defs::dacIndex, int] + input: [ dacIndex, "args[1]", '"0"' ] + output: [ "args[0]", "' '", "args[1]" ] + - argc: 3 + arg_types: [defs::dacIndex, int, special::mv] + input: [ dacIndex, "args[1]", '"1"' ] + output: [ "args[0]", "' '", "args[1]", '" mV"' ] + +resetdacs: + help: "[(optional) hard] \n\t[Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Mythen3]Reset dac values to the defaults. A 'hard' optional reset will reset the dacs to the hardcoded defaults in on-board detector server." + actions: + PUT: + function: resetToDefaultDacs + require_det_id: true + input_types: [ bool ] + output: [ '"successful"' ] + args: + - argc: 1 + arg_types: [ special::hard ] + exceptions: + - condition: 'args[0] != "hard"' + message: '"Unknown argument " + args[0] + ". Did you mean hard?"' + input: [ '"1"' ] + - argc: 0 + input: [ '"0"' ] + +defaultdac: + help: "[dac name][value][(optional)setting]\n\tSets the default for that dac to this value.\n\t[Jungfrau][Moench][Mythen3] When settings is provided, it sets the default value only for that setting" + actions: + GET: + function: getDefaultDac + require_det_id: true + args: + - argc: 1 + input: [ "args[0]" ] + cast_input: [ true ] + input_types: [ defs::dacIndex ] + output: [ "args[0]", "' '", OutString(t) ] + - argc: 2 + input: [ "args[0]", "args[1]" ] + cast_input: [ true, true ] + input_types: [ defs::dacIndex, defs::detectorSettings ] + output: [ "args[0]", "' '", "args[1]", "' '", OutString(t) ] + PUT: + function: setDefaultDac + require_det_id: true + args: + - argc: 2 + cast_input: [ true, true ] + input: [ "args[0]", "args[1]" ] + input_types: [ defs::dacIndex, int ] + output: [ "args[0]", "' '", "args[1]" ] + + - argc: 3 + cast_input: [ true, true, true ] + input: [ "args[0]", "args[1]", "args[2]" ] + input_types: [ defs::dacIndex, int, defs::detectorSettings ] + output: [ "args[0]", "' '", "args[2]", "' '", "args[1]" ] + +rx_status: + help: "[running, idle, transmitting]\n\tReceiver listener status." + actions: + GET: + argc: 0 + function: getReceiverStatus + require_det_id: true + output: [ OutString(t) ] + PUT: + argc: -1 + exceptions: + - condition: 'true' + message: '"Cannot put. Did you mean to use command: \"rx_start\" or \"rx_stop\"?"' + +status: + help: "[running, error, transmitting, finished, waiting, idle]\n\tDetector status. Goes to stop server." + actions: + GET: + argc: 0 + function: getDetectorStatus + require_det_id: true + output: [ OutString(t) ] + PUT: + argc: -1 + exceptions: + - condition: 'true' + message: '"Cannot put. Did you mean to use command: \"start\" or \"stop\"?"' + + +scan: + help: "[dac_name|0|trimbits] [start_val] [stop_val] [step_size] [dac settling time ns|us|ms|s]\n\tEnables/ disables scans for dac and trimbits \n\tEnabling scan sets number of frames to number of steps in receiver. \n\tTo cancel scan configuration, set dac to '0', which also sets number of frames to 1. \n\t[Eiger][Mythen3] Use trimbits as dac name for a trimbit scan." + actions: + GET: + argc: 0 + function: getScan + require_det_id: true + output: [ OutString(t) ] + PUT: + check_det_id: true + function: setScan + output: [ ToString(args) ] + args: + - argc: 1 + exceptions: + - condition: 'StringTo(args[0]) != 0' + message: '"Unknown argument " + args[0] + ". Did you mean 0 to disable scan?"' + arg_types: [ int ] + input: [ "defs::scanParameters()" ] + input_types: [ auto ] + - argc: 4 + arg_types: [ defs::dacIndex, int, int, int ] + input: [ "defs::scanParameters(StringTo(args[0]), StringTo(args[1]), StringTo(args[2]), StringTo(args[3]))" ] + input_types: [ auto ] + - argc: 5 + arg_types: [ defs::dacIndex, int, int, int, std::string ] + separate_time_units: + input: 'args[4]' + output: [ t, unit ] + input: [ "defs::scanParameters(StringTo(args[0]), StringTo(args[1]), StringTo(args[2]), StringTo(args[3]), t)" ] + input_types: [ auto ] + +Trigger: + template: true + actions: + PUT: + check_det_id: true + argc: 0 + function: sendSoftwareTrigger + input: [ block ] + input_types: [ bool ] + cast_input: [ false ] + output: [ '"successful"' ] + +trigger: + inherit_actions: Trigger + help: "\n\t[Eiger][Mythen3][Jungfrau][Moench] Sends software trigger signal to detector" + actions: + PUT: + extra_variables: + - name: block + type: bool + value: "false" + +blockingtrigger: + inherit_actions: Trigger + help: "\n\t[Eiger][Jungfrau][Moench] Sends software trigger signal to detector and blocks till the frames are sent out for that trigger." + actions: + PUT: + extra_variables: + - name: block + type: bool + value: "true" + +udp_dstlist: + help: "[ip=x.x.x.x] [(optional)ip2=x.x.x.x] \n\t\t[mac=xx:xx:xx:xx:xx:xx] [(optional)mac2=xx:xx:xx:xx:xx:xx]\n\t\t[port=value] [(optional)port2=value]\n\t\tThe order of ip, mac and port does not matter. entry_value can be >0 only for [Eiger][Jungfrau][Moench][Mythen3][Gotthard2] where round robin is implemented. If 'auto' used, then ip is set to ip of rx_hostname." + actions: + GET: + exceptions: + - condition: "det_id == -1" + message: '"Can execute udp_dstlist only at module level."' + - condition: "rx_id < 0 || rx_id >= MAX_UDP_DESTINATION" + message: '"Invalid receiver index " + std::to_string(rx_id) + " to set round robin entry."' + argc: 0 + function: getDestinationUDPList + require_det_id: true + input: [ rx_id ] + input_types: [ auto ] + output: [ OutString(t) ] + PUT: + exceptions: + - condition: "det_id == -1" + message: '"Can execute udp_dstlist only at module level."' + - condition: "rx_id < 0 || rx_id >= MAX_UDP_DESTINATION" + message: '"Invalid receiver index " + std::to_string(rx_id) + " to set round robin entry."' + - condition: "args.empty()" + message: '"udp_dstlist require at least one argument."' + argc: -1 + function: setDestinationUDPList + require_det_id: true + convert_det_id: false + arg_types: [ std::string ] + input: [ getUdpEntry() ] + input_types: [ auto ] + output: [ ToString(args) ] + +txdelay: + help: "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Set transmission delay for all modules in the detector using the step size provided.Sets up \n\t\t[Eiger] txdelay_left to (2 * mod_index * n_delay), \n\t\t[Eiger] txdelay_right to ((2 * mod_index + 1) * n_delay) and \n\t\t[Eiger] txdelay_frame to (2 *num_modules * n_delay) \n\t\t[Jungfrau][Moench][Mythen3] txdelay_frame to (num_modules * n_delay) \nfor every module." + actions: + GET: + argc: 0 + check_det_id: true + function: getTransmissionDelay + output: [ OutString(t) ] + PUT: + argc: 1 + check_det_id: true + function: setTransmissionDelay + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ 'args.front()' ] + +zmqhwm: + help: "[n_limit] \n\tClient's zmq receive high water mark. Default is the zmq library's default (1000), can also be set here using -1. \n\tThis is a high number and can be set to 2 for gui purposes. \n\tOne must also set the receiver's send high water mark to similar value. Final effect is sum of them.\n\t Setting it via command line is useful only before zmq enabled (before opening gui)." + actions: + GET: + argc: 0 + function: getClientZmqHwm + output: [ t ] + PUT: + argc: 1 + function: setClientZmqHwm + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ 'det->getClientZmqHwm()' ] + +Pulse: + template: true + help: '' + actions: + PUT: + argc: 3 + require_det_id: true + function: '' + arg_types: [int, int, int] + extra_variables: + - name: c + type: defs::xy + value: defs::xy(StringTo(args[1]), StringTo(args[2])) + input: [ 'args[0]', c ] + input_types: [ int, defs::xy ] + cast_input: [ true, false ] + output: [ ToString(args) ] + +pulse: + inherit_actions: Pulse + help: "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times at coordinates (x, y). Advanced User!" + actions: + PUT: + function: pulsePixel + +pulsenmove: + inherit_actions: Pulse + help: "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times and moves relatively by (x, y). Advanced User!" + actions: + PUT: + function: pulsePixelNMove + +pulsechip: + help: "[n_times] \n\t[Eiger] Pulse chip n times. If n is -1, resets to normal mode (reset chip completely at start of acquisition, where partialreset = 0). Advanced User!" + actions: + PUT: + argc: 1 + require_det_id: true + function: pulseChip + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ args.front() ] + +quad: + help: "[0, 1]\n\t[Eiger] Sets detector size to a quad. 0 (disabled) is default. (Specific hardware required)." + actions: + GET: + argc: 0 + require_det_id: true + function: getQuad + output: [ OutString(t) ] + PUT: + argc: 1 + check_det_id: true + function: setQuad + input: [ 'args[0]' ] + input_types: [ bool ] + cast_input: [ true ] + output: [ args.front() ] + +datastream: + help: "[left|right] [0, 1]\n\t[Eiger] Enables or disables data streaming from left or/and right side of detector for 10 GbE mode. 1 (enabled) by default." + actions: + GET: + argc: 1 + require_det_id: true + function: getDataStream + input: [ 'args[0]' ] + input_types: [ defs::portPosition ] + cast_input: [ true ] + output: [ OutString(t) ] + PUT: + argc: 2 + require_det_id: true + function: setDataStream + input: [ 'args[0]', 'args[1]' ] + input_types: [ defs::portPosition, bool ] + cast_input: [ true, true ] + output: [ 'ToString(args)' ] + +temp_event: + help: "[0]\n\t[Jungfrau][Moench] 1, if a temperature event occured. To clear this event, set it to 0.\n\tIf temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared." + actions: + GET: + argc: 0 + require_det_id: true + function: getTemperatureEvent + output: [ OutString(t) ] + PUT: + argc: 1 + exceptions: + - condition: 'StringTo(args[0]) != 0' + message: '"Unknown argument for temp event: ( " + args[0] + " ). Did you mean 0 to reset event?"' + require_det_id: true + function: resetTemperatureEvent + arg_types: [ int ] + output: [ '"cleared"' ] + +pedestalmode: + help: " [frames] [loops]\n\t\t[Jungfrau] Enable pedestal mode. \n\t\tThe number of frames or triggers is overwritten by: \n\t\t(#pedestal_frames x #pedestal_loops x 2). \n\t\tIn auto timing mode or in trigger mode with #frames > 1, \n\t\t#frames is overwritten and #triggers = 1, \n\t\telse #triggers is overwritten and #frames = 1. \n\t\tOne cannot set #frames, #triggers or timing mode in pedestal mode (exception thrown).\n\npedestalmode [0]\n\t\t[Jungfrau] Disable pedestal mode.\n\t\tDisabling pedestal mode will set back the normal mode values of #frames and #triggers." + actions: + GET: + argc: 0 + require_det_id: true + function: getPedestalMode + output: [ OutString(t) ] + PUT: + function: setPedestalMode + output: [ "ToString(args)" ] + args: + - argc: 1 + exceptions: + - condition: 'args[0] != "0"' + message: '"Unknown argument " + args[0] + ". Did you mean 0 to disable pedestal mode?"' + arg_types: [ special::pedestal_parameters ] + input: [ defs::pedestalParameters() ] + input_types: [ defs::pedestalParameters ] + - argc: 2 + arg_types: [ uint8_t, uint16_t ] + input_types: [ defs::pedestalParameters ] + input: [ 'defs::pedestalParameters(StringTo(args[0]), StringTo(args[1]))' ] + +roi: + help: "[xmin] [xmax] \n\t[Gotthard] Region of interest in detector.\n\tOptions: Only a single ROI per module. \n\tEither all channels or a single adc or 2 chips (256 channels). Default is all channels enabled (-1 -1). " + actions: + GET: + argc: 0 + require_det_id: true + function: getROI + output: [ t ] + PUT: + argc: 2 + exceptions: + - condition: 'det_id == -1 && det->size() > 1' + message: '"Cannot execute ROI at multi module level"' + require_det_id: true + convert_det_id: false + function: setROI + arg_types: [ int, int ] + extra_variables: + - name: t + type: defs::ROI + value: defs::ROI(StringTo(args[0]), StringTo(args[1])) + input: [ t ] + input_types: [ defs::ROI ] + output: [ 't' ] + +inj_ch: + help: "[offset] [increment]\n\t[Gotthard2] Inject channels with current source for calibration. Offset is starting channel that is injected, increment determines succeeding channels to be injected." + actions: + GET: + argc: 0 + require_det_id: true + function: getInjectChannel + output: [ OutString(t) ] + PUT: + argc: 2 + function: setInjectChannel + require_det_id: true + arg_types: [int, int] + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, int ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +vetophoton: + help: "[ichip] [#photons] [energy in keV] [reference file]\n\t[Gotthard2] Set veto reference for 128 channels for chip ichip according to reference file and #photons and energy in keV.\n[ichip] [output file]\n\t Get gain indices and veto reference for 128 channels for chip ichip, saved to file." + actions: + GET: + argc: 2 + require_det_id: true + function: getVetoPhoton + store_result_in_t: false + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, std::string ] + cast_input: [ true, false ] + output: [ '"saved to file "' , "args[1]" ] + PUT: + argc: 4 + require_det_id: true + function: setVetoPhoton + input: [ 'args[0]', 'args[1]', "args[2]", "args[3]" ] + input_types: [ int, int, int, std::string ] + cast_input: [ true, true, true, false ] + output: [ ToString(args) ] + +vetoref: + help: "[gain index] [12 bit value]\n\t[Gotthard2] Set veto reference for all 128 channels for all chips." + actions: + GET: + argc: -1 + exceptions: + - condition: 'true' + message: '"Cannot get vetoref. Did you mean vetophoton?"' + + PUT: + argc: 2 + function: setVetoReference + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, int ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +vetofile: + help: "[chip index 0-9, -1 for all] [file name] \n\t[Gotthard2] Set veto reference for each 128 channels for specific chip. The file should have 128 rows of gain index and 12 bit value in dec" + actions: + GET: + argc: -1 + exceptions: + - condition: 'true' + message: '"Cannot get vetofile. Did you mean vetophoton?"' + PUT: + argc: 2 + function: setVetoFile + require_det_id: true + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, std::string ] + cast_input: [ true, false ] + output: [ ToString(args) ] + +vetoalg: + help: "[hits|raw] [lll|10gbe]\n\t[Gotthard2] Set the veto algorithm. Default is hits." + actions: + GET: + argc: 1 + extra_variables: + - name: interface + type: defs::streamingInterface + value: StringTo(args[0]) + exceptions: + - condition: 'interface == defs::streamingInterface::NONE' + message: '"Must specify an interface to set algorithm"' + require_det_id: true + function: getVetoAlgorithm + input: [ 'interface' ] + input_types: [ defs::streamingInterface ] + cast_input: [ false ] + output: [ OutString(t), "' '", ToString(interface) ] + PUT: + argc: 2 + extra_variables: + - name: alg + type: defs::vetoAlgorithm + value: StringTo(args[0]) + - name: interface + type: defs::streamingInterface + value: StringTo(args[1]) + exceptions: + - condition: 'interface == defs::streamingInterface::NONE' + message: '"Must specify an interface to set algorithm"' + require_det_id: true + function: setVetoAlgorithm + input: [ 'alg', 'interface' ] + input_types: [ defs::vetoAlgorithm, defs::streamingInterface ] + cast_input: [ false, false ] + output: [ ToString(alg), "' '", ToString(interface) ] + +confadc: + help: "[chip index 0-9, -1 for all] [adc index 0-31, -1 for all] [7 bit configuration value in hex]\n\t[Gotthard2] Sets configuration for specific chip and adc, but configures 1 chip (all adcs for that chip) at a time." + actions: + GET: + argc: 2 + require_det_id: true + function: getADCConfiguration + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, int ] + cast_input: [ true, true ] + output: [ OutStringHex(t) ] + PUT: + argc: 3 + require_det_id: true + function: setADCConfiguration + input: [ 'args[0]', 'args[1]', 'args[2]' ] + input_types: [ int, int, int ] + cast_input: [ true, true, true ] + output: [ "'['", "args[0]", '", "', "args[1]", '", "', "ToStringHex( StringTo(args[2]))", '"]"' ] + +gatedelay: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of all gate signals in auto and trigger mode (internal gating)." + actions: + GET: + function: getGateDelayForAllGates + require_det_id: true + args: + - argc: 0 + output: [ OutString(t) ] + - argc: 1 + arg_types: [ special::time_unit ] + output: [ "OutString(t, args[0])" ] + PUT: + extra_variables: + - name: gateIndex + type: int + value: -1 + require_det_id: true + function: setGateDelay + input: [ gateIndex, converted_time ] + input_types: [ int, time::ns ] + args: + - argc: 1 + arg_types: [ std::string ] + separate_time_units: + input: 'args[0]' + output: [ converted_time, unit ] + output: [ 'args[0]' ] + - argc: 2 + arg_types: [ int, special::time_unit ] + convert_to_time: + input: [ 'args[0]', 'args[1]' ] + output: converted_time + output: [ 'args[0]', 'args[1]' ] + +gatedelay1: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal 1 in auto and trigger mode (internal gating)." + inherit_actions: gatedelay + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getGateDelay + input: [ gateIndex ] + input_types: [ int ] + PUT: + extra_variables: + - name: gateIndex + type: int + value: 0 + +gatedelay2: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal 2 in auto and trigger mode (internal gating)." + inherit_actions: gatedelay1 + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 1 + PUT: + extra_variables: + - name: gateIndex + type: int + value: 1 + +gatedelay3: + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal 3 in auto and trigger mode (internal gating)." + inherit_actions: gatedelay1 + actions: + GET: + extra_variables: + - name: gateIndex + type: int + value: 2 + PUT: + extra_variables: + - name: gateIndex + type: int + value: 2 + +adcvpp: + help: "[dac or mV value][(optional unit) mV] \n\t[Ctb] Vpp of ADC.\n\t 0 -> 1V ; 1 -> 1.14V ; 2 -> 1.33V ; 3 -> 1.6V ; 4 -> 2V. \n\tAdvanced User function!" + actions: + GET: + require_det_id: true + function: getADCVpp + args: + - argc: 0 + input: [ '"0"' ] + input_types: [ bool ] + cast_input: [ true ] + output: [ OutString(t) ] + - argc: 1 + arg_type: [ special::mv ] + exceptions: + - condition: '(args[0] != "mv") && (args[0] != "mV")' + message: '"Unknown argument " + args[0] + ". Did you mean mV?"' + input: [ '"1"' ] + input_types: [ bool ] + cast_input: [ true ] + output: [ OutString(t), '" mV"' ] + PUT: + require_det_id: true + function: setADCVpp + args: + - argc: 1 + output: [ "args[0]" ] + input: [ "args[0]", '"0"' ] + input_types: [ int, bool ] + arg_types: [ int ] + cast_input: [ true, true ] + - argc: 2 + arg_types: [ int, special::mv ] + exceptions: + - condition: '(args[1] != "mv") && (args[1] != "mV")' + message: '"Unknown argument " + args[1] + ". Did you mean mV?"' + input: [ "args[0]", '"1"' ] + input_types: [ int, bool ] + cast_input: [ true , true ] + output: [ "args[0]", '" mV"' ] + +diodelay: + help: "[0-775]\n\t[Ctb] Delay for diode. Delay is in ps and max of 775 ps. Resolution is 25 ps." + actions: + PUT: + argc: 2 + require_det_id: true + function: setDigitalIODelay + input: [ 'args[0]', 'args[1]' ] + input_types: [ uint64_t, int ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +# pattern is a keyword in yaml, so patternX is used to avoid it +patternX: + help: "[fname]\n\t[Mythen3][Ctb][Xilinx Ctb] Loads ASCII pattern file directly to server (instead of executing line by line)" + command_name: "pattern" + actions: + PUT: + argc: 1 + require_det_id: true + function: setPattern + input: [ 'args[0]' ] + input_types: [ std::string ] + cast_input: [ false ] + output: [ 'args.front()' ] + +patword: + help: "[step or address] [64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] 64 bit pattern at address of pattern memory.\n\t[Ctb] read is same as executing pattern" + actions: + GET: + argc: 1 + require_det_id: true + function: getPatternWord + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + output: [ "'['","ToStringHex(arg0, 4)", '", "', "OutStringHex(t, 16)", '"]"' ] + PUT: + argc: 2 + require_det_id: true + function: setPatternWord + input: [ 'args[0]', 'args[1]' ] + input_types: [ int, uint64_t ] + cast_input: [ true, true ] + output: [ "'['", "ToStringHex(arg0, 4)", '", "', "ToStringHex(arg1, 16)", '"]"' ] + +patlimits: + help: "[start addr] [stop addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Limits of complete pattern" + actions: + GET: + argc: -1 + require_det_id: true + function: getPatternLoopAddresses + input: [ '"-1"' ] + input_types: [ int ] + cast_input: [ true ] + output: [ "OutStringHex(t, 4)" ] + PUT: + argc: -1 + require_det_id: true + function: setPatternLoopAddresses + input: [ '"-1"', 'args[0]', 'args[1]' ] + input_types: [ int, int, int ] + cast_input: [ true, true, true ] + output: [ "'['" , "ToStringHex(arg1, 4)" , '", "' , "ToStringHex(arg2, 4)", "']'" ] + +patloop: + help: "[0-6] [start addr] [stop addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Limits of the loop level provided.\n\t[Mythen3] Level options: 0-3 only." + actions: + GET: + argc: -1 + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + function: getPatternLoopAddresses + input: [ level ] + input_types: [ int ] + cast_input: [ false ] + output: [level,"' '" ,"OutStringHex(t, 4)" ] + PUT: + argc: -1 + extra_variables: + - name: start + type: int + value: "StringTo(args[iArg++])" + - name: stop + type: int + value: "StringTo(args[iArg++])" + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + function: setPatternLoopAddresses + input: [ level, start, stop ] + input_types: [ int, int, int ] + output: [level,"' '" , "'['" , "ToStringHex(start, 4)" , '", "' , "ToStringHex(stop, 4)", "']'" ] + +patloop0: + help: "Depreciated command. Use patloop." + inherit_actions: patloop + actions: + GET: + output: ["OutStringHex(t, 4)" ] + PUT: + output: [ "'['" , "ToStringHex(start, 4)" , '", "' , "ToStringHex(stop, 4)", "']'" ] + +patloop1: + inherit_actions: patloop0 + +patloop2: + inherit_actions: patloop0 + +patnloop: + help: "[0-6] [n_cycles] \n\t[Ctb][Mythen3][Xilinx Ctb] Number of cycles of the loop level provided.\n\t[Mythen3] Level options: 0-3 only." + actions: + GET: + argc: -1 + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: getPatternLoopCycles + input: [ level ] + input_types: [ int ] + cast_input: [ false ] + output: [ level,"' '" , "OutString(t)" ] + PUT: + argc: -1 + extra_variables: + - name: nloops + type: std::string + value: "args[iArg++]" + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: setPatternLoopCycles + input: [ level, nloops ] + input_types: [ int, int ] + cast_input: [ false, true ] + output: [ level,"' '" , nloops ] + +patnloop0: + help: "Depreciated command. Use patnloop." + inherit_actions: patnloop + actions: + GET: + output: [ "OutString(t)" ] + PUT: + output: [ "nloops" ] + +patnloop1: + inherit_actions: patnloop0 + +patnloop2: + inherit_actions: patnloop0 + +patwait: + help: "[0-6] [addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Wait address for loop level provided. \n\t[Mythen3] Level options: 0-3 only." + actions: + GET: + argc: -1 + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: getPatternWaitAddr + input: [ level ] + input_types: [ int ] + cast_input: [ false ] + output: [level,"' '" , "OutStringHex(t, 4)" ] + PUT: + argc: -1 + extra_variables: + - name: addr + type: int + value: "StringTo(args[iArg++])" + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: setPatternWaitAddr + input: [ level, addr ] + input_types: [ int, int ] + output: [level,"' '" , "ToStringHex(addr, 4)" ] + +patwait0: + help: "Depreciated command. Use patwait." + inherit_actions: patwait + actions: + GET: + output: [ "OutStringHex(t, 4)" ] + PUT: + output: [ "ToStringHex(addr, 4)" ] + +patwait1: + inherit_actions: patwait0 + +patwait2: + inherit_actions: patwait0 + +patwaittime: + help: "[0-6] [n_clk] \n\t[Ctb][Mythen3][Xilinx Ctb] Wait time in clock cycles for the loop provided.\n\t[Mythen3] Level options: 0-3 only." + actions: + GET: + argc: -1 + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: getPatternWaitTime + input: [ level ] + input_types: [ int ] + cast_input: [ false ] + output: [ level,"' '" , "OutString(t)" ] + PUT: + argc: -1 + extra_variables: + - name: waittime + type: uint64_t + value: "StringTo(args[iArg++])" + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + function: setPatternWaitTime + input: [ level, waittime ] + input_types: [ int, int ] + output: [level,"' '" , "waittime" ] + +patwaittime0: + help: "Depreciated command. Use patwaittime." + inherit_actions: patwaittime + actions: + GET: + output: [ "OutString(t)" ] + PUT: + output: [ "waittime" ] + +patwaittime1: + inherit_actions: patwaittime0 + +patwaittime2: + inherit_actions: patwaittime0 + +rx_jsonpara: + help: "[key1] [value1]\n\t[Receiver] Additional json header parameter streamed out from receiver. If not found in header, the pair is appended. An empty values deletes parameter. Max 20 characters for each key/value." + actions: + GET: + argc: 1 + require_det_id: true + function: getAdditionalJsonParameter + input: [ 'args[0]' ] + input_types: [ std::string ] + output: [ OutString(t) ] + PUT: + require_det_id: true + function: setAdditionalJsonParameter + args: + - argc: 1 + input: [ 'args[0]', '""' ] + arg_types: [ std::string ] + input_types: [ std::string, std::string ] + cast_input: [ false, false ] + output: [ 'args[0]', '" deleted"' ] + - argc: 2 + input: [ 'args[0]', 'args[1]' ] + input_types: [ std::string, std::string ] + cast_input: [ false, false ] + output: [ '"{"', 'args[0]', '": "', 'args[1]', '"}"' ] + +programfpga: + help: "[fname.pof | fname.rbf (full path)][(opitonal)--force-delete-normal-file]\n\t[Jungfrau][Moench][Ctb] Programs FPGA from pof file (full path). Then, detector controller is rebooted. \n\t\tUse --force-delete-normal-file argument, if normal file found in device tree, it must be deleted, a new device drive created and programming continued.\n\t[Mythen3][Gotthard2] Programs FPGA from rbf file (full path). Then, detector controller is rebooted." + actions: + PUT: + require_det_id: true + function: programFPGA + output: [ '"successful"' ] + args: + - argc: 1 + input: [ 'args[0]', '"0"' ] + input_types: [ std::string, bool ] + arg_types: [special::path] + cast_input: [ false, true ] + - argc: 2 + arg_types: [special::path, special::force-delete-normal-file] + exceptions: + - condition: 'args[1] != "--force-delete-normal-file"' + message: '"Could not scan second argument. Did you mean --force-delete-normal-file?"' + input: [ 'args[0]', '"1"' ] + input_types: [ std::string, bool ] + cast_input: [ false, true ] + +updatedetectorserver: + help: "[server_name with full path]\n\t[Jungfrau][Moench][Eiger][Ctb][Mythen3][Gotthard2] Copies detector server via TCP (without tftp). Makes a symbolic link with a shorter name (without vx.x.x). Then, detector controller reboots (except Eiger).\n\t[Jungfrau][Moench][Ctb]Also changes respawn server to the link, which is effective after a reboot." + actions: + PUT: + argc: 1 + require_det_id: true + function: updateDetectorServer + input: [ 'args[0]' ] + arg_types: [special::path] + input_types: [ std::string ] + output: [ '"successful"' ] + +updatekernel: + help: "[kernel_name with full path]\n\t[Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Advanced Command!! You could damage the detector. Please use with caution.\n\tUpdates the kernel image. Then, detector controller reboots with new kernel." + actions: + PUT: + argc: 1 + require_det_id: true + function: updateKernel + input: [ 'args[0]' ] + arg_types: [special::path] + input_types: [ std::string ] + output: [ '"successful"' ] + +update: + help: "\n\tWithout tftp: [server_name (incl fullpath)] [fname.pof (incl full path)] This does not use tftp.\n\t\t[Jungfrau][Moench][Gotthard][Ctb] Updates the firmware, detector server, deletes old server, creates the symbolic link and then reboots detector controller. \n\t\t[Mythen3][Gotthard2] will require a script to start up the shorter named server link at start up. \n\t\tserver_name is full path name of detector server binary\n\t\tfname is full path of programming file" + actions: + PUT: + argc: 2 + exceptions: + - condition: 'args[args.size() - 1].find(".pof") == std::string::npos && args[args.size() - 1].find(".rbf") == std::string::npos' + message: '"Programming file must be a pof/rbf file."' + require_det_id: true + function: updateFirmwareAndServer + input: [ 'args[0]', 'args[1]' ] + arg_types: [ special::path, special::path ] + input_types: [ std::string, std::string ] + output: [ '"successful"' ] + +reg: + help: "[address] [32 bit value]\n\t[Mythen3][Gotthard2] Reads/writes to a 32 bit register in hex. Advanced Function!\n\tGoes to stop server. Hence, can be called while calling blocking acquire().\n\t[Eiger] +0x100 for only left, +0x200 for only right." + actions: + GET: + argc: 1 + require_det_id: true + function: readRegister + input: [ 'args[0]' ] + input_types: [ uint32_t ] + cast_input: [ true ] + output: [ OutStringHex(t) ] + PUT: + argc: 2 + require_det_id: true + function: writeRegister + input: [ 'args[0]', 'args[1]' ] + input_types: [ uint32_t, uint32_t ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +adcreg: + help: "[address] [value]\n\t[Jungfrau][Moench][Ctb][Gotthard] Writes to an adc register in hex. Advanced user Function!" + actions: + PUT: + argc: 2 + require_det_id: true + function: writeAdcRegister + input: [ 'args[0]', 'args[1]' ] + input_types: [ uint32_t, uint32_t ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +getbit: + help: "[reg address in hex] [bit index]\n\tGets bit in address." + actions: + GET: + argc: 2 + exceptions: + - condition: 'StringTo(args[1]) < 0 || StringTo(args[1]) > 31' + message: '"Bit number out of range: " + args[1]' + require_det_id: true + function: getBit + input: [ 'args[0]', 'args[1]' ] + input_types: [ uint32_t, int ] + cast_input: [ true, true ] + output: [ OutString(t) ] + +Setbit: + template: true + actions: + PUT: + argc: 2 + exceptions: + - condition: 'StringTo(args[1]) < 0 || StringTo(args[1]) > 31' + message: '"Bit number out of range: " + args[1]' + require_det_id: true + function: setBit + input: [ 'args[0]', 'args[1]' ] + input_types: [ uint32_t, int ] + cast_input: [ true, true ] + output: [ ToString(args) ] + +setbit: + inherit_actions: Setbit + help: "[reg address in hex] [bit index]\n\tSets bit in address." + actions: + PUT: + function: setBit + +clearbit: + inherit_actions: Setbit + help: "[reg address in hex] [bit index]\n\tClears bit in address." + actions: + PUT: + function: clearBit + +initialchecks: + help: "[0, 1]\n\t[Mythen3][Gotthard2] Enable or disable intial compatibility and other checks at detector start up. It is enabled by default. Must come before 'hostname' command to take effect. Can be used to reprogram fpga when current firmware is incompatible.\n\tAdvanced User function!" + actions: + GET: + argc: 0 + check_det_id: true + function: getInitialChecks + output: [ t ] + PUT: + argc: 1 + check_det_id: true + function: setInitialChecks + input: [ 'args[0]' ] + input_types: [ bool ] + cast_input: [ true ] + output: [ args.front() ] + +user: + help: "\n\tUser details from shared memory (hostname, type, PID, User, Date)." + actions: + GET: + argc: 0 + check_det_id: true + function: getUserDetails + output: [ t ] + + + + + + diff --git a/slsDetectorSoftware/generator/commands_parser/__init__.py b/slsDetectorSoftware/generator/commands_parser/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/slsDetectorSoftware/generator/commands_parser/commands_parser.py b/slsDetectorSoftware/generator/commands_parser/commands_parser.py new file mode 100644 index 000000000..9a11cd789 --- /dev/null +++ b/slsDetectorSoftware/generator/commands_parser/commands_parser.py @@ -0,0 +1,379 @@ +import copy +import logging +import yaml +from pathlib import Path + + +class CommandParser: + def __init__( + self, + commands_file: Path = Path(__file__).parent.parent / 'commands.yaml', + output_file: Path = Path(__file__).parent.parent / 'extended_commands.yaml' + ): + + self.output_file = output_file + self.commands_file = commands_file + self.fp = self.commands_file.open('r') + self.simple_commands = yaml.unsafe_load(self.fp) + self.extended_commands = {} + self.argc_set = set() + self.logger = logging.getLogger('command_parser') + self.__current_action: str = '' + FORMAT = '[%(levelname)s] %(message)s' + logging.basicConfig(format=FORMAT, level=logging.INFO) + + self.propagate_config = { + 'require_det_id': False, + 'convert_det_id': True, + 'input': [], + 'input_types': [], + 'function': '', + 'output': [], + 'cast_input': [], + 'check_det_id': False, + 'arg_types': [], + # 'store_result_in_t': False, # always true in GET action + } + self.default_config = { + 'infer_action': True, + 'help': '', + 'actions': {} + } + + def _verify_argument(self, arg, infer_action, command_name, action): + if arg['function'] == '' and 'ctb_output_list' not in arg: + special_exception_message_list = ["Cannot put", "Cannot get"] + if 'exceptions' in arg and arg['exceptions'][0]['condition'] == 'true' and any(ele in arg['exceptions'][0]['message'] for ele in special_exception_message_list): + self.logger.warning(f"{command_name} has a special exception message for {action}.") + else: + self.logger.warning(f"{command_name} [{action}] does not have a function") + if len(arg['input_types']) != len(arg['input']): + raise ValueError(f'Argument {arg} does not have the correct number of inputs') + if 'separate_time_units' in arg: + + if arg['separate_time_units']['input'] == "": + raise ValueError(f'Argument {arg} does not have the correct number of inputs for separate_time_units') + if len(arg['separate_time_units']['output']) != 2: + raise ValueError(f'Argument {arg} does not have the correct number of outputs for separate_time_units') + if 'convert_to_time' in arg: + if len(arg['convert_to_time']['input']) != 2: + raise ValueError(f'Argument {arg} does not have the correct number of inputs for convert_to_time') + if len(arg['convert_to_time']['output']) == "": + raise ValueError(f'Argument {arg} does not have the correct number of outputs for convert_to_time') + # if infer_action: + # if arg['argc'] in self.argc_set: + # raise ValueError(f'Argument {arg} has a duplicate argc') + # self.argc_set.add(arg['argc']) + + def verify_format(self): + # todo verify detectors + # todo verify circular inheritance + # todo verify child commands (those that inherit) + # todo verify that there is no wrongly typed parameters + # todo verify that the same number of input_types and input are given + # todo verify that each argument has argc (error can happen when inheriting) + for command_name, command in self.simple_commands.items(): + if 'inherit_actions' in command or 'template' in command and command[ + 'template'] or 'is_description' in command and command['is_description']: + continue + self.argc_set = set() + if 'infer_action' not in command: + command['infer_action'] = True + if 'actions' not in command: + raise ValueError(f'Command {command_name} does not have any actions') + for action, action_params in command['actions'].items(): + if 'argc' in action_params: + if 'args' in action_params: + raise ValueError(f'Action {action} has both argc and args') + arg = {**self.propagate_config, **action_params} + self._verify_argument(arg, command['infer_action'], command_name, action) + elif 'args' in action_params: + if type(action_params['args']) is not list: + raise ValueError(f'Action {action} args is not a list') + if len(action_params['args']) == 0: + raise ValueError(f'Action {action} args is empty') + action_args = {**self.propagate_config, **action_params} + del action_args['args'] + for arg in action_params['args']: + arg = {**action_args, **arg} + self._verify_argument(arg, command['infer_action'], command_name, action) + self.logger.info('Commands file is valid ✅️') + return True + + def _parse_inherited_command(self, parent, command, simple_parent): + """ + parse a command that inherits from parent command + :param parent: parsed parent command + :param command: the current command + :param simple_parent: unparsed parent command + :return: parsed command + """ + # deepcopy parent and command to avoid modifying the originals + command = copy.deepcopy(command) + config = copy.deepcopy(parent) + # add help + if 'help' in command: + config['help'] = command['help'] + if 'actions' not in command: + return config + for action, command_params in command['actions'].items(): + self.__current_action = action + if action not in config['actions']: + # todo: handle this case + pass + parent_params = config['actions'][action] + if 'args' in command_params: + # child has args => inherit action level params from parent + override with child args + use child's + # action level params + context = {**self.propagate_config, **simple_parent['actions'][action], **command_params} + config['actions'][action]['args'] = self.parse_action(context, command_params['args']) + elif 'argc' in command_params: + # child has action level args (argc) + context = {**self.propagate_config, **simple_parent['actions'][action], **command_params} + config['actions'][action]['args'] = self.parse_action(context, []) + else: + # child does not have args => use parent's action level params + override with child's action level + if 'args' in parent_params: + config['actions'][action]['args'] = self.parse_action({}, parent_params['args'], command_params) + + if 'detectors' in command_params: + if command_params['detectors'] is None: + # if child has an empty detector section, then delete the parent's detector section + del config['actions'][action]['detectors'] + continue + + for detector_name, detector_params in command_params['detectors'].items(): + if 'detectors' not in config['actions'][action]: + config['actions'][action]['detectors'] = {} + config_detector = config['actions'][action]['detectors'] + if 'detectors' not in parent_params or detector_name not in parent_params['detectors']: + if 'args' in detector_params: + # if child has detector args and parent does not have detectors + # => use child's detector args + context = {**self.propagate_config, **simple_parent['actions'][action], **detector_params} + config_detector[detector_name] = self.parse_action(context, detector_params['args']) + elif 'args' in parent_params: + # if child does not have detector args and parent does not have detectors + # => use the child's action args + context = {**self.propagate_config, **simple_parent['actions'][action]} + config_detector[detector_name] = self.parse_action(context, + config['actions'][action]['args'], + detector_params) + elif detector_name in parent_params['detectors']: + + if 'args' in detector_params: + # child and parent have the same detector and child has detector args + # => use child's detector args + context = { + **self.propagate_config, + **simple_parent['actions'][action], + **simple_parent['actions'][action]['detectors'][detector_name], + + } + config_detector[detector_name] = self.parse_action(context, detector_params['args']) + else: + # child and parent have the same detector and child does not have detector args + # => use parent's detector args + priority_context = {**command_params, **detector_params} + config_detector[detector_name] = self.parse_action( + {}, + parent_params['detectors'][detector_name], + priority_context + ) + + else: + pass + + return config + + def _parse_command(self, command): + """ + logic function for parse_command. + This function is recursive + :return: parsed command + """ + config = self.default_config.copy() + config.update(command) + config['actions'] = {} + + # check if command inherits from another command + if 'inherit_actions' in command: + if command['inherit_actions'] in self.extended_commands: + # if parent command has already been parsed, use that + parent = self.extended_commands[command['inherit_actions']] + else: + # if parent command has not been parsed, parse it + parent = self.parse_command(command['inherit_actions']) + # parse the current command and merge it with the parent command + config = self._parse_inherited_command(parent, command, self.simple_commands[command['inherit_actions']]) + return config + + if 'actions' not in command: + return config + + for action, action_params in command['actions'].items(): + self.__current_action = action + + config['actions'][action] = {} + config_action = config['actions'][action] + # the context in the current command and the current action + action_context = {**self.propagate_config, **action_params} + if 'args' not in action_params: + # parse the action with the action context + if action_params.keys() != {'detectors'}: + config_action['args'] = self.parse_action(action_context, []) + else: + config_action['args'] = self.parse_action(action_context, action_params['args']) + + # check if the action has detectors + if 'detectors' in action_params: + config_action['detectors'] = {} + for detector_name, detector_params in action_params['detectors'].items(): + # get the context for the detector and merge it with the action context + detector_context = {**action_context, **detector_params} + + # if the detector does not have args, then use the action args + # otherwise, use the detector args and override the action args + tmp_args = [] + if 'args' not in detector_params: + if 'args' in config_action: + tmp_args = config_action['args'] + else: + tmp_args = detector_params['args'] + detector_params['args'] = tmp_args + + # parse the action with the detector context + config_action['detectors'][detector_name] = self.parse_action(detector_context, + tmp_args, + detector_params) + return config + + def sanitize_argument(func): + def f(self, action_context, args_old, priority_context={}): + args = func(self, action_context, args_old, priority_context) + for i, arg in enumerate(args): + if 'args' in arg: + del arg['args'] + if 'detectors' in arg: + del arg['detectors'] + if not arg['cast_input']: + # if the cast_input is empty, then set it to False + arg['cast_input'] = [False] * len(arg['input']) + + elif len(arg['cast_input']) != len(arg['input']): + # if the cast_input is not the same length as the input, then set it to False + arg['cast_input'] = [False] * len(arg['input']) + self.logger.warning(f'cast_input for {arg["function"]} ' + f'with argc: {arg["argc"]} has different length than input') + if 'store_result_in_t' not in arg: + if self.__current_action == 'GET': + arg['store_result_in_t'] = True + else: + arg['store_result_in_t'] = False + return args + + return f + + @sanitize_argument + def parse_action(self, action_context, args, priority_context={}): + """ + parse an action + :param action_context: context of the action + :param args: arguments to be used in the action + :param priority_context: context that should override the arguments params + :return: parsed action + """ + + def add_cast_input(argument): + return argument + + # deepcopy action_context to avoid modifying the original + action_context = {**self.propagate_config, **copy.deepcopy(action_context)} + priority_context = copy.deepcopy(priority_context) + + if 'detectors' in action_context: + del action_context['detectors'] + if 'detectors' in priority_context: + del priority_context['detectors'] + + if args == []: + # if there are no arguments, then the action has only one argument + context = {**action_context, **priority_context} + return [add_cast_input(context)] + + ret_args = [] + if 'args' in action_context: + del action_context['args'] + if 'args' in priority_context: + del priority_context['args'] + + # if there are arguments, then merge them with the action context and priority context + for arg in args: + arg = {**action_context, **arg, **priority_context} + ret_args.append(add_cast_input(arg)) + return ret_args + + def parse_command(self, command_name): + """ + parse a single command + This function is recursive + + :param command_name: name of the command to parse + :return: the parsed command + """ + command = self.simple_commands[command_name] + parsed_command = self._parse_command(command) + if 'function_alias' not in command: + if 'command_name' in command: + parsed_command['function_alias'] = command['command_name'] + else: + parsed_command['function_alias'] = command_name + + if 'command_name' not in command: + parsed_command['command_name'] = command_name + + if 'template' in command and command['template']: + return parsed_command + self.extended_commands[command_name] = parsed_command + return self.extended_commands[command_name] + + def parse_all_commands(self): + """ + iterate over all commands in yaml file and parse them + :return: None + """ + + for command_name in self.simple_commands: + # todo remove this (added for debugging) + if command_name != 'xtiming': + self.parse_command(command_name) + + # post-process the parsed commands + self.post_process_all_commands() + + yaml.Dumper.ignore_aliases = lambda *args: True + self.logger.info(f'parsed {len(self.extended_commands)} commands') + yaml.dump(self.extended_commands, self.output_file.open('w'), default_flow_style=False) + + def post_process_all_commands(self): + for command_name, command in self.extended_commands.items(): + if 'is_description' in command and command['is_description']: + continue + for action_name, action, in command['actions'].items(): + for arg in action['args']: + if arg['argc'] == 0: + arg['arg_types'] = [] + continue + if arg['argc'] == -1: + pass + if arg['arg_types'] == []: + arg['arg_types'] = arg['input_types'] + + +# command_parser = CommandParser(Path( +# '/afs/psi.ch/user/b/braham_b/github/slsDetectorPackage/slsDetectorSoftware/generator/tests/command_parser/data/detectors.yaml')) +command_parser = CommandParser() + +if __name__ == '__main__': + command_parser.verify_format() + command_parser.parse_all_commands() diff --git a/slsDetectorSoftware/generator/cpp_codegen/__init__.py b/slsDetectorSoftware/generator/cpp_codegen/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/slsDetectorSoftware/generator/cpp_codegen/codegen.py b/slsDetectorSoftware/generator/cpp_codegen/codegen.py new file mode 100644 index 000000000..ffb2c52e8 --- /dev/null +++ b/slsDetectorSoftware/generator/cpp_codegen/codegen.py @@ -0,0 +1,282 @@ +class CodeGenerator: + def __init__(self): + self.file = None + self.actions_dict = { + 'GET': 'slsDetectorDefs::GET_ACTION', + 'PUT': 'slsDetectorDefs::PUT_ACTION', + 'READOUT': 'slsDetectorDefs::READOUT_ACTION', + 'HELP': 'slsDetectorDefs::HELP_ACTION', + } + self.template_file = None + + def open(self, path): + self.file = path.open('w') + + def close(self): + self.file.close() + self.file = None + + def write_line(self, line): + self.file.write(line + '\n') + + def write(self, text): + self.file.write(text) + + def write_opening(self, path): + """Write the opening file for the caller.cpp file""" + self.template_file = path.open('r') + for line in self.template_file: + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE" in line: + return + self.file.write(line) + + def write_closing(self): + """Write the closing file for the caller.cpp file""" + for line in self.template_file.readlines(): + self.file.write(line) + self.template_file.close() + + def write_header(self, in_path, out_path, commands, deprecated_commands): + """Write the header file for the caller.h file""" + with out_path.open('w') as fp: + with in_path.open('r') as fp2: + for line in fp2: + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1)" in line: + for command_name, command in commands.items(): + if 'duplicate_function' in command and command['duplicate_function']: + continue + fp.write(f'std::string {command["function_alias"]}(int action);\n') + continue + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (2)" in line: + map_string = '' + for command_name, command in commands.items(): + map_string += f'{{"{command_name}", &Caller::{command["function_alias"]}}},' + fp.write(map_string[:-1] + '\n') + continue + + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (3)" in line: + for key, value in deprecated_commands.items(): + fp.write(f'{{"{key}", "{value}"}},\n') + continue + + fp.write(line) + + def write_infer_header(self, in_path, out_path, commands): + """Write the header file for the inferAction.h file""" + with out_path.open('w+') as fp: + with in_path.open('r') as fp2: + for line in fp2: + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1) - DO NOT REMOVE" in line: + for command_name, command in commands.items(): + if 'duplicate_function' in command and command['duplicate_function']: + continue + + fp.write(f'int {command["function_alias"]}();\n') + continue + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (2) - DO NOT REMOVE" in line: + map_string = '' + for command_name, command in commands.items(): + map_string += f'{{"{command_name}", &InferAction::{command["function_alias"]}}},' + fp.write(map_string[:-1] + '\n') + continue + fp.write(line) + + def write_infer_cpp(self, in_path, out_path, commands, non_dist, type_dist): + """Write the source file for the inferAction.cpp file""" + with in_path.open('r') as fp2: + for line in fp2: + if "THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1) - DO NOT REMOVE" in line: + for command_name, command in commands.items(): + if 'duplicate_function' in command and command['duplicate_function']: + continue + + with function('int', f"InferAction::{command['function_alias']}", []) as f: + if (command_name, -1) in non_dist| type_dist: + self.write_line( + f'throw RuntimeError("sls_detector is disabled for command: {command_name}. Use sls_detector_get or sls_detector_put");') + elif not command['infer_action']: + self.write_line('throw RuntimeError("infer_action is disabled");') + else: + checked_argcs = set() + for action, action_params in command['actions'].items(): + for arg in action_params['args']: + if arg['argc'] in checked_argcs: + continue + checked_argcs.add(arg['argc']) + with if_block(f'args.size() == {arg["argc"]}'): + # check if this argc is not distinguishable + if (command_name, arg["argc"]) in non_dist | type_dist: + self.write_line( + f'throw RuntimeError("sls_detector is disabled for command: {command_name} with number of arguments {arg["argc"]}. Use sls_detector_get or sls_detector_put");') + else: + self.write_line(f'return {self.actions_dict[action]};') + with else_block(): + self.write_line( + 'throw RuntimeError("Could not infer action: Wrong number of arguments");') + continue + self.write_line(line) + + def write_check_arg(self): + pass + + def write_arg(self, args, action, command_name): + for arg in args: + if arg['argc'] != -1: + if_block(f'args.size() == {arg["argc"]}',).__enter__() + if 'pattern_command' in arg and arg['pattern_command']: + self.write_line(f'int level = -1, iArg = 0, ' + f'nGetArgs = {arg["pattern_command"]["nGetArgs"]},' + f' nPutArgs = {arg["pattern_command"]["nPutArgs"]};\nGetLevelAndUpdateArgIndex(action, ' + f'"{arg["pattern_command"]["command_name"]}", level, iArg, nGetArgs,nPutArgs);' + ) + + if 'extra_variables' in arg: + for var in arg['extra_variables']: + codegen.write_line(f'{var["type"]} {var["name"]} = {var["value"]};') + if 'separate_time_units' in arg and arg['separate_time_units']: + self.write_line(f'std::string tmp_time({arg["separate_time_units"]["input"]});') + self.write_line(f'std::string {arg["separate_time_units"]["output"][1]}' + f' = RemoveUnit(tmp_time);') + self.write_line(f'auto {arg["separate_time_units"]["output"][0]} = ' + f'StringTo < time::ns > (tmp_time,' + f' {arg["separate_time_units"]["output"][1]});') + if 'convert_to_time' in arg and arg['convert_to_time']: + self.write_line(f'auto {arg["convert_to_time"]["output"]} = ' + f'StringTo < time::ns > ({", ".join(arg["convert_to_time"]["input"])});') + input_arguments = [] + if 'exceptions' in arg: + for exception in arg['exceptions']: + self.write_line(f'if ({exception["condition"]}) {{ throw RuntimeError({exception["message"]}); }}') + if 'check_det_id' in arg and arg['check_det_id']: + self.write_line( + f'if (det_id != -1) {{ throw RuntimeError("Cannot execute {command_name} at module level"); }} ' + ) + # only used for 3 commands :( + if 'ctb_output_list' in arg: + self.write_line(f""" + std::string suffix = " {arg['ctb_output_list']['suffix']}"; + auto t = det->{arg['ctb_output_list']['GETFCNLIST']}();""") + if arg['ctb_output_list']['GETFCNNAME'] != '': + self.write_line(f""" + auto names = det->{arg['ctb_output_list']['GETFCNNAME']}(); + auto name_it = names.begin();""") + self.write_line("os << '[';") + with if_block(f't.size() > 0'): + self.write_line(f""" + auto it = t.cbegin(); + os << ToString({arg['ctb_output_list']['printable_name']}) << ' '; + os << OutString(det->{arg['ctb_output_list']['GETFCN']}(*it++, std::vector{{det_id}}))<< suffix; + while (it != t.cend()) {{ + os << ", " << ToString({arg['ctb_output_list']['printable_name']}) << ' '; + os << OutString(det->{arg['ctb_output_list']['GETFCN']}(*it++, std::vector{{det_id}}))<< suffix; + }} + """) + self.write_line('os << "]\\n";') + if arg['argc'] != -1: + if_block().__exit__() + + return + + for i in range(len(arg['input'])): + if arg['cast_input'][i]: + self.write_line( + f'auto arg{i} = StringTo<{arg["input_types"][i]}>({arg["input"][i]});') + input_arguments.append(f'arg{i}') + else: + input_arguments.append(arg["input"][i]) + if 'require_det_id' in arg and arg['require_det_id']: + if 'convert_det_id' in arg and arg['convert_det_id']: + input_arguments.append("std::vector{ det_id }") + else: + input_arguments.append("det_id") + + input_arguments = ", ".join(input_arguments) + # call function + if arg["function"]: + if arg['store_result_in_t']: + self.write_line(f'auto t = det->{arg["function"]}({input_arguments});') + else: + self.write_line(f'det->{arg["function"]}({input_arguments});') + else: + pass #We have no function so skip block + + output_args = [] + for output in arg['output']: + output_args.append(output) + if len(output_args) > 0: + self.write_line(f"os << {'<< '.join(output_args)} << '\\n';") + + if arg['argc'] != -1: + if_block().__exit__() + + +class if_block: + def __init__(self, condition="", elseif=False): + self.condition = condition + self.elseif = elseif + self.block = False + + def __enter__(self): + if self.elseif: + codegen.write_line('else if (' + self.condition + ') {') + else: + codegen.write_line('if (' + self.condition + ') {') + if self.block: + codegen.write_line('{\n') + + def __exit__(self, *args): + codegen.write_line('}') + if self.block: + codegen.write_line('}') + codegen.write_line('') + + +class else_block: + def __init__(self): + pass + + def __enter__(self): + codegen.write_line('else {') + codegen.write_line('') + + def __exit__(self, *args): + codegen.write_line('}') + codegen.write_line('') + + +class for_block: + def __init__(self, condition): + self.condition = condition + + def __enter__(self): + codegen.write_line('for (' + self.condition + ') {') + codegen.write_line('') + + def __exit__(self, *args): + codegen.write_line('}') + codegen.write_line('') + + +class function: + def __init__(self, return_type, name, args: list[tuple[str, str]]): + self.name = name + self.args = args + self.return_type = return_type + + def __enter__(self): + s = "" + for arg in self.args: + arg_type, arg_name = arg + s += arg_type + ' ' + arg_name + ', ' + s = s[:-2] + codegen.write_line(self.return_type + ' ' + self.name + + f'({s}) {{') + codegen.write_line('') + return self + + def __exit__(self, *args): + codegen.write_line('}') + codegen.write_line('') + + +codegen = CodeGenerator() diff --git a/slsDetectorSoftware/generator/deprecated_commands.yaml b/slsDetectorSoftware/generator/deprecated_commands.yaml new file mode 100644 index 000000000..22788505d --- /dev/null +++ b/slsDetectorSoftware/generator/deprecated_commands.yaml @@ -0,0 +1,176 @@ +#configuration +detectorversion: firmwareversion +softwareversion: detectorserverversion +receiverversion: rx_version +detectornumber: serialnumber +thisversion: clientversion +detsizechan: detsize +trimdir: settingspath +settingsdir: settingspath +flippeddatax: fliprows + +#acquisition parameters +cycles: triggers +cyclesl: triggersl +clkdivider: readoutspeed +speed: readoutspeed +vhighvoltage: highvoltage +digitest: imagetest +filter: filterresistor +readnlines: readnrows + +# temperature + +# super old dacs +vtr: vtrim +vrf: vrpreamp +vrs: vrshaper +vcall: vcal +vis: vishaper +vshaper: vrshaper +vpreamp: vrpreamp +vshaperneg: vrshaper_n +viinsh: vishaper +vpl: vcal_n +vph: vcal_p + +# dacs +vthreshold: dac +vsvp: dac +vsvn: dac +vtrim: dac +vrpreamp: dac +vrshaper: dac +vtgstv: dac +vcmp_ll: dac +vcmp_lr: dac +vcal: dac +vcmp_rl: dac +vcmp_rr: dac +rxb_rb: dac +rxb_lb: dac +vcp: dac +vcn: dac +vishaper: dac +iodelay: dac +vref_ds: dac +vcascn_pb: dac +vcascp_pb: dac +vout_cm: dac +vcasc_out: dac +vin_cm: dac +vref_comp: dac +ib_test_c: dac +vrshaper_n: dac +vipre: dac +vdcsh: dac +vth1: dac +vth2: dac +vth3: dac +vcal_n: dac +vcal_p: dac +vcassh: dac +vcas: dac +vicin: dac +vipre_out: dac +vref_h_adc: dac +vb_comp_fe: dac +vb_comp_adc: dac +vcom_cds: dac +vref_rstore: dac +vb_opa_1st: dac +vref_comp_fe: dac +vcom_adc1: dac +vref_prech: dac +vref_l_adc: dac +vref_cds: dac +vb_cs: dac +vb_opa_fd: dac +vcom_adc2: dac +vb_ds: dac +vb_comp: dac +vb_pixbuf: dac +vin_com: dac +vdd_prot: dac +vbp_colbuf: dac +vb_sda: dac +vcasc_sfp: dac +vipre_cds: dac +ibias_sfp: dac + +defaultdacs: resetdacs + +#acquisition +busy: clearbusy +receiver: rx_status +framescaught: rx_framescaught +startingfnum: nextframenumber + +#Network Configuration (Detector<->Receiver) +detectorip: udp_srcip +detectorip2: udp_srcip2 +detectormac: udp_srcmac +detectormac2: udp_srcmac2 +rx_udpip: udp_dstip +rx_udpip2: udp_dstip2 +rx_udpmac: udp_dstmac +rx_udpmac2: udp_dstmac2 +rx_udpport: udp_dstport +rx_udpport2: udp_dstport2 +flowcontrol_10g: flowcontrol10g +txndelay_frame: txdelay_frame +txndelay_left: txdelay_left +txndelay_right: txdelay_right + +#Receiver Config +r_silent: rx_silent +r_discardpolicy: rx_discardpolicy +r_padding: rx_padding +r_lock: rx_lock +r_lastclient: rx_lastclient + +#File +fileformat: fformat +outdir: fpath +index: findex +enablefwrite: fwrite +masterfile: fmaster +overwrite: foverwrite +r_framesperfile: rx_framesperfile + +#ZMQ Streaming Parameters (Receiver<->Client) +r_readfreq: rx_zmqfreq +rx_readfreq: rx_zmqfreq +rx_datastream: rx_zmqstream + +#Eiger Specific +resmat: partialreset + +#Jungfrau Specific +storagecells: extrastoragecells +auto_comp_disable: autocompdisable +comp_disable_time: compdisabletime + +#Gotthard Specific +#Gotthard2 Specific +#Mythen3 Specific +#CTB Specific +adc: slowadc +flags: romode +i_a: im_a +i_b: im_b +i_c: im_c +i_d: im_d +i_io: im_io + +#Pattern +#Moench + +#Advanced +copydetectorserver: updatedetectorserver + +#Insignificant +nframes: framecounter +now: runtime +timestamp: frametime +frameindex: rx_frameindex \ No newline at end of file diff --git a/slsDetectorSoftware/generator/extended_commands.yaml b/slsDetectorSoftware/generator/extended_commands.yaml new file mode 100644 index 000000000..c5e5c67b2 --- /dev/null +++ b/slsDetectorSoftware/generator/extended_commands.yaml @@ -0,0 +1,13813 @@ +acquire: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: acquire + function_alias: acquire + help: '' + infer_action: true + is_description: true +activate: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getActive + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setActive + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: activate + function_alias: activate + help: "[0, 1] \n\t[Eiger] 1 is default. 0 deactivates readout and does not send\ + \ data." + infer_action: true + template: true +adcclk: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getADCClock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setADCClock + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: adcclk + function_alias: adcclk + help: "[n_clk in MHz]\n\t[Ctb] ADC clock frequency in MHz." + infer_action: true + template: true +adcenable: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getADCEnableMask + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint32_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setADCEnableMask + input: + - args[0] + input_types: + - uint32_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: adcenable + function_alias: adcenable + help: "[bitmask]\n\t[Ctb] ADC Enable Mask for 1Gb Enable for each 32 ADC channel." + infer_action: true + template: true +adcenable10g: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTenGigaADCEnableMask + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint32_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTenGigaADCEnableMask + input: + - args[0] + input_types: + - uint32_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: adcenable10g + function_alias: adcenable10g + help: "[bitmask]\n\t[Ctb] ADC Enable Mask for 10Gb mode for each 32 ADC channel.\ + \ However, if any of a consecutive 4 bits are enabled, the complete 4 bits are\ + \ enabled." + infer_action: true + template: true +adcindex: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: getAdcIndex + input: + - args[0] + input_types: + - std::string + output: + - static_cast(t) + require_det_id: false + store_result_in_t: true + command_name: adcindex + function_alias: adcindex + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the adc index for the given name." + infer_action: true + template: true +adcinvert: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getADCInvert + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint32_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setADCInvert + input: + - args[0] + input_types: + - uint32_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: adcinvert + function_alias: adcinvert + help: "[bitmask]\n\t[Ctb][Jungfrau][Moench] ADC Inversion Mask.\n\t[Jungfrau][Moench]\ + \ Inversions on top of the default mask." + infer_action: true + template: true +adclist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getAdcNames + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + - condition: cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: '"This detector already has fixed dac names. Cannot change them."' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setAdcNames + input: + - args + input_types: + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: adclist + function_alias: adclist + help: "[adcname1 adcname2 .. adcname32] \n\t\t[Ctb][Xilinx_Ctb] Set the list of\ + \ adc names for this board." + infer_action: true + template: true +adcname: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: getAdcName + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - std::string + argc: 2 + cast_input: + - true + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: setAdcName + input: + - args[0] + - args[1] + input_types: + - int + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: adcname + function_alias: adcname + help: "[0-31][name] \n\t\t[Ctb][Xilinx_Ctb] Set the adc at the given position to\ + \ the given name." + infer_action: true + template: true +adcphase: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 + message: '"adcphase not implemented for this detector"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getADCPhase + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::deg + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 + message: '"adcphase not implemented for this detector"' + - condition: args[0] != "deg" + message: '"Unknown adcphase argument " + args[0] + ". Did you mean deg? "' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getADCPhaseInDegrees + input: [] + input_types: [] + output: + - OutString(t) + - '" deg"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 + message: '"adcphase not implemented for this detector"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setADCPhase + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + - arg_types: + - int + - special::deg + argc: 2 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 + message: '"adcphase not implemented for this detector"' + - condition: args[1] != "deg" + message: '"Unknown adcphase 2nd argument " + args[1] + ". Did you mean deg?"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setADCPhaseInDegrees + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: adcphase + function_alias: adcphase + help: "[n_value] [(optional)deg]\n\t[Jungfrau][Moench][Ctb][Gotthard] Phase shift\ + \ of ADC clock. \n\t[Jungfrau][Moench] Absolute phase shift. If deg used, then\ + \ shift in degrees. Changing Speed also resets adcphase to recommended defaults.\n\ + \t[Ctb] Absolute phase shift. If deg used, then shift in degrees. Changing adcclk\ + \ also resets adcphase and sets it to previous values.\n\t[Gotthard] Relative\ + \ phase shift. Cannot get" + infer_action: true +adcpipeline: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getADCPipeline + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setADCPipeline + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: adcpipeline + function_alias: adcpipeline + help: "[n_value]\n\t[Ctb][Moench] Pipeline for ADC clock." + infer_action: true + template: true +adcreg: + actions: + PUT: + args: + - arg_types: + - uint32_t + - uint32_t + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: writeAdcRegister + input: + - args[0] + - args[1] + input_types: + - uint32_t + - uint32_t + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: adcreg + function_alias: adcreg + help: "[address] [value]\n\t[Jungfrau][Moench][Ctb][Gotthard] Writes to an adc register\ + \ in hex. Advanced user Function!" + infer_action: true +adcvpp: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getADCVpp + input: + - '"0"' + input_types: + - bool + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_type: + - special::mv + arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: (args[0] != "mv") && (args[0] != "mV") + message: '"Unknown argument " + args[0] + ". Did you mean mV?"' + function: getADCVpp + input: + - '"1"' + input_types: + - bool + output: + - OutString(t) + - '" mV"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setADCVpp + input: + - args[0] + - '"0"' + input_types: + - int + - bool + output: + - args[0] + require_det_id: true + store_result_in_t: false + - arg_types: + - int + - special::mv + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: (args[1] != "mv") && (args[1] != "mV") + message: '"Unknown argument " + args[1] + ". Did you mean mV?"' + function: setADCVpp + input: + - args[0] + - '"1"' + input_types: + - int + - bool + output: + - args[0] + - '" mV"' + require_det_id: true + store_result_in_t: false + command_name: adcvpp + function_alias: adcvpp + help: "[dac or mV value][(optional unit) mV] \n\t[Ctb] Vpp of ADC.\n\t 0 -> 1V ;\ + \ 1 -> 1.14V ; 2 -> 1.33V ; 3 -> 1.6V ; 4 -> 2V. \n\tAdvanced User function!" + infer_action: true +apulse: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getAnalogPulsing + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setAnalogPulsing + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: apulse + function_alias: apulse + help: "[0, 1]\n\t[Mythen3] Enables or disables analog pulsing. Default is disabled" + infer_action: true + template: true +asamples: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfAnalogSamples + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberOfAnalogSamples + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: asamples + function_alias: asamples + help: "[n_samples]\n\t[Ctb] Number of analog samples expected." + infer_action: true + template: true +autocompdisable: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getAutoComparatorDisable + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setAutoComparatorDisable + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: autocompdisable + function_alias: autocompdisable + help: "[0, 1]\n\t[Jungfrau] Auto comparator disable mode. By default, the on-chip\ + \ gain switching is active during the entire exposure.This mode disables the on\ + \ - chip gain switching comparator automatically after 93.75% (only for chipv1.0)\ + \ of exposure time (only for longer than 100us). It is possible to set the duration\ + \ for chipv1.1 using compdisabletime command.\n\tDefault is 0 or this mode disabled(comparator\ + \ enabled throughout). 1 enables mode. 0 disables mode. " + infer_action: true + template: true +badchannels: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: badchannels + function_alias: badchannels + help: '' + infer_action: true + is_description: true +blockingtrigger: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: true + convert_det_id: true + extra_variables: + - name: block + type: bool + value: 'true' + function: sendSoftwareTrigger + input: + - block + input_types: + - bool + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: blockingtrigger + function_alias: blockingtrigger + help: "\n\t[Eiger][Jungfrau][Moench] Sends software trigger signal to detector and\ + \ blocks till the frames are sent out for that trigger." + infer_action: true + template: true +burstmode: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::burstMode + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: burstmode + function_alias: burstmode + help: '' + infer_action: true + is_description: true +burstperiod: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getBurstPeriod + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getBurstPeriod + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setBurstPeriod + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setBurstPeriod + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: burstperiod + function_alias: burstperiod + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Gotthard2] Period between 2 bursts.\ + \ Only in burst mode and auto timing mode." + infer_action: true + template: true +bursts: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfBursts + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int64_t + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setNumberOfBursts + input: + - args[0] + input_types: + - int64_t + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: bursts + function_alias: bursts + help: "[n_bursts]\n\t[Gotthard2] Number of bursts per aquire. Only in auto timing\ + \ mode and burst mode. Use timing command to set timing mode and burstmode command\ + \ to set burst mode." + infer_action: true + template: true +burstsl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfBurstsLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: burstsl + function_alias: burstsl + help: "\n\t[Gotthard2] Number of bursts left in acquisition. Only in burst auto\ + \ mode." + infer_action: true + template: true +bustest: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: executeBusTest + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: bustest + function_alias: bustest + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Bus test, ie. Writes\ + \ different values in a R/W register and confirms the writes to check bus.\n\t\ + Advanced User function!" + infer_action: true + template: true +cdsgain: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getCDSGain + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setCDSGain + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: cdsgain + function_alias: cdsgain + help: "[0, 1]\n\t[Gotthard2] Enable or disable CDS gain. Default is disabled." + infer_action: true + template: true +chipversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getChipVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: chipversion + function_alias: chipversion + help: "\n\t[Jungfrau] Returns chip version. Can be 1.0 or 1.1" + infer_action: true + template: true +clearbit: + actions: + PUT: + args: + - arg_types: + - uint32_t + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: StringTo(args[1]) < 0 || StringTo(args[1]) > 31 + message: '"Bit number out of range: " + args[1]' + function: clearBit + input: + - args[0] + - args[1] + input_types: + - uint32_t + - int + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: clearbit + function_alias: clearbit + help: "[reg address in hex] [bit index]\n\tClears bit in address." + infer_action: true + template: true +clearbusy: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: clearAcquiringFlag + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: clearbusy + function_alias: clearbusy + help: "\n\tIf acquisition aborted during acquire command, use this to clear acquiring\ + \ flag in shared memory before starting next acquisition" + infer_action: true + template: true +clearroi: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: clearROI + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: clearroi + function_alias: clearroi + help: '[Gotthard] Resets Region of interest in detector. All channels enabled. Default + is all channels enabled.' + infer_action: true + template: true +clientversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getClientVersion + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + command_name: clientversion + function_alias: clientversion + help: "\n\tClient software version" + infer_action: true +clkdiv: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkdiv not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: getClockDivider + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkdiv not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: setClockDivider + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: clkdiv + function_alias: clkdiv + help: "[n_clock (0-5)] [n_divider]\n\t[Gotthard2][Mythen3] Clock Divider of clock\ + \ n_clock. Must be greater than 1." + infer_action: true +clkfreq: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkfreq not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: getClockFrequency + input: + - args[0] + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: clkfreq + function_alias: clkfreq + help: "[n_clock (0-5)] [freq_in_Hz]\n\t[Gotthard2][Mythen3] Frequency of clock n_clock\ + \ in Hz. Use clkdiv to set frequency." + infer_action: true +clkphase: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkphase not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: getClockPhase + input: + - args[0] + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - int + - special::deg + argc: 2 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkphase not implemented for this detector."' + - condition: args[1] != "deg" + message: '"Cannot scan argument" + args[1] + ". Did you mean deg?"' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: getClockPhaseinDegrees + input: + - args[0] + input_types: + - int + output: + - OutString(t) + - '" deg"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkphase not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: setClockPhase + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - args[1] + require_det_id: true + store_result_in_t: false + - arg_types: + - int + - int + - special::deg + argc: 3 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"clkphase not implemented for this detector."' + - condition: args[2] != "deg" + message: '"Cannot scan argument" + args[2] + ". Did you mean deg?"' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: setClockPhaseinDegrees + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - args[1] + - '" "' + - args[2] + require_det_id: true + store_result_in_t: false + command_name: clkphase + function_alias: clkphase + help: "[n_clock (0-5)] [phase] [deg (optional)]\n\t[Gotthard2][Mythen3] Phase of\ + \ clock n_clock. If deg, then phase shift in degrees, else absolute phase shift\ + \ values." + infer_action: true +column: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getColumn + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setColumn + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: column + function_alias: column + help: "[value]\n\tSet Detector column (udp header) to value. \n\tGui uses it to\ + \ rearrange for complete image" + infer_action: true + template: true +compdisabletime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getComparatorDisableTime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getComparatorDisableTime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setComparatorDisableTime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setComparatorDisableTime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: compdisabletime + function_alias: compdisabletime + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Jungfrau] Time before end of\ + \ exposure when comparator is disabled. It is only possible for chipv1.1." + infer_action: true + template: true +confadc: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: getADCConfiguration + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 3 + cast_input: + - true + - true + - true + check_det_id: false + convert_det_id: true + function: setADCConfiguration + input: + - args[0] + - args[1] + - args[2] + input_types: + - int + - int + - int + output: + - '''[''' + - args[0] + - '", "' + - args[1] + - '", "' + - ToStringHex( StringTo(args[2])) + - '"]"' + require_det_id: true + store_result_in_t: false + command_name: confadc + function_alias: confadc + help: "[chip index 0-9, -1 for all] [adc index 0-31, -1 for all] [7 bit configuration\ + \ value in hex]\n\t[Gotthard2] Sets configuration for specific chip and adc,\ + \ but configures 1 chip (all adcs for that chip) at a time." + infer_action: true +config: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + function: loadConfig + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: config + function_alias: config + help: "\n\tFrees shared memory before loading configuration file. Set up once." + infer_action: true + template: true +counters: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: counters + function_alias: counters + help: '' + infer_action: true + is_description: true +currentsource: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - bool + - special::currentSourceFix + - int + argc: 3 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - bool + - special::currentSourceFix + - int + - special::currentSourceLow + argc: 4 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: currentsource + function_alias: currentsource + help: '' + infer_action: true + is_description: true +dac: + actions: + GET: + args: + - arg_types: + - defs::dacIndex + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD + && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD + message: '"Dac indices can only be used for chip test board. Use daclist + to get list of dac names for current detector."' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: '((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() + == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) + : StringTo(args[0])' + function: getDAC + input: + - dacIndex + - '"0"' + input_types: + - defs::dacIndex + - bool + output: + - args[0] + - ''' ''' + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - defs::dacIndex + - special::mv + argc: 2 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD + && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD + message: '"Dac indices can only be used for chip test board. Use daclist + to get list of dac names for current detector."' + - condition: args[1] != "mv" && args[1] != "mV" + message: '"Unknown argument " + args[1] + ". Did you mean mV?"' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: '((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() + == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) + : StringTo(args[0])' + function: getDAC + input: + - dacIndex + - '"1"' + input_types: + - defs::dacIndex + - bool + output: + - args[0] + - ''' ''' + - OutString(t) + - '" mV"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::dacIndex + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD + && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD + message: '"Dac indices can only be used for chip test board. Use daclist + to get list of dac names for current detector."' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: '((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() + == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) + : StringTo(args[0])' + function: setDAC + input: + - dacIndex + - args[1] + - '"0"' + input_types: + - defs::dacIndex + - int + - bool + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + - arg_types: + - defs::dacIndex + - int + - special::mv + argc: 3 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: is_int(args[0]) && det->getDetectorType().squash() != defs::CHIPTESTBOARD + && det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD + message: '"Dac indices can only be used for chip test board. Use daclist + to get list of dac names for current detector."' + extra_variables: + - name: dacIndex + type: defs::dacIndex + value: '((det->getDetectorType().squash() == defs::CHIPTESTBOARD || det->getDetectorType().squash() + == defs::XILINX_CHIPTESTBOARD) && !is_int(args[0])) ? det->getDacIndex(args[0]) + : StringTo(args[0])' + function: setDAC + input: + - dacIndex + - args[1] + - '"1"' + input_types: + - defs::dacIndex + - int + - bool + output: + - args[0] + - ''' ''' + - args[1] + - '" mV"' + require_det_id: true + store_result_in_t: false + command_name: dac + function_alias: dac + help: 'code: return GetHelpDacWrapper(cmd, args); + + ' + infer_action: true +dacindex: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + function: getDacIndex + input: + - args[0] + input_types: + - std::string + output: + - ToString(static_cast(t) - index) + require_det_id: false + store_result_in_t: true + command_name: dacindex + function_alias: dacindex + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the dac index for the given name." + infer_action: true + template: true +daclist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getDacNames + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + - condition: cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: '"This detector already has fixed dac names. Cannot change them."' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setDacNames + input: + - args + input_types: + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: daclist + function_alias: daclist + help: "[dacname1 dacname2 .. dacname18] \n\t\t[Ctb][Xilinx_Ctb] Set the list of\ + \ dac names for this detector.\n\t\t[All] Gets the list of dac names for every\ + \ dac for this detector." + infer_action: true + template: true +dacname: + actions: + GET: + args: + - arg_types: + - defs::dacIndex + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + function: getDacName + input: + - static_cast(StringTo(args[0]) + index) + input_types: + - defs::dacIndex + output: + - args[0] + - ''' ''' + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::dacIndex + - std::string + argc: 2 + cast_input: + - false + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::DAC_0 + function: setDacName + input: + - static_cast(StringTo(args[0]) + index) + - args[1] + input_types: + - defs::dacIndex + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: dacname + function_alias: dacname + help: "[0-17][name] \n\t\t[Ctb][Xilinx_Ctb] Set the dac at the given position to\ + \ the given name." + infer_action: true + template: true +dacvalues: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + - arg_types: + - special::mv + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: dacvalues + function_alias: dacvalues + help: '' + infer_action: true + is_description: true +datastream: + actions: + GET: + args: + - arg_types: + - defs::portPosition + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getDataStream + input: + - args[0] + input_types: + - defs::portPosition + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::portPosition + - bool + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setDataStream + input: + - args[0] + - args[1] + input_types: + - defs::portPosition + - bool + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: datastream + function_alias: datastream + help: "[left|right] [0, 1]\n\t[Eiger] Enables or disables data streaming from left\ + \ or/and right side of detector for 10 GbE mode. 1 (enabled) by default." + infer_action: true +dbitclk: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDBITClock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setDBITClock + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: dbitclk + function_alias: dbitclk + help: "[n_clk in MHz]\n\t[Ctb] Clock for latching the digital bits in MHz." + infer_action: true + template: true +dbitphase: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 || det_type == defs::MOENCH + message: '"dbitphase not implemented for this detector"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getDBITPhase + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::deg + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 || det_type == defs::MOENCH + message: '"dbitphase not implemented for this detector"' + - condition: args[0] != "deg" + message: '"Unknown dbitphase argument " + args[0] + ". Did you mean deg? "' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getDBITPhaseInDegrees + input: [] + input_types: [] + output: + - OutString(t) + - '" deg"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 || det_type == defs::MOENCH + message: '"dbitphase not implemented for this detector"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setDBITPhase + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + - arg_types: + - int + - special::deg + argc: 2 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type + == defs::GOTTHARD2 || det_type == defs::MOENCH + message: '"dbitphase not implemented for this detector"' + - condition: args[1] != "deg" + message: '"Unknown dbitphase 2nd argument " + args[1] + ". Did you mean + deg? "' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setDBITPhaseInDegrees + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: dbitphase + function_alias: dbitphase + help: "[n_value] [(optional)deg]\n\t[Ctb][Jungfrau] Phase shift of clock to latch\ + \ digital bits. Absolute phase shift. If deg used, then shift in degrees. \n\t\ + [Ctb]Changing dbitclk also resets dbitphase and sets to previous values." + infer_action: true +dbitpipeline: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDBITPipeline + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setDBITPipeline + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: dbitpipeline + function_alias: dbitpipeline + help: "[n_value]\n\t[Ctb][Gotthard2] Pipeline of the clock for latching digital\ + \ bits.\n\t[Gotthard2] Options: 0-7\n\t[Ctb] Options: 0-255" + infer_action: true + template: true +defaultdac: + actions: + GET: + args: + - arg_types: + - defs::dacIndex + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getDefaultDac + input: + - args[0] + input_types: + - defs::dacIndex + output: + - args[0] + - ''' ''' + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - defs::dacIndex + - defs::detectorSettings + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: getDefaultDac + input: + - args[0] + - args[1] + input_types: + - defs::dacIndex + - defs::detectorSettings + output: + - args[0] + - ''' ''' + - args[1] + - ''' ''' + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::dacIndex + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setDefaultDac + input: + - args[0] + - args[1] + input_types: + - defs::dacIndex + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + - arg_types: + - defs::dacIndex + - int + - defs::detectorSettings + argc: 3 + cast_input: + - true + - true + - true + check_det_id: false + convert_det_id: true + function: setDefaultDac + input: + - args[0] + - args[1] + - args[2] + input_types: + - defs::dacIndex + - int + - defs::detectorSettings + output: + - args[0] + - ''' ''' + - args[2] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: defaultdac + function_alias: defaultdac + help: "[dac name][value][(optional)setting]\n\tSets the default for that dac to\ + \ this value.\n\t[Jungfrau][Moench][Mythen3] When settings is provided, it sets\ + \ the default value only for that setting" + infer_action: true +defaultpattern: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: loadDefaultPattern + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: defaultpattern + function_alias: defaultpattern + help: "\n\t[Mythen3] Loads and runs default pattern in pattern generator. It is\ + \ to go back to initial settings." + infer_action: true + template: true +delay: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDelayAfterTrigger + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDelayAfterTrigger + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setDelayAfterTrigger + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setDelayAfterTrigger + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: delay + function_alias: delay + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb][Moench]\ + \ Delay after trigger" + infer_action: true + template: true +delayl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDelayAfterTriggerLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDelayAfterTriggerLeft + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: delayl + function_alias: delayl + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Delay Left in Acquisition.\ + \ \n\t[Gotthard2] only in continuous mode." + infer_action: true + template: true +detectorserverversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDetectorServerVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: detectorserverversion + function_alias: detectorserverversion + help: "\n\tOn-board detector server software version" + infer_action: true + template: true +detsize: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDetectorSize + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setDetectorSize + input: + - defs::xy(StringTo(args[0]),StringTo(args[1])) + input_types: + - defs::xy + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: detsize + function_alias: detsize + help: "[nx] [ny]\n\tDetector size, ie. Number of channels in x and y dim. This is\ + \ used to calculate module coordinates included in UDP data. \n\tBy default, it\ + \ adds module in y dimension for 2d detectors and in x dimension for 1d detectors\ + \ packet header." + infer_action: true +diodelay: + actions: + PUT: + args: + - arg_types: + - uint64_t + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setDigitalIODelay + input: + - args[0] + - args[1] + input_types: + - uint64_t + - int + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: diodelay + function_alias: diodelay + help: "[0-775]\n\t[Ctb] Delay for diode. Delay is in ps and max of 775 ps. Resolution\ + \ is 25 ps." + infer_action: true +dpulse: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDigitalPulsing + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setDigitalPulsing + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: dpulse + function_alias: dpulse + help: "[0, 1]\n\t[Mythen3] Enables or disables digital pulsing. Default is disabled" + infer_action: true + template: true +dr: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDynamicRange + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setDynamicRange + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: dr + function_alias: dr + help: "[value]\n\tDynamic Range or number of bits per pixel in detector.\n\t[Eiger]\ + \ Options: 4, 8, 12, 16, 32. If set to 32, also sets clkdivider to 2, else to\ + \ 0.\n\t[Mythen3] Options: 8, 16, 32\n\t[Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2][Xilinx\ + \ Ctb] 16" + infer_action: true + template: true +drlist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDynamicRangeList + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: drlist + function_alias: drlist + help: "\n\tGets the list of dynamic ranges for this detector." + infer_action: true + template: true +dsamples: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfDigitalSamples + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberOfDigitalSamples + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: dsamples + function_alias: dsamples + help: "[n_value]\n\t[Ctb] Number of digital samples expected." + infer_action: true + template: true +execcommand: + actions: + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: execcommand + function_alias: execcommand + help: '' + infer_action: true + is_description: true +exptime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + detectors: + MYTHEN3: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptimeForAllGates + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptimeForAllGates + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setExptime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setExptime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: exptime + function_alias: exptime + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Ctb]\ + \ Exposure time\n\t[Mythen3] Exposure time of all gate signals in auto and trigger\ + \ mode (internal gating). To specify gate index, use exptime1, exptime2, exptime3." + infer_action: true + template: true +exptime1: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 0 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: exptime1 + function_alias: exptime1 + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 1 in auto and trigger\ + \ mode (internal gating)." + infer_action: true + template: true +exptime2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 1 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: exptime2 + function_alias: exptime2 + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 2 in auto and trigger\ + \ mode (internal gating)." + infer_action: true + template: true +exptime3: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: getExptime + input: + - gateIndex + input_types: + - int + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 2 + function: setExptime + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: exptime3 + function_alias: exptime3 + help: "[n_value]\n\t[Mythen3] Exposure time of gate signal 3 in auto and trigger\ + \ mode (internal gating)." + infer_action: true + template: true +exptimel: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptimeLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExptimeLeft + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: exptimel + function_alias: exptimel + help: "[(optional unit) ns|us|ms|s]\n\t[Gotthard] Exposure time left for current\ + \ frame. " + infer_action: true + template: true +extrastoragecells: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfAdditionalStorageCells + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setNumberOfAdditionalStorageCells + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: extrastoragecells + function_alias: extrastoragecells + help: "[0-15]\n\t[Jungfrau] Only for chipv1.0. Number of additional storage cells.\ + \ Default is 0. For advanced users only. \n\tThe #images = #frames x #triggers\ + \ x (#extrastoragecells + 1)." + infer_action: true + template: true +extsampling: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExternalSampling + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setExternalSampling + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: extsampling + function_alias: extsampling + help: "[0, 1]\n\t[Ctb] Enable for external sampling signal for digital data to signal\ + \ by extsampling src command. For advanced users only." + infer_action: true + template: true +extsamplingsrc: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getExternalSamplingSource + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setExternalSamplingSource + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: extsamplingsrc + function_alias: extsamplingsrc + help: "[0-63]\n\t[Ctb] Sampling source signal for digital data. For advanced users\ + \ only." + infer_action: true + template: true +extsig: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getExternalSignalFlags + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - defs::externalSignalFlag + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setExternalSignalFlags + input: + - args[0] + - args[1] + input_types: + - int + - defs::externalSignalFlag + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: extsig + function_alias: extsig + help: "[n_signal] [signal_type]\n\t[Gotthard][Mythen3] External signal mode for\ + \ trigger timing mode.\n\t[Gotthard] [0] [trigger_in_rising_edge|trigger_in_falling_edge]\n\ + \t[Mythen3] [0-7] [trigger_in_rising_edge|trigger_in_falling_edge|inversion_on|inversion_off]\n\ + \t where 0 is master input trigger signal, 1-3 is master input gate signals, 4\ + \ is busy out signal and 5-7 is master output gate signals." + infer_action: true +fformat: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFileFormat + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::fileFormat + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFileFormat + input: + - args[0] + input_types: + - defs::fileFormat + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: fformat + function_alias: fformat + help: "[binary|hdf5]\n\tFile format of data file. For HDF5, package must be compiled\ + \ with HDF5 flags. Default is binary." + infer_action: true + template: true +filtercells: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfFilterCells + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberOfFilterCells + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: filtercells + function_alias: filtercells + help: "[0-12]\n\t[Jungfrau] Set Filter Cell. Only for chipv1.1. Advanced user Command" + infer_action: true + template: true +filterresistor: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFilterResistor + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFilterResistor + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: filterresistor + function_alias: filterresistor + help: "[value] [Gotthard2][Jungfrau] Set filter resistor. Increasing values for\ + \ increasing resistance.\n\t[Gotthard2] Options: [0|1|2|3]. Default is 0.\n\t\ + [Jungfrau] Options: [0|1]. Default is 1." + infer_action: true + template: true +findex: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getAcquisitionIndex + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint64_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setAcquisitionIndex + input: + - args[0] + input_types: + - uint64_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: findex + function_alias: findex + help: "[n_value]\n\tFile or Acquisition index." + infer_action: true + template: true +firmwaretest: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: executeFirmwareTest + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: firmwaretest + function_alias: firmwaretest + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Firmware test,\ + \ ie. reads a read fixed pattern from a register." + infer_action: true + template: true +firmwareversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFirmwareVersion + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + detectors: + EIGER: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFirmwareVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: firmwareversion + function_alias: firmwareversion + help: "\n\tFirmware version of detector in format [0xYYMMDD] or an increasing 2\ + \ digit number for Eiger." + infer_action: true +fliprows: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFlipRows + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFlipRows + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: fliprows + function_alias: fliprows + help: "[0, 1]\n\t[Eiger] flips rows paramater sent to slsreceiver to stream as json\ + \ parameter to flip rows in gui \n\t[Jungfrau][Moench] flips rows in the detector\ + \ itself. For bottom module and number of interfaces must be set to 2. slsReceiver\ + \ and slsDetectorGui does not handle." + infer_action: true + template: true +flowcontrol10g: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTenGigaFlowControl + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTenGigaFlowControl + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: flowcontrol10g + function_alias: flowcontrol10g + help: "[0, 1]\n\t[Eiger][Jungfrau][Moench] 10GbE Flow Control." + infer_action: true + template: true +fmaster: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: getMasterFileWrite + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setMasterFileWrite + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: fmaster + function_alias: fmaster + help: "[0, 1]\n\tEnable or disable receiver master file. Default is 1." + infer_action: true + template: true +fname: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFileNamePrefix + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setFileNamePrefix + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: fname + function_alias: fname + help: "[name]\n\tFile name prefix for output data file. Default is run. File name:\ + \ [file name prefix]_d[detector index]_f[sub file index]_[acquisition/file index].raw." + infer_action: true + template: true +foverwrite: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFileOverWrite + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFileOverWrite + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: foverwrite + function_alias: foverwrite + help: "[0, 1]\n\tEnable or disable file overwriting. Default is 1." + infer_action: true + template: true +fpath: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFilePath + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setFilePath + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: fpath + function_alias: fpath + help: "[path]\n\tDirectory where output data files are written in receiver. Default\ + \ is '/'. \n\tIf path does not exist, it will try to create it." + infer_action: true + template: true +framecounter: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfFramesFromStart + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: framecounter + function_alias: framecounter + help: "\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Number of frames from start\ + \ run control.\n\t[Gotthard2] only in continuous mode." + infer_action: true + template: true +frames: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfFrames + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int64_t + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setNumberOfFrames + input: + - args[0] + input_types: + - int64_t + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: frames + function_alias: frames + help: "[n_frames]\n\tNumber of frames per acquisition. In trigger mode, number of\ + \ frames per trigger. \n\tCannot be set in modular level. \n\tIn scan mode, number\ + \ of frames is set to number of steps.\n\t[Gotthard2] Burst mode has a maximum\ + \ of 2720 frames." + infer_action: true + template: true +framesl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfFramesLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: framesl + function_alias: framesl + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number\ + \ of frames left in acquisition. \n\t[Gotthard2] only in continuous auto mode." + infer_action: true + template: true +frametime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasurementTime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasurementTime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: frametime + function_alias: frametime + help: "[(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb]\ + \ Timestamp at a frame start.\n\t[Gotthard2] not in burst and auto mode." + infer_action: true + template: true +free: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: free + function_alias: free + help: '' + infer_action: true + is_description: true +fwrite: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFileWrite + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFileWrite + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: fwrite + function_alias: fwrite + help: "[0, 1]\n\tEnable or disable receiver file write. Default is 1." + infer_action: true + template: true +gaincaps: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::defs::M3_GainCaps + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: gaincaps + function_alias: gaincaps + help: '' + infer_action: true + is_description: true +gainmode: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getGainMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::gainMode + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setGainMode + input: + - args[0] + input_types: + - defs::gainMode + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: gainmode + function_alias: gainmode + help: "[dynamicgain|forceswitchg1|forceswitchg2|fixg1|fixg2|fixg0]\n\t[Jungfrau]\ + \ Gain mode.\n\tCAUTION: Do not use fixg0 without caution, you can damage the\ + \ detector!!!" + infer_action: true + template: true +gappixels: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: getGapPixelsinCallback + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setGapPixelsinCallback + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: gappixels + function_alias: gappixels + help: "[0, 1]\n\t[Eiger][Jungfrau][Moench] Include Gap pixels in client data call\ + \ back in Detecor api. Will not be in detector streaming, receiver file or streaming.\ + \ Default is 0. " + infer_action: true +gatedelay: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getGateDelayForAllGates + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getGateDelayForAllGates + input: [] + input_types: [] + output: + - OutString(t, args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: -1 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: -1 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: gatedelay + function_alias: gatedelay + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of all gate\ + \ signals in auto and trigger mode (internal gating)." + infer_action: true +gatedelay1: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t, args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 0 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 0 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: gatedelay1 + function_alias: gatedelay1 + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal\ + \ 1 in auto and trigger mode (internal gating)." + infer_action: true +gatedelay2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t, args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 1 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 1 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: gatedelay2 + function_alias: gatedelay2 + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal\ + \ 2 in auto and trigger mode (internal gating)." + infer_action: true +gatedelay3: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: getGateDelay + input: + - gateIndex + input_types: + - int + output: + - OutString(t, args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: gateIndex + type: int + value: 2 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + extra_variables: + - name: gateIndex + type: int + value: 2 + function: setGateDelay + input: + - gateIndex + - converted_time + input_types: + - int + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: gatedelay3 + function_alias: gatedelay3 + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate Delay of gate signal\ + \ 3 in auto and trigger mode (internal gating)." + infer_action: true +gates: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfGates + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberOfGates + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: gates + function_alias: gates + help: "[n_gates]\n\t[Mythen3] Number of external gates in gating or trigger_gating\ + \ mode (external gating)." + infer_action: true + template: true +getbit: + actions: + GET: + args: + - arg_types: + - uint32_t + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: StringTo(args[1]) < 0 || StringTo(args[1]) > 31 + message: '"Bit number out of range: " + args[1]' + function: getBit + input: + - args[0] + - args[1] + input_types: + - uint32_t + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: getbit + function_alias: getbit + help: "[reg address in hex] [bit index]\n\tGets bit in address." + infer_action: true +hardwareversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getHardwareVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: hardwareversion + function_alias: hardwareversion + help: "\n\tHardware version of detector. \n\t[Eiger] Hardware version of front FPGA\ + \ on detector." + infer_action: true + template: true +highvoltage: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getHighVoltage + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setHighVoltage + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: highvoltage + function_alias: highvoltage + help: "[n_value]\n\tHigh voltage to the sensor in Voltage. \n\t[Gotthard] [0|90|110|120|150|180|200]\ + \ \n\t[Eiger][Mythen3][Gotthard2] 0-200 \n\t[Jungfrau][Moench][Ctb] [0|60-200]" + infer_action: true + template: true +hostname: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: hostname + function_alias: hostname + help: '' + infer_action: true + is_description: true +im_a: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredCurrent + input: + - defs::I_POWER_A + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: im_a + function_alias: im_a + help: "\n\t[Ctb] Measured current of power supply a in mA." + infer_action: true + template: true +im_b: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredCurrent + input: + - defs::I_POWER_B + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: im_b + function_alias: im_b + help: "\n\t[Ctb] Measured current of power supply b in mA." + infer_action: true + template: true +im_c: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredCurrent + input: + - defs::I_POWER_C + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: im_c + function_alias: im_c + help: "\n\t[Ctb] Measured current of power supply c in mA." + infer_action: true + template: true +im_d: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredCurrent + input: + - defs::I_POWER_D + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: im_d + function_alias: im_d + help: "\n\t[Ctb] Measured current of power supply d in mA." + infer_action: true + template: true +im_io: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredCurrent + input: + - defs::I_POWER_IO + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: im_io + function_alias: im_io + help: "\n\t[Ctb] Measured current of power supply io in mA." + infer_action: true + template: true +imagetest: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getImageTestMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setImageTestMode + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: imagetest + function_alias: imagetest + help: "[0, 1]\n\t[Gotthard] 1 adds channel intensity with precalculated values when\ + \ taking an acquisition. Default is 0.\n\t[Eiger][Jungfrau][Moench] Only for Virtual\ + \ servers. If 0, each pixel intensity incremented by 1. If 1, all pixels almost\ + \ saturated." + infer_action: true + template: true +initialchecks: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: getInitialChecks + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setInitialChecks + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: initialchecks + function_alias: initialchecks + help: "[0, 1]\n\t[Mythen3][Gotthard2] Enable or disable intial compatibility and\ + \ other checks at detector start up. It is enabled by default. Must come before\ + \ 'hostname' command to take effect. Can be used to reprogram fpga when current\ + \ firmware is incompatible.\n\tAdvanced User function!" + infer_action: true +inj_ch: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getInjectChannel + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setInjectChannel + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: inj_ch + function_alias: inj_ch + help: "[offset] [increment]\n\t[Gotthard2] Inject channels with current source for\ + \ calibration. Offset is starting channel that is injected, increment determines\ + \ succeeding channels to be injected." + infer_action: true +interpolation: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getInterpolation + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setInterpolation + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: interpolation + function_alias: interpolation + help: "[0, 1]\n\t[Mythen3] Enables or disables interpolation. Default is disabled.\ + \ Interpolation mode enables all counters and disables vth3. Disabling sets back\ + \ counter mask and vth3." + infer_action: true + template: true +interruptsubframe: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getInterruptSubframe + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setInterruptSubframe + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: interruptsubframe + function_alias: interruptsubframe + help: "[0, 1]\n\t[Eiger] 1 interrupts last subframe at required exposure time. 0\ + \ will wait for last sub frame to finish exposing. 0 is default." + infer_action: true + template: true +kernelversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getKernelVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: kernelversion + function_alias: kernelversion + help: "\n\tGet kernel version on the detector including time and date." + infer_action: true + template: true +lastclient: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getLastClientIP + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: lastclient + function_alias: lastclient + help: "\n\tClient IP Address that last communicated with the detector." + infer_action: true + template: true +led: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getLEDEnable + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setLEDEnable + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: led + function_alias: led + help: "[0, 1]\n\t[Ctb] Switches on/off all LEDs." + infer_action: true + template: true +lock: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDetectorLock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setDetectorLock + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: lock + function_alias: lock + help: "[0, 1]\n\tLock detector to one IP, 1: locks. Default is unlocked" + infer_action: true + template: true +master: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMaster + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setMaster + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: master + function_alias: master + help: "[0, 1]\n\t[Eiger][Gotthard2][Jungfrau][Moench] Sets (half) module to master\ + \ and other(s) to slaves.\n\t[Gotthard][Gotthard2][Mythen3][Eiger][Jungfrau][Moench]\ + \ Gets if the current (half) module is master." + infer_action: true + template: true +maxadcphaseshift: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMaxADCPhaseShift + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: maxadcphaseshift + function_alias: maxadcphaseshift + help: "\n\t[Jungfrau][Moench][Ctb] Absolute maximum Phase shift of ADC clock." + infer_action: true + template: true +maxclkphaseshift: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: type != defs::GOTTHARD2 && type != defs::MYTHEN3 + message: '"maxclkphaseshift not implemented for this detector."' + extra_variables: + - name: type + type: defs::detectorType + value: det->getDetectorType().squash(defs::GENERIC); + function: getMaxClockPhaseShift + input: + - args[0] + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: maxclkphaseshift + function_alias: maxclkphaseshift + help: "[n_clock (0-5)]\n\t[Gotthard2][Mythen3] Absolute Maximum Phase shift of clock\ + \ n_clock." + infer_action: true +maxdbitphaseshift: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMaxDBITPhaseShift + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: maxdbitphaseshift + function_alias: maxdbitphaseshift + help: "\n\t[Ctb][Jungfrau] Absolute maximum Phase shift of of the clock to latch\ + \ digital bits." + infer_action: true + template: true +measuredperiod: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasuredPeriod + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasuredPeriod + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: measuredperiod + function_alias: measuredperiod + help: "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured frame period between last\ + \ frame and previous one. Can be measured with minimum 2 frames in an acquisition." + infer_action: true + template: true +measuredsubperiod: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasuredSubFramePeriod + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getMeasuredSubFramePeriod + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: measuredsubperiod + function_alias: measuredsubperiod + help: "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured sub frame period between\ + \ last sub frame and previous one." + infer_action: true + template: true +moduleid: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getModuleId + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: moduleid + function_alias: moduleid + help: "\n\t[Gotthard2][Eiger][Mythen3][Jungfrau][Moench] 16 bit value (ideally unique)\ + \ that is streamed out in the UDP header of the detector. Picked up from a file\ + \ on the module." + infer_action: true + template: true +nextframenumber: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNextFrameNumber + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint64_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNextFrameNumber + input: + - args[0] + input_types: + - uint64_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: nextframenumber + function_alias: nextframenumber + help: "[n_value]\n\t[Eiger][Jungfrau][Moench][Ctb] Next frame number. Stopping acquisition\ + \ might result in different frame numbers for different modules." + infer_action: true + template: true +nmod: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: size + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: nmod + function_alias: nmod + help: "\n\tNumber of modules in shared memory." + infer_action: true + template: true +numinterfaces: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberofUDPInterfaces + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberofUDPInterfaces + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: numinterfaces + function_alias: numinterfaces + help: "[1, 2]\n\t[Jungfrau][Moench] Number of udp interfaces to stream data from\ + \ detector. Default: 1.\n\tAlso enables second interface in receiver for listening\ + \ (Writes a file per interface if writing enabled).\n\tAlso restarts client and\ + \ receiver zmq sockets if zmq streaming enabled.\n\t[Eiger] Only gets with result\ + \ 2." + infer_action: true + template: true +overflow: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getOverFlowMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setOverFlowMode + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: overflow + function_alias: overflow + help: "[0, 1]\n\t[Eiger] Enable or disable show overflow flag in 32 bit mode. Default\ + \ is disabled." + infer_action: true + template: true +packageversion: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPackageVersion + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + command_name: packageversion + function_alias: packageversion + help: "\n\tPackage version." + infer_action: true +parallel: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getParallelMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setParallelMode + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: parallel + function_alias: parallel + help: "[0, 1]\n\t[Eiger][Mythen3][Gotthard2][Moench] Enable or disable parallel\ + \ mode.\n\t[Mythen3] If exptime is too short, the acquisition will return ERROR\ + \ status and take fewer frames than expected.\n\t[Mythen3][Eiger][Moench] Default:\ + \ Non parallel.\n\t[Gotthard2] Default: Parallel. Non parallel mode works only\ + \ in continuous mode." + infer_action: true + template: true +parameters: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + function: loadParameters + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: parameters + function_alias: parameters + help: "\n\tSets detector measurement parameters to those contained in fname. Set\ + \ up per measurement." + infer_action: true + template: true +partialreset: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPartialReset + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPartialReset + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: partialreset + function_alias: partialreset + help: "[0, 1]\n\t[Eiger] Sets up detector to do partial or complete reset at start\ + \ of acquisition. 0 complete reset, 1 partial reset. Default is complete reset.\ + \ Advanced function!" + infer_action: true + template: true +patfname: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPatterFileName + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: patfname + function_alias: patfname + help: "\n\t[Ctb][Mythen3][Xilinx Ctb] Gets the pattern file name including path\ + \ of the last pattern uploaded. Returns an empty if nothing was uploaded or via\ + \ a server default file" + infer_action: true + template: true +patioctrl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPatternIOControl + input: [] + input_types: [] + output: + - OutStringHex(t, 16) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint64_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPatternIOControl + input: + - args[0] + input_types: + - uint64_t + output: + - ToStringHex(arg0, 16) + require_det_id: true + store_result_in_t: false + command_name: patioctrl + function_alias: patioctrl + help: "[64 bit mask]\n\t[Ctb] 64 bit mask defining input (0) and output (1) signals." + infer_action: true + template: true +patlimits: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getPatternLoopAddresses + input: + - '"-1"' + input_types: + - int + output: + - OutStringHex(t, 4) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: -1 + cast_input: + - true + - true + - true + check_det_id: false + convert_det_id: true + function: setPatternLoopAddresses + input: + - '"-1"' + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - '''[''' + - ToStringHex(arg1, 4) + - '", "' + - ToStringHex(arg2, 4) + - ''']''' + require_det_id: true + store_result_in_t: false + command_name: patlimits + function_alias: patlimits + help: "[start addr] [stop addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Limits of complete\ + \ pattern" + infer_action: true +patloop: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopAddresses + input: + - level + input_types: + - int + output: + - level + - ''' ''' + - OutStringHex(t, 4) + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: -1 + cast_input: + - false + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: start + type: int + value: StringTo(args[iArg++]) + - name: stop + type: int + value: StringTo(args[iArg++]) + function: setPatternLoopAddresses + input: + - level + - start + - stop + input_types: + - int + - int + - int + output: + - level + - ''' ''' + - '''[''' + - ToStringHex(start, 4) + - '", "' + - ToStringHex(stop, 4) + - ''']''' + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: false + command_name: patloop + function_alias: patloop + help: "[0-6] [start addr] [stop addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Limits of the\ + \ loop level provided.\n\t[Mythen3] Level options: 0-3 only." + infer_action: true +patloop0: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopAddresses + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: -1 + cast_input: + - false + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: start + type: int + value: StringTo(args[iArg++]) + - name: stop + type: int + value: StringTo(args[iArg++]) + function: setPatternLoopAddresses + input: + - level + - start + - stop + input_types: + - int + - int + - int + output: + - '''[''' + - ToStringHex(start, 4) + - '", "' + - ToStringHex(stop, 4) + - ''']''' + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: false + command_name: patloop0 + function_alias: patloop0 + help: Depreciated command. Use patloop. + infer_action: true +patloop1: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopAddresses + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: -1 + cast_input: + - false + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: start + type: int + value: StringTo(args[iArg++]) + - name: stop + type: int + value: StringTo(args[iArg++]) + function: setPatternLoopAddresses + input: + - level + - start + - stop + input_types: + - int + - int + - int + output: + - '''[''' + - ToStringHex(start, 4) + - '", "' + - ToStringHex(stop, 4) + - ''']''' + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: false + command_name: patloop1 + function_alias: patloop1 + help: Depreciated command. Use patloop. + infer_action: true +patloop2: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopAddresses + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: -1 + cast_input: + - false + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: start + type: int + value: StringTo(args[iArg++]) + - name: stop + type: int + value: StringTo(args[iArg++]) + function: setPatternLoopAddresses + input: + - level + - start + - stop + input_types: + - int + - int + - int + output: + - '''[''' + - ToStringHex(start, 4) + - '", "' + - ToStringHex(stop, 4) + - ''']''' + pattern_command: + command_name: patloop + nGetArgs: 0 + nPutArgs: 2 + require_det_id: true + store_result_in_t: false + command_name: patloop2 + function_alias: patloop2 + help: Depreciated command. Use patloop. + infer_action: true +patmask: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPatternMask + input: [] + input_types: [] + output: + - OutStringHex(t, 16) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint64_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPatternMask + input: + - args[0] + input_types: + - uint64_t + output: + - ToStringHex(arg0, 16) + require_det_id: true + store_result_in_t: false + command_name: patmask + function_alias: patmask + help: "[64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] Selects the bits that will have\ + \ a pattern mask applied to the selected patmask for every pattern." + infer_action: true + template: true +patnloop: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopCycles + input: + - level + input_types: + - int + output: + - level + - ''' ''' + - OutString(t) + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + extra_variables: + - name: nloops + type: std::string + value: args[iArg++] + function: setPatternLoopCycles + input: + - level + - nloops + input_types: + - int + - int + output: + - level + - ''' ''' + - nloops + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patnloop + function_alias: patnloop + help: "[0-6] [n_cycles] \n\t[Ctb][Mythen3][Xilinx Ctb] Number of cycles of the loop\ + \ level provided.\n\t[Mythen3] Level options: 0-3 only." + infer_action: true +patnloop0: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopCycles + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + extra_variables: + - name: nloops + type: std::string + value: args[iArg++] + function: setPatternLoopCycles + input: + - level + - nloops + input_types: + - int + - int + output: + - nloops + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patnloop0 + function_alias: patnloop0 + help: Depreciated command. Use patnloop. + infer_action: true +patnloop1: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopCycles + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + extra_variables: + - name: nloops + type: std::string + value: args[iArg++] + function: setPatternLoopCycles + input: + - level + - nloops + input_types: + - int + - int + output: + - nloops + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patnloop1 + function_alias: patnloop1 + help: Depreciated command. Use patnloop. + infer_action: true +patnloop2: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternLoopCycles + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + extra_variables: + - name: nloops + type: std::string + value: args[iArg++] + function: setPatternLoopCycles + input: + - level + - nloops + input_types: + - int + - int + output: + - nloops + pattern_command: + command_name: patnloop + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patnloop2 + function_alias: patnloop2 + help: Depreciated command. Use patnloop. + infer_action: true +patsetbit: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPatternBitMask + input: [] + input_types: [] + output: + - OutStringHex(t, 16) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint64_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPatternBitMask + input: + - args[0] + input_types: + - uint64_t + output: + - ToStringHex(arg0, 16) + require_det_id: true + store_result_in_t: false + command_name: patsetbit + function_alias: patsetbit + help: "[64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] Sets the mask applied to every\ + \ pattern to the selected bits." + infer_action: true + template: true +patternX: + actions: + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setPattern + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: pattern + function_alias: pattern + help: "[fname]\n\t[Mythen3][Ctb][Xilinx Ctb] Loads ASCII pattern file directly to\ + \ server (instead of executing line by line)" + infer_action: true +patternstart: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: startPattern + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: patternstart + function_alias: patternstart + help: "\n\t[Mythen3] Starts Pattern" + infer_action: true + template: true +patwait: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitAddr + input: + - level + input_types: + - int + output: + - level + - ''' ''' + - OutStringHex(t, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: addr + type: int + value: StringTo(args[iArg++]) + function: setPatternWaitAddr + input: + - level + - addr + input_types: + - int + - int + output: + - level + - ''' ''' + - ToStringHex(addr, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwait + function_alias: patwait + help: "[0-6] [addr] \n\t[Ctb][Mythen3][Xilinx Ctb] Wait address for loop level provided.\ + \ \n\t[Mythen3] Level options: 0-3 only." + infer_action: true +patwait0: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitAddr + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: addr + type: int + value: StringTo(args[iArg++]) + function: setPatternWaitAddr + input: + - level + - addr + input_types: + - int + - int + output: + - ToStringHex(addr, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwait0 + function_alias: patwait0 + help: Depreciated command. Use patwait. + infer_action: true +patwait1: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitAddr + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: addr + type: int + value: StringTo(args[iArg++]) + function: setPatternWaitAddr + input: + - level + - addr + input_types: + - int + - int + output: + - ToStringHex(addr, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwait1 + function_alias: patwait1 + help: Depreciated command. Use patwait. + infer_action: true +patwait2: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitAddr + input: + - level + input_types: + - int + output: + - OutStringHex(t, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: addr + type: int + value: StringTo(args[iArg++]) + function: setPatternWaitAddr + input: + - level + - addr + input_types: + - int + - int + output: + - ToStringHex(addr, 4) + pattern_command: + command_name: patwait + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwait2 + function_alias: patwait2 + help: Depreciated command. Use patwait. + infer_action: true +patwaittime: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitTime + input: + - level + input_types: + - int + output: + - level + - ''' ''' + - OutString(t) + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: waittime + type: uint64_t + value: StringTo(args[iArg++]) + function: setPatternWaitTime + input: + - level + - waittime + input_types: + - int + - int + output: + - level + - ''' ''' + - waittime + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwaittime + function_alias: patwaittime + help: "[0-6] [n_clk] \n\t[Ctb][Mythen3][Xilinx Ctb] Wait time in clock cycles for\ + \ the loop provided.\n\t[Mythen3] Level options: 0-3 only." + infer_action: true +patwaittime0: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitTime + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: waittime + type: uint64_t + value: StringTo(args[iArg++]) + function: setPatternWaitTime + input: + - level + - waittime + input_types: + - int + - int + output: + - waittime + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwaittime0 + function_alias: patwaittime0 + help: Depreciated command. Use patwaittime. + infer_action: true +patwaittime1: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitTime + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: waittime + type: uint64_t + value: StringTo(args[iArg++]) + function: setPatternWaitTime + input: + - level + - waittime + input_types: + - int + - int + output: + - waittime + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwaittime1 + function_alias: patwaittime1 + help: Depreciated command. Use patwaittime. + infer_action: true +patwaittime2: + actions: + GET: + args: + - arg_types: + - int + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPatternWaitTime + input: + - level + input_types: + - int + output: + - OutString(t) + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: -1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: waittime + type: uint64_t + value: StringTo(args[iArg++]) + function: setPatternWaitTime + input: + - level + - waittime + input_types: + - int + - int + output: + - waittime + pattern_command: + command_name: patwaittime + nGetArgs: 0 + nPutArgs: 1 + require_det_id: true + store_result_in_t: false + command_name: patwaittime2 + function_alias: patwaittime2 + help: Depreciated command. Use patwaittime. + infer_action: true +patword: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: getPatternWord + input: + - args[0] + input_types: + - int + output: + - '''[''' + - ToStringHex(arg0, 4) + - '", "' + - OutStringHex(t, 16) + - '"]"' + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - uint64_t + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setPatternWord + input: + - args[0] + - args[1] + input_types: + - int + - uint64_t + output: + - '''[''' + - ToStringHex(arg0, 4) + - '", "' + - ToStringHex(arg1, 16) + - '"]"' + require_det_id: true + store_result_in_t: false + command_name: patword + function_alias: patword + help: "[step or address] [64 bit mask]\n\t[Ctb][Mythen3][Xilinx Ctb] 64 bit pattern\ + \ at address of pattern memory.\n\t[Ctb] read is same as executing pattern" + infer_action: true +pedestalmode: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPedestalMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - special::pedestal_parameters + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: args[0] != "0" + message: '"Unknown argument " + args[0] + ". Did you mean 0 to disable pedestal + mode?"' + function: setPedestalMode + input: + - defs::pedestalParameters() + input_types: + - defs::pedestalParameters + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + - arg_types: + - uint8_t + - uint16_t + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setPedestalMode + input: + - defs::pedestalParameters(StringTo(args[0]), StringTo(args[1])) + input_types: + - defs::pedestalParameters + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: pedestalmode + function_alias: pedestalmode + help: " [frames] [loops]\n\t\t[Jungfrau] Enable pedestal mode.\ + \ \n\t\tThe number of frames or triggers is overwritten by: \n\t\t(#pedestal_frames\ + \ x #pedestal_loops x 2). \n\t\tIn auto timing mode or in trigger mode with #frames\ + \ > 1, \n\t\t#frames is overwritten and #triggers = 1, \n\t\telse #triggers is\ + \ overwritten and #frames = 1. \n\t\tOne cannot set #frames, #triggers or timing\ + \ mode in pedestal mode (exception thrown).\n\npedestalmode [0]\n\t\t[Jungfrau]\ + \ Disable pedestal mode.\n\t\tDisabling pedestal mode will set back the normal\ + \ mode values of #frames and #triggers." + infer_action: true +period: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPeriod + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPeriod + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setPeriod + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setPeriod + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: period + function_alias: period + help: "[duration] [(optional unit) ns|us|ms|s]\n\tPeriod between frames" + infer_action: true + template: true +periodl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPeriodLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPeriodLeft + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: periodl + function_alias: periodl + help: "\n\t[Gotthard][Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Period left for\ + \ current frame. \n\t[Gotthard2] only in continuous mode." + infer_action: true + template: true +polarity: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPolarity + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::polarity + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPolarity + input: + - args[0] + input_types: + - defs::polarity + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: polarity + function_alias: polarity + help: "[pos|neg]\n\t[Mythen3] Sets negative or positive polarity. Default is positive" + infer_action: true + template: true +port: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getControlPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setControlPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: port + function_alias: port + help: "[n]\n\tPort number of the control server on detector for detector-client\ + \ tcp interface. Default is 1952. Normally unchanged. Set different ports for\ + \ virtual servers on same pc." + infer_action: true + template: true +powerchip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPowerChip + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPowerChip + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: powerchip + function_alias: powerchip + help: "[0, 1]\n\t[Jungfrau][Moench][Mythen3][Gotthard2] Power the chip. \n\t[Jungfrau][Moench]\ + \ Default is 0. Get will return power status. Can be off if temperature event\ + \ occured (temperature over temp_threshold with temp_control enabled. Will configure\ + \ chip (only chip v1.1)\n\t[Mythen3][Gotthard2] Default is 1. If module not connected\ + \ or wrong module, powerchip will fail." + infer_action: true + template: true +powerindex: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + function: getPowerIndex + input: + - args[0] + input_types: + - std::string + output: + - ToString(static_cast(t) - index) + require_det_id: false + store_result_in_t: true + command_name: powerindex + function_alias: powerindex + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the power index for the given name." + infer_action: true + template: true +powerlist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getPowerNames + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + - condition: cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: '"This detector already has fixed dac names. Cannot change them."' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setPowerNames + input: + - args + input_types: + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: powerlist + function_alias: powerlist + help: "[powername1 powername2 .. powername4] \n\t\t[Ctb][Xilinx_Ctb] Set the list\ + \ of power names for this board." + infer_action: true + template: true +powername: + actions: + GET: + args: + - arg_types: + - defs::dacIndex + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + function: getPowerName + input: + - static_cast(StringTo(args[0]) + index) + input_types: + - defs::dacIndex + output: + - args[0] + - ''' ''' + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::dacIndex + - std::string + argc: 2 + cast_input: + - false + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::V_POWER_A + function: setPowerName + input: + - static_cast(StringTo(args[0]) + index) + - args[1] + input_types: + - defs::dacIndex + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: powername + function_alias: powername + help: "[0-4][name] \n\t\t[Ctb][Xilinx_Ctb] Set the power at the given position to\ + \ the given name." + infer_action: true + template: true +powervalues: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + ctb_output_list: + GETFCN: getPower + GETFCNLIST: getPowerList + GETFCNNAME: getPowerNames + printable_name: '*name_it++' + suffix: mV + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: powervalues + function_alias: powervalues + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get values of all powers." + infer_action: true +programfpga: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: programFPGA + input: + - args[0] + - '"0"' + input_types: + - std::string + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + - arg_types: + - special::path + - special::force-delete-normal-file + argc: 2 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: args[1] != "--force-delete-normal-file" + message: '"Could not scan second argument. Did you mean --force-delete-normal-file?"' + function: programFPGA + input: + - args[0] + - '"1"' + input_types: + - std::string + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: programfpga + function_alias: programfpga + help: "[fname.pof | fname.rbf (full path)][(opitonal)--force-delete-normal-file]\n\ + \t[Jungfrau][Moench][Ctb] Programs FPGA from pof file (full path). Then, detector\ + \ controller is rebooted. \n\t\tUse --force-delete-normal-file argument, if normal\ + \ file found in device tree, it must be deleted, a new device drive created and\ + \ programming continued.\n\t[Mythen3][Gotthard2] Programs FPGA from rbf file (full\ + \ path). Then, detector controller is rebooted." + infer_action: true +pulse: + actions: + PUT: + args: + - arg_types: + - int + - int + - int + argc: 3 + cast_input: + - true + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: c + type: defs::xy + value: defs::xy(StringTo(args[1]), StringTo(args[2])) + function: pulsePixel + input: + - args[0] + - c + input_types: + - int + - defs::xy + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: pulse + function_alias: pulse + help: "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times at coordinates\ + \ (x, y). Advanced User!" + infer_action: true + template: true +pulsechip: + actions: + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: pulseChip + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: pulsechip + function_alias: pulsechip + help: "[n_times] \n\t[Eiger] Pulse chip n times. If n is -1, resets to normal mode\ + \ (reset chip completely at start of acquisition, where partialreset = 0). Advanced\ + \ User!" + infer_action: true +pulsenmove: + actions: + PUT: + args: + - arg_types: + - int + - int + - int + argc: 3 + cast_input: + - true + - false + check_det_id: false + convert_det_id: true + extra_variables: + - name: c + type: defs::xy + value: defs::xy(StringTo(args[1]), StringTo(args[2])) + function: pulsePixelNMove + input: + - args[0] + - c + input_types: + - int + - defs::xy + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: pulsenmove + function_alias: pulsenmove + help: "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times and moves relatively\ + \ by (x, y). Advanced User!" + infer_action: true + template: true +pumpprobe: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPumpProbe + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPumpProbe + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: pumpprobe + function_alias: pumpprobe + help: "[0, 1]\n\t[Mythen3] Enables or disables pump probe mode. Default is disabled.\ + \ Pump probe mode only enables vth2. Disabling sets back to previous value." + infer_action: true + template: true +quad: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getQuad + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setQuad + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: quad + function_alias: quad + help: "[0, 1]\n\t[Eiger] Sets detector size to a quad. 0 (disabled) is default.\ + \ (Specific hardware required)." + infer_action: true +ratecorr: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: ratecorr + function_alias: ratecorr + help: '' + infer_action: true + is_description: true +readnrows: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getReadNRows + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setReadNRows + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: readnrows + function_alias: readnrows + help: "\n\t[1-256]\n\t\t[Eiger] Number of rows to readout per half module starting\ + \ from the centre. Options: 0 - 256. 256 is default. The permissible values depend\ + \ on dynamic range and 10Gbe enabled.\n\t[8-512 (multiple of 8)]\n\t\t[Jungfrau]\ + \ Number of rows per module starting from the centre. Options: 8 - 512, must be\ + \ multiples of 8. Default is 512.\n\t\t[Moench] Number of rows per module starting\ + \ from the centre. Options:16 - 400, must be multiples of 16. Default is 400." + infer_action: true + template: true +readout: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: startDetectorReadout + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: readout + function_alias: readout + help: "\n\t[Mythen3] Starts detector readout. Status changes to TRANSMITTING and\ + \ automatically returns to idle at the end of readout." + infer_action: true + template: true +readoutspeed: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::CHIPTESTBOARD || det_type == defs::XILINX_CHIPTESTBOARD + message: '"ReadoutSpeed not implemented. Did you mean runclk?"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getReadoutSpeed + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::speedLevel + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_type == defs::CHIPTESTBOARD || det_type == defs::XILINX_CHIPTESTBOARD + message: '"ReadoutSpeed not implemented. Did you mean runclk?"' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setReadoutSpeed + input: + - args[0] + input_types: + - defs::speedLevel + output: + - ToString(StringTo(args[0])) + require_det_id: true + store_result_in_t: false + command_name: readoutspeed + function_alias: readoutspeed + help: "\n\t[0 or full_speed|1 or half_speed|2 or quarter_speed]\n\t[Eiger][Jungfrau][Moench]\ + \ Readout speed of chip.\n\t[Eiger][Moench] Default speed is full_speed.\n\t[Jungfrau]\ + \ Default speed is half_speed. full_speed option only available from v2.0 boards\ + \ and is recommended to set number of interfaces to 2. Also overwrites adcphase\ + \ to recommended default.\n\t [144|108]\n\t\t[Gotthard2] Readout speed of chip\ + \ in MHz. Default is 108." + infer_action: true +readoutspeedlist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getReadoutSpeedList + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: readoutspeedlist + function_alias: readoutspeedlist + help: "\n\tList of readout speed levels implemented for this detector." + infer_action: true + template: true +rebootcontroller: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: rebootController + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: rebootcontroller + function_alias: rebootcontroller + help: "\n\t[Jungfrau][Moench][Ctb][Gotthard][Mythen3][Gotthard2] Reboot controller\ + \ of detector." + infer_action: true + template: true +reg: + actions: + GET: + args: + - arg_types: + - uint32_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: readRegister + input: + - args[0] + input_types: + - uint32_t + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint32_t + - uint32_t + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: writeRegister + input: + - args[0] + - args[1] + input_types: + - uint32_t + - uint32_t + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: reg + function_alias: reg + help: "[address] [32 bit value]\n\t[Mythen3][Gotthard2] Reads/writes to a 32 bit\ + \ register in hex. Advanced Function!\n\tGoes to stop server. Hence, can be called\ + \ while calling blocking acquire().\n\t[Eiger] +0x100 for only left, +0x200 for\ + \ only right." + infer_action: true +resetdacs: + actions: + PUT: + args: + - arg_types: + - special::hard + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: args[0] != "hard" + message: '"Unknown argument " + args[0] + ". Did you mean hard?"' + function: resetToDefaultDacs + input: + - '"1"' + input_types: + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: resetToDefaultDacs + input: + - '"0"' + input_types: + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: resetdacs + function_alias: resetdacs + help: "[(optional) hard] \n\t[Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Mythen3]Reset\ + \ dac values to the defaults. A 'hard' optional reset will reset the dacs to the\ + \ hardcoded defaults in on-board detector server." + infer_action: true +resetfpga: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: resetFPGA + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: resetfpga + function_alias: resetfpga + help: "\n\t[Jungfrau][Moench][Ctb] Reset FPGA." + infer_action: true + template: true +roi: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getROI + input: [] + input_types: [] + output: + - t + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: false + exceptions: + - condition: det_id == -1 && det->size() > 1 + message: '"Cannot execute ROI at multi module level"' + extra_variables: + - name: t + type: defs::ROI + value: defs::ROI(StringTo(args[0]), StringTo(args[1])) + function: setROI + input: + - t + input_types: + - defs::ROI + output: + - t + require_det_id: true + store_result_in_t: false + command_name: roi + function_alias: roi + help: "[xmin] [xmax] \n\t[Gotthard] Region of interest in detector.\n\tOptions:\ + \ Only a single ROI per module. \n\tEither all channels or a single adc or 2 chips\ + \ (256 channels). Default is all channels enabled (-1 -1). " + infer_action: true +romode: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getReadoutMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::readoutMode + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setReadoutMode + input: + - args[0] + input_types: + - defs::readoutMode + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: romode + function_alias: romode + help: "[analog|digital|analog_digital|transceiver|digital_transceiver]\n\t[Ctb]\ + \ Readout mode. Default is analog." + infer_action: true + template: true +row: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRow + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRow + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: row + function_alias: row + help: "[value]\n\tSet Detector row (udp header) to value. \n\tGui uses it to rearrange\ + \ for complete image" + infer_action: true + template: true +runclk: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRUNClock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRUNClock + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: runclk + function_alias: runclk + help: "[n_clk in MHz]\n\t[Ctb] Run clock in MHz." + infer_action: true + template: true +runtime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getActualTime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getActualTime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + command_name: runtime + function_alias: runtime + help: "[(optional unit) ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][Ctb]\ + \ Time from detector start up.\n\t[Gotthard2] not in burst and auto mode." + infer_action: true + template: true +rx_arping: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxArping + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxArping + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_arping + function_alias: rx_arping + help: "[0, 1]\n\tStarts a thread in slsReceiver to arping the interface it is listening\ + \ to every minute. Useful in 10G mode." + infer_action: true + template: true +rx_clearroi: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: clearRxROI + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: rx_clearroi + function_alias: rx_clearroi + help: Resets Region of interest in receiver. Default is all channels/pixels enabled. + infer_action: true + template: true +rx_dbitlist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: rx_dbitlist + function_alias: rx_dbitlist + help: '' + infer_action: true + is_description: true +rx_dbitoffset: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxDbitOffset + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxDbitOffset + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_dbitoffset + function_alias: rx_dbitoffset + help: "[n_bytes]\n\t[Ctb] Offset in bytes in digital data to skip in receiver." + infer_action: true + template: true +rx_discardpolicy: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxFrameDiscardPolicy + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::frameDiscardPolicy + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxFrameDiscardPolicy + input: + - args[0] + input_types: + - defs::frameDiscardPolicy + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_discardpolicy + function_alias: rx_discardpolicy + help: "[nodiscard (default)|discardempty|discardpartial(fastest)]\n\tFrame discard\ + \ policy of receiver. nodiscard does not discard frames, discardempty discards\ + \ empty frames, discardpartial discards partial frames." + infer_action: true + template: true +rx_fifodepth: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxFifoDepth + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxFifoDepth + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_fifodepth + function_alias: rx_fifodepth + help: "[n_frames]\n\tSet the number of frames in the receiver fifo depth (buffer\ + \ between listener and writer threads)." + infer_action: true + template: true +rx_frameindex: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxCurrentFrameIndex + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_frameindex + function_alias: rx_frameindex + help: "\n\tCurrent frame index received for each port in receiver during acquisition." + infer_action: true + template: true +rx_framescaught: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFramesCaught + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_framescaught + function_alias: rx_framescaught + help: "\n\tNumber of frames caught by each port in receiver." + infer_action: true + template: true +rx_framesperfile: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFramesPerFile + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFramesPerFile + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_framesperfile + function_alias: rx_framesperfile + help: "[n_frames]\n\tNumber of frames per file in receiver in an acquisition. Default\ + \ depends on detector type. 0 is infinite or all frames in single file." + infer_action: true + template: true +rx_hostname: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: rx_hostname + function_alias: rx_hostname + help: '' + infer_action: true + is_description: true +rx_jsonaddheader: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: rx_jsonaddheader + function_alias: rx_jsonaddheader + help: '' + infer_action: true + is_description: true +rx_jsonpara: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getAdditionalJsonParameter + input: + - args[0] + input_types: + - std::string + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + function: setAdditionalJsonParameter + input: + - args[0] + - '""' + input_types: + - std::string + - std::string + output: + - args[0] + - '" deleted"' + require_det_id: true + store_result_in_t: false + - arg_types: + - std::string + - std::string + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + function: setAdditionalJsonParameter + input: + - args[0] + - args[1] + input_types: + - std::string + - std::string + output: + - '"{"' + - args[0] + - '": "' + - args[1] + - '"}"' + require_det_id: true + store_result_in_t: false + command_name: rx_jsonpara + function_alias: rx_jsonpara + help: "[key1] [value1]\n\t[Receiver] Additional json header parameter streamed out\ + \ from receiver. If not found in header, the pair is appended. An empty values\ + \ deletes parameter. Max 20 characters for each key/value." + infer_action: true +rx_lastclient: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxLastClientIP + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_lastclient + function_alias: rx_lastclient + help: "\n\tClient IP Address that last communicated with the receiver." + infer_action: true + template: true +rx_lock: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxLock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxLock + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_lock + function_alias: rx_lock + help: "[0, 1]\n\tLock receiver to one client IP, 1 locks, 0 unlocks. Default is\ + \ unlocked." + infer_action: true + template: true +rx_missingpackets: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumMissingPackets + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_missingpackets + function_alias: rx_missingpackets + help: "\n\tNumber of missing packets for receiver. If negative, they are packets\ + \ in excess." + infer_action: true + template: true +rx_padding: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getPartialFramesPadding + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setPartialFramesPadding + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_padding + function_alias: rx_padding + help: "[0, 1]\n\tPartial frames padding enable in the receiver. Default: enabled.\ + \ Disabling is fastest." + infer_action: true + template: true +rx_printconfig: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: printRxConfiguration + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_printconfig + function_alias: rx_printconfig + help: "\n\tPrints the receiver configuration." + infer_action: true + template: true +rx_realudpsocksize: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxRealUDPSocketBufferSize + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_realudpsocksize + function_alias: rx_realudpsocksize + help: "\n\tActual udp socket buffer size. Double the size of rx_udpsocksize due\ + \ to kernel bookkeeping." + infer_action: true + template: true +rx_roi: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - int + - int + - int + argc: 4 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: rx_roi + function_alias: rx_roi + help: '' + infer_action: true + is_description: true +rx_silent: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxSilentMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxSilentMode + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_silent + function_alias: rx_silent + help: "[0, 1]\n\tSwitch on or off receiver text output during acquisition." + infer_action: true + template: true +rx_start: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: startReceiver + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: rx_start + function_alias: rx_start + help: "\n\tStarts receiver listener for detector data packets and create a data\ + \ file (if file write enabled)." + infer_action: true + template: true +rx_status: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getReceiverStatus + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: 'true' + message: '"Cannot put. Did you mean to use command: \"rx_start\" or \"rx_stop\"?"' + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: rx_status + function_alias: rx_status + help: "[running, idle, transmitting]\n\tReceiver listener status." + infer_action: true +rx_stop: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: stopReceiver + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: rx_stop + function_alias: rx_stop + help: "\n\tStops receiver listener for detector data packets and closes current\ + \ data file (if file write enabled)." + infer_action: true + template: true +rx_tcpport: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setRxPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_tcpport + function_alias: rx_tcpport + help: "[port]\n\tTCP port for client-receiver communication. Default is 1954. Must\ + \ be different if multiple receivers on same pc. Must be first command to set\ + \ a receiver parameter. Multi command will automatically increment for individual\ + \ modules." + infer_action: true + template: true +rx_threads: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxThreadIds + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_threads + function_alias: rx_threads + help: "\n\tGet kernel thread ids from the receiver in order of [parent, tcp, listener\ + \ 0, processor 0, streamer 0, listener 1, processor 1, streamer 1, arping]. If\ + \ no streamer yet or there is no second interface, it gives 0 in its place." + infer_action: true + template: true +rx_udpsocksize: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxUDPSocketBufferSize + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxUDPSocketBufferSize + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_udpsocksize + function_alias: rx_udpsocksize + help: "[n_size]\n\tUDP socket buffer size in receiver. Tune rmem_default and rmem_max\ + \ accordingly. Max value is INT_MAX/2." + infer_action: true + template: true +rx_version: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getReceiverVersion + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: rx_version + function_alias: rx_version + help: "\n\tReceiver version" + infer_action: true + template: true +rx_zmqfreq: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqFrequency + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxZmqFrequency + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_zmqfreq + function_alias: rx_zmqfreq + help: "[nth frame]\n\tFrequency of frames streamed out from receiver via zmq\n\t\ + Default: 1, Means every frame is streamed out. \n\tIf 2, every second frame is\ + \ streamed out. \n\tIf 0, streaming timer is the timeout, after which current\ + \ frame is sent out. (default timeout is 500 ms). Usually used for gui purposes." + infer_action: true + template: true +rx_zmqhwm: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqHwm + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setRxZmqHwm + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: rx_zmqhwm + function_alias: rx_zmqhwm + help: "[n_value]\n\tReceiver's zmq send high water mark. Default is the zmq library's\ + \ default (1000). This is a high number and can be set to 2 for gui purposes.\ + \ One must also set the client's receive high water mark to similar value. Final\ + \ effect is sum of them. Also restarts receiver zmq streaming if enabled. Can\ + \ set to -1 to set default value." + infer_action: true + template: true +rx_zmqip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqIP + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - IpAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setRxZmqIP + input: + - IpAddr(args[0]) + input_types: + - IpAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_zmqip + function_alias: rx_zmqip + help: "[x.x.x.x]\n\tZmq Ip Address from which data is to be streamed out of the\ + \ receiver. Also restarts receiver zmq streaming if enabled. Default is from rx_hostname.\ + \ Modified only when using an intermediate process between receiver." + infer_action: true + template: true +rx_zmqport: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setRxZmqPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_zmqport + function_alias: rx_zmqport + help: "[port]\n\tZmq port for data to be streamed out of the receiver. Also restarts\ + \ receiver zmq streaming if enabled. Default is 30001. Modified only when using\ + \ an intermediate process between receiver and client(gui). Must be different\ + \ for every detector (and udp port). Multi command will automatically increment\ + \ for individual modules." + infer_action: true + template: true +rx_zmqstartfnum: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqStartingFrame + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxZmqStartingFrame + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_zmqstartfnum + function_alias: rx_zmqstartfnum + help: "[fnum]\n\tThe starting frame index to stream out. 0 by default, which streams\ + \ the first frame in an acquisition, and then depending on the rx zmq frequency/\ + \ timer" + infer_action: true + template: true +rx_zmqstream: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getRxZmqDataStream + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setRxZmqDataStream + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: rx_zmqstream + function_alias: rx_zmqstream + help: "[0, 1]\n\tEnable/ disable data streaming from receiver via zmq (eg. to GUI\ + \ or to another process for further processing). This creates/ destroys zmq streamer\ + \ threads in receiver. \n\tSwitching to Gui automatically enables data streaming\ + \ in receiver. \n\tSwitching back to command line acquire will require disabling\ + \ data streaming in receiver for fast applications. " + infer_action: true + template: true +samples: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: samples + function_alias: samples + help: '' + infer_action: true + is_description: true +savepattern: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + function: savePattern + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: savepattern + function_alias: savepattern + help: "\n\t[Ctb][Mythen3][Xilinx Ctb] Saves pattern to file (ascii). \n\t[Ctb] Also\ + \ executes pattern." + infer_action: true + template: true +scan: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getScan + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: StringTo(args[0]) != 0 + message: '"Unknown argument " + args[0] + ". Did you mean 0 to disable scan?"' + function: setScan + input: + - defs::scanParameters() + input_types: + - auto + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + - arg_types: + - defs::dacIndex + - int + - int + - int + argc: 4 + cast_input: + - false + check_det_id: true + convert_det_id: true + function: setScan + input: + - defs::scanParameters(StringTo(args[0]), StringTo(args[1]), + StringTo(args[2]), StringTo(args[3])) + input_types: + - auto + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + - arg_types: + - defs::dacIndex + - int + - int + - int + - std::string + argc: 5 + cast_input: + - false + check_det_id: true + convert_det_id: true + function: setScan + input: + - defs::scanParameters(StringTo(args[0]), StringTo(args[1]), + StringTo(args[2]), StringTo(args[3]), t) + input_types: + - auto + output: + - ToString(args) + require_det_id: false + separate_time_units: + input: args[4] + output: + - t + - unit + store_result_in_t: false + command_name: scan + function_alias: scan + help: "[dac_name|0|trimbits] [start_val] [stop_val] [step_size] [dac settling time\ + \ ns|us|ms|s]\n\tEnables/ disables scans for dac and trimbits \n\tEnabling scan\ + \ sets number of frames to number of steps in receiver. \n\tTo cancel scan configuration,\ + \ set dac to '0', which also sets number of frames to 1. \n\t[Eiger][Mythen3]\ + \ Use trimbits as dac name for a trimbit scan." + infer_action: true +scanerrmsg: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getScanErrorMessage + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: scanerrmsg + function_alias: scanerrmsg + help: "\n\tGets Scan error message if scan ended in error for non blocking acquisitions." + infer_action: true + template: true +selinterface: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSelectedUDPInterface + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: selectUDPInterface + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: selinterface + function_alias: selinterface + help: "[0, 1]\n\t[Jungfrau][Moench] The udp interface to stream data from detector.\ + \ Effective only when number of interfaces is 1. Default: 0 (outer)" + infer_action: true + template: true +serialnumber: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSerialNumber + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + command_name: serialnumber + function_alias: serialnumber + help: "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb]\nSerial number\ + \ of detector." + infer_action: true + template: true +setbit: + actions: + PUT: + args: + - arg_types: + - uint32_t + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + exceptions: + - condition: StringTo(args[1]) < 0 || StringTo(args[1]) > 31 + message: '"Bit number out of range: " + args[1]' + function: setBit + input: + - args[0] + - args[1] + input_types: + - uint32_t + - int + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: setbit + function_alias: setbit + help: "[reg address in hex] [bit index]\n\tSets bit in address." + infer_action: true + template: true +settings: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSettings + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::detectorSettings + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setSettings + input: + - args[0] + input_types: + - defs::detectorSettings + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: settings + function_alias: settings + help: "[standard, fast, highgain, dynamicgain, lowgain, mediumgain, veryhighgain,\ + \ highgain0, fixgain1, fixgain2, forceswitchg1, forceswitchg2, verylowgain, g1_hg,\ + \ g1_lg, g2_hc_hg, g2_hc_lg, g2_lc_hg, g2_lc_lg, g4_hg, g4_lg, gain0]\n\t Detector\ + \ Settings\n\t[Jungfrau] - [ gain0 | highgain0]\n\t[Gotthard] - [dynamicgain |\ + \ highgain | lowgain | mediumgain | veryhighgain]\n\t[Gotthard] Also loads default\ + \ dacs on to the detector.\n\t[Gotthard2] - [dynamicgain | fixgain1 | fixgain2]\n\ + \t[Mythen3] - [standard | fast | highgain] Also changes vrshaper and vrpreamp.\ + \ \n\t[Eiger] Use threshold or thresholdnotb. \n\t[Eiger] threshold and settings\ + \ loaded from file found in settingspath. \n\t[Moench] - [g1_hg | g1_lg | g2_hc_hg\ + \ | g2_hc_lg | g2_lc_hg | g2_lc_lg | g4_hg | g4_lg]" + infer_action: true + template: true +settingslist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSettingsList + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: settingslist + function_alias: settingslist + help: "\n\tList of settings implemented for this detector." + infer_action: true + template: true +settingspath: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSettingsPath + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setSettingsPath + input: + - args[0] + input_types: + - std::string + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: settingspath + function_alias: settingspath + help: "[path]\n\t[Eiger][Mythen3] Directory where settings files are loaded from/to." + infer_action: true + template: true +signalindex: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: getSignalIndex + input: + - args[0] + input_types: + - std::string + output: + - static_cast(t) + require_det_id: false + store_result_in_t: true + command_name: signalindex + function_alias: signalindex + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the signal index for the given name." + infer_action: true + template: true +signallist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getSignalNames + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + - condition: cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: '"This detector already has fixed dac names. Cannot change them."' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setSignalNames + input: + - args + input_types: + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: signallist + function_alias: signallist + help: "[signalname1 signalname2 .. signalname63] \n\t\t[Ctb][Xilinx_Ctb] Set the\ + \ list of signal names for this board." + infer_action: true + template: true +signalname: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: getSignalName + input: + - args[0] + input_types: + - int + output: + - args[0] + - ''' ''' + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - std::string + argc: 2 + cast_input: + - true + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + function: setSignalName + input: + - args[0] + - args[1] + input_types: + - int + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: signalname + function_alias: signalname + help: "[0-63][name] \n\t\t[Ctb][Xilinx_Ctb] Set the signal at the given position\ + \ to the given name." + infer_action: true + template: true +slowadc: + actions: + GET: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: slowadc + function_alias: slowadc + help: '' + infer_action: true + is_description: true +slowadcindex: + actions: + GET: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + function: getSlowADCIndex + input: + - args[0] + input_types: + - std::string + output: + - ToString(static_cast(t) - index) + require_det_id: false + store_result_in_t: true + command_name: slowadcindex + function_alias: slowadcindex + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get the slowadc index for the given name." + infer_action: true + template: true +slowadclist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: getSlowADCNames + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: cmd != "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + - condition: cmd == "daclist" && det_type != defs::CHIPTESTBOARD && det_type + != defs::XILINX_CHIPTESTBOARD + message: '"This detector already has fixed dac names. Cannot change them."' + extra_variables: + - name: det_type + type: auto + value: det->getDetectorType().squash(defs::GENERIC); + function: setSlowADCNames + input: + - args + input_types: + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: slowadclist + function_alias: slowadclist + help: "[slowadcname1 slowadcname2 .. slowadcname7] \n\t\t[Ctb][Xilinx_Ctb] Set the\ + \ list of slowadc names for this board." + infer_action: true + template: true +slowadcname: + actions: + GET: + args: + - arg_types: + - defs::dacIndex + argc: 1 + cast_input: + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + function: getSlowADCName + input: + - static_cast(StringTo(args[0]) + index) + input_types: + - defs::dacIndex + output: + - args[0] + - ''' ''' + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::dacIndex + - std::string + argc: 2 + cast_input: + - false + - false + check_det_id: true + convert_det_id: true + exceptions: + - condition: det->getDetectorType().squash(defs::GENERIC) != defs::CHIPTESTBOARD + && det->getDetectorType().squash(defs::GENERIC) != defs::XILINX_CHIPTESTBOARD + message: cmd + " only allowed for CTB." + extra_variables: + - name: index + type: defs::dacIndex + value: defs::SLOW_ADC0 + function: setSlowADCName + input: + - static_cast(StringTo(args[0]) + index) + - args[1] + input_types: + - defs::dacIndex + - std::string + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: slowadcname + function_alias: slowadcname + help: "[0-7][name] \n\t\t[Ctb][Xilinx_Ctb] Set the slowadc at the given position\ + \ to the given name." + infer_action: true + template: true +slowadcvalues: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + ctb_output_list: + GETFCN: getSlowADC + GETFCNLIST: getSlowADCList + GETFCNNAME: getSlowADCNames + printable_name: '*name_it++' + suffix: mV + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: slowadcvalues + function_alias: slowadcvalues + help: "[name] \n\t\t[Ctb][Xilinx_Ctb] Get values of all slow adcs." + infer_action: true +start: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: startDetector + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: start + function_alias: start + help: "\n\tStarts detector acquisition. Status changes to RUNNING or WAITING and\ + \ automatically returns to idle at the end of acquisition. If the acquisition\ + \ was abruptly stopped, some detectors come back to STOPPED." + infer_action: true + template: true +status: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDetectorStatus + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: 'true' + message: '"Cannot put. Did you mean to use command: \"start\" or \"stop\"?"' + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: status + function_alias: status + help: "[running, error, transmitting, finished, waiting, idle]\n\tDetector status.\ + \ Goes to stop server." + infer_action: true +stop: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: stopDetector + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: stop + function_alias: stop + help: "\n\tAbort detector acquisition. Status changes to IDLE or STOPPED. Goes to\ + \ stop server." + infer_action: true + template: true +stopport: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getStopPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setStopPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: stopport + function_alias: stopport + help: "[n]\n\tPort number of the stop server on detector for detector-client tcp\ + \ interface. Default is 1953. Normally unchanged." + infer_action: true + template: true +storagecell_delay: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getStorageCellDelay + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getStorageCellDelay + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setStorageCellDelay + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setStorageCellDelay + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: storagecell_delay + function_alias: storagecell_delay + help: "[duration (0-1638375 ns)] [(optional unit) ns|us|ms|s]\n\t[Jungfrau] Additional\ + \ time delay between 2 consecutive exposures in burst mode (resolution of 25ns).\ + \ Only applicable for chipv1.0. For advanced users only." + infer_action: true + template: true +storagecell_start: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getStorageCellStart + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setStorageCellStart + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: storagecell_start + function_alias: storagecell_start + help: "[0-max]\n\t[Jungfrau] Storage cell that stores the first acquisition of the\ + \ series. max is 15 (default) for chipv1.0 and 3 (default) for chipv1.1. For advanced\ + \ users only." + infer_action: true + template: true +subdeadtime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSubDeadTime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSubDeadTime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setSubDeadTime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setSubDeadTime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: subdeadtime + function_alias: subdeadtime + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Dead time of EIGER subframes\ + \ in 32 bit mode. Subperiod = subexptime + subdeadtime." + infer_action: true + template: true +subexptime: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSubExptime + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + - arg_types: + - special::time_unit + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSubExptime + input: [] + input_types: [] + output: + - OutString(t , args[0]) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setSubExptime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + require_det_id: true + separate_time_units: + input: args[0] + output: + - converted_time + - unit + store_result_in_t: false + - arg_types: + - int + - special::time_unit + argc: 2 + cast_input: + - false + check_det_id: false + convert_det_id: true + convert_to_time: + input: + - args[0] + - args[1] + output: converted_time + function: setSubExptime + input: + - converted_time + input_types: + - time::ns + output: + - args[0] + - args[1] + require_det_id: true + store_result_in_t: false + command_name: subexptime + function_alias: subexptime + help: "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Exposure time of EIGER\ + \ subframes in 32 bit mode." + infer_action: true + template: true +sync: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSynchronization + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setSynchronization + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: sync + function_alias: sync + help: "[0, 1]\n\t[Jungfrau][Moench] Enables or disables synchronization between\ + \ modules. Sync mode requires at least one master configured. Also requires flatband\ + \ cabling between master and slave with termination board." + infer_action: true + template: true +syncclk: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSYNCClock + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: syncclk + function_alias: syncclk + help: "[n_clk in MHz]\n\t[Ctb] Sync clock in MHz." + infer_action: true + template: true +temp_10ge: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_10GE + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_10ge + function_alias: temp_10ge + help: "[n_value]\n\t[Eiger]Temperature close to the 10GbE" + infer_action: true + template: true +temp_adc: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_ADC + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_adc + function_alias: temp_adc + help: "[n_value]\n\t[Jungfrau][Moench][Gotthard] ADC Temperature" + infer_action: true + template: true +temp_control: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTemperatureControl + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTemperatureControl + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: temp_control + function_alias: temp_control + help: "[0, 1]\n\t[Jungfrau][Moench] Temperature control enable. Default is 0 (disabled).\ + \ If temperature crosses threshold temperature and temperature control is enabled,\ + \ power to chip will be switched off and temperature event occurs. To power on\ + \ chip again, temperature has to be less than threshold temperature and temperature\ + \ event has to be cleared." + infer_action: true + template: true +temp_dcdc: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_DCDC + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_dcdc + function_alias: temp_dcdc + help: "[n_value]\n\t[Eiger]Temperature close to the dc dc converter" + infer_action: true + template: true +temp_event: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTemperatureEvent + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: StringTo(args[0]) != 0 + message: '"Unknown argument for temp event: ( " + args[0] + " ). Did you + mean 0 to reset event?"' + function: resetTemperatureEvent + input: [] + input_types: [] + output: + - '"cleared"' + require_det_id: true + store_result_in_t: false + command_name: temp_event + function_alias: temp_event + help: "[0]\n\t[Jungfrau][Moench] 1, if a temperature event occured. To clear this\ + \ event, set it to 0.\n\tIf temperature crosses threshold temperature and temperature\ + \ control is enabled, power to chip will be switched off and temperature event\ + \ occurs. To power on chip again, temperature has to be less than threshold temperature\ + \ and temperature event has to be cleared." + infer_action: true +temp_fpga: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_FPGA + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_fpga + function_alias: temp_fpga + help: "[n_value]\n\t[Eiger][Jungfrau][Moench][Gotthard][Mythen3][Gotthard2] FPGA\ + \ Temperature" + infer_action: true + template: true +temp_fpgaext: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_FPGAEXT + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_fpgaext + function_alias: temp_fpgaext + help: "[n_value]\n\t[Eiger]Temperature close to the FPGA" + infer_action: true + template: true +temp_fpgafl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_FPGA2 + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_fpgafl + function_alias: temp_fpgafl + help: "[n_value]\n\t[Eiger]Temperature of the left front end board fpga." + infer_action: true + template: true +temp_fpgafr: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_FPGA3 + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_fpgafr + function_alias: temp_fpgafr + help: "[n_value]\n\t[Eiger]Temperature of the right front end board fpga." + infer_action: true + template: true +temp_slowadc: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::SLOW_ADC_TEMP + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_slowadc + function_alias: temp_slowadc + help: "[n_value]\n\t[Ctb]Temperature of the slow adc" + infer_action: true + template: true +temp_sodl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_SODL + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_sodl + function_alias: temp_sodl + help: "[n_value]\n\t[Eiger]Temperature close to the left so-dimm memory" + infer_action: true + template: true +temp_sodr: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getTemperature + input: + - defs::TEMPERATURE_SODR + input_types: + - int + output: + - OutString(t) + - "\" \xB0C\"" + require_det_id: true + store_result_in_t: true + command_name: temp_sodr + function_alias: temp_sodr + help: "[n_value]\n\t[Eiger]Temperature close to the right so-dimm memory" + infer_action: true + template: true +temp_threshold: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getThresholdTemperature + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setThresholdTemperature + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: temp_threshold + function_alias: temp_threshold + help: "[n_temp (in degrees)]\n\t[Jungfrau][Moench] Threshold temperature in degrees.\ + \ If temperature crosses threshold temperature and temperature control is enabled,\ + \ power to chip will be switched off and temperature event occurs. To power on\ + \ chip again, temperature has to be less than threshold temperature and temperature\ + \ event has to be cleared." + infer_action: true + template: true +templist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTemperatureList + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: templist + function_alias: templist + help: "\n\tList of temperature commands implemented for this detector." + infer_action: true + template: true +tempvalues: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + ctb_output_list: + GETFCN: getTemperature + GETFCNLIST: getTemperatureList + GETFCNNAME: '' + printable_name: '*it' + suffix: "\xB0C" + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: tempvalues + function_alias: tempvalues + help: "\n\tGets the values for every temperature for this detector." + infer_action: true +tengiga: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTenGiga + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTenGiga + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: tengiga + function_alias: tengiga + help: "[0, 1]\n\t[Eiger][Ctb][Mythen3] 10GbE Enable." + infer_action: true + template: true +threshold: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - defs::detectorSettings + argc: 2 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - int + - int + argc: 3 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - int + - int + - defs::detectorSettings + argc: 4 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: threshold + function_alias: threshold + help: '' + infer_action: true + is_description: true +thresholdnotb: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - defs::detectorSettings + argc: 2 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - int + - int + argc: 3 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + - arg_types: + - int + - int + - int + - defs::detectorSettings + argc: 4 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: thresholdnotb + duplicate_function: true + function_alias: threshold + help: '' + infer_action: true + is_description: true +timing: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTimingMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::timingMode + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTimingMode + input: + - args[0] + input_types: + - defs::timingMode + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: timing + function_alias: timing + help: "[auto|trigger|gating|burst_trigger]\n\tTiming Mode of detector.\n\t[Jungfrau][Moench][Gotthard][Ctb][Gotthard2][Xilinx\ + \ Ctb] [auto|trigger]\n\t[Mythen3] [auto|trigger|gating|trigger_gating]\n\t[Eiger]\ + \ [auto|trigger|gating|burst_trigger]" + infer_action: true + template: true +timinglist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTimingModeList + input: [] + input_types: [] + output: + - ToString(t) + require_det_id: false + store_result_in_t: true + command_name: timinglist + function_alias: timinglist + help: "\n\tGets the list of timing modes for this detector." + infer_action: true + template: true +timingsource: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTimingSource + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::timingSourceType + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTimingSource + input: + - args[0] + input_types: + - defs::timingSourceType + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: timingsource + function_alias: timingsource + help: "[internal|external]\n\t[Gotthard2] Timing source. Internal is crystal and\ + \ external is system timing. Default is internal." + infer_action: true + template: true +top: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTop + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTop + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: top + function_alias: top + help: "[0, 1]\n\t[Eiger] Sets half module to top (1), else bottom." + infer_action: true + template: true +transceiverenable: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTransceiverEnableMask + input: [] + input_types: [] + output: + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint32_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTransceiverEnableMask + input: + - args[0] + input_types: + - uint32_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: transceiverenable + function_alias: transceiverenable + help: "[bitmask]\n\t[Ctb] Transceiver Enable Mask. Enable for each 4 Transceiver\ + \ channel." + infer_action: true + template: true +trigger: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: true + convert_det_id: true + extra_variables: + - name: block + type: bool + value: 'false' + function: sendSoftwareTrigger + input: + - block + input_types: + - bool + output: + - '"successful"' + require_det_id: false + store_result_in_t: false + command_name: trigger + function_alias: trigger + help: "\n\t[Eiger][Mythen3][Jungfrau][Moench] Sends software trigger signal to detector" + infer_action: true + template: true +triggers: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfTriggers + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int64_t + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setNumberOfTriggers + input: + - args[0] + input_types: + - int64_t + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: triggers + function_alias: triggers + help: "[n_triggers]\n\tNumber of triggers per aquire. Set timing mode to use triggers." + infer_action: true + template: true +triggersl: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfTriggersLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: triggersl + function_alias: triggersl + help: "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number\ + \ of triggers left in acquisition. Only when external trigger used." + infer_action: true + template: true +trimbits: + actions: + GET: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: saveTrimbits + input: + - args[0] + input_types: + - std::string + output: + - args[0] + require_det_id: true + store_result_in_t: false + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: loadTrimbits + input: + - args[0] + input_types: + - std::string + output: + - args[0] + require_det_id: true + store_result_in_t: false + command_name: trimbits + function_alias: trimbits + help: "[fname]\n\t[Eiger][Mythen3] Put will load the trimbit file to detector. If\ + \ no extension specified, serial number of each module is attached. Get will save\ + \ the trimbits from the detector to file with serial number added to file name." + infer_action: true +trimen: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: trimen + function_alias: trimen + help: '' + infer_action: true + is_description: true +trimval: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getAllTrimbits + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setAllTrimbits + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: trimval + function_alias: trimval + help: "[n_trimval]\n\t[Eiger][Mythen3] All trimbits set to this value. Returns -1\ + \ if all trimbits are different values." + infer_action: true + template: true +tsamples: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberOfTransceiverSamples + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setNumberOfTransceiverSamples + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: tsamples + function_alias: tsamples + help: "[n_value]\n\t[Ctb] Number of transceiver samples expected." + infer_action: true + template: true +txdelay: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: getTransmissionDelay + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: true + convert_det_id: true + function: setTransmissionDelay + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: false + store_result_in_t: false + command_name: txdelay + function_alias: txdelay + help: "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Set transmission delay for\ + \ all modules in the detector using the step size provided.Sets up \n\t\t[Eiger]\ + \ txdelay_left to (2 * mod_index * n_delay), \n\t\t[Eiger] txdelay_right to ((2\ + \ * mod_index + 1) * n_delay) and \n\t\t[Eiger] txdelay_frame to (2 *num_modules\ + \ * n_delay) \n\t\t[Jungfrau][Moench][Mythen3] txdelay_frame to (num_modules\ + \ * n_delay) \nfor every module." + infer_action: true +txdelay_frame: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTransmissionDelayFrame + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTransmissionDelayFrame + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: txdelay_frame + function_alias: txdelay_frame + help: "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Transmission delay of first\ + \ udp packet being streamed out of the module.\n\t[Jungfrau][Moench] [0-31] Each\ + \ value represents 1 ms\n\t[Eiger] Additional delay to txdelay_left and txdelay_right.\ + \ Each value represents 10ns. Typical value is 50000.\n\t[Mythen3] [0-16777215]\ + \ Each value represents 8 ns (125 MHz clock), max is 134 ms." + infer_action: true + template: true +txdelay_left: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTransmissionDelayLeft + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTransmissionDelayLeft + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: txdelay_left + function_alias: txdelay_left + help: "[n_delay]\n\t[Eiger] Transmission delay of first packet in an image being\ + \ streamed out of the module's left UDP port. Each value represents 10ns. Typical\ + \ value is 50000." + infer_action: true + template: true +txdelay_right: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getTransmissionDelayRight + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setTransmissionDelayRight + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: txdelay_right + function_alias: txdelay_right + help: "[n_delay]\n\t[Eiger] Transmission delay of first packet in an image being\ + \ streamed out of the module's right UDP port. Each value represents 10ns. Typical\ + \ value is 50000." + infer_action: true + template: true +type: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDetectorType + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: type + function_alias: type + help: "\n\tReturns detector type. Can be Eiger, Jungfrau, Gotthard, Moench, Mythen3,\ + \ Gotthard2, ChipTestBoard, Xilinx_ChipTestBoard" + infer_action: true + template: true +udp_cleardst: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: clearUDPDestinations + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: udp_cleardst + function_alias: udp_cleardst + help: "\n\tClears udp destination details on the detector." + infer_action: true + template: true +udp_dstip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: udp_dstip + function_alias: udp_dstip + help: '' + infer_action: true + is_description: true +udp_dstip2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: udp_dstip2 + function_alias: udp_dstip2 + help: '' + infer_action: true + is_description: true +udp_dstlist: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: det_id == -1 + message: '"Can execute udp_dstlist only at module level."' + - condition: rx_id < 0 || rx_id >= MAX_UDP_DESTINATION + message: '"Invalid receiver index " + std::to_string(rx_id) + " to set round + robin entry."' + function: getDestinationUDPList + input: + - rx_id + input_types: + - auto + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: -1 + cast_input: + - false + check_det_id: false + convert_det_id: false + exceptions: + - condition: det_id == -1 + message: '"Can execute udp_dstlist only at module level."' + - condition: rx_id < 0 || rx_id >= MAX_UDP_DESTINATION + message: '"Invalid receiver index " + std::to_string(rx_id) + " to set round + robin entry."' + - condition: args.empty() + message: '"udp_dstlist require at least one argument."' + function: setDestinationUDPList + input: + - getUdpEntry() + input_types: + - auto + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: udp_dstlist + function_alias: udp_dstlist + help: "[ip=x.x.x.x] [(optional)ip2=x.x.x.x] \n\t\t[mac=xx:xx:xx:xx:xx:xx] [(optional)mac2=xx:xx:xx:xx:xx:xx]\n\ + \t\t[port=value] [(optional)port2=value]\n\t\tThe order of ip, mac and port does\ + \ not matter. entry_value can be >0 only for [Eiger][Jungfrau][Moench][Mythen3][Gotthard2]\ + \ where round robin is implemented. If 'auto' used, then ip is set to ip of rx_hostname." + infer_action: true +udp_dstmac: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDestinationUDPMAC + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - MacAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setDestinationUDPMAC + input: + - MacAddr(args[0]) + input_types: + - MacAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_dstmac + function_alias: udp_dstmac + help: "[x:x:x:x:x:x]\n\tMac address of the receiver (destination) udp interface.\ + \ Not mandatory to set as udp_dstip retrieves it from slsReceiver process, but\ + \ must be set if you use a custom receiver (not slsReceiver). Use router mac if\ + \ router between detector and receiver." + infer_action: true + template: true +udp_dstmac2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDestinationUDPMAC2 + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - MacAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setDestinationUDPMAC2 + input: + - MacAddr(args[0]) + input_types: + - MacAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_dstmac2 + function_alias: udp_dstmac2 + help: "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the receiver (destination)\ + \ udp interface 2. Not mandatory to set as udp_dstip2 retrieves it from slsReceiver\ + \ process but must be set if you use a custom receiver (not slsReceiver). \n\t\ + \ [Jungfrau][Moench] top half or inner interface \n\t [Gotthard2] veto debugging.\ + \ Use router mac if router between detector and receiver." + infer_action: true + template: true +udp_dstport: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDestinationUDPPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setDestinationUDPPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_dstport + function_alias: udp_dstport + help: "[n]\n\tPort number of the receiver (destination) udp interface. Default is\ + \ 50001. \n\tIf multi command, ports for each module is calculated (incremented\ + \ by 1 if no 2nd interface)" + infer_action: true + template: true +udp_dstport2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getDestinationUDPPort2 + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setDestinationUDPPort2 + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_dstport2 + function_alias: udp_dstport2 + help: "[n]\n\t[Jungfrau][Moench][Eiger][Gotthard2] Port number of the receiver (destination)\ + \ udp interface 2. Default is 50002. \n\tIf multi command, ports for each module\ + \ is calculated (incremented by 2) \n\t[Jungfrau][Moench] top half or inner interface\ + \ \n\t[Eiger] right half \n\t[Gotthard2] veto debugging" + infer_action: true + template: true +udp_firstdst: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getFirstUDPDestination + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setFirstUDPDestination + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_firstdst + function_alias: udp_firstdst + help: "\n[0 - 31 (or number of udp destinations)]\n\t[Jungfrau][Moench][Gotthard2]\n\ + [0-63]\n\t[Mythen3]\n\n\t One can set which is the first destination that the\ + \ detector will stream images out from in a round robin fashion. The entry must\ + \ not have been empty. Default: 0" + infer_action: true + template: true +udp_numdst: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getNumberofUDPDestinations + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: udp_numdst + function_alias: udp_numdst + help: "\n\t[Jungfrau][Moench][Eiger][Mythen3][Gotthard2] One can enter upto 32 (64\ + \ for Mythen3) destinations that the detector will stream images out in a round\ + \ robin fashion. This is get only command. Default: 1" + infer_action: true + template: true +udp_reconfigure: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: reconfigureUDPDestination + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: udp_reconfigure + function_alias: udp_reconfigure + help: "\n\tReconfigures Detector with UDP destination. More for debugging as the\ + \ configuration is done automatically when the detector has sufficient UDP details." + infer_action: true + template: true +udp_srcip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: udp_srcip + function_alias: udp_srcip + help: '' + infer_action: true + is_description: true +udp_srcip2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - std::string + argc: 1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: udp_srcip2 + function_alias: udp_srcip2 + help: '' + infer_action: true + is_description: true +udp_srcmac: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSourceUDPMAC + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - MacAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setSourceUDPMAC + input: + - MacAddr(args[0]) + input_types: + - MacAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_srcmac + function_alias: udp_srcmac + help: "[x:x:x:x:x:x]\n\tMac address of the detector (source) udp interface. \n\t\ + [Eiger] Do not set as detector will replace with its own DHCP Mac (1G) or DHCP\ + \ Mac + 1 (10G)." + infer_action: true + template: true +udp_srcmac2: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getSourceUDPMAC2 + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - MacAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setSourceUDPMAC2 + input: + - MacAddr(args[0]) + input_types: + - MacAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: udp_srcmac2 + function_alias: udp_srcmac2 + help: "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the top half or inner\ + \ (source) udp interface. " + infer_action: true + template: true +udp_validate: + actions: + PUT: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: validateUDPConfiguration + input: [] + input_types: [] + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: udp_validate + function_alias: udp_validate + help: "\n\tValidates that UDP configuration in the detector is valid. If not configured,\ + \ it will throw with error message requesting missing udp information." + infer_action: true + template: true +update: + actions: + PUT: + args: + - arg_types: + - special::path + - special::path + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: args[args.size() - 1].find(".pof") == std::string::npos && args[args.size() + - 1].find(".rbf") == std::string::npos + message: '"Programming file must be a pof/rbf file."' + function: updateFirmwareAndServer + input: + - args[0] + - args[1] + input_types: + - std::string + - std::string + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: update + function_alias: update + help: "\n\tWithout tftp: [server_name (incl fullpath)] [fname.pof (incl full path)]\ + \ This does not use tftp.\n\t\t[Jungfrau][Moench][Gotthard][Ctb] Updates the firmware,\ + \ detector server, deletes old server, creates the symbolic link and then reboots\ + \ detector controller. \n\t\t[Mythen3][Gotthard2] will require a script to start\ + \ up the shorter named server link at start up. \n\t\tserver_name is full path\ + \ name of detector server binary\n\t\tfname is full path of programming file" + infer_action: true +updatedetectorserver: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: updateDetectorServer + input: + - args[0] + input_types: + - std::string + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: updatedetectorserver + function_alias: updatedetectorserver + help: "[server_name with full path]\n\t[Jungfrau][Moench][Eiger][Ctb][Mythen3][Gotthard2]\ + \ Copies detector server via TCP (without tftp). Makes a symbolic link with a\ + \ shorter name (without vx.x.x). Then, detector controller reboots (except Eiger).\n\ + \t[Jungfrau][Moench][Ctb]Also changes respawn server to the link, which is effective\ + \ after a reboot." + infer_action: true +updatekernel: + actions: + PUT: + args: + - arg_types: + - special::path + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: updateKernel + input: + - args[0] + input_types: + - std::string + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: updatekernel + function_alias: updatekernel + help: "[kernel_name with full path]\n\t[Jungfrau][Moench][Ctb][Mythen3][Gotthard2]\ + \ Advanced Command!! You could damage the detector. Please use with caution.\n\ + \tUpdates the kernel image. Then, detector controller reboots with new kernel." + infer_action: true +updatemode: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getUpdateMode + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setUpdateMode + input: + - args[0] + input_types: + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: updatemode + function_alias: updatemode + help: "[0|1]\n\tRestart the detector server in update mode or not. This is useful\ + \ when server-firmware compatibility is at its worst and server cannot start up\ + \ normally" + infer_action: true + template: true +user: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: true + convert_det_id: true + function: getUserDetails + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + command_name: user + function_alias: user + help: "\n\tUser details from shared memory (hostname, type, PID, User, Date)." + infer_action: true +v_a: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_A + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_A + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_a + function_alias: v_a + help: "[n_value]\n\t[Ctb] Power supply a in mV." + infer_action: true + template: true +v_b: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_B + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_B + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_b + function_alias: v_b + help: "[n_value]\n\t[Ctb] Power supply b in mV." + infer_action: true + template: true +v_c: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_C + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_C + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_c + function_alias: v_c + help: "[n_value]\n\t[Ctb] Power supply c in mV." + infer_action: true + template: true +v_chip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_CHIP + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_CHIP + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_chip + function_alias: v_chip + help: "[n_value]\n\t[Ctb] Power supply chip in mV. Do not use it unless you are\ + \ completely sure you will not fry the board." + infer_action: true + template: true +v_d: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_D + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_D + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_d + function_alias: v_d + help: "[n_value]\n\t[Ctb] Power supply d in mV." + infer_action: true + template: true +v_io: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_POWER_IO + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_POWER_IO + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_io + function_alias: v_io + help: "[n_value]\n\t[Ctb] Power supply io in mV. Minimum 1200 mV. Must be the first\ + \ power regulator to be set after fpga reset (on-board detector server start up)." + infer_action: true + template: true +v_limit: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getPower + input: + - defs::V_LIMIT + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: setPower + input: + - defs::V_LIMIT + - args[0] + input_types: + - int + - int + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: v_limit + function_alias: v_limit + help: "[n_value]\n\t[Ctb] Soft limit for power supplies (ctb only) and DACS in mV." + infer_action: true + template: true +vchip_comp_adc: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VB_COMP_ADC + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VB_COMP_ADC + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_comp_adc + function_alias: vchip_comp_adc + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ for comparator current of ADC." + infer_action: true + template: true +vchip_comp_fe: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VB_COMP_FE + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VB_COMP_FE + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_comp_fe + function_alias: vchip_comp_fe + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ for comparator current of analogue front end." + infer_action: true + template: true +vchip_cs: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VB_CS + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VB_CS + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_cs + function_alias: vchip_cs + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ for current injection into preamplifier." + infer_action: true + template: true +vchip_opa_1st: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VB_OPA_1ST + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VB_OPA_1ST + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_opa_1st + function_alias: vchip_opa_1st + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ for opa current for driving the other DACs in chip." + infer_action: true + template: true +vchip_opa_fd: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VB_OPA_FD + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VB_OPA_FD + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_opa_fd + function_alias: vchip_opa_fd + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ current for CDS opa stage." + infer_action: true + template: true +vchip_ref_comp_fe: + actions: + GET: + args: + - arg_types: + - int + - int + argc: 1 + cast_input: + - false + - true + check_det_id: false + convert_det_id: true + function: getOnChipDAC + input: + - defs::VREF_COMP_FE + - args[0] + input_types: + - int + - int + output: + - args[0] + - ''' ''' + - OutStringHex(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + - int + argc: 2 + cast_input: + - false + - true + - true + check_det_id: false + convert_det_id: true + function: setOnChipDAC + input: + - defs::VREF_COMP_FE + - args[0] + - args[1] + input_types: + - int + - int + - int + output: + - args[0] + - ''' ''' + - args[1] + require_det_id: true + store_result_in_t: false + command_name: vchip_ref_comp_fe + function_alias: vchip_ref_comp_fe + help: "[chip index 0-9, -1 for all][10 bit hex value] \n\t[Gotthard2] On chip Dac\ + \ for reference voltage of the comparator of analogue front end." + infer_action: true + template: true +versions: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + command_name: versions + function_alias: versions + help: '' + infer_action: true + is_description: true +veto: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getVeto + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - bool + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setVeto + input: + - args[0] + input_types: + - bool + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: veto + function_alias: veto + help: "[0, 1]\n\t[Gotthard2] Enable or disable veto data data from chip. Default\ + \ is 0." + infer_action: true + template: true +vetoalg: + actions: + GET: + args: + - arg_types: + - defs::streamingInterface + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: interface == defs::streamingInterface::NONE + message: '"Must specify an interface to set algorithm"' + extra_variables: + - name: interface + type: defs::streamingInterface + value: StringTo(args[0]) + function: getVetoAlgorithm + input: + - interface + input_types: + - defs::streamingInterface + output: + - OutString(t) + - ''' ''' + - ToString(interface) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - defs::vetoAlgorithm + - defs::streamingInterface + argc: 2 + cast_input: + - false + - false + check_det_id: false + convert_det_id: true + exceptions: + - condition: interface == defs::streamingInterface::NONE + message: '"Must specify an interface to set algorithm"' + extra_variables: + - name: alg + type: defs::vetoAlgorithm + value: StringTo(args[0]) + - name: interface + type: defs::streamingInterface + value: StringTo(args[1]) + function: setVetoAlgorithm + input: + - alg + - interface + input_types: + - defs::vetoAlgorithm + - defs::streamingInterface + output: + - ToString(alg) + - ''' ''' + - ToString(interface) + require_det_id: true + store_result_in_t: false + command_name: vetoalg + function_alias: vetoalg + help: "[hits|raw] [lll|10gbe]\n\t[Gotthard2] Set the veto algorithm. Default is\ + \ hits." + infer_action: true +vetofile: + actions: + GET: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: 'true' + message: '"Cannot get vetofile. Did you mean vetophoton?"' + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - std::string + argc: 2 + cast_input: + - true + - false + check_det_id: false + convert_det_id: true + function: setVetoFile + input: + - args[0] + - args[1] + input_types: + - int + - std::string + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: vetofile + function_alias: vetofile + help: "[chip index 0-9, -1 for all] [file name] \n\t[Gotthard2] Set veto reference\ + \ for each 128 channels for specific chip. The file should have 128 rows of gain\ + \ index and 12 bit value in dec" + infer_action: true +vetophoton: + actions: + GET: + args: + - arg_types: + - int + - std::string + argc: 2 + cast_input: + - true + - false + check_det_id: false + convert_det_id: true + function: getVetoPhoton + input: + - args[0] + - args[1] + input_types: + - int + - std::string + output: + - '"saved to file "' + - args[1] + require_det_id: true + store_result_in_t: false + PUT: + args: + - arg_types: + - int + - int + - int + - std::string + argc: 4 + cast_input: + - true + - true + - true + - false + check_det_id: false + convert_det_id: true + function: setVetoPhoton + input: + - args[0] + - args[1] + - args[2] + - args[3] + input_types: + - int + - int + - int + - std::string + output: + - ToString(args) + require_det_id: true + store_result_in_t: false + command_name: vetophoton + function_alias: vetophoton + help: "[ichip] [#photons] [energy in keV] [reference file]\n\t[Gotthard2] Set veto\ + \ reference for 128 channels for chip ichip according to reference file and #photons\ + \ and energy in keV.\n[ichip] [output file]\n\t Get gain indices and veto reference\ + \ for 128 channels for chip ichip, saved to file." + infer_action: true +vetoref: + actions: + GET: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + exceptions: + - condition: 'true' + message: '"Cannot get vetoref. Did you mean vetophoton?"' + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + - int + argc: 2 + cast_input: + - true + - true + check_det_id: false + convert_det_id: true + function: setVetoReference + input: + - args[0] + - args[1] + input_types: + - int + - int + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: vetoref + function_alias: vetoref + help: "[gain index] [12 bit value]\n\t[Gotthard2] Set veto reference for all 128\ + \ channels for all chips." + infer_action: true +vetostream: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: [] + argc: -1 + cast_input: [] + check_det_id: false + convert_det_id: true + function: '' + input: [] + input_types: [] + output: [] + require_det_id: false + store_result_in_t: false + command_name: vetostream + function_alias: vetostream + help: '' + infer_action: true + is_description: true +virtual: + actions: + PUT: + args: + - arg_types: + - int + - uint16_t + argc: 2 + cast_input: + - true + - true + check_det_id: true + convert_det_id: true + function: setVirtualDetectorServers + input: + - args[0] + - args[1] + input_types: + - int + - uint16_t + output: + - ToString(args) + require_det_id: false + store_result_in_t: false + command_name: virtual + function_alias: virtualFunction + help: "[n_servers] [starting_port_number]\n\tConnecs to n virtual server at local\ + \ host starting at specific control port. Every virtual server will have a stop\ + \ port (control port + 1)" + infer_action: true +vm_a: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredPower + input: + - defs::V_POWER_A + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: vm_a + function_alias: vm_a + help: "\n\t[Ctb] Measured voltage of power supply a in mV." + infer_action: true + template: true +vm_b: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredPower + input: + - defs::V_POWER_B + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: vm_b + function_alias: vm_b + help: "\n\t[Ctb] Measured voltage of power supply b in mV." + infer_action: true + template: true +vm_c: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredPower + input: + - defs::V_POWER_C + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: vm_c + function_alias: vm_c + help: "\n\t[Ctb] Measured voltage of power supply c in mV." + infer_action: true + template: true +vm_d: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredPower + input: + - defs::V_POWER_D + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: vm_d + function_alias: vm_d + help: "\n\t[Ctb] Measured voltage of power supply d in mV." + infer_action: true + template: true +vm_io: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: getMeasuredPower + input: + - defs::V_POWER_IO + input_types: + - int + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + command_name: vm_io + function_alias: vm_io + help: "\n\t[Ctb] Measured voltage of power supply io in mV." + infer_action: true + template: true +zmqhwm: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getClientZmqHwm + input: [] + input_types: [] + output: + - t + require_det_id: false + store_result_in_t: true + PUT: + args: + - arg_types: + - int + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: true + function: setClientZmqHwm + input: + - args[0] + input_types: + - int + output: + - det->getClientZmqHwm() + require_det_id: false + store_result_in_t: false + command_name: zmqhwm + function_alias: zmqhwm + help: "[n_limit] \n\tClient's zmq receive high water mark. Default is the zmq library's\ + \ default (1000), can also be set here using -1. \n\tThis is a high number and\ + \ can be set to 2 for gui purposes. \n\tOne must also set the receiver's send\ + \ high water mark to similar value. Final effect is sum of them.\n\t Setting it\ + \ via command line is useful only before zmq enabled (before opening gui)." + infer_action: true +zmqip: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getClientZmqIp + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - IpAddr + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: setClientZmqIp + input: + - IpAddr(args[0]) + input_types: + - IpAddr + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: zmqip + function_alias: zmqip + help: "[x.x.x.x]\n\tIp Address to listen to zmq data streamed out from receiver\ + \ or intermediate process. Default connects to receiver zmq Ip Address (from rx_hostname).\ + \ Modified only when using an intermediate process between receiver and client(gui).\ + \ Also restarts client zmq streaming if enabled." + infer_action: true + template: true +zmqport: + actions: + GET: + args: + - arg_types: [] + argc: 0 + cast_input: [] + check_det_id: false + convert_det_id: true + function: getClientZmqPort + input: [] + input_types: [] + output: + - OutString(t) + require_det_id: true + store_result_in_t: true + PUT: + args: + - arg_types: + - uint16_t + argc: 1 + cast_input: + - true + check_det_id: false + convert_det_id: false + function: setClientZmqPort + input: + - args[0] + input_types: + - uint16_t + output: + - args.front() + require_det_id: true + store_result_in_t: false + command_name: zmqport + function_alias: zmqport + help: "[port]\n\tZmq port in client(gui) or intermediate process for data to be\ + \ streamed to from receiver. Default connects to receiver zmq streaming out port\ + \ (30001). Modified only when using an intermediate process between receiver and\ + \ client(gui). Also restarts client zmq streaming if enabled. Must be different\ + \ for every detector (and udp port). Multi command will automatically increment\ + \ for individual modules." + infer_action: true + template: true diff --git a/slsDetectorSoftware/generator/gen_commands.py b/slsDetectorSoftware/generator/gen_commands.py new file mode 100644 index 000000000..764f087a4 --- /dev/null +++ b/slsDetectorSoftware/generator/gen_commands.py @@ -0,0 +1,276 @@ +import argparse +import os +import subprocess +from pathlib import Path + +import yaml + +from autocomplete.autocomplete import type_info +from cpp_codegen.codegen import codegen, if_block, for_block, function, else_block +from infer_action.check_infer import check_infer +from autocomplete.autocomplete import type_values + +GEN_PATH = Path(__file__).parent + +COMMANDS_PATH = GEN_PATH / 'extended_commands.yaml' +DEPRECATED_COMMANDS_PATH = GEN_PATH / 'deprecated_commands.yaml' +CPP_INPUT_PATH = GEN_PATH / 'Caller.in.cpp' +HEADER_INPUT_PATH = GEN_PATH / 'Caller.in.h' +CPP_OUTPUT_PATH = GEN_PATH.parent / 'src' / 'Caller.cpp' +HEADER_OUTPUT_PATH = GEN_PATH.parent / 'src' / 'Caller.h' + +INFER_HEADER_INPUT_PATH = GEN_PATH / 'inferAction.in.h' +INFER_CPP_INPUT_PATH = GEN_PATH / 'inferAction.in.cpp' +INFER_HEADER_OUTPUT_PATH = GEN_PATH.parent / 'src' / 'inferAction.h' +INFER_CPP_OUTPUT_PATH = GEN_PATH.parent / 'src' / 'inferAction.cpp' + + +def generate( + commands_path=COMMANDS_PATH, + cpp_input_path=CPP_INPUT_PATH, + header_input_path=HEADER_INPUT_PATH, + cpp_output_path=CPP_OUTPUT_PATH, + header_output_path=HEADER_OUTPUT_PATH, + infer_header_input_path=INFER_HEADER_INPUT_PATH, + infer_cpp_input_path=INFER_CPP_INPUT_PATH, + infer_header_output_path=INFER_HEADER_OUTPUT_PATH, + infer_cpp_output_path=INFER_CPP_OUTPUT_PATH, + +): + commands_config = yaml.unsafe_load(commands_path.open('r')) + deprecated_commands_config = yaml.unsafe_load(DEPRECATED_COMMANDS_PATH.open('r')) + type_dist, non_dist = check_infer(commands=commands_config) + + codegen.open(cpp_output_path) + # write call function + codegen.write_opening(cpp_input_path) + + # iterate over the commands and generate code for each + print(f"[X] found {len(commands_config)} commands") + print('[*] generating code for commands') + for command_name, command in commands_config.items(): + if 'is_description' in command and command['is_description']: + continue + with function('std::string', 'Caller::' + command['function_alias'], [('int', 'action')]) as fn: + codegen.write_line('std::ostringstream os;') + + # print help + codegen.write_line('// print help') + with if_block('action == slsDetectorDefs::HELP_ACTION'): + if command["help"].startswith('code:'): + codegen.write_line(command["help"].strip('code:')) + else: + codegen.write_line(f'os << "Command: {command_name}" << std::endl;') + codegen.write_line(f'os << R"V0G0N({command["help"]} )V0G0N" << std::endl;') + codegen.write_line('return os.str();') + + # check if action and arguments are valid + + codegen.write_line('// check if action and arguments are valid') + first = True + for action, action_params in command['actions'].items(): + + with if_block(f'action == {codegen.actions_dict[action]}', elseif=not first): + + check_argc = True + for arg in action_params['args']: + if arg['argc'] == -1: + check_argc = False + break + # check number of arguments + condition = "1" if check_argc else "0" + + if check_argc: + for arg in action_params['args']: + condition += f' && args.size() != {arg["argc"]}' + + with if_block(condition): + codegen.write_line(f'throw RuntimeError("Wrong number of arguments for action {action}");') + + for arg in action_params['args']: + if not check_argc: + continue + with if_block(f'args.size() == {arg["argc"]}'): + # check argument types + if 'extra_variables' in arg: + for var in arg['extra_variables']: + codegen.write_line(f'{var["type"]} {var["name"]} = {var["value"]};') + + if 'separate_time_units' in arg and arg['separate_time_units']: + codegen.write_line(f'try {{') + # TODO: refactor this repeating code + codegen.write_line(f'std::string tmp_time({arg["separate_time_units"]["input"]});') + codegen.write_line(f'std::string {arg["separate_time_units"]["output"][1]}' + f' = RemoveUnit(tmp_time);') + codegen.write_line(f'auto {arg["separate_time_units"]["output"][0]} = ' + f'StringTo < time::ns > (tmp_time,' + f' {arg["separate_time_units"]["output"][1]});') + codegen.write_line( + f'}} catch (...) {{ throw RuntimeError("Could not convert argument to time::ns");}}') + + elif 'convert_to_time' in arg and arg['convert_to_time']: + codegen.write_line(f'try {{') + + codegen.write_line( + f'StringTo < time::ns > ({", ".join(arg["convert_to_time"]["input"])});') + codegen.write_line( + f'}} catch (...) {{ throw RuntimeError("Could not convert arguments to time::ns");}}') + + for i in range(len(arg['input'])): + if not arg['cast_input'][i]: + continue + codegen.write_line(f'try {{') + codegen.write_line(f'StringTo<{arg["input_types"][i]}>({arg["input"][i]});') + codegen.write_line(f'}} catch (...) {{') + codegen.write_line( + f' throw RuntimeError("Could not convert argument {i} to {arg["input_types"][i]}");') + codegen.write_line(f'}}') + first = False + with else_block(): + codegen.write_line( + f'throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions are {list(command["actions"].keys())}");') + + # generate code for each action + codegen.write_line('// generate code for each action') + for action, action_params in command['actions'].items(): + if 'detectors' in action_params: + codegen.write_line('auto detector_type = det->getDetectorType().squash();') + + with if_block(f'action == {codegen.actions_dict[action]}'): + if 'detectors' in action_params: + first = True + for detector, detector_params in action_params['detectors'].items(): + with if_block(f'detector_type == defs::{detector}', elseif=not first): + codegen.write_arg(detector_params, action, command_name) + + else_block().__enter__() + + if not action_params: + codegen.write_line(f'throw RuntimeError("detector not supported for action: {action}");') + else: + tmp_args = [] + if 'args' in action_params: + tmp_args = action_params['args'] + codegen.write_arg(tmp_args, action, command_name) + + if 'detectors' in action_params: + else_block().__exit__() + + codegen.write_line('return os.str();') + + # close sls namespace + codegen.write_closing() + codegen.close() + print('[X] .cpp code generated') + deprecated_commands = [] + codegen.write_header(header_input_path, header_output_path, commands_config, deprecated_commands_config) + print('[X] header code generated') + + + codegen.write_infer_header(infer_header_input_path, infer_header_output_path, commands_config) #TODO: add deprecated commands + print('[X] infer header code generated') + codegen.open(infer_cpp_output_path) + + codegen.write_infer_cpp(infer_cpp_input_path, infer_cpp_output_path, commands_config, non_dist, type_dist) + codegen.close() + print('[X] infer cpp code generated') + + +if __name__ == '__main__': + parser = argparse.ArgumentParser( + description='generate c++ code for cli commands from the commands.yaml file', + ) + parser.add_argument('-f', '--format', action='store_true', default=False, dest='format', + help='format header and cpp file using clang-format') + parser.add_argument('-p', '--parse', action='store_true', default=False, dest='parse', + help='parse the commands.yaml file into extended_commands.yaml') + parser.add_argument('-c', '--check', action='store_true', default=False, dest='check', + help='check missing commands') + parser.add_argument('-g', '--generate', action='store_true', default=False, dest='generate', help='generate code (C++ or bash if -a is used)') + parser.add_argument('-a', '--autocomplete', action='store_true', default=False, dest='autocomplete', + help='print bash autocomplete values') + cli_args = parser.parse_args() + + if cli_args.autocomplete: + from autocomplete.autocomplete import generate_type_values, generate_bash_autocomplete + if cli_args.generate: + generate_bash_autocomplete() + print('[X] bash autocomplete generated') + generate_bash_autocomplete( + output_path=Path(__file__).parent / 'autocomplete' / 'zsh_autocomplete.sh', + input_path=Path(__file__).parent / 'autocomplete' / 'zsh_autocomplete.in.sh' + ) + print('[X] zsh autocomplete generated') + exit(0) + else: + ret = generate_type_values() + print(ret) + exit(0) + + if cli_args.check: + from commands_parser.commands_parser import command_parser + + commands_config = yaml.unsafe_load(COMMANDS_PATH.open('r')) + + # infer action based on number of arguments and types + type_dist, non_dist = check_infer(commands=commands_config) + + command_parser.verify_format() + command_parser.parse_all_commands() + # generate list of commands found in sls_detector_get + glist_path = GEN_PATH / 'glist' + ret = subprocess.run([f"sls_detector_get list | tail -n +2 | sort > {glist_path.absolute()}"], shell=True, + capture_output=True, check=True) + if ret.stderr != b'': + print('[!] glist generation failed and glist not found') + exit(1) + + if not COMMANDS_PATH.exists(): + print('[!] extended_commands.yaml not found') + exit(1) + detglist = set(command['command_name'] for __, command in commands_config.items()) + detglist.add('free') + detglist.add('list') + + g_path = GEN_PATH / 'glist' + if not g_path.exists(): + print('[!] glist not found') + exit(1) + glist = set(g_path.read_text().split('\n')) + if "" in glist: + glist.remove("") + if "" in detglist: + detglist.remove("") + + not_found = set() + for command in glist: + if command not in detglist: + not_found.add(command) + print() + if len(not_found) > 0: + print(f'[!] found {len(not_found)} missing') + print(f"not_found: {not_found}") + else: + print(f'[X] found no missing commands') + + for command in detglist: + if command not in glist: + print(f'[!] command {command} found in commands.yaml but not found in g list') + + exit(0) + + if cli_args.parse: + from commands_parser.commands_parser import command_parser + + command_parser.verify_format() + command_parser.parse_all_commands() + + if cli_args.generate: + generate() + + if cli_args.format: + files = [CPP_OUTPUT_PATH, HEADER_OUTPUT_PATH, INFER_HEADER_OUTPUT_PATH, INFER_CPP_OUTPUT_PATH] + for file in files: + os.system(f'clang-format -i {file.absolute()}') + #os.system(f'clang-format -i --style="{{Standard: C++11}}" {file.absolute()}') + print('[X] code formatted') diff --git a/slsDetectorSoftware/generator/inferAction.in.cpp b/slsDetectorSoftware/generator/inferAction.in.cpp new file mode 100644 index 000000000..715109075 --- /dev/null +++ b/slsDetectorSoftware/generator/inferAction.in.cpp @@ -0,0 +1,20 @@ +#include "inferAction.h" +#include "sls/sls_detector_defs.h" +namespace sls { + +int InferAction::infer(sls::CmdParser &parser, std::ostream &os) { + args = parser.arguments(); + cmd = parser.command(); + auto it = functions.find(parser.command()); + if (it != functions.end()) { + return ((*this).*(it->second))(); + } else { + throw RuntimeError( + "sls_detector not implemented for command: " + parser.command() + + ". Use sls_detector_get or sls_detector_put."); + } +} + +// THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1) - DO NOT REMOVE + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/generator/inferAction.in.h b/slsDetectorSoftware/generator/inferAction.in.h new file mode 100644 index 000000000..c9e298009 --- /dev/null +++ b/slsDetectorSoftware/generator/inferAction.in.h @@ -0,0 +1,30 @@ +#include "CmdParser.h" +#include +#include +#include + +namespace sls { +class InferAction { + public: + InferAction() {} + int infer(sls::CmdParser &parser, std::ostream &os = std::cout); + std::vector args; + std::string cmd; + + // generated functions + // THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (1) - DO NOT REMOVE + // int frames(); + + private: + using FunctionMap = std::map; + FunctionMap functions{ + // generated functions + + // THIS COMMENT TO BE REPLACED BY THE ACTUAL CODE (2) - DO NOT REMOVE + + // {"frames",&InferAction::frames} + + }; +}; + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/generator/infer_action/check_infer.py b/slsDetectorSoftware/generator/infer_action/check_infer.py new file mode 100644 index 000000000..fe88eedcc --- /dev/null +++ b/slsDetectorSoftware/generator/infer_action/check_infer.py @@ -0,0 +1,64 @@ +from pathlib import Path + +import argparse +import yaml + + +def check_infer(EXTENDED_COMMANDS_PATH=Path(__file__).parent.parent / "extended_commands.yaml", commands=None): + if commands is None: + # load yaml file + with EXTENDED_COMMANDS_PATH.open('r') as f: + commands = yaml.safe_load(f) + + type_distinguishable = {} + non_distinguishable = {} + + for command_name, command in commands.items(): + # todo: remove this (added for debug) + # if command_name != 'badchannels': + # continue + if len(command["actions"]) == 1: + action = list(command["actions"].items())[0][1] + for arg in action['args']: + if arg['argc'] == -1: + non_distinguishable[(command_name, arg['argc'])] = ([], arg['arg_types']) + continue + + + get_argcs = {} + get_args = command['actions']['GET']['args'] + for arg in get_args: + if arg['argc'] != -1: + get_argcs[arg["argc"]] = arg['arg_types'] + else: + non_distinguishable[(command_name, arg['argc'])] = ([], arg['arg_types']) + put_args = command['actions']['PUT']['args'] + for arg in put_args: + if arg['argc'] == -1: + non_distinguishable[(command_name, arg['argc'])] = ([], arg['arg_types']) + elif arg['argc'] in get_argcs: + if arg['arg_types'] != get_argcs[arg['argc']]: + type_distinguishable[(command_name, arg['argc'])] = (get_argcs[arg['argc']], arg['arg_types']) + else: + non_distinguishable[(command_name, arg['argc'])] = (get_argcs[arg['argc']], arg['arg_types']) + + return type_distinguishable, non_distinguishable + + +if __name__ == "__main__": + argparse = argparse.ArgumentParser() + argparse.add_argument("--print", choices=['all', 'type', 'impossible'], default="all", help="command name") + args = argparse.parse_args() + + type_distinguishable, non_distinguishable = check_infer() + if args.print == 'type' or args.print == 'all': + print("type distinguishable:") + print("command_name: argc get_arg_type put_arg_type\n") + for (command_name, argc), (get_arg_types, put_arg_types) in type_distinguishable.items(): + print(f"{command_name}: {argc} {get_arg_types} {put_arg_types}") + + if args.print == 'impossible' or args.print == 'all': + print("\n\nimpossible to distinguish:") + print("command_name: argc get_arg_type put_arg_type") + for (command_name, argc), (get_arg_types, put_arg_types) in non_distinguishable.items(): + print(f"{command_name}: {argc} {get_arg_types} {put_arg_types}") diff --git a/slsDetectorSoftware/generator/readme.md b/slsDetectorSoftware/generator/readme.md new file mode 100644 index 000000000..6fb8d741b --- /dev/null +++ b/slsDetectorSoftware/generator/readme.md @@ -0,0 +1,288 @@ +# Generator +used to generate C++ cli commands. and bash autocompletion scripts. +## Autocomplete + +### Overview + +Looks through the `dump.json` file for the different values of an enum and stores them in the dictionary `type_values`. +```sh +# To print the different values for enums +python gen_commands.py -a +``` + +also the autocomplete.py generates shell autocompletion scripts for both bash and zsh. It uses the template file `bash_autocomplete.in.sh` and adds the necessary code in an output file `bash_autocomplete.sh` (same for zsh). +To use the bash autocompletion the `bash_autocomplete.sh` must be sourced. + +```sh +source bash_autocomplete.sh +# g will give the list of all commands +# p 0: will also give the list of all commands +# g exp will autocomplete to g exptime +# g exptime will return "s ms us ns" +# p timing will return "auto,burst_trigger,gating..." +``` + +**Note:** +The dump.json is the AST of the file `slsDetectorPackage/slsSupportLib/src/ToString.cpp`. + +```sh +# to generate the dump.json file +cd slsSupportLib/src/ToString.cpp +clang++ -Xclang -ast-dump=json -Xclang -ast-dump-filter -Xclang StringTo -c ToString.cpp -I ../include/ -std=gnu++11 +# clang version used: 14.0.0-1ubuntu1.1 +``` + +the `dump.json` file produced by clang is not a correct json file because we used the `-ast-dump-filter`. autocomplete.py can be used to fix the format of `dump.json` and produce a new file called `fixed.json` that is json format. +``` +# to convert dump.json into correct json format. +python autocomplete.py -f # produces the file fixed.json +``` + +### Code components + +- `type_values` is a dictionary that contains the different values for commands args. It is populated with enum values that stard with defs:: or slsDetectorDefs:: (eg. defs::burstMode). Also it contains values added manually such as "mv,mV" and those start with special:: +- `generate_type_values` parses the AST file to find the part that contains if statements. and extracts the different possible values for an enum. +- `generate_bash_autocomplete` generates autocompletion scripts for bash or zsh. the difference between zsh and bash scripts can be found in the template files. (bash handles 0: completion differently than zsh more details can be found in the comments of the template files ) +- `fix_json` fixes the file 'autocomplete/dump.json' and outputs a new corrected file in 'autocomplete/fixed.json' + +## Command Parser + +Definitely the most important component of all the generator module. + +command_parser exist to keep the commands.yaml file concise and easy to read and produce a complete version of the commands.yaml for the code generator to work on. + +The goal is that the code generator works on a version of commands.yaml that is easy to iterate over and generate code. +``` +# complete version +some_command: + help: "do this" + infer_action: true + actions: + GET: + args: + - argc: 0 + function: "getCommand" + ... + - argc: 1 + function: "getCommand" + ... + detectors: + MYTHEN3: + - argc: 0 + function: "getCommandMythen" + ... + PUT: + args: + - argc: 2 + function: "setCommand" + ... + - argc: 3 + function: "setCommand" + ... + +``` + +the complete vesion can only have `args` or `detectors` field inside an action (GET or PUT). **Each element in the args array have a different argc**. and in each element in the args array we can find all the information needed to generate the code for that one argc case. for example in the code `if(action == 'GET')` and `if (args.size() == 1)` then we can generate the code for that one case independetly. + + +commands.yaml has a lot on ~inheritance~. examples show best what it is: + +> fields insides an action will be passed to args and detectors + +> the extended args for default actions will be used for detectors + +> any field can be overriden + +``` +resetdacs: + help: "[(optional) hard] ..." + actions: + PUT: + function: resetToDefaultDacs + require_det_id: true + output: [ '"successful"' ] + input_types: [ bool ] + args: + - argc: 1 + arg_types: [ special::hard ] + input: [ '"1"' ] + - argc: 0 + input: [ '"0"' ] + +# this will be converted to + +resetdacs: + actions: + PUT: + args: + - arg_types: + - special::hard + argc: 1 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: resetToDefaultDacs + input: + - '"1"' + input_types: + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + - arg_types: [] + argc: 0 + cast_input: + - false + check_det_id: false + convert_det_id: true + function: resetToDefaultDacs + input: + - '"0"' + input_types: + - bool + output: + - '"successful"' + require_det_id: true + store_result_in_t: false + command_name: resetdacs + function_alias: resetdacs + help: "[(optional) hard] ..." + infer_action: true + +``` + +command_parser does not have a specific schema for the commands.yaml this is by design so it can be very extensible and future-proof. This also can have problems when there is typos (writing intput instead of input...) + +command_parser first verifies the commands.yaml and checks if there's some obvious problems in it. + +templates found in commands.yaml were taken from the CmdProxy code they were added for debugging purposes when writing the generator. + + +tricky things: +-- +- if input array has n elements and cast_input array is empty. command_parser will fill it with n false values. +- store_result_in_t will be added by default as true to GET action. but as false to PUT action. (unless it is written in the action) +- infer_action by default is true +- commands that have is_description true won't be verified +- function_alias is the name of the function in the c++ code. by default it is the command name. errors came up with the command virtual as virtual is a reserved keyword in c++ +- command_name is the string of the command that will be typed in cli. (frames, exptime, ...). by default it is the command name. pattern is a special keyword in yaml. problems came up with the command pattern +- arg_types is by default input_types unless otherwise specified +- when the parent has specific detector behaviour and the child does not. writing an empty detector section in the action would not inherit any detector specific fields (check exptime1) +- commands can inherit other commands (check exptime1 and exptime2) +- argc: -1 means that the command has an unknown number of arguments + + +### Code Walkthrough +the code is well commented it is well explained in the script + +### Tests +tests for command_parser can be found in `generator/tests/command_parser/` +``` +pip install -r requirements.txt +python -m pytests +``` + +verification is not well tested + + + +## codegen + +Now for C++ code generation. After parsing the commands.yaml file and producing the extended_commands.yaml `gen_commands.py` will iterate over the commands and generate `Caller.h`, `Caller.cpp`, `inferAction.cpp` and `inferAction.h` . + +### infer action + +the generated code will produce 5 new targets: "sls_detector_get sls_detector_put sls_detector_acquire sls_detector_help sls_detector" + +`sls_detector_get` will set the action as GET +`sls_detector_put` will the action as PUT + +`sls_detector` will guess the action depending on the number of arguments + +the codegen module will generate a function for every command that will return the action based on the number of arguments + +```cpp +int InferAction::activate() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} +``` + +the `inferAction` class will be called from `CmdApp.cpp` to infer the action and the command function will be called with the appropriate action. + +some commands have the same number of argument count for both get and put. These commands can be found using the the `check_infer.py` script. in the generated code it will say that "sls_detector is disabled" +```bash +# to see these commands +python infer_action/check_infer.py +``` + +### Caller.cpp code + +in this level we only use the extended_commands.yaml file. +the `generate()` function in `gen_commands.py` will iterate over all of the commands and : +- write the function signature +- write the help +- write c++ code to check the inputs: check argument count and check if we are able to convert the arguments into the required types +- iterate over actions and arguments +- iterate over the detectors and write code for each one of them (if mythen3 ... if eiger ... else default code... ) and call `codegen.write_arg()` to write the argument for a single argument + +codegen.write_arg() +- +write_arg in codegen reads the argument fields and generate c++ code accordingly. + +## fields explanations +- arg_types:[array of types] it is only used for autocompletion no C++ code is dependent on it +- is_description:[boolean] same as above +- template:[boolean] only used in commands.yaml and it won't present in extended_commands.yaml. it is inspired by the CmdProxy.h code +- help:[string] command help +- input:[array of variable names] the input arguments that will be passed to the function +- input_types:[array of types] the types of the input arguments given to the function +- cast_input:[array of boolean] if true it will cast the corresponding input to the type in input_types +- output:[array] outputs that will be printed (eg. ["123", "'a'"] will be os<<123<<'a') +- function: the function that will be called +- function_alias: the name of the function in the c++ code (more on it in tricky things) +- command_name: the string of the command that will be typed in cli. (more on it in tricky things) +- require_det_id: if true it will require a detector id to be passed as the last argument +- check_det_id: if true it will check the detector id and throw an error if it is not valid +- convert_det_id: if true it will convert the detector id to the correct type `std::vector{ det_id }` +- store_result_in_t: if true it will store the result of the function in the variable t (more on it in tricky things) +- infer_action: if true it will infer the action (only if sls_detector is used) +- detectors: the detectors that have specific behaviour +- args: the arguments of the command +- argc: the number of arguments +- extra_variables[array]: each element takes three parameters: value, name, type and creates that variable in the beginning of the argument code +- exceptions[array]: each element takes two parameters: condition, message +- pattern_command: takes three arguments: nGetArgs, nPutArgs and command_name and it will write this code + ```cpp + int level = -1, iArg = 0, nGetArgs = $nGetArgs$, nPutArgs = $nPutArgs$; + GetLevelAndUpdateArgIndex(action, $command_name$, level, iArg, nGetArgs,nPutArgs); + ``` +- separate_time_units: takes three parameters: input, output[0], output[1] each one is a variable name + ```cpp + std::string tmp_time($input$); + std::string $output[1]$ = RemoveUnit(tmp_time); + auto $output[0]$ = StringTo(tmp_time, $output[1]$); + ``` +- convert_to_time: takes three parameters: input[0], input[1], output + ```cpp + auto output = StringTo(input[0], input[1]); + ``` +- ctb_output_list: **maybe it should be removed?** takes 5 parameters: GETFCNLIST, GETFCNNAME, GETFCN, suffix, printable_name + + + + + + + diff --git a/slsDetectorSoftware/generator/requirements.txt b/slsDetectorSoftware/generator/requirements.txt new file mode 100644 index 000000000..049320b14 --- /dev/null +++ b/slsDetectorSoftware/generator/requirements.txt @@ -0,0 +1,6 @@ +coverage==7.3.1 +iniconfig==2.0.0 +packaging==23.1 +pluggy==1.3.0 +pytest==7.4.2 +PyYAML==6.0.1 diff --git a/slsDetectorSoftware/generator/tests/command_parser/data/basic.yaml b/slsDetectorSoftware/generator/tests/command_parser/data/basic.yaml new file mode 100644 index 000000000..b684b39e5 --- /dev/null +++ b/slsDetectorSoftware/generator/tests/command_parser/data/basic.yaml @@ -0,0 +1,16 @@ +basic: + infer_action: false + help: "xx11" + actions: + GET: + function: 'func1' + output: [ OutString(t) ] + args: + - argc: 0 + PUT: + function: 'func2' + output: [ 'args.front()' ] + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + argc: 1 diff --git a/slsDetectorSoftware/generator/tests/command_parser/data/basic_inheritance.yaml b/slsDetectorSoftware/generator/tests/command_parser/data/basic_inheritance.yaml new file mode 100644 index 000000000..cb9365809 --- /dev/null +++ b/slsDetectorSoftware/generator/tests/command_parser/data/basic_inheritance.yaml @@ -0,0 +1,66 @@ +--- +template: + infer_action: false + help: "" + actions: + GET: + function: 'func1' + args: + - argc: 0 + output: [ OutString(t) ] + PUT: + function: 'func2' + output: [ 'args.front()' ] + input: [ 'args[0]' ] + input_types: [ int ] + cast_input: [ true ] + argc: 1 + +basic: + help: "xx11" + inherit_actions: template + actions: + GET: + function: 'x' + argc: 2 + args: + - check_det_id: true + + +template2: + infer_action: false + template: true + help: "" + actions: + GET: + convert_to_time: + input: [ 'args[0]', 'args[1]' ] + output: converted_time + separate_time_units: + input: 'args[0]' + output: [ converted_time, unit ] + function: 'func1' + output: [ OutString(t) ] + args: + - argc: 0 + - argc: 99 + PUT: + function: funcTemplatePUT + args: + - argc: 19 + function: 'func19' + - argc: 91 + +basic2: + inherit_actions: template2 + actions: + GET: + function: 'x' + argc: 2 + args: + - check_det_id: true + input: [ 'args[0]', a,b,c ] + input_types: [ int, int, int, int ] + PUT: + function: 'y' + diff --git a/slsDetectorSoftware/generator/tests/command_parser/data/detectors.yaml b/slsDetectorSoftware/generator/tests/command_parser/data/detectors.yaml new file mode 100644 index 000000000..3e12394eb --- /dev/null +++ b/slsDetectorSoftware/generator/tests/command_parser/data/detectors.yaml @@ -0,0 +1,208 @@ +basic: + infer_action: false + help: "xx11" + actions: + GET: + function: 'func1' + output: [ OutString(t) ] + args: + - argc: 0 + - argc : 1 + output: [ testytest ] + detectors: + MYTHEN3: + function: 'do_mythen3' + CHIPTESTBOARD: + args: + - argc: 55 + output: [ ctbOutput ] + PUT: + detectors: + EIGER: + function: 'do_eiger' + argc: 99 + output: [ eigerOutput ] + + +# classes of tests: +# classes of template tests: has args or has detectors => 4 cases noted (0,0) ... (1,1) +# classes of childs: has args or has detectors => 4 cases noted (0,0) ... (1,1) +# => 16 cases +# example: case_0111: template (0,1) and child (1,1) +#################### exhaustive testing over chosen classes of tests + +template_01: + infer_action: true + help: "vv12" + template: true + + actions: + GET: + detectors: + MYTHEN3: + function: 'do_mythen3' + argc: 99 + CHIPTESTBOARD: + function: 'do_ctb' + argc: 98 + +case_0100: + inherit_actions: template_01 + help: "0100" + +case_0101: + inherit_actions: template_01 + help: "0101" + actions: + GET: + function: 'get_function' + detectors: + MYTHEN3: + function: 'do_mythen23' + argc: 420 + +case_0110: + inherit_actions: template_01 + help: "0110" + actions: + GET: + argc: 111 + function: 'get_function' + +case_0110v2: + inherit_actions: template_01 + help: "0110v2" + actions: + GET: + args: + - argc: 111 + function: 'get_function' + + +case_0111: + inherit_actions: template_01 + help: "0111" + actions: + GET: + args: + - argc: 111 + function: 'get_function' + detectors: + MYTHEN3: + function: 'do_mythen23' + argc: 420 + +##### cases 10** tests +template_10: + template: true + actions: + GET: + args: + - argc: 0 + - argc : 1 + output: [ testytest ] + +case_1000: + inherit_actions: template_10 + help: "1000" + +case_1001: + inherit_actions: template_10 + help: "1001" + actions: + GET: + detectors: + MYTHEN3: + args: + - function: 'do_mythen23' + argc: 420 + - function: 'do_mythen3' + argc: 99 + + + +case_1010: + inherit_actions: template_10 + help: "1010" + actions: + GET: + args: + - argc: 111 + function: 'get_function' + +case_1011: + inherit_actions: template_10 + help: "1011" + actions: + GET: + args: + - argc: 111 + function: 'get_function' + detectors: + MYTHEN3: + function: 'do_mythen23' + +##### cases 11** tests +template_11: + template: true + actions: + GET: + args: + - argc: 0 + - argc : 1 + output: [ testytest ] + detectors: + EIGER: + function: 'do_eiger' + args: + - argc: 99 + output: [ eigerOutput ] + POTATO: + function: 'do_potato' + + +case_1100: + inherit_actions: template_11 + help: "1100" + +case_1101: + inherit_actions: template_11 + help: "1101" + actions: + GET: + detectors: + MYTHEN3: + function: 'do_mythen3' + POTATO: + function: 'do_potato' + args: + - argc: 101 + function: 'potato_function' + - argc: 202 + +case_1110: + inherit_actions: template_11 + help: "1110" + actions: + GET: + argc: 77 + function: 'get_function' + + + +case_1111: + inherit_actions: template_11 + help: "1111" + actions: + GET: + argc: 77 + function: 'get_function' + detectors: + MYTHEN3: + function: 'do_mythen3' + POTATO: + function: 'do_potato' + args: + - argc: 101 + function: 'potato_function' + - argc: 202 \ No newline at end of file diff --git a/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_basic.py b/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_basic.py new file mode 100644 index 000000000..53d0e1d0a --- /dev/null +++ b/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_basic.py @@ -0,0 +1,101 @@ +from pathlib import Path + +import yaml + +from commands_parser.commands_parser import CommandParser + +data_path = Path(__file__).parent.parent / "data" + + +def test_basic_propagation(tmp_path): + output_file = tmp_path / "basic.yaml" + command_parser = CommandParser(commands_file=data_path / "basic.yaml", output_file=output_file) + command_parser.verify_format() + command_parser.parse_all_commands() + + assert output_file.exists() + command = yaml.unsafe_load(output_file.open('r'))['basic'] + assert command['help'] == "xx11" + assert len(command['actions']) == 2 + # test 'GET' action + assert 'args' in command['actions']['GET'] + assert len(command['actions']['GET'].keys()) == 1 # only 'args' key + assert len(command['actions']['GET']['args']) == 1 # only one argument + assert command['actions']['GET']['args'][0]['argc'] == 0 + assert command['actions']['GET']['args'][0]['function'] == 'func1' + assert command['actions']['GET']['args'][0]['output'] == ['OutString(t)'] + assert command['actions']['GET']['args'][0]['input'] == [] + assert command['actions']['GET']['args'][0]['cast_input'] == [] + assert command['actions']['GET']['args'][0]['require_det_id'] is False + # test PUT action + assert 'args' in command['actions']['PUT'] + assert len(command['actions']['PUT'].keys()) == 1 # only 'args' key + assert len(command['actions']['PUT']['args']) == 1 # only one argument + assert command['actions']['PUT']['args'][0]['argc'] == 1 + assert command['actions']['PUT']['args'][0]['function'] == 'func2' + assert command['actions']['PUT']['args'][0]['cast_input'] == [True] + assert command['actions']['PUT']['args'][0]['output'] == ['args.front()'] + assert command['actions']['PUT']['args'][0]['input_types'] == ['int'] + assert command['actions']['PUT']['args'][0]['require_det_id'] is False + + +def test_basic_inheritance(tmp_path): + output_file = tmp_path / "basic_inheritance.yaml" + command_parser = CommandParser(commands_file=data_path / "basic_inheritance.yaml", output_file=output_file) + command_parser.verify_format() + command_parser.parse_all_commands() + assert output_file.exists() + command = yaml.unsafe_load(output_file.open('r'))['basic'] + assert command['help'] == "xx11" + assert command['actions'].keys() == {'GET', 'PUT'} + # test 'GET' action + assert 'args' in command['actions']['GET'] + assert command['actions']['GET'].keys() == {'args'} # only 'args' key + assert len(command['actions']['GET']['args']) == 1 # only one argument + assert command['actions']['GET']['args'][0]['argc'] == 2 + assert command['actions']['GET']['args'][0]['function'] == 'x' + assert command['actions']['GET']['args'][0]['output'] == [] # test overwriting args when they are present in child + assert command['actions']['GET']['args'][0]['input'] == [] + assert command['actions']['GET']['args'][0]['cast_input'] == [] + assert command['actions']['GET']['args'][0]['require_det_id'] is False + # test PUT action + assert 'args' in command['actions']['PUT'] + assert command['actions']['PUT'].keys() == {'args'} # only 'args' key + assert len(command['actions']['PUT']['args']) == 1 # only one argument + assert command['actions']['PUT']['args'][0]['argc'] == 1 + assert command['actions']['PUT']['args'][0]['function'] == 'func2' + assert command['actions']['PUT']['args'][0]['cast_input'] == [True] + assert command['actions']['PUT']['args'][0]['output'] == ['args.front()'] + assert command['actions']['PUT']['args'][0]['input_types'] == ['int'] + assert command['actions']['PUT']['args'][0]['require_det_id'] is False + + +def test_basic_inheritance2(tmp_path): + output_file = tmp_path / "basic_inheritance.yaml" + command_parser = CommandParser(commands_file=data_path / "basic_inheritance.yaml", output_file=output_file) + command_parser.verify_format() + command_parser.parse_all_commands() + assert output_file.exists() + command = yaml.unsafe_load(output_file.open('r'))['basic2'] + # check GET + assert len(command['actions']['GET']['args']) == 1 + assert command['actions']['GET'].keys() == {'args'} + arg = command['actions']['GET']['args'][0] + assert arg['argc'] == 2 + assert arg['output'] == ['OutString(t)'] + # check that length of cast input is equal to length of input_types and input + assert len(arg['input']) == len(arg['input_types']) == len(arg['cast_input']) == 4 + assert arg['function'] == 'x' + assert 'convert_to_time' in arg + assert arg['convert_to_time'].keys() == {'input', 'output'} + assert 'separate_time_units' in arg + assert arg['separate_time_units'].keys() == {'input', 'output'} + + # check PUT + assert command['actions']['PUT'].keys() == {'args'} + assert len(command['actions']['PUT']['args']) == 2 + assert command['actions']['PUT']['args'][0]['argc'] == 19 + assert command['actions']['PUT']['args'][0]['function'] == 'y' + assert command['actions']['PUT']['args'][1]['argc'] == 91 + assert command['actions']['PUT']['args'][1]['function'] == 'y' + diff --git a/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_detector.py b/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_detector.py new file mode 100644 index 000000000..cfbff4b9f --- /dev/null +++ b/slsDetectorSoftware/generator/tests/command_parser/functional_tests/test_commands_parser_detector.py @@ -0,0 +1,309 @@ +import json +from pathlib import Path + +import pytest as pytest +import yaml + +from commands_parser.commands_parser import CommandParser + +data_path = Path(__file__).parent.parent / "data" + + +@pytest.fixture() +def detector_file_commands(tmp_path): + output_file = tmp_path / "detectors.yaml" + command_parser = CommandParser(commands_file=data_path / "detectors.yaml", output_file=output_file) + command_parser.verify_format() + + def func(command): + return command_parser.parse_command(command) + + return func + + +def test_basic_propagation(tmp_path, detector_file_commands): + command = detector_file_commands('basic') + + assert command['help'] == "xx11" + + # GET + assert command['actions']['GET'].keys() == {'detectors', 'args'} + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3', 'CHIPTESTBOARD'} + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 2 + assert mythen[0]['argc'] == 0 + assert mythen[1]['argc'] == 1 + assert mythen[0]['function'] == mythen[1]['function'] == 'do_mythen3' + assert mythen[0]['output'] == ['OutString(t)'] + assert mythen[1]['output'] == ['testytest'] + + ctb = command['actions']['GET']['detectors']['CHIPTESTBOARD'] + assert len(ctb) == 1 + assert ctb[0]['argc'] == 55 + assert ctb[0]['function'] == 'func1' + + # PUT + assert command['actions']['PUT'].keys() == {'detectors'} + assert command['actions']['PUT']['detectors'].keys() == {'EIGER'} + eiger = command['actions']['PUT']['detectors']['EIGER'] + assert len(eiger) == 1 + assert eiger[0]['argc'] == 99 + assert eiger[0]['function'] == 'do_eiger' + assert eiger[0]['output'] == ['eigerOutput'] + +# 16 test cases for inheritance +# 1st bit: parent has args +# 2nd bit: parent has detectors +# 3rd bit: child has args +# 4th bit: child has detectors +# each test case is a combination of the above bits +# all the possible combinations are tested + +def test_inheritance_0100(tmp_path, detector_file_commands): + command = detector_file_commands('case_0100') + assert command['help'] == "0100" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'detectors'} + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3', 'CHIPTESTBOARD'} + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 1 + assert mythen[0]['argc'] == 99 + assert mythen[0]['function'] == 'do_mythen3' + + +def test_inheritance_0101(tmp_path, detector_file_commands): + command = detector_file_commands('case_0101') + assert command['help'] == "0101" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'detectors'} + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3', 'CHIPTESTBOARD'} + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 1 + assert mythen[0]['argc'] == 420 + assert mythen[0]['function'] == 'do_mythen23' + ctb = command['actions']['GET']['detectors']['CHIPTESTBOARD'] + assert len(ctb) == 1 + assert ctb[0]['argc'] == 98 + assert ctb[0]['function'] == 'do_ctb' + + +def test_inheritance_0110(tmp_path, detector_file_commands): + command = detector_file_commands('case_0110') + assert command['help'] == "0110" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert command['actions']['GET']['args'][0]['argc'] == 111 + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 1 + assert mythen[0]['argc'] == 99 + assert mythen[0]['function'] == 'do_mythen3' + ctb = command['actions']['GET']['detectors']['CHIPTESTBOARD'] + assert len(ctb) == 1 + assert ctb[0]['argc'] == 98 + assert ctb[0]['function'] == 'do_ctb' + + +def test_inheritance_0110v2(tmp_path, detector_file_commands): + command = detector_file_commands('case_0110v2') + assert command['help'] == "0110v2" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert command['actions']['GET']['args'][0]['argc'] == 111 + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 1 + assert mythen[0]['argc'] == 99 + assert mythen[0]['function'] == 'do_mythen3' + ctb = command['actions']['GET']['detectors']['CHIPTESTBOARD'] + assert len(ctb) == 1 + assert ctb[0]['argc'] == 98 + assert ctb[0]['function'] == 'do_ctb' + + +def test_inheritacnce_0111(tmp_path, detector_file_commands): + command = detector_file_commands('case_0111') + assert command['help'] == "0111" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3', 'CHIPTESTBOARD'} + mythen = command['actions']['GET']['detectors']['MYTHEN3'] + assert len(mythen) == 1 + assert command['actions']['GET']['args'][0]['argc'] == 111 + assert len(mythen) == 1 + assert mythen[0]['argc'] == 420 + assert mythen[0]['function'] == 'do_mythen23' + ctb = command['actions']['GET']['detectors']['CHIPTESTBOARD'] + assert len(ctb) == 1 + assert ctb[0]['argc'] == 98 + assert ctb[0]['function'] == 'do_ctb' + + +# cases 1000, 1001, 1010, 1011 +def test_inheritance_1000(tmp_path, detector_file_commands): + command = detector_file_commands('case_1000') + assert command['help'] == "1000" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args'} + assert len(command['actions']['GET']['args']) == 2 + assert command['actions']['GET']['args'][0]['argc'] == 0 + assert command['actions']['GET']['args'][0]['output'] == [] + + assert command['actions']['GET']['args'][1]['argc'] == 1 + assert command['actions']['GET']['args'][1]['output'] == ['testytest'] + + +def test_inheritance_1001(tmp_path, detector_file_commands): + command = detector_file_commands('case_1001') + assert command['help'] == "1001" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 2 + assert command['actions']['GET']['args'][0]['argc'] == 0 + assert command['actions']['GET']['args'][0]['output'] == [] + assert command['actions']['GET']['args'][1]['argc'] == 1 + assert command['actions']['GET']['args'][1]['output'] == ['testytest'] + + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3'} + assert len(command['actions']['GET']['detectors']['MYTHEN3']) == 2 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['argc'] == 420 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['function'] == 'do_mythen23' + assert command['actions']['GET']['detectors']['MYTHEN3'][1]['argc'] == 99 + assert command['actions']['GET']['detectors']['MYTHEN3'][1]['function'] == 'do_mythen3' + + +def test_inheritance_1010(tmp_path, detector_file_commands): + command = detector_file_commands('case_1010') + assert command['help'] == "1010" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args'} + assert len(command['actions']['GET']['args']) == 1 + assert command['actions']['GET']['args'][0]['argc'] == 111 + assert command['actions']['GET']['args'][0]['function'] == 'get_function' + + +def test_inheritance_1011(tmp_path, detector_file_commands): + command = detector_file_commands('case_1011') + assert command['help'] == "1011" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 1 + assert command['actions']['GET']['args'][0]['argc'] == 111 + assert command['actions']['GET']['args'][0]['function'] == 'get_function' + + assert command['actions']['GET']['detectors'].keys() == {'MYTHEN3'} + assert len(command['actions']['GET']['detectors']['MYTHEN3']) == 1 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['argc'] == 111 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['function'] == 'do_mythen23' + + +# cases 1100, 1101, 1110, 1111 + +def test_inheritance_1100(tmp_path, detector_file_commands): + command = detector_file_commands('case_1100') + assert command['help'] == "1100" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 2 + assert command['actions']['GET']['args'][0]['argc'] == 0 + assert command['actions']['GET']['args'][0]['output'] == [] + + assert command['actions']['GET']['args'][1]['argc'] == 1 + assert command['actions']['GET']['args'][1]['output'] == ['testytest'] + + assert command['actions']['GET']['detectors'].keys() == {'EIGER', 'POTATO'} + assert len(command['actions']['GET']['detectors']['EIGER']) == 1 + assert command['actions']['GET']['detectors']['EIGER'][0]['argc'] == 99 + assert command['actions']['GET']['detectors']['EIGER'][0]['function'] == 'do_eiger' + assert command['actions']['GET']['detectors']['EIGER'][0]['output'] == ['eigerOutput'] + + assert len(command['actions']['GET']['detectors']['POTATO']) == 2 + assert command['actions']['GET']['detectors']['POTATO'][0]['argc'] == 0 + assert command['actions']['GET']['detectors']['POTATO'][0]['function'] == 'do_potato' + + +def test_inheritance_1101(tmp_path, detector_file_commands): + command = detector_file_commands('case_1101') + assert command['help'] == "1101" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 2 + assert command['actions']['GET']['args'][0]['argc'] == 0 + assert command['actions']['GET']['args'][0]['output'] == [] + assert command['actions']['GET']['args'][1]['argc'] == 1 + assert command['actions']['GET']['args'][1]['output'] == ['testytest'] + + assert command['actions']['GET']['detectors'].keys() == {'EIGER', 'MYTHEN3', 'POTATO'} + assert len(command['actions']['GET']['detectors']['MYTHEN3']) == 2 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['argc'] == 0 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['function'] == 'do_mythen3' + assert command['actions']['GET']['detectors']['MYTHEN3'][1]['argc'] == 1 + assert command['actions']['GET']['detectors']['MYTHEN3'][1]['function'] == 'do_mythen3' + + assert len(command['actions']['GET']['detectors']['EIGER']) == 1 + assert command['actions']['GET']['detectors']['EIGER'][0]['argc'] == 99 + assert command['actions']['GET']['detectors']['EIGER'][0]['function'] == 'do_eiger' + assert command['actions']['GET']['detectors']['EIGER'][0]['output'] == ['eigerOutput'] + + assert len(command['actions']['GET']['detectors']['POTATO']) == 2 + assert command['actions']['GET']['detectors']['POTATO'][0]['argc'] == 101 + assert command['actions']['GET']['detectors']['POTATO'][0]['function'] == 'potato_function' + assert command['actions']['GET']['detectors']['POTATO'][1]['argc'] == 202 + assert command['actions']['GET']['detectors']['POTATO'][1]['function'] == 'do_potato' + + +def test_inheritance_1110(tmp_path, detector_file_commands): + command = detector_file_commands('case_1110') + assert command['help'] == "1110" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 1 + assert command['actions']['GET']['args'][0]['argc'] == 77 + assert command['actions']['GET']['args'][0]['function'] == 'get_function' + + assert command['actions']['GET']['detectors'].keys() == {'EIGER', 'POTATO'} + assert len(command['actions']['GET']['detectors']['EIGER']) == 1 + assert command['actions']['GET']['detectors']['EIGER'][0]['argc'] == 99 + assert command['actions']['GET']['detectors']['EIGER'][0]['function'] == 'do_eiger' + + assert len(command['actions']['GET']['detectors']['POTATO']) == 2 + assert command['actions']['GET']['detectors']['POTATO'][0]['argc'] == 0 + assert command['actions']['GET']['detectors']['POTATO'][0]['function'] == 'do_potato' + assert command['actions']['GET']['detectors']['POTATO'][1]['argc'] == 1 + assert command['actions']['GET']['detectors']['POTATO'][1]['function'] == 'do_potato' + + +def test_inheritance_1111(tmp_path, detector_file_commands): + command = detector_file_commands('case_1111') + assert command['help'] == "1111" + assert 'actions' in command + assert command['actions'].keys() == {'GET'} + assert command['actions']['GET'].keys() == {'args', 'detectors'} + assert len(command['actions']['GET']['args']) == 1 + assert command['actions']['GET']['args'][0]['argc'] == 77 + assert command['actions']['GET']['args'][0]['function'] == 'get_function' + + assert command['actions']['GET']['detectors'].keys() == {'EIGER', 'MYTHEN3', 'POTATO'} + assert len(command['actions']['GET']['detectors']['MYTHEN3']) == 1 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['argc'] == 77 + assert command['actions']['GET']['detectors']['MYTHEN3'][0]['function'] == 'do_mythen3' + + assert len(command['actions']['GET']['detectors']['EIGER']) == 1 + assert command['actions']['GET']['detectors']['EIGER'][0]['argc'] == 99 + assert command['actions']['GET']['detectors']['EIGER'][0]['function'] == 'do_eiger' + + assert len(command['actions']['GET']['detectors']['POTATO']) == 2 + assert command['actions']['GET']['detectors']['POTATO'][0]['argc'] == 101 + assert command['actions']['GET']['detectors']['POTATO'][0]['function'] == 'potato_function' + assert command['actions']['GET']['detectors']['POTATO'][1]['argc'] == 202 + assert command['actions']['GET']['detectors']['POTATO'][1]['function'] == 'do_potato' diff --git a/slsDetectorSoftware/generator/tests/test_parse_and_generate.py b/slsDetectorSoftware/generator/tests/test_parse_and_generate.py new file mode 100644 index 000000000..333c667b8 --- /dev/null +++ b/slsDetectorSoftware/generator/tests/test_parse_and_generate.py @@ -0,0 +1,29 @@ +from pathlib import Path +from commands_parser.commands_parser import CommandParser +import gen_commands + +data_path = Path(__file__).parent.parent + + +def test_parse_and_generate(tmp_path): + """ + tests that the parse and generate functions work without errors + :param tmp_path: + :return: + """ + output_file = tmp_path / "detectors.yaml" + command_parser = CommandParser(commands_file=data_path / "commands.yaml", output_file=output_file) + command_parser.verify_format() + command_parser.parse_all_commands() + assert output_file.exists() + + GEN_PATH = Path(__file__).parent.parent + gen_commands.generate( + output_file, + GEN_PATH / "Caller.in.cpp", + GEN_PATH / "Caller.in.h", + tmp_path / "Caller.cpp", + tmp_path / "Caller.h", + ) + assert (tmp_path / "Caller.cpp").exists() + assert (tmp_path / "Caller.h").exists() diff --git a/slsDetectorSoftware/generator/very_special_functions.txt b/slsDetectorSoftware/generator/very_special_functions.txt new file mode 100644 index 000000000..63ee9c104 --- /dev/null +++ b/slsDetectorSoftware/generator/very_special_functions.txt @@ -0,0 +1,28 @@ +hostname (find +) +acquire +versions (maybe with few tweaks) +threshold (+++++) +trimen (maybe with few tweaks) +badchannels (somewhat special) +currentsource (special) +dacvalues (can be done with the ctb_output_list) +udp_srcip (could be done if I add condition functionality for logging) +udp_srcip2 (same as above) +udp_dstip (same as above) +udp_dstip2 +rx_hostname (split('+')) +rx_roi (can be done if there;s condition support?) +ratecorr (can be done if there's condition support?) +burstmode (very special) +vetostream +counters +gaincaps (has for loop and condition) +samples (ask Dhanya if it is okay to change the order of calling the ctb functions in PUT) +slowadc (has for loop) +rx_dbitlist (very special) +rx_jsonaddheader (very special) +execcommand (has for loop) +thresholdnotb +# notes +# ReceiverStatus error on put is not done +# ask about burstmode function diff --git a/slsDetectorSoftware/include/sls/Detector.h b/slsDetectorSoftware/include/sls/Detector.h index 09c15f6cd..55e7826bb 100644 --- a/slsDetectorSoftware/include/sls/Detector.h +++ b/slsDetectorSoftware/include/sls/Detector.h @@ -71,7 +71,6 @@ class Detector { /** Gets shared memory ID */ int getShmId() const; - /** package git branch */ std::string getPackageVersion() const; std::string getClientVersion() const; @@ -99,7 +98,7 @@ class Detector { Result getReceiverVersion(Positions pos = {}) const; /** Options: EIGER, JUNGFRAU, GOTTHARD, MOENCH, MYTHEN3, GOTTHARD2, - * CHIPTESTBOARD */ + * CHIPTESTBOARD, XILINX_CHIPTESTBOARD */ Result getDetectorType(Positions pos = {}) const; /** Gets the total number of modules in shared memory */ @@ -216,7 +215,10 @@ class Detector { /** [Jungfrau][Moench] **/ Result getSynchronization(Positions pos = {}) const; - /** [Jungfrau][Moench] */ + /** [Jungfrau][Moench] Sync mode requires at least one master configured. + Also requires flatband cabling between master and slave with + termination board. + */ void setSynchronization(bool value); /** [Gotthard2][Mythen3] */ @@ -320,11 +322,11 @@ class Detector { /** [Gotthard][Jungfrau][Moench][CTB][Mythen3][Gotthard2] */ void setDelayAfterTrigger(ns value, Positions pos = {}); - /** [Gotthard][Jungfrau][Moench][CTB][Mythen3] + /** [Gotthard][Jungfrau][Moench][CTB][Mythen3][Xilinx CTB] * [Gotthard2] only in continuous auto mode */ Result getNumberOfFramesLeft(Positions pos = {}) const; - /** [Gotthard][Jungfrau][Moench][CTB][Mythen3] + /** [Gotthard][Jungfrau][Moench][CTB][Mythen3][Xilinx CTB] * Only when external trigger used */ Result getNumberOfTriggersLeft(Positions pos = {}) const; @@ -341,7 +343,7 @@ class Detector { /** * [Eiger] Options: 4, 8, 12, 16, 32. If i is 32, also sets clkdivider to 2, * else sets clkdivider to 1 \n [Mythen3] Options: 8, 16, 32 \n - * [Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2] 16 + * [Jungfrau][Moench][Gotthard][CTB][Mythen3][Gotthard2][Xilinx CTB] 16 */ void setDynamicRange(int value); @@ -351,10 +353,10 @@ class Detector { Result getTimingMode(Positions pos = {}) const; /** - * [Gotthard][Jungfrau][Moench][Gotthard][CTB][Gotthard2] Options: - * AUTO_TIMING, TRIGGER_EXPOSURE \n - * [Mythen3] Options: AUTO_TIMING, TRIGGER_EXPOSURE, GATED, TRIGGER_GATED \n - * [Eiger] Options: AUTO_TIMING, TRIGGER_EXPOSURE, GATED, BURST_TRIGGER + * [Gotthard][Jungfrau][Moench][Gotthard][CTB][Gotthard2][Xilinx CTB] + * Options: AUTO_TIMING, TRIGGER_EXPOSURE \n [Mythen3] Options: AUTO_TIMING, + * TRIGGER_EXPOSURE, GATED, TRIGGER_GATED \n [Eiger] Options: AUTO_TIMING, + * TRIGGER_EXPOSURE, GATED, BURST_TRIGGER */ void setTimingMode(defs::timingMode value, Positions pos = {}); @@ -1844,20 +1846,20 @@ class Detector { * Pattern * * * * ************************************************/ - /** [CTB][Mythen3] Gets the pattern file name including path of the last - * pattern uploaded. \n Returns an empty if nothing was uploaded or via a - * server default file*/ + /** [CTB][Mythen3][Xilinx CTB] Gets the pattern file name including path of + * the last pattern uploaded. \n Returns an empty if nothing was uploaded or + * via a server default file*/ Result getPatterFileName(Positions pos = {}) const; - /** [CTB][Mythen3] Loads ASCII pattern file directly to server + /** [CTB][Mythen3][Xilinx CTB] Loads ASCII pattern file directly to server * (instead of executing line by line)*/ void setPattern(const std::string &fname, Positions pos = {}); - /** [CTB][Mythen3] Loads pattern parameters structure directly to - * server */ + /** [CTB][Mythen3][Xilinx CTB] Loads pattern parameters structure directly + * to server */ void setPattern(const Pattern &pat, Positions pos = {}); - /** [CTB][Mythen3] [Ctb][Mythen3] Saves pattern to file + /** [CTB][Mythen3][Xilinx CTB] Saves pattern to file * (ascii). \n [Ctb] Also executes pattern.*/ void savePattern(const std::string &fname); @@ -1870,57 +1872,57 @@ class Detector { /** [CTB] */ void setPatternIOControl(uint64_t word, Positions pos = {}); - /** [CTB][Mythen3] same as executing for ctb */ + /** [CTB][Mythen3][Xilinx CTB] same as executing for ctb */ Result getPatternWord(int addr, Positions pos = {}); - /** [CTB] Caution: If word is -1 reads the addr (same as + /** [CTB][Xilinx CTB] Caution: If word is -1 reads the addr (same as * executing the pattern) * [Mythen3] */ void setPatternWord(int addr, uint64_t word, Positions pos = {}); - /**[CTB][Mythen3] Options: level: -1 (complete pattern) and 0-2 + /**[CTB][Mythen3][Xilinx CTB] Options: level: -1 (complete pattern) and 0-2 * levels * @returns array of start address and stop address */ Result> getPatternLoopAddresses(int level, Positions pos = {}) const; - /** [CTB][Mythen3] Options: level: -1 (complete pattern) and 0-2 + /** [CTB][Mythen3][Xilinx CTB] Options: level: -1 (complete pattern) and 0-2 * levels */ void setPatternLoopAddresses(int level, int start, int stop, Positions pos = {}); - /**[CTB][Mythen3] Options: level: -1 (complete pattern) and 0-2 + /**[CTB][Mythen3][Xilinx CTB] Options: level: -1 (complete pattern) and 0-2 * levels */ Result getPatternLoopCycles(int level, Positions pos = {}) const; - /** [CTB][Mythen3] n: 0-2, level: -1 (complete pattern) and 0-2 + /** [CTB][Mythen3][Xilinx CTB] n: 0-2, level: -1 (complete pattern) and 0-2 * levels */ void setPatternLoopCycles(int level, int n, Positions pos = {}); - /**[CTB][Mythen3] */ + /**[CTB][Mythen3][Xilinx CTB] */ Result getPatternWaitAddr(int level, Positions pos = {}) const; - /** [CTB][Mythen3] Options: level 0-2 */ + /** [CTB][Mythen3][Xilinx CTB] Options: level 0-2 */ void setPatternWaitAddr(int level, int addr, Positions pos = {}); - /** [CTB][Mythen3] */ + /** [CTB][Mythen3][Xilinx CTB] */ Result getPatternWaitTime(int level, Positions pos = {}) const; - /** [CTB][Mythen3] Options: level 0-2 */ + /** [CTB][Mythen3][Xilinx CTB] Options: level 0-2 */ void setPatternWaitTime(int level, uint64_t t, Positions pos = {}); - /** [CTB][Mythen3] */ + /** [CTB][Mythen3][Xilinx CTB] */ Result getPatternMask(Positions pos = {}); - /** [CTB][Mythen3] Selects the bits that will have a pattern mask - * applied to the selected patmask for every pattern. */ + /** [CTB][Mythen3][Xilinx CTB] Selects the bits that will have a pattern + * mask applied to the selected patmask for every pattern. */ void setPatternMask(uint64_t mask, Positions pos = {}); - /** [CTB][Mythen3] */ + /** [CTB][Mythen3][Xilinx CTB] */ Result getPatternBitMask(Positions pos = {}) const; - /** [CTB][Mythen3] Sets the mask applied to every pattern to the + /** [CTB][Mythen3][Xilinx CTB] Sets the mask applied to every pattern to the * selected bits */ void setPatternBitMask(uint64_t mask, Positions pos = {}); diff --git a/slsDetectorSoftware/include/sls/Result.h b/slsDetectorSoftware/include/sls/Result.h index 2578ad2ba..0cb937408 100644 --- a/slsDetectorSoftware/include/sls/Result.h +++ b/slsDetectorSoftware/include/sls/Result.h @@ -8,7 +8,8 @@ * from the detector. Since every module could have a different value, we need * to return a vector instead of just a single value. * - * Easy conversions to single values are provided using the squash method. + * Easy conversions to single values are provided using the squash and tsquash + * method. */ #include @@ -16,6 +17,7 @@ #include #include "sls/ToString.h" +#include "sls/TypeTraits.h" #include "sls/container_utils.h" namespace sls { @@ -128,6 +130,25 @@ template > class Result { /** Test whether all elements of the result are equal */ bool equal() const noexcept { return allEqual(vec); } + /** Test whether any element of the result are equal to a value */ + bool any(const T &value) const noexcept { return anyEqualTo(vec, value); } + + template > + typename std::enable_if::value, bool>::type + contains_only(const V &a, const Args &...args) const noexcept { + auto values = {a, args...}; + for (const auto &element : vec) { + int found = 0; + for (const auto &value : values) { + if (value == element) + found++; + } + if (!found) + return false; + } + return true; + } + /** Convert Result to std::vector */ operator std::vector() { return vec; } }; diff --git a/slsDetectorSoftware/src/Caller.cpp b/slsDetectorSoftware/src/Caller.cpp new file mode 100644 index 000000000..163811d93 --- /dev/null +++ b/slsDetectorSoftware/src/Caller.cpp @@ -0,0 +1,18260 @@ +#include "Caller.h" +#include "sls/logger.h" +#include "sls/string_utils.h" +#include + +namespace sls { + +std::string Caller::activate(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: activate" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] 1 is default. 0 deactivates readout and does not send data. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getActive(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setActive(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcclk(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcclk" << std::endl; + os << R"V0G0N([n_clk in MHz] + [Ctb] ADC clock frequency in MHz. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getADCClock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setADCClock(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcenable(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcenable" << std::endl; + os << R"V0G0N([bitmask] + [Ctb] ADC Enable Mask for 1Gb Enable for each 32 ADC channel. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getADCEnableMask(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setADCEnableMask(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcenable10g(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcenable10g" << std::endl; + os << R"V0G0N([bitmask] + [Ctb] ADC Enable Mask for 10Gb mode for each 32 ADC channel. However, if any of a consecutive 4 bits are enabled, the complete 4 bits are enabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTenGigaADCEnableMask(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTenGigaADCEnableMask(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcindex" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get the adc index for the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute adcindex at module level"); + } + auto t = det->getAdcIndex(args[0]); + os << static_cast(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcinvert(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcinvert" << std::endl; + os << R"V0G0N([bitmask] + [Ctb][Jungfrau][Moench] ADC Inversion Mask. + [Jungfrau][Moench] Inversions on top of the default mask. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getADCInvert(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setADCInvert(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adclist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adclist" << std::endl; + os << R"V0G0N([adcname1 adcname2 .. adcname32] + [Ctb][Xilinx_Ctb] Set the list of adc names for this board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute adclist at module level"); + } + auto t = det->getAdcNames(); + os << ToString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (cmd == "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError("This detector already has fixed dac names. " + "Cannot change them."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute adclist at module level"); + } + det->setAdcNames(args); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::adcname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcname" << std::endl; + os << R"V0G0N([0-31][name] + [Ctb][Xilinx_Ctb] Set the adc at the given position to the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute adcname at module level"); + } + auto arg0 = StringTo(args[0]); + auto t = det->getAdcName(arg0); + os << args[0] << ' ' << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute adcname at module level"); + } + auto arg0 = StringTo(args[0]); + det->setAdcName(arg0, args[1]); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcphase(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcphase" << std::endl; + os << R"V0G0N([n_value] [(optional)deg] + [Jungfrau][Moench][Ctb][Gotthard] Phase shift of ADC clock. + [Jungfrau][Moench] Absolute phase shift. If deg used, then shift in degrees. Changing Speed also resets adcphase to recommended defaults. + [Ctb] Absolute phase shift. If deg used, then shift in degrees. Changing adcclk also resets adcphase and sets it to previous values. + [Gotthard] Relative phase shift. Cannot get )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + if (args.size() == 2) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2) { + throw RuntimeError( + "adcphase not implemented for this detector"); + } + auto t = det->getADCPhase(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2) { + throw RuntimeError( + "adcphase not implemented for this detector"); + } + if (args[0] != "deg") { + throw RuntimeError("Unknown adcphase argument " + args[0] + + ". Did you mean deg? "); + } + auto t = det->getADCPhaseInDegrees(std::vector{det_id}); + os << OutString(t) << " deg" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2) { + throw RuntimeError( + "adcphase not implemented for this detector"); + } + auto arg0 = StringTo(args[0]); + det->setADCPhase(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + + if (args.size() == 2) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2) { + throw RuntimeError( + "adcphase not implemented for this detector"); + } + if (args[1] != "deg") { + throw RuntimeError("Unknown adcphase 2nd argument " + args[1] + + ". Did you mean deg?"); + } + auto arg0 = StringTo(args[0]); + det->setADCPhaseInDegrees(arg0, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcpipeline(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcpipeline" << std::endl; + os << R"V0G0N([n_value] + [Ctb][Moench] Pipeline for ADC clock. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getADCPipeline(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setADCPipeline(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcreg(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcreg" << std::endl; + os << R"V0G0N([address] [value] + [Jungfrau][Moench][Ctb][Gotthard] Writes to an adc register in hex. Advanced user Function! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->writeAdcRegister(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::adcvpp(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: adcvpp" << std::endl; + os << R"V0G0N([dac or mV value][(optional unit) mV] + [Ctb] Vpp of ADC. + 0 -> 1V ; 1 -> 1.14V ; 2 -> 1.33V ; 3 -> 1.6V ; 4 -> 2V. + Advanced User function! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + try { + StringTo("0"); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + if (args.size() == 1) { + try { + StringTo("1"); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo("0"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo("1"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto arg0 = StringTo("0"); + auto t = det->getADCVpp(arg0, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + if ((args[0] != "mv") && (args[0] != "mV")) { + throw RuntimeError("Unknown argument " + args[0] + + ". Did you mean mV?"); + } + auto arg0 = StringTo("1"); + auto t = det->getADCVpp(arg0, std::vector{det_id}); + os << OutString(t) << " mV" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo("0"); + det->setADCVpp(arg0, arg1, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + if ((args[1] != "mv") && (args[1] != "mV")) { + throw RuntimeError("Unknown argument " + args[1] + + ". Did you mean mV?"); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo("1"); + det->setADCVpp(arg0, arg1, std::vector{det_id}); + os << args[0] << " mV" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::apulse(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: apulse" << std::endl; + os << R"V0G0N([0, 1] + [Mythen3] Enables or disables analog pulsing. Default is disabled )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getAnalogPulsing(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setAnalogPulsing(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::asamples(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: asamples" << std::endl; + os << R"V0G0N([n_samples] + [Ctb] Number of analog samples expected. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfAnalogSamples(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberOfAnalogSamples(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::autocompdisable(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: autocompdisable" << std::endl; + os << R"V0G0N([0, 1] + [Jungfrau] Auto comparator disable mode. By default, the on-chip gain switching is active during the entire exposure.This mode disables the on - chip gain switching comparator automatically after 93.75% (only for chipv1.0) of exposure time (only for longer than 100us). It is possible to set the duration for chipv1.1 using compdisabletime command. + Default is 0 or this mode disabled(comparator enabled throughout). 1 enables mode. 0 disables mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getAutoComparatorDisable(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setAutoComparatorDisable(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::blockingtrigger(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: blockingtrigger" << std::endl; + os << R"V0G0N( + [Eiger][Jungfrau][Moench] Sends software trigger signal to detector and blocks till the frames are sent out for that trigger. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + bool block = true; + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + bool block = true; + if (det_id != -1) { + throw RuntimeError( + "Cannot execute blockingtrigger at module level"); + } + det->sendSoftwareTrigger(block); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::burstperiod(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: burstperiod" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Gotthard2] Period between 2 bursts. Only in burst mode and auto timing mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getBurstPeriod(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getBurstPeriod(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setBurstPeriod(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setBurstPeriod(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::bursts(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: bursts" << std::endl; + os << R"V0G0N([n_bursts] + [Gotthard2] Number of bursts per aquire. Only in auto timing mode and burst mode. Use timing command to set timing mode and burstmode command to set burst mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfBursts(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute bursts at module level"); + } + auto arg0 = StringTo(args[0]); + det->setNumberOfBursts(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::burstsl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: burstsl" << std::endl; + os << R"V0G0N( + [Gotthard2] Number of bursts left in acquisition. Only in burst auto mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfBurstsLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::bustest(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: bustest" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Bus test, ie. Writes different values in a R/W register and confirms the writes to check bus. + Advanced User function! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->executeBusTest(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::cdsgain(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: cdsgain" << std::endl; + os << R"V0G0N([0, 1] + [Gotthard2] Enable or disable CDS gain. Default is disabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getCDSGain(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setCDSGain(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::chipversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: chipversion" << std::endl; + os << R"V0G0N( + [Jungfrau] Returns chip version. Can be 1.0 or 1.1 )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getChipVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clearbit(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clearbit" << std::endl; + os << R"V0G0N([reg address in hex] [bit index] + Clears bit in address. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (StringTo(args[1]) < 0 || StringTo(args[1]) > 31) { + throw RuntimeError("Bit number out of range: " + args[1]); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->clearBit(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clearbusy(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clearbusy" << std::endl; + os << R"V0G0N( + If acquisition aborted during acquire command, use this to clear acquiring flag in shared memory before starting next acquisition )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute clearbusy at module level"); + } + det->clearAcquiringFlag(); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clearroi(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clearroi" << std::endl; + os << R"V0G0N([Gotthard] Resets Region of interest in detector. All channels enabled. Default is all channels enabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->clearROI(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clientversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clientversion" << std::endl; + os << R"V0G0N( + Client software version )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getClientVersion(); + os << t << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clkdiv(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clkdiv" << std::endl; + os << R"V0G0N([n_clock (0-5)] [n_divider] + [Gotthard2][Mythen3] Clock Divider of clock n_clock. Must be greater than 1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError("clkdiv not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto t = det->getClockDivider(arg0, std::vector{det_id}); + os << args[0] << ' ' << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError("clkdiv not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setClockDivider(arg0, arg1, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clkfreq(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clkfreq" << std::endl; + os << R"V0G0N([n_clock (0-5)] [freq_in_Hz] + [Gotthard2][Mythen3] Frequency of clock n_clock in Hz. Use clkdiv to set frequency. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "clkfreq not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto t = det->getClockFrequency(arg0, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::clkphase(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: clkphase" << std::endl; + os << R"V0G0N([n_clock (0-5)] [phase] [deg (optional)] + [Gotthard2][Mythen3] Phase of clock n_clock. If deg, then phase shift in degrees, else absolute phase shift values. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + if (args.size() == 3) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "clkphase not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto t = det->getClockPhase(arg0, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "clkphase not implemented for this detector."); + } + if (args[1] != "deg") { + throw RuntimeError("Cannot scan argument" + args[1] + + ". Did you mean deg?"); + } + auto arg0 = StringTo(args[0]); + auto t = + det->getClockPhaseinDegrees(arg0, std::vector{det_id}); + os << OutString(t) << " deg" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "clkphase not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setClockPhase(arg0, arg1, std::vector{det_id}); + os << args[1] << '\n'; + } + + if (args.size() == 3) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "clkphase not implemented for this detector."); + } + if (args[2] != "deg") { + throw RuntimeError("Cannot scan argument" + args[2] + + ". Did you mean deg?"); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setClockPhaseinDegrees(arg0, arg1, std::vector{det_id}); + os << args[1] << " " << args[2] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::column(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: column" << std::endl; + os << R"V0G0N([value] + Set Detector column (udp header) to value. + Gui uses it to rearrange for complete image )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getColumn(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setColumn(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::compdisabletime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: compdisabletime" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Jungfrau] Time before end of exposure when comparator is disabled. It is only possible for chipv1.1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getComparatorDisableTime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getComparatorDisableTime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setComparatorDisableTime(converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setComparatorDisableTime(converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::confadc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: confadc" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all] [adc index 0-31, -1 for all] [7 bit configuration value in hex] + [Gotthard2] Sets configuration for specific chip and adc, but configures 1 chip (all adcs for that chip) at a time. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 3) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[2]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto t = + det->getADCConfiguration(arg0, arg1, std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 3) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto arg2 = StringTo(args[2]); + det->setADCConfiguration(arg0, arg1, arg2, + std::vector{det_id}); + os << '[' << args[0] << ", " << args[1] << ", " + << ToStringHex(StringTo(args[2])) << "]" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::config(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: config" << std::endl; + os << R"V0G0N( + Frees shared memory before loading configuration file. Set up once. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute config at module level"); + } + det->loadConfig(args[0]); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dac(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + return GetHelpDacWrapper(cmd, args); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + try { + StringTo("0"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + if (args.size() == 2) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + try { + StringTo("1"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo("0"); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to bool"); + } + } + + if (args.size() == 3) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo("1"); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + if (is_int(args[0]) && + det->getDetectorType().squash() != defs::CHIPTESTBOARD && + det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "Dac indices can only be used for chip test board. Use " + "daclist to get list of dac names for current detector."); + } + auto arg1 = StringTo("0"); + auto t = det->getDAC(dacIndex, arg1, std::vector{det_id}); + os << args[0] << ' ' << OutString(t) << '\n'; + } + + if (args.size() == 2) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + if (is_int(args[0]) && + det->getDetectorType().squash() != defs::CHIPTESTBOARD && + det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "Dac indices can only be used for chip test board. Use " + "daclist to get list of dac names for current detector."); + } + if (args[1] != "mv" && args[1] != "mV") { + throw RuntimeError("Unknown argument " + args[1] + + ". Did you mean mV?"); + } + auto arg1 = StringTo("1"); + auto t = det->getDAC(dacIndex, arg1, std::vector{det_id}); + os << args[0] << ' ' << OutString(t) << " mV" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + if (is_int(args[0]) && + det->getDetectorType().squash() != defs::CHIPTESTBOARD && + det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "Dac indices can only be used for chip test board. Use " + "daclist to get list of dac names for current detector."); + } + auto arg1 = StringTo(args[1]); + auto arg2 = StringTo("0"); + det->setDAC(dacIndex, arg1, arg2, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + + if (args.size() == 3) { + defs::dacIndex dacIndex = + ((det->getDetectorType().squash() == defs::CHIPTESTBOARD || + det->getDetectorType().squash() == + defs::XILINX_CHIPTESTBOARD) && + !is_int(args[0])) + ? det->getDacIndex(args[0]) + : StringTo(args[0]); + if (is_int(args[0]) && + det->getDetectorType().squash() != defs::CHIPTESTBOARD && + det->getDetectorType().squash() != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "Dac indices can only be used for chip test board. Use " + "daclist to get list of dac names for current detector."); + } + auto arg1 = StringTo(args[1]); + auto arg2 = StringTo("1"); + det->setDAC(dacIndex, arg1, arg2, std::vector{det_id}); + os << args[0] << ' ' << args[1] << " mV" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dacindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dacindex" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get the dac index for the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::DAC_0; + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::DAC_0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute dacindex at module level"); + } + auto t = det->getDacIndex(args[0]); + os << ToString(static_cast(t) - index) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::daclist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: daclist" << std::endl; + os << R"V0G0N([dacname1 dacname2 .. dacname18] + [Ctb][Xilinx_Ctb] Set the list of dac names for this detector. + [All] Gets the list of dac names for every dac for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute daclist at module level"); + } + auto t = det->getDacNames(); + os << ToString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (cmd == "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError("This detector already has fixed dac names. " + "Cannot change them."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute daclist at module level"); + } + det->setDacNames(args); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::dacname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dacname" << std::endl; + os << R"V0G0N([0-17][name] + [Ctb][Xilinx_Ctb] Set the dac at the given position to the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::DAC_0; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::dacIndex index = defs::DAC_0; + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::DAC_0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute dacname at module level"); + } + auto t = det->getDacName( + static_cast(StringTo(args[0]) + index)); + os << args[0] << ' ' << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::dacIndex index = defs::DAC_0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute dacname at module level"); + } + det->setDacName( + static_cast(StringTo(args[0]) + index), + args[1]); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::datastream(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: datastream" << std::endl; + os << R"V0G0N([left|right] [0, 1] + [Eiger] Enables or disables data streaming from left or/and right side of detector for 10 GbE mode. 1 (enabled) by default. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::portPosition"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::portPosition"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto t = det->getDataStream(arg0, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setDataStream(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dbitclk(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dbitclk" << std::endl; + os << R"V0G0N([n_clk in MHz] + [Ctb] Clock for latching the digital bits in MHz. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDBITClock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDBITClock(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dbitphase(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dbitphase" << std::endl; + os << R"V0G0N([n_value] [(optional)deg] + [Ctb][Jungfrau] Phase shift of clock to latch digital bits. Absolute phase shift. If deg used, then shift in degrees. + [Ctb]Changing dbitclk also resets dbitphase and sets to previous values. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + if (args.size() == 2) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2 || det_type == defs::MOENCH) { + throw RuntimeError( + "dbitphase not implemented for this detector"); + } + auto t = det->getDBITPhase(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2 || det_type == defs::MOENCH) { + throw RuntimeError( + "dbitphase not implemented for this detector"); + } + if (args[0] != "deg") { + throw RuntimeError("Unknown dbitphase argument " + args[0] + + ". Did you mean deg? "); + } + auto t = det->getDBITPhaseInDegrees(std::vector{det_id}); + os << OutString(t) << " deg" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2 || det_type == defs::MOENCH) { + throw RuntimeError( + "dbitphase not implemented for this detector"); + } + auto arg0 = StringTo(args[0]); + det->setDBITPhase(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + + if (args.size() == 2) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || + det_type == defs::GOTTHARD2 || det_type == defs::MOENCH) { + throw RuntimeError( + "dbitphase not implemented for this detector"); + } + if (args[1] != "deg") { + throw RuntimeError("Unknown dbitphase 2nd argument " + args[1] + + ". Did you mean deg? "); + } + auto arg0 = StringTo(args[0]); + det->setDBITPhaseInDegrees(arg0, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dbitpipeline(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dbitpipeline" << std::endl; + os << R"V0G0N([n_value] + [Ctb][Gotthard2] Pipeline of the clock for latching digital bits. + [Gotthard2] Options: 0-7 + [Ctb] Options: 0-255 )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDBITPipeline(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDBITPipeline(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::defaultdac(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: defaultdac" << std::endl; + os << R"V0G0N([dac name][value][(optional)setting] + Sets the default for that dac to this value. + [Jungfrau][Moench][Mythen3] When settings is provided, it sets the default value only for that setting )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::dacIndex"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::dacIndex"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 1 to defs::detectorSettings"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::dacIndex"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + if (args.size() == 3) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::dacIndex"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[2]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 2 to defs::detectorSettings"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto t = det->getDefaultDac(arg0, std::vector{det_id}); + os << args[0] << ' ' << OutString(t) << '\n'; + } + + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto t = det->getDefaultDac(arg0, arg1, std::vector{det_id}); + os << args[0] << ' ' << args[1] << ' ' << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setDefaultDac(arg0, arg1, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + + if (args.size() == 3) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto arg2 = StringTo(args[2]); + det->setDefaultDac(arg0, arg1, arg2, std::vector{det_id}); + os << args[0] << ' ' << args[2] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::defaultpattern(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: defaultpattern" << std::endl; + os << R"V0G0N( + [Mythen3] Loads and runs default pattern in pattern generator. It is to go back to initial settings. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->loadDefaultPattern(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::delay(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: delay" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb][Moench] Delay after trigger )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDelayAfterTrigger(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getDelayAfterTrigger(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setDelayAfterTrigger(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setDelayAfterTrigger(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::delayl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: delayl" << std::endl; + os << R"V0G0N( + [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Delay Left in Acquisition. + [Gotthard2] only in continuous mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDelayAfterTriggerLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getDelayAfterTriggerLeft(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::detectorserverversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: detectorserverversion" << std::endl; + os << R"V0G0N( + On-board detector server software version )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDetectorServerVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::detsize(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: detsize" << std::endl; + os << R"V0G0N([nx] [ny] + Detector size, ie. Number of channels in x and y dim. This is used to calculate module coordinates included in UDP data. + By default, it adds module in y dimension for 2d detectors and in x dimension for 1d detectors packet header. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDetectorSize(); + os << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + det->setDetectorSize( + defs::xy(StringTo(args[0]), StringTo(args[1]))); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::diodelay(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: diodelay" << std::endl; + os << R"V0G0N([0-775] + [Ctb] Delay for diode. Delay is in ps and max of 775 ps. Resolution is 25 ps. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setDigitalIODelay(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dpulse(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dpulse" << std::endl; + os << R"V0G0N([0, 1] + [Mythen3] Enables or disables digital pulsing. Default is disabled )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDigitalPulsing(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDigitalPulsing(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dr(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dr" << std::endl; + os << R"V0G0N([value] + Dynamic Range or number of bits per pixel in detector. + [Eiger] Options: 4, 8, 12, 16, 32. If set to 32, also sets clkdivider to 2, else to 0. + [Mythen3] Options: 8, 16, 32 + [Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2][Xilinx Ctb] 16 )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDynamicRange(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute dr at module level"); + } + auto arg0 = StringTo(args[0]); + det->setDynamicRange(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::drlist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: drlist" << std::endl; + os << R"V0G0N( + Gets the list of dynamic ranges for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDynamicRangeList(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::dsamples(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: dsamples" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Number of digital samples expected. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfDigitalSamples(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberOfDigitalSamples(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::exptime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: exptime" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Ctb] Exposure time + [Mythen3] Exposure time of all gate signals in auto and trigger mode (internal gating). To specify gate index, use exptime1, exptime2, exptime3. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + auto detector_type = det->getDetectorType().squash(); + if (action == slsDetectorDefs::GET_ACTION) { + if (detector_type == defs::MYTHEN3) { + if (args.size() == 0) { + auto t = det->getExptimeForAllGates(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getExptimeForAllGates(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + + } + + else { + + if (args.size() == 0) { + auto t = det->getExptime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getExptime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setExptime(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setExptime(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::exptime1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: exptime1" << std::endl; + os << R"V0G0N([n_value] + [Mythen3] Exposure time of gate signal 1 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 0; + } + + if (args.size() == 1) { + int gateIndex = 0; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 0; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 0; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 0; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 0; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 0; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 0; + auto converted_time = StringTo(args[0], args[1]); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::exptime2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: exptime2" << std::endl; + os << R"V0G0N([n_value] + [Mythen3] Exposure time of gate signal 2 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 1; + } + + if (args.size() == 1) { + int gateIndex = 1; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 1; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 1; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 1; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 1; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 1; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 1; + auto converted_time = StringTo(args[0], args[1]); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::exptime3(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: exptime3" << std::endl; + os << R"V0G0N([n_value] + [Mythen3] Exposure time of gate signal 3 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 2; + } + + if (args.size() == 1) { + int gateIndex = 2; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 2; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 2; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 2; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 2; + auto t = det->getExptime(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 2; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 2; + auto converted_time = StringTo(args[0], args[1]); + det->setExptime(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::exptimel(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: exptimel" << std::endl; + os << R"V0G0N([(optional unit) ns|us|ms|s] + [Gotthard] Exposure time left for current frame. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getExptimeLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getExptimeLeft(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::extrastoragecells(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: extrastoragecells" << std::endl; + os << R"V0G0N([0-15] + [Jungfrau] Only for chipv1.0. Number of additional storage cells. Default is 0. For advanced users only. + The #images = #frames x #triggers x (#extrastoragecells + 1). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfAdditionalStorageCells( + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError( + "Cannot execute extrastoragecells at module level"); + } + auto arg0 = StringTo(args[0]); + det->setNumberOfAdditionalStorageCells(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::extsampling(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: extsampling" << std::endl; + os << R"V0G0N([0, 1] + [Ctb] Enable for external sampling signal for digital data to signal by extsampling src command. For advanced users only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getExternalSampling(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setExternalSampling(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::extsamplingsrc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: extsamplingsrc" << std::endl; + os << R"V0G0N([0-63] + [Ctb] Sampling source signal for digital data. For advanced users only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getExternalSamplingSource(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setExternalSamplingSource(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::extsig(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: extsig" << std::endl; + os << R"V0G0N([n_signal] [signal_type] + [Gotthard][Mythen3] External signal mode for trigger timing mode. + [Gotthard] [0] [trigger_in_rising_edge|trigger_in_falling_edge] + [Mythen3] [0-7] [trigger_in_rising_edge|trigger_in_falling_edge|inversion_on|inversion_off] + where 0 is master input trigger signal, 1-3 is master input gate signals, 4 is busy out signal and 5-7 is master output gate signals. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 1 to defs::externalSignalFlag"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto t = + det->getExternalSignalFlags(arg0, std::vector{det_id}); + os << args[0] << ' ' << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setExternalSignalFlags(arg0, arg1, std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::fformat(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fformat" << std::endl; + os << R"V0G0N([binary|hdf5] + File format of data file. For HDF5, package must be compiled with HDF5 flags. Default is binary. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::fileFormat"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFileFormat(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFileFormat(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::filtercells(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: filtercells" << std::endl; + os << R"V0G0N([0-12] + [Jungfrau] Set Filter Cell. Only for chipv1.1. Advanced user Command )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfFilterCells(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberOfFilterCells(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::filterresistor(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: filterresistor" << std::endl; + os << R"V0G0N([value] [Gotthard2][Jungfrau] Set filter resistor. Increasing values for increasing resistance. + [Gotthard2] Options: [0|1|2|3]. Default is 0. + [Jungfrau] Options: [0|1]. Default is 1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFilterResistor(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFilterResistor(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::findex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: findex" << std::endl; + os << R"V0G0N([n_value] + File or Acquisition index. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getAcquisitionIndex(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setAcquisitionIndex(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::firmwaretest(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: firmwaretest" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Firmware test, ie. reads a read fixed pattern from a register. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->executeFirmwareTest(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::firmwareversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: firmwareversion" << std::endl; + os << R"V0G0N( + Firmware version of detector in format [0xYYMMDD] or an increasing 2 digit number for Eiger. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + auto detector_type = det->getDetectorType().squash(); + if (action == slsDetectorDefs::GET_ACTION) { + if (detector_type == defs::EIGER) { + if (args.size() == 0) { + auto t = det->getFirmwareVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + } + + else { + + if (args.size() == 0) { + auto t = det->getFirmwareVersion(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + } + + return os.str(); +} + +std::string Caller::fliprows(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fliprows" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] flips rows paramater sent to slsreceiver to stream as json parameter to flip rows in gui + [Jungfrau][Moench] flips rows in the detector itself. For bottom module and number of interfaces must be set to 2. slsReceiver and slsDetectorGui does not handle. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFlipRows(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFlipRows(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::flowcontrol10g(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: flowcontrol10g" << std::endl; + os << R"V0G0N([0, 1] + [Eiger][Jungfrau][Moench] 10GbE Flow Control. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTenGigaFlowControl(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTenGigaFlowControl(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::fmaster(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fmaster" << std::endl; + os << R"V0G0N([0, 1] + Enable or disable receiver master file. Default is 1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute fmaster at module level"); + } + auto t = det->getMasterFileWrite(); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute fmaster at module level"); + } + auto arg0 = StringTo(args[0]); + det->setMasterFileWrite(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::fname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fname" << std::endl; + os << R"V0G0N([name] + File name prefix for output data file. Default is run. File name: [file name prefix]_d[detector index]_f[sub file index]_[acquisition/file index].raw. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFileNamePrefix(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setFileNamePrefix(args[0], std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::foverwrite(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: foverwrite" << std::endl; + os << R"V0G0N([0, 1] + Enable or disable file overwriting. Default is 1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFileOverWrite(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFileOverWrite(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::fpath(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fpath" << std::endl; + os << R"V0G0N([path] + Directory where output data files are written in receiver. Default is '/'. + If path does not exist, it will try to create it. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFilePath(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setFilePath(args[0], std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::framecounter(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: framecounter" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Number of frames from start run control. + [Gotthard2] only in continuous mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfFramesFromStart(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::frames(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: frames" << std::endl; + os << R"V0G0N([n_frames] + Number of frames per acquisition. In trigger mode, number of frames per trigger. + Cannot be set in modular level. + In scan mode, number of frames is set to number of steps. + [Gotthard2] Burst mode has a maximum of 2720 frames. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfFrames(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute frames at module level"); + } + auto arg0 = StringTo(args[0]); + det->setNumberOfFrames(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::framesl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: framesl" << std::endl; + os << R"V0G0N( + [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number of frames left in acquisition. + [Gotthard2] only in continuous auto mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfFramesLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::frametime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: frametime" << std::endl; + os << R"V0G0N([(optional unit) ns|us|ms|s] + [Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Timestamp at a frame start. + [Gotthard2] not in burst and auto mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasurementTime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getMeasurementTime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::fwrite(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: fwrite" << std::endl; + os << R"V0G0N([0, 1] + Enable or disable receiver file write. Default is 1. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFileWrite(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFileWrite(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gainmode(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gainmode" << std::endl; + os << R"V0G0N([dynamicgain|forceswitchg1|forceswitchg2|fixg1|fixg2|fixg0] + [Jungfrau] Gain mode. + CAUTION: Do not use fixg0 without caution, you can damage the detector!!! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::gainMode"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getGainMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setGainMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gappixels(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gappixels" << std::endl; + os << R"V0G0N([0, 1] + [Eiger][Jungfrau][Moench] Include Gap pixels in client data call back in Detecor api. Will not be in detector streaming, receiver file or streaming. Default is 0. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute gappixels at module level"); + } + auto t = det->getGapPixelsinCallback(); + os << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute gappixels at module level"); + } + auto arg0 = StringTo(args[0]); + det->setGapPixelsinCallback(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gatedelay(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gatedelay" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Mythen3] Gate Delay of all gate signals in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = -1; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = -1; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getGateDelayForAllGates(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getGateDelayForAllGates(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = -1; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = -1; + auto converted_time = StringTo(args[0], args[1]); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gatedelay1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gatedelay1" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Mythen3] Gate Delay of gate signal 1 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 0; + } + + if (args.size() == 1) { + int gateIndex = 0; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 0; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 0; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 0; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 0; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 0; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 0; + auto converted_time = StringTo(args[0], args[1]); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gatedelay2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gatedelay2" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Mythen3] Gate Delay of gate signal 2 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 1; + } + + if (args.size() == 1) { + int gateIndex = 1; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 1; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 1; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 1; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 1; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 1; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 1; + auto converted_time = StringTo(args[0], args[1]); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gatedelay3(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gatedelay3" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Mythen3] Gate Delay of gate signal 3 in auto and trigger mode (internal gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + int gateIndex = 2; + } + + if (args.size() == 1) { + int gateIndex = 2; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + int gateIndex = 2; + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + int gateIndex = 2; + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + int gateIndex = 2; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + int gateIndex = 2; + auto t = det->getGateDelay(gateIndex, std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + int gateIndex = 2; + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + int gateIndex = 2; + auto converted_time = StringTo(args[0], args[1]); + det->setGateDelay(gateIndex, converted_time, + std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::gates(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: gates" << std::endl; + os << R"V0G0N([n_gates] + [Mythen3] Number of external gates in gating or trigger_gating mode (external gating). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfGates(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberOfGates(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::getbit(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: getbit" << std::endl; + os << R"V0G0N([reg address in hex] [bit index] + Gets bit in address. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 2) { + if (StringTo(args[1]) < 0 || StringTo(args[1]) > 31) { + throw RuntimeError("Bit number out of range: " + args[1]); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto t = det->getBit(arg0, arg1, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::hardwareversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: hardwareversion" << std::endl; + os << R"V0G0N( + Hardware version of detector. + [Eiger] Hardware version of front FPGA on detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getHardwareVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::highvoltage(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: highvoltage" << std::endl; + os << R"V0G0N([n_value] + High voltage to the sensor in Voltage. + [Gotthard] [0|90|110|120|150|180|200] + [Eiger][Mythen3][Gotthard2] 0-200 + [Jungfrau][Moench][Ctb] [0|60-200] )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getHighVoltage(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setHighVoltage(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::im_a(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: im_a" << std::endl; + os << R"V0G0N( + [Ctb] Measured current of power supply a in mA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredCurrent(defs::I_POWER_A, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::im_b(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: im_b" << std::endl; + os << R"V0G0N( + [Ctb] Measured current of power supply b in mA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredCurrent(defs::I_POWER_B, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::im_c(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: im_c" << std::endl; + os << R"V0G0N( + [Ctb] Measured current of power supply c in mA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredCurrent(defs::I_POWER_C, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::im_d(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: im_d" << std::endl; + os << R"V0G0N( + [Ctb] Measured current of power supply d in mA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredCurrent(defs::I_POWER_D, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::im_io(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: im_io" << std::endl; + os << R"V0G0N( + [Ctb] Measured current of power supply io in mA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredCurrent(defs::I_POWER_IO, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::imagetest(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: imagetest" << std::endl; + os << R"V0G0N([0, 1] + [Gotthard] 1 adds channel intensity with precalculated values when taking an acquisition. Default is 0. + [Eiger][Jungfrau][Moench] Only for Virtual servers. If 0, each pixel intensity incremented by 1. If 1, all pixels almost saturated. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getImageTestMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setImageTestMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::initialchecks(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: initialchecks" << std::endl; + os << R"V0G0N([0, 1] + [Mythen3][Gotthard2] Enable or disable intial compatibility and other checks at detector start up. It is enabled by default. Must come before 'hostname' command to take effect. Can be used to reprogram fpga when current firmware is incompatible. + Advanced User function! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError( + "Cannot execute initialchecks at module level"); + } + auto t = det->getInitialChecks(); + os << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError( + "Cannot execute initialchecks at module level"); + } + auto arg0 = StringTo(args[0]); + det->setInitialChecks(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::inj_ch(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: inj_ch" << std::endl; + os << R"V0G0N([offset] [increment] + [Gotthard2] Inject channels with current source for calibration. Offset is starting channel that is injected, increment determines succeeding channels to be injected. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getInjectChannel(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setInjectChannel(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::interpolation(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: interpolation" << std::endl; + os << R"V0G0N([0, 1] + [Mythen3] Enables or disables interpolation. Default is disabled. Interpolation mode enables all counters and disables vth3. Disabling sets back counter mask and vth3. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getInterpolation(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setInterpolation(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::interruptsubframe(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: interruptsubframe" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] 1 interrupts last subframe at required exposure time. 0 will wait for last sub frame to finish exposing. 0 is default. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getInterruptSubframe(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setInterruptSubframe(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::kernelversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: kernelversion" << std::endl; + os << R"V0G0N( + Get kernel version on the detector including time and date. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getKernelVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::lastclient(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: lastclient" << std::endl; + os << R"V0G0N( + Client IP Address that last communicated with the detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getLastClientIP(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::led(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: led" << std::endl; + os << R"V0G0N([0, 1] + [Ctb] Switches on/off all LEDs. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getLEDEnable(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setLEDEnable(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::lock(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: lock" << std::endl; + os << R"V0G0N([0, 1] + Lock detector to one IP, 1: locks. Default is unlocked )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDetectorLock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDetectorLock(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::master(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: master" << std::endl; + os << R"V0G0N([0, 1] + [Eiger][Gotthard2][Jungfrau][Moench] Sets (half) module to master and other(s) to slaves. + [Gotthard][Gotthard2][Mythen3][Eiger][Jungfrau][Moench] Gets if the current (half) module is master. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMaster(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setMaster(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::maxadcphaseshift(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: maxadcphaseshift" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Ctb] Absolute maximum Phase shift of ADC clock. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMaxADCPhaseShift(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::maxclkphaseshift(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: maxclkphaseshift" << std::endl; + os << R"V0G0N([n_clock (0-5)] + [Gotthard2][Mythen3] Absolute Maximum Phase shift of clock n_clock. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::detectorType type = + det->getDetectorType().squash(defs::GENERIC); + ; + if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { + throw RuntimeError( + "maxclkphaseshift not implemented for this detector."); + } + auto arg0 = StringTo(args[0]); + auto t = det->getMaxClockPhaseShift(arg0, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::maxdbitphaseshift(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: maxdbitphaseshift" << std::endl; + os << R"V0G0N( + [Ctb][Jungfrau] Absolute maximum Phase shift of of the clock to latch digital bits. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMaxDBITPhaseShift(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::measuredperiod(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: measuredperiod" << std::endl; + os << R"V0G0N([(optional unit) ns|us|ms|s] + [Eiger] Measured frame period between last frame and previous one. Can be measured with minimum 2 frames in an acquisition. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPeriod(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getMeasuredPeriod(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::measuredsubperiod(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: measuredsubperiod" << std::endl; + os << R"V0G0N([(optional unit) ns|us|ms|s] + [Eiger] Measured sub frame period between last sub frame and previous one. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredSubFramePeriod(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getMeasuredSubFramePeriod(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::moduleid(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: moduleid" << std::endl; + os << R"V0G0N( + [Gotthard2][Eiger][Mythen3][Jungfrau][Moench] 16 bit value (ideally unique) that is streamed out in the UDP header of the detector. Picked up from a file on the module. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getModuleId(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::nextframenumber(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: nextframenumber" << std::endl; + os << R"V0G0N([n_value] + [Eiger][Jungfrau][Moench][Ctb] Next frame number. Stopping acquisition might result in different frame numbers for different modules. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNextFrameNumber(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNextFrameNumber(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::nmod(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: nmod" << std::endl; + os << R"V0G0N( + Number of modules in shared memory. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->size(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::numinterfaces(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: numinterfaces" << std::endl; + os << R"V0G0N([1, 2] + [Jungfrau][Moench] Number of udp interfaces to stream data from detector. Default: 1. + Also enables second interface in receiver for listening (Writes a file per interface if writing enabled). + Also restarts client and receiver zmq sockets if zmq streaming enabled. + [Eiger] Only gets with result 2. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberofUDPInterfaces(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberofUDPInterfaces(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::overflow(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: overflow" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] Enable or disable show overflow flag in 32 bit mode. Default is disabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getOverFlowMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setOverFlowMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::packageversion(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: packageversion" << std::endl; + os << R"V0G0N( + Package version. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPackageVersion(); + os << t << '\n'; + } + } + + return os.str(); +} + +std::string Caller::parallel(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: parallel" << std::endl; + os << R"V0G0N([0, 1] + [Eiger][Mythen3][Gotthard2][Moench] Enable or disable parallel mode. + [Mythen3] If exptime is too short, the acquisition will return ERROR status and take fewer frames than expected. + [Mythen3][Eiger][Moench] Default: Non parallel. + [Gotthard2] Default: Parallel. Non parallel mode works only in continuous mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getParallelMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setParallelMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::parameters(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: parameters" << std::endl; + os << R"V0G0N( + Sets detector measurement parameters to those contained in fname. Set up per measurement. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute parameters at module level"); + } + det->loadParameters(args[0]); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::partialreset(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: partialreset" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] Sets up detector to do partial or complete reset at start of acquisition. 0 complete reset, 1 partial reset. Default is complete reset. Advanced function! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPartialReset(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPartialReset(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patfname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patfname" << std::endl; + os << R"V0G0N( + [Ctb][Mythen3][Xilinx Ctb] Gets the pattern file name including path of the last pattern uploaded. Returns an empty if nothing was uploaded or via a server default file )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPatterFileName(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patioctrl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patioctrl" << std::endl; + os << R"V0G0N([64 bit mask] + [Ctb] 64 bit mask defining input (0) and output (1) signals. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPatternIOControl(std::vector{det_id}); + os << OutStringHex(t, 16) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPatternIOControl(arg0, std::vector{det_id}); + os << ToStringHex(arg0, 16) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patlimits(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patlimits" << std::endl; + os << R"V0G0N([start addr] [stop addr] + [Ctb][Mythen3][Xilinx Ctb] Limits of complete pattern )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + auto arg0 = StringTo("-1"); + auto t = det->getPatternLoopAddresses(arg0, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto arg0 = StringTo("-1"); + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setPatternLoopAddresses(arg0, arg1, arg2, + std::vector{det_id}); + os << '[' << ToStringHex(arg1, 4) << ", " << ToStringHex(arg2, 4) << ']' + << '\n'; + } + + return os.str(); +} + +std::string Caller::patloop(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patloop" << std::endl; + os << R"V0G0N([0-6] [start addr] [stop addr] + [Ctb][Mythen3][Xilinx Ctb] Limits of the loop level provided. + [Mythen3] Level options: 0-3 only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopAddresses(level, std::vector{det_id}); + os << level << ' ' << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + int start = StringTo(args[iArg++]); + int stop = StringTo(args[iArg++]); + det->setPatternLoopAddresses(level, start, stop, + std::vector{det_id}); + os << level << ' ' << '[' << ToStringHex(start, 4) << ", " + << ToStringHex(stop, 4) << ']' << '\n'; + } + + return os.str(); +} + +std::string Caller::patloop0(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patloop0" << std::endl; + os << R"V0G0N(Depreciated command. Use patloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopAddresses(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + int start = StringTo(args[iArg++]); + int stop = StringTo(args[iArg++]); + det->setPatternLoopAddresses(level, start, stop, + std::vector{det_id}); + os << '[' << ToStringHex(start, 4) << ", " << ToStringHex(stop, 4) + << ']' << '\n'; + } + + return os.str(); +} + +std::string Caller::patloop1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patloop1" << std::endl; + os << R"V0G0N(Depreciated command. Use patloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopAddresses(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + int start = StringTo(args[iArg++]); + int stop = StringTo(args[iArg++]); + det->setPatternLoopAddresses(level, start, stop, + std::vector{det_id}); + os << '[' << ToStringHex(start, 4) << ", " << ToStringHex(stop, 4) + << ']' << '\n'; + } + + return os.str(); +} + +std::string Caller::patloop2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patloop2" << std::endl; + os << R"V0G0N(Depreciated command. Use patloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopAddresses(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; + GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, + nPutArgs); + int start = StringTo(args[iArg++]); + int stop = StringTo(args[iArg++]); + det->setPatternLoopAddresses(level, start, stop, + std::vector{det_id}); + os << '[' << ToStringHex(start, 4) << ", " << ToStringHex(stop, 4) + << ']' << '\n'; + } + + return os.str(); +} + +std::string Caller::patmask(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patmask" << std::endl; + os << R"V0G0N([64 bit mask] + [Ctb][Mythen3][Xilinx Ctb] Selects the bits that will have a pattern mask applied to the selected patmask for every pattern. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPatternMask(std::vector{det_id}); + os << OutStringHex(t, 16) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPatternMask(arg0, std::vector{det_id}); + os << ToStringHex(arg0, 16) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patnloop(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patnloop" << std::endl; + os << R"V0G0N([0-6] [n_cycles] + [Ctb][Mythen3][Xilinx Ctb] Number of cycles of the loop level provided. + [Mythen3] Level options: 0-3 only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopCycles(level, std::vector{det_id}); + os << level << ' ' << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + std::string nloops = args[iArg++]; + auto arg1 = StringTo(nloops); + det->setPatternLoopCycles(level, arg1, std::vector{det_id}); + os << level << ' ' << nloops << '\n'; + } + + return os.str(); +} + +std::string Caller::patnloop0(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patnloop0" << std::endl; + os << R"V0G0N(Depreciated command. Use patnloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopCycles(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + std::string nloops = args[iArg++]; + auto arg1 = StringTo(nloops); + det->setPatternLoopCycles(level, arg1, std::vector{det_id}); + os << nloops << '\n'; + } + + return os.str(); +} + +std::string Caller::patnloop1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patnloop1" << std::endl; + os << R"V0G0N(Depreciated command. Use patnloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopCycles(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + std::string nloops = args[iArg++]; + auto arg1 = StringTo(nloops); + det->setPatternLoopCycles(level, arg1, std::vector{det_id}); + os << nloops << '\n'; + } + + return os.str(); +} + +std::string Caller::patnloop2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patnloop2" << std::endl; + os << R"V0G0N(Depreciated command. Use patnloop. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternLoopCycles(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, + nPutArgs); + std::string nloops = args[iArg++]; + auto arg1 = StringTo(nloops); + det->setPatternLoopCycles(level, arg1, std::vector{det_id}); + os << nloops << '\n'; + } + + return os.str(); +} + +std::string Caller::patsetbit(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patsetbit" << std::endl; + os << R"V0G0N([64 bit mask] + [Ctb][Mythen3][Xilinx Ctb] Sets the mask applied to every pattern to the selected bits. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPatternBitMask(std::vector{det_id}); + os << OutStringHex(t, 16) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPatternBitMask(arg0, std::vector{det_id}); + os << ToStringHex(arg0, 16) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pattern(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patternX" << std::endl; + os << R"V0G0N([fname] + [Mythen3][Ctb][Xilinx Ctb] Loads ASCII pattern file directly to server (instead of executing line by line) )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setPattern(args[0], std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patternstart(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patternstart" << std::endl; + os << R"V0G0N( + [Mythen3] Starts Pattern )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->startPattern(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::patwait(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwait" << std::endl; + os << R"V0G0N([0-6] [addr] + [Ctb][Mythen3][Xilinx Ctb] Wait address for loop level provided. + [Mythen3] Level options: 0-3 only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitAddr(level, std::vector{det_id}); + os << level << ' ' << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + int addr = StringTo(args[iArg++]); + det->setPatternWaitAddr(level, addr, std::vector{det_id}); + os << level << ' ' << ToStringHex(addr, 4) << '\n'; + } + + return os.str(); +} + +std::string Caller::patwait0(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwait0" << std::endl; + os << R"V0G0N(Depreciated command. Use patwait. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitAddr(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + int addr = StringTo(args[iArg++]); + det->setPatternWaitAddr(level, addr, std::vector{det_id}); + os << ToStringHex(addr, 4) << '\n'; + } + + return os.str(); +} + +std::string Caller::patwait1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwait1" << std::endl; + os << R"V0G0N(Depreciated command. Use patwait. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitAddr(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + int addr = StringTo(args[iArg++]); + det->setPatternWaitAddr(level, addr, std::vector{det_id}); + os << ToStringHex(addr, 4) << '\n'; + } + + return os.str(); +} + +std::string Caller::patwait2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwait2" << std::endl; + os << R"V0G0N(Depreciated command. Use patwait. )V0G0N" << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitAddr(level, std::vector{det_id}); + os << OutStringHex(t, 4) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, + nPutArgs); + int addr = StringTo(args[iArg++]); + det->setPatternWaitAddr(level, addr, std::vector{det_id}); + os << ToStringHex(addr, 4) << '\n'; + } + + return os.str(); +} + +std::string Caller::patwaittime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwaittime" << std::endl; + os << R"V0G0N([0-6] [n_clk] + [Ctb][Mythen3][Xilinx Ctb] Wait time in clock cycles for the loop provided. + [Mythen3] Level options: 0-3 only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitTime(level, std::vector{det_id}); + os << level << ' ' << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + uint64_t waittime = StringTo(args[iArg++]); + det->setPatternWaitTime(level, waittime, std::vector{det_id}); + os << level << ' ' << waittime << '\n'; + } + + return os.str(); +} + +std::string Caller::patwaittime0(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwaittime0" << std::endl; + os << R"V0G0N(Depreciated command. Use patwaittime. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitTime(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + uint64_t waittime = StringTo(args[iArg++]); + det->setPatternWaitTime(level, waittime, std::vector{det_id}); + os << waittime << '\n'; + } + + return os.str(); +} + +std::string Caller::patwaittime1(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwaittime1" << std::endl; + os << R"V0G0N(Depreciated command. Use patwaittime. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitTime(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + uint64_t waittime = StringTo(args[iArg++]); + det->setPatternWaitTime(level, waittime, std::vector{det_id}); + os << waittime << '\n'; + } + + return os.str(); +} + +std::string Caller::patwaittime2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patwaittime2" << std::endl; + os << R"V0G0N(Depreciated command. Use patwaittime. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + auto t = det->getPatternWaitTime(level, std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (action == slsDetectorDefs::PUT_ACTION) { + int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; + GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, + nPutArgs); + uint64_t waittime = StringTo(args[iArg++]); + det->setPatternWaitTime(level, waittime, std::vector{det_id}); + os << waittime << '\n'; + } + + return os.str(); +} + +std::string Caller::patword(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: patword" << std::endl; + os << R"V0G0N([step or address] [64 bit mask] + [Ctb][Mythen3][Xilinx Ctb] 64 bit pattern at address of pattern memory. + [Ctb] read is same as executing pattern )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to uint64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto t = det->getPatternWord(arg0, std::vector{det_id}); + os << '[' << ToStringHex(arg0, 4) << ", " << OutStringHex(t, 16) + << "]" << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setPatternWord(arg0, arg1, std::vector{det_id}); + os << '[' << ToStringHex(arg0, 4) << ", " << ToStringHex(arg1, 16) + << "]" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pedestalmode(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: pedestalmode" << std::endl; + os << R"V0G0N( [frames] [loops] + [Jungfrau] Enable pedestal mode. + The number of frames or triggers is overwritten by: + (#pedestal_frames x #pedestal_loops x 2). + In auto timing mode or in trigger mode with #frames > 1, + #frames is overwritten and #triggers = 1, + else #triggers is overwritten and #frames = 1. + One cannot set #frames, #triggers or timing mode in pedestal mode (exception thrown). + +pedestalmode [0] + [Jungfrau] Disable pedestal mode. + Disabling pedestal mode will set back the normal mode values of #frames and #triggers. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + if (args.size() == 2) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPedestalMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (args[0] != "0") { + throw RuntimeError( + "Unknown argument " + args[0] + + ". Did you mean 0 to disable pedestal mode?"); + } + det->setPedestalMode(defs::pedestalParameters()); + os << ToString(args) << '\n'; + } + + if (args.size() == 2) { + det->setPedestalMode(defs::pedestalParameters( + StringTo(args[0]), StringTo(args[1]))); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::period(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: period" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + Period between frames )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPeriod(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getPeriod(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setPeriod(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setPeriod(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::periodl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: periodl" << std::endl; + os << R"V0G0N( + [Gotthard][Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Period left for current frame. + [Gotthard2] only in continuous mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPeriodLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getPeriodLeft(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::polarity(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: polarity" << std::endl; + os << R"V0G0N([pos|neg] + [Mythen3] Sets negative or positive polarity. Default is positive )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::polarity"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPolarity(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPolarity(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::port(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: port" << std::endl; + os << R"V0G0N([n] + Port number of the control server on detector for detector-client tcp interface. Default is 1952. Normally unchanged. Set different ports for virtual servers on same pc. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getControlPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setControlPort(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::powerchip(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: powerchip" << std::endl; + os << R"V0G0N([0, 1] + [Jungfrau][Moench][Mythen3][Gotthard2] Power the chip. + [Jungfrau][Moench] Default is 0. Get will return power status. Can be off if temperature event occured (temperature over temp_threshold with temp_control enabled. Will configure chip (only chip v1.1) + [Mythen3][Gotthard2] Default is 1. If module not connected or wrong module, powerchip will fail. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPowerChip(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPowerChip(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::powerindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: powerindex" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get the power index for the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::V_POWER_A; + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::V_POWER_A; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute powerindex at module level"); + } + auto t = det->getPowerIndex(args[0]); + os << ToString(static_cast(t) - index) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::powerlist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: powerlist" << std::endl; + os << R"V0G0N([powername1 powername2 .. powername4] + [Ctb][Xilinx_Ctb] Set the list of power names for this board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute powerlist at module level"); + } + auto t = det->getPowerNames(); + os << ToString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (cmd == "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError("This detector already has fixed dac names. " + "Cannot change them."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute powerlist at module level"); + } + det->setPowerNames(args); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::powername(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: powername" << std::endl; + os << R"V0G0N([0-4][name] + [Ctb][Xilinx_Ctb] Set the power at the given position to the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::V_POWER_A; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::dacIndex index = defs::V_POWER_A; + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::V_POWER_A; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute powername at module level"); + } + auto t = det->getPowerName( + static_cast(StringTo(args[0]) + index)); + os << args[0] << ' ' << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::dacIndex index = defs::V_POWER_A; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute powername at module level"); + } + det->setPowerName( + static_cast(StringTo(args[0]) + index), + args[1]); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::powervalues(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: powervalues" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get values of all powers. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + + std::string suffix = " mV"; + auto t = det->getPowerList(); + + auto names = det->getPowerNames(); + auto name_it = names.begin(); + os << '['; + if (t.size() > 0) { + + auto it = t.cbegin(); + os << ToString(*name_it++) << ' '; + os << OutString(det->getPower(*it++, std::vector{det_id})) + << suffix; + while (it != t.cend()) { + os << ", " << ToString(*name_it++) << ' '; + os << OutString( + det->getPower(*it++, std::vector{det_id})) + << suffix; + } + } + + os << "]\n"; + } + } + + return os.str(); +} + +std::string Caller::programfpga(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: programfpga" << std::endl; + os << R"V0G0N([fname.pof | fname.rbf (full path)][(opitonal)--force-delete-normal-file] + [Jungfrau][Moench][Ctb] Programs FPGA from pof file (full path). Then, detector controller is rebooted. + Use --force-delete-normal-file argument, if normal file found in device tree, it must be deleted, a new device drive created and programming continued. + [Mythen3][Gotthard2] Programs FPGA from rbf file (full path). Then, detector controller is rebooted. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo("0"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + if (args.size() == 2) { + try { + StringTo("1"); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to bool"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo("0"); + det->programFPGA(args[0], arg1, std::vector{det_id}); + os << "successful" << '\n'; + } + + if (args.size() == 2) { + if (args[1] != "--force-delete-normal-file") { + throw RuntimeError("Could not scan second argument. Did you " + "mean --force-delete-normal-file?"); + } + auto arg1 = StringTo("1"); + det->programFPGA(args[0], arg1, std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pulse(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: pulse" << std::endl; + os << R"V0G0N([n_times] [x] [y] + [Eiger] Pulse pixel n number of times at coordinates (x, y). Advanced User! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 3) { + defs::xy c = + defs::xy(StringTo(args[1]), StringTo(args[2])); + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 3) { + defs::xy c = + defs::xy(StringTo(args[1]), StringTo(args[2])); + auto arg0 = StringTo(args[0]); + det->pulsePixel(arg0, c, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pulsechip(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: pulsechip" << std::endl; + os << R"V0G0N([n_times] + [Eiger] Pulse chip n times. If n is -1, resets to normal mode (reset chip completely at start of acquisition, where partialreset = 0). Advanced User! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->pulseChip(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pulsenmove(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: pulsenmove" << std::endl; + os << R"V0G0N([n_times] [x] [y] + [Eiger] Pulse pixel n number of times and moves relatively by (x, y). Advanced User! )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 3) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 3) { + defs::xy c = + defs::xy(StringTo(args[1]), StringTo(args[2])); + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 3) { + defs::xy c = + defs::xy(StringTo(args[1]), StringTo(args[2])); + auto arg0 = StringTo(args[0]); + det->pulsePixelNMove(arg0, c, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::pumpprobe(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: pumpprobe" << std::endl; + os << R"V0G0N([0, 1] + [Mythen3] Enables or disables pump probe mode. Default is disabled. Pump probe mode only enables vth2. Disabling sets back to previous value. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPumpProbe(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPumpProbe(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::quad(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: quad" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] Sets detector size to a quad. 0 (disabled) is default. (Specific hardware required). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getQuad(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute quad at module level"); + } + auto arg0 = StringTo(args[0]); + det->setQuad(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::readnrows(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: readnrows" << std::endl; + os << R"V0G0N( + [1-256] + [Eiger] Number of rows to readout per half module starting from the centre. Options: 0 - 256. 256 is default. The permissible values depend on dynamic range and 10Gbe enabled. + [8-512 (multiple of 8)] + [Jungfrau] Number of rows per module starting from the centre. Options: 8 - 512, must be multiples of 8. Default is 512. + [Moench] Number of rows per module starting from the centre. Options:16 - 400, must be multiples of 16. Default is 400. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getReadNRows(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setReadNRows(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::readout(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: readout" << std::endl; + os << R"V0G0N( + [Mythen3] Starts detector readout. Status changes to TRANSMITTING and automatically returns to idle at the end of readout. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute readout at module level"); + } + det->startDetectorReadout(); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::readoutspeed(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: readoutspeed" << std::endl; + os << R"V0G0N( + [0 or full_speed|1 or half_speed|2 or quarter_speed] + [Eiger][Jungfrau][Moench] Readout speed of chip. + [Eiger][Moench] Default speed is full_speed. + [Jungfrau] Default speed is half_speed. full_speed option only available from v2.0 boards and is recommended to set number of interfaces to 2. Also overwrites adcphase to recommended default. + [144|108] + [Gotthard2] Readout speed of chip in MHz. Default is 108. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::speedLevel"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "ReadoutSpeed not implemented. Did you mean runclk?"); + } + auto t = det->getReadoutSpeed(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError( + "ReadoutSpeed not implemented. Did you mean runclk?"); + } + auto arg0 = StringTo(args[0]); + det->setReadoutSpeed(arg0, std::vector{det_id}); + os << ToString(StringTo(args[0])) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::readoutspeedlist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: readoutspeedlist" << std::endl; + os << R"V0G0N( + List of readout speed levels implemented for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getReadoutSpeedList(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rebootcontroller(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rebootcontroller" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Ctb][Gotthard][Mythen3][Gotthard2] Reboot controller of detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->rebootController(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::reg(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: reg" << std::endl; + os << R"V0G0N([address] [32 bit value] + [Mythen3][Gotthard2] Reads/writes to a 32 bit register in hex. Advanced Function! + Goes to stop server. Hence, can be called while calling blocking acquire(). + [Eiger] +0x100 for only left, +0x200 for only right. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + auto t = det->readRegister(arg0, std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->writeRegister(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::resetdacs(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: resetdacs" << std::endl; + os << R"V0G0N([(optional) hard] + [Eiger][Jungfrau][Moench][Gotthard][Gotthard2][Mythen3]Reset dac values to the defaults. A 'hard' optional reset will reset the dacs to the hardcoded defaults in on-board detector server. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (args[0] != "hard") { + throw RuntimeError("Unknown argument " + args[0] + + ". Did you mean hard?"); + } + det->resetToDefaultDacs("1", std::vector{det_id}); + os << "successful" << '\n'; + } + + if (args.size() == 0) { + det->resetToDefaultDacs("0", std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::resetfpga(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: resetfpga" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Ctb] Reset FPGA. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->resetFPGA(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::roi(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: roi" << std::endl; + os << R"V0G0N([xmin] [xmax] + [Gotthard] Region of interest in detector. + Options: Only a single ROI per module. + Either all channels or a single adc or 2 chips (256 channels). Default is all channels enabled (-1 -1). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::ROI t = + defs::ROI(StringTo(args[0]), StringTo(args[1])); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getROI(std::vector{det_id}); + os << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::ROI t = + defs::ROI(StringTo(args[0]), StringTo(args[1])); + if (det_id == -1 && det->size() > 1) { + throw RuntimeError("Cannot execute ROI at multi module level"); + } + det->setROI(t, det_id); + os << t << '\n'; + } + } + + return os.str(); +} + +std::string Caller::romode(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: romode" << std::endl; + os << R"V0G0N([analog|digital|analog_digital|transceiver|digital_transceiver] + [Ctb] Readout mode. Default is analog. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::readoutMode"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getReadoutMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setReadoutMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::row(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: row" << std::endl; + os << R"V0G0N([value] + Set Detector row (udp header) to value. + Gui uses it to rearrange for complete image )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRow(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRow(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::runclk(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: runclk" << std::endl; + os << R"V0G0N([n_clk in MHz] + [Ctb] Run clock in MHz. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRUNClock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRUNClock(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::runtime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: runtime" << std::endl; + os << R"V0G0N([(optional unit) ns|us|ms|s] + [Jungfrau][Moench][Mythen3][Gotthard2][Ctb] Time from detector start up. + [Gotthard2] not in burst and auto mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getActualTime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getActualTime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_arping(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_arping" << std::endl; + os << R"V0G0N([0, 1] + Starts a thread in slsReceiver to arping the interface it is listening to every minute. Useful in 10G mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxArping(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxArping(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_clearroi(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_clearroi" << std::endl; + os << R"V0G0N(Resets Region of interest in receiver. Default is all channels/pixels enabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError( + "Cannot execute rx_clearroi at module level"); + } + det->clearRxROI(); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_dbitoffset(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_dbitoffset" << std::endl; + os << R"V0G0N([n_bytes] + [Ctb] Offset in bytes in digital data to skip in receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxDbitOffset(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxDbitOffset(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_discardpolicy(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_discardpolicy" << std::endl; + os << R"V0G0N([nodiscard (default)|discardempty|discardpartial(fastest)] + Frame discard policy of receiver. nodiscard does not discard frames, discardempty discards empty frames, discardpartial discards partial frames. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::frameDiscardPolicy"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxFrameDiscardPolicy(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxFrameDiscardPolicy(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_fifodepth(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_fifodepth" << std::endl; + os << R"V0G0N([n_frames] + Set the number of frames in the receiver fifo depth (buffer between listener and writer threads). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxFifoDepth(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxFifoDepth(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_frameindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_frameindex" << std::endl; + os << R"V0G0N( + Current frame index received for each port in receiver during acquisition. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxCurrentFrameIndex(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_framescaught(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_framescaught" << std::endl; + os << R"V0G0N( + Number of frames caught by each port in receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFramesCaught(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_framesperfile(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_framesperfile" << std::endl; + os << R"V0G0N([n_frames] + Number of frames per file in receiver in an acquisition. Default depends on detector type. 0 is infinite or all frames in single file. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFramesPerFile(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFramesPerFile(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_jsonpara(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_jsonpara" << std::endl; + os << R"V0G0N([key1] [value1] + [Receiver] Additional json header parameter streamed out from receiver. If not found in header, the pair is appended. An empty values deletes parameter. Max 20 characters for each key/value. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + if (args.size() == 2) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto t = det->getAdditionalJsonParameter(args[0], + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setAdditionalJsonParameter(args[0], "", + std::vector{det_id}); + os << args[0] << " deleted" << '\n'; + } + + if (args.size() == 2) { + det->setAdditionalJsonParameter(args[0], args[1], + std::vector{det_id}); + os << "{" << args[0] << ": " << args[1] << "}" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_lastclient(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_lastclient" << std::endl; + os << R"V0G0N( + Client IP Address that last communicated with the receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxLastClientIP(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_lock(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_lock" << std::endl; + os << R"V0G0N([0, 1] + Lock receiver to one client IP, 1 locks, 0 unlocks. Default is unlocked. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxLock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxLock(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_missingpackets(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_missingpackets" << std::endl; + os << R"V0G0N( + Number of missing packets for receiver. If negative, they are packets in excess. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumMissingPackets(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_padding(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_padding" << std::endl; + os << R"V0G0N([0, 1] + Partial frames padding enable in the receiver. Default: enabled. Disabling is fastest. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPartialFramesPadding(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setPartialFramesPadding(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_printconfig(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_printconfig" << std::endl; + os << R"V0G0N( + Prints the receiver configuration. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->printRxConfiguration(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_realudpsocksize(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_realudpsocksize" << std::endl; + os << R"V0G0N( + Actual udp socket buffer size. Double the size of rx_udpsocksize due to kernel bookkeeping. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = + det->getRxRealUDPSocketBufferSize(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_silent(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_silent" << std::endl; + os << R"V0G0N([0, 1] + Switch on or off receiver text output during acquisition. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxSilentMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxSilentMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_start(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_start" << std::endl; + os << R"V0G0N( + Starts receiver listener for detector data packets and create a data file (if file write enabled). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute rx_start at module level"); + } + det->startReceiver(); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_status(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_status" << std::endl; + os << R"V0G0N([running, idle, transmitting] + Receiver listener status. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getReceiverStatus(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (true) { + throw RuntimeError("Cannot put. Did you mean to use command: " + "\"rx_start\" or \"rx_stop\"?"); + } + } + + return os.str(); +} + +std::string Caller::rx_stop(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_stop" << std::endl; + os << R"V0G0N( + Stops receiver listener for detector data packets and closes current data file (if file write enabled). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute rx_stop at module level"); + } + det->stopReceiver(); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_tcpport(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_tcpport" << std::endl; + os << R"V0G0N([port] + TCP port for client-receiver communication. Default is 1954. Must be different if multiple receivers on same pc. Must be first command to set a receiver parameter. Multi command will automatically increment for individual modules. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxPort(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_threads(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_threads" << std::endl; + os << R"V0G0N( + Get kernel thread ids from the receiver in order of [parent, tcp, listener 0, processor 0, streamer 0, listener 1, processor 1, streamer 1, arping]. If no streamer yet or there is no second interface, it gives 0 in its place. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxThreadIds(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_udpsocksize(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_udpsocksize" << std::endl; + os << R"V0G0N([n_size] + UDP socket buffer size in receiver. Tune rmem_default and rmem_max accordingly. Max value is INT_MAX/2. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxUDPSocketBufferSize(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxUDPSocketBufferSize(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_version(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_version" << std::endl; + os << R"V0G0N( + Receiver version )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getReceiverVersion(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqfreq(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqfreq" << std::endl; + os << R"V0G0N([nth frame] + Frequency of frames streamed out from receiver via zmq + Default: 1, Means every frame is streamed out. + If 2, every second frame is streamed out. + If 0, streaming timer is the timeout, after which current frame is sent out. (default timeout is 500 ms). Usually used for gui purposes. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqFrequency(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxZmqFrequency(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqhwm(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqhwm" << std::endl; + os << R"V0G0N([n_value] + Receiver's zmq send high water mark. Default is the zmq library's default (1000). This is a high number and can be set to 2 for gui purposes. One must also set the client's receive high water mark to similar value. Final effect is sum of them. Also restarts receiver zmq streaming if enabled. Can set to -1 to set default value. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqHwm(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute rx_zmqhwm at module level"); + } + auto arg0 = StringTo(args[0]); + det->setRxZmqHwm(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqip(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqip" << std::endl; + os << R"V0G0N([x.x.x.x] + Zmq Ip Address from which data is to be streamed out of the receiver. Also restarts receiver zmq streaming if enabled. Default is from rx_hostname. Modified only when using an intermediate process between receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqIP(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setRxZmqIP(IpAddr(args[0]), std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqport(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqport" << std::endl; + os << R"V0G0N([port] + Zmq port for data to be streamed out of the receiver. Also restarts receiver zmq streaming if enabled. Default is 30001. Modified only when using an intermediate process between receiver and client(gui). Must be different for every detector (and udp port). Multi command will automatically increment for individual modules. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxZmqPort(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqstartfnum(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqstartfnum" << std::endl; + os << R"V0G0N([fnum] + The starting frame index to stream out. 0 by default, which streams the first frame in an acquisition, and then depending on the rx zmq frequency/ timer )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqStartingFrame(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxZmqStartingFrame(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::rx_zmqstream(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: rx_zmqstream" << std::endl; + os << R"V0G0N([0, 1] + Enable/ disable data streaming from receiver via zmq (eg. to GUI or to another process for further processing). This creates/ destroys zmq streamer threads in receiver. + Switching to Gui automatically enables data streaming in receiver. + Switching back to command line acquire will require disabling data streaming in receiver for fast applications. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getRxZmqDataStream(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setRxZmqDataStream(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::savepattern(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: savepattern" << std::endl; + os << R"V0G0N( + [Ctb][Mythen3][Xilinx Ctb] Saves pattern to file (ascii). + [Ctb] Also executes pattern. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError( + "Cannot execute savepattern at module level"); + } + det->savePattern(args[0]); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::scan(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: scan" << std::endl; + os << R"V0G0N([dac_name|0|trimbits] [start_val] [stop_val] [step_size] [dac settling time ns|us|ms|s] + Enables/ disables scans for dac and trimbits + Enabling scan sets number of frames to number of steps in receiver. + To cancel scan configuration, set dac to '0', which also sets number of frames to 1. + [Eiger][Mythen3] Use trimbits as dac name for a trimbit scan. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 4 && args.size() != 5) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + if (args.size() == 4) { + } + + if (args.size() == 5) { + try { + std::string tmp_time(args[4]); + std::string unit = RemoveUnit(tmp_time); + auto t = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getScan(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (StringTo(args[0]) != 0) { + throw RuntimeError("Unknown argument " + args[0] + + ". Did you mean 0 to disable scan?"); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute scan at module level"); + } + det->setScan(defs::scanParameters()); + os << ToString(args) << '\n'; + } + + if (args.size() == 4) { + if (det_id != -1) { + throw RuntimeError("Cannot execute scan at module level"); + } + det->setScan(defs::scanParameters( + StringTo(args[0]), StringTo(args[1]), + StringTo(args[2]), StringTo(args[3]))); + os << ToString(args) << '\n'; + } + + if (args.size() == 5) { + std::string tmp_time(args[4]); + std::string unit = RemoveUnit(tmp_time); + auto t = StringTo(tmp_time, unit); + if (det_id != -1) { + throw RuntimeError("Cannot execute scan at module level"); + } + det->setScan(defs::scanParameters( + StringTo(args[0]), StringTo(args[1]), + StringTo(args[2]), StringTo(args[3]), t)); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::scanerrmsg(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: scanerrmsg" << std::endl; + os << R"V0G0N( + Gets Scan error message if scan ended in error for non blocking acquisitions. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getScanErrorMessage(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::selinterface(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: selinterface" << std::endl; + os << R"V0G0N([0, 1] + [Jungfrau][Moench] The udp interface to stream data from detector. Effective only when number of interfaces is 1. Default: 0 (outer) )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSelectedUDPInterface(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->selectUDPInterface(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::serialnumber(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: serialnumber" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] +Serial number of detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSerialNumber(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::setbit(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: setbit" << std::endl; + os << R"V0G0N([reg address in hex] [bit index] + Sets bit in address. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (StringTo(args[1]) < 0 || StringTo(args[1]) > 31) { + throw RuntimeError("Bit number out of range: " + args[1]); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setBit(arg0, arg1, std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::settings(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: settings" << std::endl; + os << R"V0G0N([standard, fast, highgain, dynamicgain, lowgain, mediumgain, veryhighgain, highgain0, fixgain1, fixgain2, forceswitchg1, forceswitchg2, verylowgain, g1_hg, g1_lg, g2_hc_hg, g2_hc_lg, g2_lc_hg, g2_lc_lg, g4_hg, g4_lg, gain0] + Detector Settings + [Jungfrau] - [ gain0 | highgain0] + [Gotthard] - [dynamicgain | highgain | lowgain | mediumgain | veryhighgain] + [Gotthard] Also loads default dacs on to the detector. + [Gotthard2] - [dynamicgain | fixgain1 | fixgain2] + [Mythen3] - [standard | fast | highgain] Also changes vrshaper and vrpreamp. + [Eiger] Use threshold or thresholdnotb. + [Eiger] threshold and settings loaded from file found in settingspath. + [Moench] - [g1_hg | g1_lg | g2_hc_hg | g2_hc_lg | g2_lc_hg | g2_lc_lg | g4_hg | g4_lg] )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::detectorSettings"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSettings(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setSettings(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::settingslist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: settingslist" << std::endl; + os << R"V0G0N( + List of settings implemented for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSettingsList(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::settingspath(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: settingspath" << std::endl; + os << R"V0G0N([path] + [Eiger][Mythen3] Directory where settings files are loaded from/to. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSettingsPath(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setSettingsPath(args[0], std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::signalindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: signalindex" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get the signal index for the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot execute signalindex at module level"); + } + auto t = det->getSignalIndex(args[0]); + os << static_cast(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::signallist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: signallist" << std::endl; + os << R"V0G0N([signalname1 signalname2 .. signalname63] + [Ctb][Xilinx_Ctb] Set the list of signal names for this board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute signallist at module level"); + } + auto t = det->getSignalNames(); + os << ToString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (cmd == "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError("This detector already has fixed dac names. " + "Cannot change them."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute signallist at module level"); + } + det->setSignalNames(args); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::signalname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: signalname" << std::endl; + os << R"V0G0N([0-63][name] + [Ctb][Xilinx_Ctb] Set the signal at the given position to the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute signalname at module level"); + } + auto arg0 = StringTo(args[0]); + auto t = det->getSignalName(arg0); + os << args[0] << ' ' << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute signalname at module level"); + } + auto arg0 = StringTo(args[0]); + det->setSignalName(arg0, args[1]); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::slowadcindex(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: slowadcindex" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get the slowadc index for the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::SLOW_ADC0; + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::SLOW_ADC0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot execute slowadcindex at module level"); + } + auto t = det->getSlowADCIndex(args[0]); + os << ToString(static_cast(t) - index) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::slowadclist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: slowadclist" << std::endl; + os << R"V0G0N([slowadcname1 slowadcname2 .. slowadcname7] + [Ctb][Xilinx_Ctb] Set the list of slowadc names for this board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot execute slowadclist at module level"); + } + auto t = det->getSlowADCNames(); + os << ToString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + auto det_type = det->getDetectorType().squash(defs::GENERIC); + ; + if (cmd != "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (cmd == "daclist" && det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError("This detector already has fixed dac names. " + "Cannot change them."); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute slowadclist at module level"); + } + det->setSlowADCNames(args); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::slowadcname(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: slowadcname" << std::endl; + os << R"V0G0N([0-7][name] + [Ctb][Xilinx_Ctb] Set the slowadc at the given position to the given name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::dacIndex index = defs::SLOW_ADC0; + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::dacIndex index = defs::SLOW_ADC0; + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::dacIndex index = defs::SLOW_ADC0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot execute slowadcname at module level"); + } + auto t = det->getSlowADCName( + static_cast(StringTo(args[0]) + index)); + os << args[0] << ' ' << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::dacIndex index = defs::SLOW_ADC0; + if (det->getDetectorType().squash(defs::GENERIC) != + defs::CHIPTESTBOARD && + det->getDetectorType().squash(defs::GENERIC) != + defs::XILINX_CHIPTESTBOARD) { + throw RuntimeError(cmd + " only allowed for CTB."); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot execute slowadcname at module level"); + } + det->setSlowADCName( + static_cast(StringTo(args[0]) + index), + args[1]); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::slowadcvalues(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: slowadcvalues" << std::endl; + os << R"V0G0N([name] + [Ctb][Xilinx_Ctb] Get values of all slow adcs. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + + std::string suffix = " mV"; + auto t = det->getSlowADCList(); + + auto names = det->getSlowADCNames(); + auto name_it = names.begin(); + os << '['; + if (t.size() > 0) { + + auto it = t.cbegin(); + os << ToString(*name_it++) << ' '; + os << OutString( + det->getSlowADC(*it++, std::vector{det_id})) + << suffix; + while (it != t.cend()) { + os << ", " << ToString(*name_it++) << ' '; + os << OutString( + det->getSlowADC(*it++, std::vector{det_id})) + << suffix; + } + } + + os << "]\n"; + } + } + + return os.str(); +} + +std::string Caller::start(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: start" << std::endl; + os << R"V0G0N( + Starts detector acquisition. Status changes to RUNNING or WAITING and automatically returns to idle at the end of acquisition. If the acquisition was abruptly stopped, some detectors come back to STOPPED. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->startDetector(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::status(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: status" << std::endl; + os << R"V0G0N([running, error, transmitting, finished, waiting, idle] + Detector status. Goes to stop server. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDetectorStatus(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (true) { + throw RuntimeError("Cannot put. Did you mean to use command: " + "\"start\" or \"stop\"?"); + } + } + + return os.str(); +} + +std::string Caller::stop(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: stop" << std::endl; + os << R"V0G0N( + Abort detector acquisition. Status changes to IDLE or STOPPED. Goes to stop server. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->stopDetector(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::stopport(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: stopport" << std::endl; + os << R"V0G0N([n] + Port number of the stop server on detector for detector-client tcp interface. Default is 1953. Normally unchanged. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getStopPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setStopPort(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::storagecell_delay(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: storagecell_delay" << std::endl; + os << R"V0G0N([duration (0-1638375 ns)] [(optional unit) ns|us|ms|s] + [Jungfrau] Additional time delay between 2 consecutive exposures in burst mode (resolution of 25ns). Only applicable for chipv1.0. For advanced users only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getStorageCellDelay(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getStorageCellDelay(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setStorageCellDelay(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setStorageCellDelay(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::storagecell_start(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: storagecell_start" << std::endl; + os << R"V0G0N([0-max] + [Jungfrau] Storage cell that stores the first acquisition of the series. max is 15 (default) for chipv1.0 and 3 (default) for chipv1.1. For advanced users only. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getStorageCellStart(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setStorageCellStart(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::subdeadtime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: subdeadtime" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Eiger] Dead time of EIGER subframes in 32 bit mode. Subperiod = subexptime + subdeadtime. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSubDeadTime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getSubDeadTime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setSubDeadTime(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setSubDeadTime(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::subexptime(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: subexptime" << std::endl; + os << R"V0G0N([duration] [(optional unit) ns|us|ms|s] + [Eiger] Exposure time of EIGER subframes in 32 bit mode. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + } catch (...) { + throw RuntimeError("Could not convert argument to time::ns"); + } + } + + if (args.size() == 2) { + try { + StringTo(args[0], args[1]); + } catch (...) { + throw RuntimeError("Could not convert arguments to time::ns"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSubExptime(std::vector{det_id}); + os << OutString(t) << '\n'; + } + + if (args.size() == 1) { + auto t = det->getSubExptime(std::vector{det_id}); + os << OutString(t, args[0]) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + std::string tmp_time(args[0]); + std::string unit = RemoveUnit(tmp_time); + auto converted_time = StringTo(tmp_time, unit); + det->setSubExptime(converted_time, std::vector{det_id}); + os << args[0] << '\n'; + } + + if (args.size() == 2) { + auto converted_time = StringTo(args[0], args[1]); + det->setSubExptime(converted_time, std::vector{det_id}); + os << args[0] << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::sync(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: sync" << std::endl; + os << R"V0G0N([0, 1] + [Jungfrau][Moench] Enables or disables synchronization between modules. Sync mode requires at least one master configured. Also requires flatband cabling between master and slave with termination board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSynchronization(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute sync at module level"); + } + auto arg0 = StringTo(args[0]); + det->setSynchronization(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::syncclk(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: syncclk" << std::endl; + os << R"V0G0N([n_clk in MHz] + [Ctb] Sync clock in MHz. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSYNCClock(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_10ge(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_10ge" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature close to the 10GbE )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_10GE, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_adc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_adc" << std::endl; + os << R"V0G0N([n_value] + [Jungfrau][Moench][Gotthard] ADC Temperature )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_ADC, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_control(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_control" << std::endl; + os << R"V0G0N([0, 1] + [Jungfrau][Moench] Temperature control enable. Default is 0 (disabled). If temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperatureControl(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTemperatureControl(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_dcdc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_dcdc" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature close to the dc dc converter )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_DCDC, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_event(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_event" << std::endl; + os << R"V0G0N([0] + [Jungfrau][Moench] 1, if a temperature event occured. To clear this event, set it to 0. + If temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperatureEvent(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (StringTo(args[0]) != 0) { + throw RuntimeError("Unknown argument for temp event: ( " + + args[0] + + " ). Did you mean 0 to reset event?"); + } + det->resetTemperatureEvent(std::vector{det_id}); + os << "cleared" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_fpga(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_fpga" << std::endl; + os << R"V0G0N([n_value] + [Eiger][Jungfrau][Moench][Gotthard][Mythen3][Gotthard2] FPGA Temperature )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_FPGA, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_fpgaext(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_fpgaext" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature close to the FPGA )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_FPGAEXT, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_fpgafl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_fpgafl" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature of the left front end board fpga. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_FPGA2, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_fpgafr(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_fpgafr" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature of the right front end board fpga. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_FPGA3, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_slowadc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_slowadc" << std::endl; + os << R"V0G0N([n_value] + [Ctb]Temperature of the slow adc )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::SLOW_ADC_TEMP, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_sodl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_sodl" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature close to the left so-dimm memory )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_SODL, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_sodr(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_sodr" << std::endl; + os << R"V0G0N([n_value] + [Eiger]Temperature close to the right so-dimm memory )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperature(defs::TEMPERATURE_SODR, + std::vector{det_id}); + os << OutString(t) << " °C" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::temp_threshold(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: temp_threshold" << std::endl; + os << R"V0G0N([n_temp (in degrees)] + [Jungfrau][Moench] Threshold temperature in degrees. If temperature crosses threshold temperature and temperature control is enabled, power to chip will be switched off and temperature event occurs. To power on chip again, temperature has to be less than threshold temperature and temperature event has to be cleared. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getThresholdTemperature(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setThresholdTemperature(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::templist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: templist" << std::endl; + os << R"V0G0N( + List of temperature commands implemented for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTemperatureList(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::tempvalues(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: tempvalues" << std::endl; + os << R"V0G0N( + Gets the values for every temperature for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + + std::string suffix = " °C"; + auto t = det->getTemperatureList(); + os << '['; + if (t.size() > 0) { + + auto it = t.cbegin(); + os << ToString(*it) << ' '; + os << OutString( + det->getTemperature(*it++, std::vector{det_id})) + << suffix; + while (it != t.cend()) { + os << ", " << ToString(*it) << ' '; + os << OutString(det->getTemperature( + *it++, std::vector{det_id})) + << suffix; + } + } + + os << "]\n"; + } + } + + return os.str(); +} + +std::string Caller::tengiga(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: tengiga" << std::endl; + os << R"V0G0N([0, 1] + [Eiger][Ctb][Mythen3] 10GbE Enable. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTenGiga(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTenGiga(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::timing(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: timing" << std::endl; + os << R"V0G0N([auto|trigger|gating|burst_trigger] + Timing Mode of detector. + [Jungfrau][Moench][Gotthard][Ctb][Gotthard2][Xilinx Ctb] [auto|trigger] + [Mythen3] [auto|trigger|gating|trigger_gating] + [Eiger] [auto|trigger|gating|burst_trigger] )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::timingMode"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTimingMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTimingMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::timinglist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: timinglist" << std::endl; + os << R"V0G0N( + Gets the list of timing modes for this detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTimingModeList(); + os << ToString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::timingsource(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: timingsource" << std::endl; + os << R"V0G0N([internal|external] + [Gotthard2] Timing source. Internal is crystal and external is system timing. Default is internal. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError( + "Could not convert argument 0 to defs::timingSourceType"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTimingSource(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTimingSource(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::top(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: top" << std::endl; + os << R"V0G0N([0, 1] + [Eiger] Sets half module to top (1), else bottom. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTop(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTop(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::transceiverenable(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: transceiverenable" << std::endl; + os << R"V0G0N([bitmask] + [Ctb] Transceiver Enable Mask. Enable for each 4 Transceiver channel. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint32_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTransceiverEnableMask(std::vector{det_id}); + os << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTransceiverEnableMask(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::trigger(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: trigger" << std::endl; + os << R"V0G0N( + [Eiger][Mythen3][Jungfrau][Moench] Sends software trigger signal to detector )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + bool block = false; + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + bool block = false; + if (det_id != -1) { + throw RuntimeError("Cannot execute trigger at module level"); + } + det->sendSoftwareTrigger(block); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::triggers(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: triggers" << std::endl; + os << R"V0G0N([n_triggers] + Number of triggers per aquire. Set timing mode to use triggers. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int64_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfTriggers(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute triggers at module level"); + } + auto arg0 = StringTo(args[0]); + det->setNumberOfTriggers(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::triggersl(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: triggersl" << std::endl; + os << R"V0G0N( + [Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][Ctb][Xilinx Ctb] Number of triggers left in acquisition. Only when external trigger used. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberOfTriggersLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::trimbits(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: trimbits" << std::endl; + os << R"V0G0N([fname] + [Eiger][Mythen3] Put will load the trimbit file to detector. If no extension specified, serial number of each module is attached. Get will save the trimbits from the detector to file with serial number added to file name. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + det->saveTrimbits(args[0], std::vector{det_id}); + os << args[0] << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->loadTrimbits(args[0], std::vector{det_id}); + os << args[0] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::trimval(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: trimval" << std::endl; + os << R"V0G0N([n_trimval] + [Eiger][Mythen3] All trimbits set to this value. Returns -1 if all trimbits are different values. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getAllTrimbits(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setAllTrimbits(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::tsamples(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: tsamples" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Number of transceiver samples expected. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = + det->getNumberOfTransceiverSamples(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setNumberOfTransceiverSamples(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::txdelay(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: txdelay" << std::endl; + os << R"V0G0N([n_delay] + [Eiger][Jungfrau][Moench][Mythen3] Set transmission delay for all modules in the detector using the step size provided.Sets up + [Eiger] txdelay_left to (2 * mod_index * n_delay), + [Eiger] txdelay_right to ((2 * mod_index + 1) * n_delay) and + [Eiger] txdelay_frame to (2 *num_modules * n_delay) + [Jungfrau][Moench][Mythen3] txdelay_frame to (num_modules * n_delay) +for every module. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute txdelay at module level"); + } + auto t = det->getTransmissionDelay(); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + if (det_id != -1) { + throw RuntimeError("Cannot execute txdelay at module level"); + } + auto arg0 = StringTo(args[0]); + det->setTransmissionDelay(arg0); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::txdelay_frame(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: txdelay_frame" << std::endl; + os << R"V0G0N([n_delay] + [Eiger][Jungfrau][Moench][Mythen3] Transmission delay of first udp packet being streamed out of the module. + [Jungfrau][Moench] [0-31] Each value represents 1 ms + [Eiger] Additional delay to txdelay_left and txdelay_right. Each value represents 10ns. Typical value is 50000. + [Mythen3] [0-16777215] Each value represents 8 ns (125 MHz clock), max is 134 ms. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTransmissionDelayFrame(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTransmissionDelayFrame(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::txdelay_left(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: txdelay_left" << std::endl; + os << R"V0G0N([n_delay] + [Eiger] Transmission delay of first packet in an image being streamed out of the module's left UDP port. Each value represents 10ns. Typical value is 50000. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTransmissionDelayLeft(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTransmissionDelayLeft(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::txdelay_right(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: txdelay_right" << std::endl; + os << R"V0G0N([n_delay] + [Eiger] Transmission delay of first packet in an image being streamed out of the module's right UDP port. Each value represents 10ns. Typical value is 50000. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getTransmissionDelayRight(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setTransmissionDelayRight(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::type(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: type" << std::endl; + os << R"V0G0N( + Returns detector type. Can be Eiger, Jungfrau, Gotthard, Moench, Mythen3, Gotthard2, ChipTestBoard, Xilinx_ChipTestBoard )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDetectorType(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_cleardst(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_cleardst" << std::endl; + os << R"V0G0N( + Clears udp destination details on the detector. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->clearUDPDestinations(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_dstlist(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_dstlist" << std::endl; + os << R"V0G0N([ip=x.x.x.x] [(optional)ip2=x.x.x.x] + [mac=xx:xx:xx:xx:xx:xx] [(optional)mac2=xx:xx:xx:xx:xx:xx] + [port=value] [(optional)port2=value] + The order of ip, mac and port does not matter. entry_value can be >0 only for [Eiger][Jungfrau][Moench][Mythen3][Gotthard2] where round robin is implemented. If 'auto' used, then ip is set to ip of rx_hostname. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id == -1) { + throw RuntimeError( + "Can execute udp_dstlist only at module level."); + } + if (rx_id < 0 || rx_id >= MAX_UDP_DESTINATION) { + throw RuntimeError("Invalid receiver index " + + std::to_string(rx_id) + + " to set round robin entry."); + } + auto t = + det->getDestinationUDPList(rx_id, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (det_id == -1) { + throw RuntimeError("Can execute udp_dstlist only at module level."); + } + if (rx_id < 0 || rx_id >= MAX_UDP_DESTINATION) { + throw RuntimeError("Invalid receiver index " + + std::to_string(rx_id) + + " to set round robin entry."); + } + if (args.empty()) { + throw RuntimeError("udp_dstlist require at least one argument."); + } + det->setDestinationUDPList(getUdpEntry(), det_id); + os << ToString(args) << '\n'; + } + + return os.str(); +} + +std::string Caller::udp_dstmac(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_dstmac" << std::endl; + os << R"V0G0N([x:x:x:x:x:x] + Mac address of the receiver (destination) udp interface. Not mandatory to set as udp_dstip retrieves it from slsReceiver process, but must be set if you use a custom receiver (not slsReceiver). Use router mac if router between detector and receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDestinationUDPMAC(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setDestinationUDPMAC(MacAddr(args[0]), + std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_dstmac2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_dstmac2" << std::endl; + os << R"V0G0N([x:x:x:x:x:x] + [Jungfrau][Moench] Mac address of the receiver (destination) udp interface 2. Not mandatory to set as udp_dstip2 retrieves it from slsReceiver process but must be set if you use a custom receiver (not slsReceiver). + [Jungfrau][Moench] top half or inner interface + [Gotthard2] veto debugging. Use router mac if router between detector and receiver. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDestinationUDPMAC2(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setDestinationUDPMAC2(MacAddr(args[0]), + std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_dstport(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_dstport" << std::endl; + os << R"V0G0N([n] + Port number of the receiver (destination) udp interface. Default is 50001. + If multi command, ports for each module is calculated (incremented by 1 if no 2nd interface) )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDestinationUDPPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDestinationUDPPort(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_dstport2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_dstport2" << std::endl; + os << R"V0G0N([n] + [Jungfrau][Moench][Eiger][Gotthard2] Port number of the receiver (destination) udp interface 2. Default is 50002. + If multi command, ports for each module is calculated (incremented by 2) + [Jungfrau][Moench] top half or inner interface + [Eiger] right half + [Gotthard2] veto debugging )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getDestinationUDPPort2(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setDestinationUDPPort2(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_firstdst(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_firstdst" << std::endl; + os << R"V0G0N( +[0 - 31 (or number of udp destinations)] + [Jungfrau][Moench][Gotthard2] +[0-63] + [Mythen3] + + One can set which is the first destination that the detector will stream images out from in a round robin fashion. The entry must not have been empty. Default: 0 )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getFirstUDPDestination(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setFirstUDPDestination(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_numdst(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_numdst" << std::endl; + os << R"V0G0N( + [Jungfrau][Moench][Eiger][Mythen3][Gotthard2] One can enter upto 32 (64 for Mythen3) destinations that the detector will stream images out in a round robin fashion. This is get only command. Default: 1 )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getNumberofUDPDestinations(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_reconfigure(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_reconfigure" << std::endl; + os << R"V0G0N( + Reconfigures Detector with UDP destination. More for debugging as the configuration is done automatically when the detector has sufficient UDP details. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->reconfigureUDPDestination(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_srcmac(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_srcmac" << std::endl; + os << R"V0G0N([x:x:x:x:x:x] + Mac address of the detector (source) udp interface. + [Eiger] Do not set as detector will replace with its own DHCP Mac (1G) or DHCP Mac + 1 (10G). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSourceUDPMAC(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setSourceUDPMAC(MacAddr(args[0]), std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_srcmac2(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_srcmac2" << std::endl; + os << R"V0G0N([x:x:x:x:x:x] + [Jungfrau][Moench] Mac address of the top half or inner (source) udp interface. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getSourceUDPMAC2(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setSourceUDPMAC2(MacAddr(args[0]), std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::udp_validate(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: udp_validate" << std::endl; + os << R"V0G0N( + Validates that UDP configuration in the detector is valid. If not configured, it will throw with error message requesting missing udp information. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 0) { + det->validateUDPConfiguration(std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::update(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: update" << std::endl; + os << R"V0G0N( + Without tftp: [server_name (incl fullpath)] [fname.pof (incl full path)] This does not use tftp. + [Jungfrau][Moench][Gotthard][Ctb] Updates the firmware, detector server, deletes old server, creates the symbolic link and then reboots detector controller. + [Mythen3][Gotthard2] will require a script to start up the shorter named server link at start up. + server_name is full path name of detector server binary + fname is full path of programming file )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (args[args.size() - 1].find(".pof") == std::string::npos && + args[args.size() - 1].find(".rbf") == std::string::npos) { + throw RuntimeError("Programming file must be a pof/rbf file."); + } + det->updateFirmwareAndServer(args[0], args[1], + std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::updatedetectorserver(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: updatedetectorserver" << std::endl; + os << R"V0G0N([server_name with full path] + [Jungfrau][Moench][Eiger][Ctb][Mythen3][Gotthard2] Copies detector server via TCP (without tftp). Makes a symbolic link with a shorter name (without vx.x.x). Then, detector controller reboots (except Eiger). + [Jungfrau][Moench][Ctb]Also changes respawn server to the link, which is effective after a reboot. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->updateDetectorServer(args[0], std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::updatekernel(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: updatekernel" << std::endl; + os << R"V0G0N([kernel_name with full path] + [Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Advanced Command!! You could damage the detector. Please use with caution. + Updates the kernel image. Then, detector controller reboots with new kernel. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->updateKernel(args[0], std::vector{det_id}); + os << "successful" << '\n'; + } + } + + return os.str(); +} + +std::string Caller::updatemode(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: updatemode" << std::endl; + os << R"V0G0N([0|1] + Restart the detector server in update mode or not. This is useful when server-firmware compatibility is at its worst and server cannot start up normally )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getUpdateMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setUpdateMode(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::user(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: user" << std::endl; + os << R"V0G0N( + User details from shared memory (hostname, type, PID, User, Date). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + if (det_id != -1) { + throw RuntimeError("Cannot execute user at module level"); + } + auto t = det->getUserDetails(); + os << t << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_a(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_a" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply a in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_POWER_A, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_A, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_b(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_b" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply b in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_POWER_B, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_B, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_c(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_c" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply c in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_POWER_C, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_C, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_chip(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_chip" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply chip in mV. Do not use it unless you are completely sure you will not fry the board. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = + det->getPower(defs::V_POWER_CHIP, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_CHIP, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_d(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_d" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply d in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_POWER_D, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_D, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_io(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_io" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Power supply io in mV. Minimum 1200 mV. Must be the first power regulator to be set after fpga reset (on-board detector server start up). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_POWER_IO, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_POWER_IO, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::v_limit(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: v_limit" << std::endl; + os << R"V0G0N([n_value] + [Ctb] Soft limit for power supplies (ctb only) and DACS in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getPower(defs::V_LIMIT, std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + det->setPower(defs::V_LIMIT, arg1, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_comp_adc(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_comp_adc" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac for comparator current of ADC. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = det->getOnChipDAC(defs::VB_COMP_ADC, arg1, + std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VB_COMP_ADC, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_comp_fe(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_comp_fe" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac for comparator current of analogue front end. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = det->getOnChipDAC(defs::VB_COMP_FE, arg1, + std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VB_COMP_FE, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_cs(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_cs" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac for current injection into preamplifier. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = + det->getOnChipDAC(defs::VB_CS, arg1, std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VB_CS, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_opa_1st(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_opa_1st" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac for opa current for driving the other DACs in chip. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = det->getOnChipDAC(defs::VB_OPA_1ST, arg1, + std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VB_OPA_1ST, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_opa_fd(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_opa_fd" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac current for CDS opa stage. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = det->getOnChipDAC(defs::VB_OPA_FD, arg1, + std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VB_OPA_FD, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vchip_ref_comp_fe(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vchip_ref_comp_fe" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all][10 bit hex value] + [Gotthard2] On chip Dac for reference voltage of the comparator of analogue front end. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + auto arg1 = StringTo(args[0]); + auto t = det->getOnChipDAC(defs::VREF_COMP_FE, arg1, + std::vector{det_id}); + os << args[0] << ' ' << OutStringHex(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg1 = StringTo(args[0]); + auto arg2 = StringTo(args[1]); + det->setOnChipDAC(defs::VREF_COMP_FE, arg1, arg2, + std::vector{det_id}); + os << args[0] << ' ' << args[1] << '\n'; + } + } + + return os.str(); +} + +std::string Caller::veto(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: veto" << std::endl; + os << R"V0G0N([0, 1] + [Gotthard2] Enable or disable veto data data from chip. Default is 0. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to bool"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getVeto(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setVeto(arg0, std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vetoalg(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vetoalg" << std::endl; + os << R"V0G0N([hits|raw] [lll|10gbe] + [Gotthard2] Set the veto algorithm. Default is hits. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 1) { + defs::streamingInterface interface = + StringTo(args[0]); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + defs::vetoAlgorithm alg = StringTo(args[0]); + defs::streamingInterface interface = + StringTo(args[1]); + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 1) { + defs::streamingInterface interface = + StringTo(args[0]); + if (interface == defs::streamingInterface::NONE) { + throw RuntimeError( + "Must specify an interface to set algorithm"); + } + auto t = det->getVetoAlgorithm(interface, std::vector{det_id}); + os << OutString(t) << ' ' << ToString(interface) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + defs::vetoAlgorithm alg = StringTo(args[0]); + defs::streamingInterface interface = + StringTo(args[1]); + if (interface == defs::streamingInterface::NONE) { + throw RuntimeError( + "Must specify an interface to set algorithm"); + } + det->setVetoAlgorithm(alg, interface, std::vector{det_id}); + os << ToString(alg) << ' ' << ToString(interface) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vetofile(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vetofile" << std::endl; + os << R"V0G0N([chip index 0-9, -1 for all] [file name] + [Gotthard2] Set veto reference for each 128 channels for specific chip. The file should have 128 rows of gain index and 12 bit value in dec )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (true) { + throw RuntimeError("Cannot get vetofile. Did you mean vetophoton?"); + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + det->setVetoFile(arg0, args[1], std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vetophoton(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vetophoton" << std::endl; + os << R"V0G0N([ichip] [#photons] [energy in keV] [reference file] + [Gotthard2] Set veto reference for 128 channels for chip ichip according to reference file and #photons and energy in keV. +[ichip] [output file] + Get gain indices and veto reference for 128 channels for chip ichip, saved to file. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 4) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 4) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + try { + StringTo(args[2]); + } catch (...) { + throw RuntimeError("Could not convert argument 2 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + det->getVetoPhoton(arg0, args[1], std::vector{det_id}); + os << "saved to file " << args[1] << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 4) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + auto arg2 = StringTo(args[2]); + det->setVetoPhoton(arg0, arg1, arg2, args[3], + std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vetoref(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vetoref" << std::endl; + os << R"V0G0N([gain index] [12 bit value] + [Gotthard2] Set veto reference for all 128 channels for all chips. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (true) { + throw RuntimeError("Cannot get vetoref. Did you mean vetophoton?"); + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setVetoReference(arg0, arg1); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::virtualFunction(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: virtual" << std::endl; + os << R"V0G0N([n_servers] [starting_port_number] + Connecs to n virtual server at local host starting at specific control port. Every virtual server will have a stop port (control port + 1) )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 2) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 2) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + try { + StringTo(args[1]); + } catch (...) { + throw RuntimeError("Could not convert argument 1 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 2) { + if (det_id != -1) { + throw RuntimeError("Cannot execute virtual at module level"); + } + auto arg0 = StringTo(args[0]); + auto arg1 = StringTo(args[1]); + det->setVirtualDetectorServers(arg0, arg1); + os << ToString(args) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vm_a(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vm_a" << std::endl; + os << R"V0G0N( + [Ctb] Measured voltage of power supply a in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPower(defs::V_POWER_A, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vm_b(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vm_b" << std::endl; + os << R"V0G0N( + [Ctb] Measured voltage of power supply b in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPower(defs::V_POWER_B, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vm_c(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vm_c" << std::endl; + os << R"V0G0N( + [Ctb] Measured voltage of power supply c in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPower(defs::V_POWER_C, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vm_d(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vm_d" << std::endl; + os << R"V0G0N( + [Ctb] Measured voltage of power supply d in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPower(defs::V_POWER_D, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::vm_io(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: vm_io" << std::endl; + os << R"V0G0N( + [Ctb] Measured voltage of power supply io in mV. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else { + + throw RuntimeError( + "INTERNAL ERROR: Invalid action: supported actions are ['GET']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getMeasuredPower(defs::V_POWER_IO, + std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + return os.str(); +} + +std::string Caller::zmqhwm(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: zmqhwm" << std::endl; + os << R"V0G0N([n_limit] + Client's zmq receive high water mark. Default is the zmq library's default (1000), can also be set here using -1. + This is a high number and can be set to 2 for gui purposes. + One must also set the receiver's send high water mark to similar value. Final effect is sum of them. + Setting it via command line is useful only before zmq enabled (before opening gui). )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to int"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getClientZmqHwm(); + os << t << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setClientZmqHwm(arg0); + os << det->getClientZmqHwm() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::zmqip(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: zmqip" << std::endl; + os << R"V0G0N([x.x.x.x] + Ip Address to listen to zmq data streamed out from receiver or intermediate process. Default connects to receiver zmq Ip Address (from rx_hostname). Modified only when using an intermediate process between receiver and client(gui). Also restarts client zmq streaming if enabled. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getClientZmqIp(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + det->setClientZmqIp(IpAddr(args[0]), std::vector{det_id}); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +std::string Caller::zmqport(int action) { + + std::ostringstream os; + // print help + if (action == slsDetectorDefs::HELP_ACTION) { + os << "Command: zmqport" << std::endl; + os << R"V0G0N([port] + Zmq port in client(gui) or intermediate process for data to be streamed to from receiver. Default connects to receiver zmq streaming out port (30001). Modified only when using an intermediate process between receiver and client(gui). Also restarts client zmq streaming if enabled. Must be different for every detector (and udp port). Multi command will automatically increment for individual modules. )V0G0N" + << std::endl; + return os.str(); + } + + // check if action and arguments are valid + if (action == slsDetectorDefs::GET_ACTION) { + if (1 && args.size() != 0) { + throw RuntimeError("Wrong number of arguments for action GET"); + } + + if (args.size() == 0) { + } + + } + + else if (action == slsDetectorDefs::PUT_ACTION) { + if (1 && args.size() != 1) { + throw RuntimeError("Wrong number of arguments for action PUT"); + } + + if (args.size() == 1) { + try { + StringTo(args[0]); + } catch (...) { + throw RuntimeError("Could not convert argument 0 to uint16_t"); + } + } + + } + + else { + + throw RuntimeError("INTERNAL ERROR: Invalid action: supported actions " + "are ['GET', 'PUT']"); + } + + // generate code for each action + if (action == slsDetectorDefs::GET_ACTION) { + if (args.size() == 0) { + auto t = det->getClientZmqPort(std::vector{det_id}); + os << OutString(t) << '\n'; + } + } + + if (action == slsDetectorDefs::PUT_ACTION) { + if (args.size() == 1) { + auto arg0 = StringTo(args[0]); + det->setClientZmqPort(arg0, det_id); + os << args.front() << '\n'; + } + } + + return os.str(); +} + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/src/Caller.h b/slsDetectorSoftware/src/Caller.h new file mode 100644 index 000000000..679f76526 --- /dev/null +++ b/slsDetectorSoftware/src/Caller.h @@ -0,0 +1,878 @@ +// This file is used as input to generate the caller class + +#include "CmdParser.h" +#include "HelpDacs.h" +#include "sls/Detector.h" + +#include +#include +#include +namespace sls { + +class Caller { + public: + Caller(Detector *ptr) : det(ptr) {} + void call(const std::string &command, + const std::vector &arguments, int detector_id, + int action, std::ostream &os = std::cout, int receiver_id = -1); + + IpAddr getDstIpFromAuto(); + IpAddr getSrcIpFromAuto(); + UdpDestination getUdpEntry(); + void GetLevelAndUpdateArgIndex(int action, + std::string levelSeparatedCommand, + int &level, int &iArg, size_t nGetArgs, + size_t nPutArgs); + void WrongNumberOfParameters(size_t expected); + + template std::string OutStringHex(const V &value) { + if (value.equal()) + return ToStringHex(value.front()); + return ToStringHex(value); + } + + template std::string OutStringHex(const V &value, int width) { + if (value.equal()) + return ToStringHex(value.front(), width); + return ToStringHex(value, width); + } + + template std::string OutString(const Result &value) { + if (value.equal()) + return ToString(value.front()); + return ToString(value); + } + + template std::string OutString(const V &value) { + return ToString(value); + } + + template + std::string OutString(const V &value, const std::string &unit) { + if (value.equal()) + return ToString(value.front(), unit); + return ToString(value, unit); + } + + std::vector getAllCommands(); + std::string list(int action); + + std::string acquire(int action); + std::string activate(int action); + std::string adcclk(int action); + std::string adcenable(int action); + std::string adcenable10g(int action); + std::string adcindex(int action); + std::string adcinvert(int action); + std::string adclist(int action); + std::string adcname(int action); + std::string adcphase(int action); + std::string adcpipeline(int action); + std::string adcreg(int action); + std::string adcvpp(int action); + std::string apulse(int action); + std::string asamples(int action); + std::string autocompdisable(int action); + std::string badchannels(int action); + std::string blockingtrigger(int action); + std::string burstmode(int action); + std::string burstperiod(int action); + std::string bursts(int action); + std::string burstsl(int action); + std::string bustest(int action); + std::string cdsgain(int action); + std::string chipversion(int action); + std::string clearbit(int action); + std::string clearbusy(int action); + std::string clearroi(int action); + std::string clientversion(int action); + std::string clkdiv(int action); + std::string clkfreq(int action); + std::string clkphase(int action); + std::string column(int action); + std::string compdisabletime(int action); + std::string confadc(int action); + std::string config(int action); + std::string counters(int action); + std::string currentsource(int action); + std::string dac(int action); + std::string dacindex(int action); + std::string daclist(int action); + std::string dacname(int action); + std::string dacvalues(int action); + std::string datastream(int action); + std::string dbitclk(int action); + std::string dbitphase(int action); + std::string dbitpipeline(int action); + std::string defaultdac(int action); + std::string defaultpattern(int action); + std::string delay(int action); + std::string delayl(int action); + std::string detectorserverversion(int action); + std::string detsize(int action); + std::string diodelay(int action); + std::string dpulse(int action); + std::string dr(int action); + std::string drlist(int action); + std::string dsamples(int action); + std::string execcommand(int action); + std::string exptime(int action); + std::string exptime1(int action); + std::string exptime2(int action); + std::string exptime3(int action); + std::string exptimel(int action); + std::string extrastoragecells(int action); + std::string extsampling(int action); + std::string extsamplingsrc(int action); + std::string extsig(int action); + std::string fformat(int action); + std::string filtercells(int action); + std::string filterresistor(int action); + std::string findex(int action); + std::string firmwaretest(int action); + std::string firmwareversion(int action); + std::string fliprows(int action); + std::string flowcontrol10g(int action); + std::string fmaster(int action); + std::string fname(int action); + std::string foverwrite(int action); + std::string fpath(int action); + std::string framecounter(int action); + std::string frames(int action); + std::string framesl(int action); + std::string frametime(int action); + std::string free(int action); + std::string fwrite(int action); + std::string gaincaps(int action); + std::string gainmode(int action); + std::string gappixels(int action); + std::string gatedelay(int action); + std::string gatedelay1(int action); + std::string gatedelay2(int action); + std::string gatedelay3(int action); + std::string gates(int action); + std::string getbit(int action); + std::string hardwareversion(int action); + std::string highvoltage(int action); + std::string hostname(int action); + std::string im_a(int action); + std::string im_b(int action); + std::string im_c(int action); + std::string im_d(int action); + std::string im_io(int action); + std::string imagetest(int action); + std::string initialchecks(int action); + std::string inj_ch(int action); + std::string interpolation(int action); + std::string interruptsubframe(int action); + std::string kernelversion(int action); + std::string lastclient(int action); + std::string led(int action); + std::string lock(int action); + std::string master(int action); + std::string maxadcphaseshift(int action); + std::string maxclkphaseshift(int action); + std::string maxdbitphaseshift(int action); + std::string measuredperiod(int action); + std::string measuredsubperiod(int action); + std::string moduleid(int action); + std::string nextframenumber(int action); + std::string nmod(int action); + std::string numinterfaces(int action); + std::string overflow(int action); + std::string packageversion(int action); + std::string parallel(int action); + std::string parameters(int action); + std::string partialreset(int action); + std::string patfname(int action); + std::string patioctrl(int action); + std::string patlimits(int action); + std::string patloop(int action); + std::string patloop0(int action); + std::string patloop1(int action); + std::string patloop2(int action); + std::string patmask(int action); + std::string patnloop(int action); + std::string patnloop0(int action); + std::string patnloop1(int action); + std::string patnloop2(int action); + std::string patsetbit(int action); + std::string pattern(int action); + std::string patternstart(int action); + std::string patwait(int action); + std::string patwait0(int action); + std::string patwait1(int action); + std::string patwait2(int action); + std::string patwaittime(int action); + std::string patwaittime0(int action); + std::string patwaittime1(int action); + std::string patwaittime2(int action); + std::string patword(int action); + std::string pedestalmode(int action); + std::string period(int action); + std::string periodl(int action); + std::string polarity(int action); + std::string port(int action); + std::string powerchip(int action); + std::string powerindex(int action); + std::string powerlist(int action); + std::string powername(int action); + std::string powervalues(int action); + std::string programfpga(int action); + std::string pulse(int action); + std::string pulsechip(int action); + std::string pulsenmove(int action); + std::string pumpprobe(int action); + std::string quad(int action); + std::string ratecorr(int action); + std::string readnrows(int action); + std::string readout(int action); + std::string readoutspeed(int action); + std::string readoutspeedlist(int action); + std::string rebootcontroller(int action); + std::string reg(int action); + std::string resetdacs(int action); + std::string resetfpga(int action); + std::string roi(int action); + std::string romode(int action); + std::string row(int action); + std::string runclk(int action); + std::string runtime(int action); + std::string rx_arping(int action); + std::string rx_clearroi(int action); + std::string rx_dbitlist(int action); + std::string rx_dbitoffset(int action); + std::string rx_discardpolicy(int action); + std::string rx_fifodepth(int action); + std::string rx_frameindex(int action); + std::string rx_framescaught(int action); + std::string rx_framesperfile(int action); + std::string rx_hostname(int action); + std::string rx_jsonaddheader(int action); + std::string rx_jsonpara(int action); + std::string rx_lastclient(int action); + std::string rx_lock(int action); + std::string rx_missingpackets(int action); + std::string rx_padding(int action); + std::string rx_printconfig(int action); + std::string rx_realudpsocksize(int action); + std::string rx_roi(int action); + std::string rx_silent(int action); + std::string rx_start(int action); + std::string rx_status(int action); + std::string rx_stop(int action); + std::string rx_tcpport(int action); + std::string rx_threads(int action); + std::string rx_udpsocksize(int action); + std::string rx_version(int action); + std::string rx_zmqfreq(int action); + std::string rx_zmqhwm(int action); + std::string rx_zmqip(int action); + std::string rx_zmqport(int action); + std::string rx_zmqstartfnum(int action); + std::string rx_zmqstream(int action); + std::string samples(int action); + std::string savepattern(int action); + std::string scan(int action); + std::string scanerrmsg(int action); + std::string selinterface(int action); + std::string serialnumber(int action); + std::string setbit(int action); + std::string settings(int action); + std::string settingslist(int action); + std::string settingspath(int action); + std::string signalindex(int action); + std::string signallist(int action); + std::string signalname(int action); + std::string slowadc(int action); + std::string slowadcindex(int action); + std::string slowadclist(int action); + std::string slowadcname(int action); + std::string slowadcvalues(int action); + std::string start(int action); + std::string status(int action); + std::string stop(int action); + std::string stopport(int action); + std::string storagecell_delay(int action); + std::string storagecell_start(int action); + std::string subdeadtime(int action); + std::string subexptime(int action); + std::string sync(int action); + std::string syncclk(int action); + std::string temp_10ge(int action); + std::string temp_adc(int action); + std::string temp_control(int action); + std::string temp_dcdc(int action); + std::string temp_event(int action); + std::string temp_fpga(int action); + std::string temp_fpgaext(int action); + std::string temp_fpgafl(int action); + std::string temp_fpgafr(int action); + std::string temp_slowadc(int action); + std::string temp_sodl(int action); + std::string temp_sodr(int action); + std::string temp_threshold(int action); + std::string templist(int action); + std::string tempvalues(int action); + std::string tengiga(int action); + std::string threshold(int action); + std::string timing(int action); + std::string timinglist(int action); + std::string timingsource(int action); + std::string top(int action); + std::string transceiverenable(int action); + std::string trigger(int action); + std::string triggers(int action); + std::string triggersl(int action); + std::string trimbits(int action); + std::string trimen(int action); + std::string trimval(int action); + std::string tsamples(int action); + std::string txdelay(int action); + std::string txdelay_frame(int action); + std::string txdelay_left(int action); + std::string txdelay_right(int action); + std::string type(int action); + std::string udp_cleardst(int action); + std::string udp_dstip(int action); + std::string udp_dstip2(int action); + std::string udp_dstlist(int action); + std::string udp_dstmac(int action); + std::string udp_dstmac2(int action); + std::string udp_dstport(int action); + std::string udp_dstport2(int action); + std::string udp_firstdst(int action); + std::string udp_numdst(int action); + std::string udp_reconfigure(int action); + std::string udp_srcip(int action); + std::string udp_srcip2(int action); + std::string udp_srcmac(int action); + std::string udp_srcmac2(int action); + std::string udp_validate(int action); + std::string update(int action); + std::string updatedetectorserver(int action); + std::string updatekernel(int action); + std::string updatemode(int action); + std::string user(int action); + std::string v_a(int action); + std::string v_b(int action); + std::string v_c(int action); + std::string v_chip(int action); + std::string v_d(int action); + std::string v_io(int action); + std::string v_limit(int action); + std::string vchip_comp_adc(int action); + std::string vchip_comp_fe(int action); + std::string vchip_cs(int action); + std::string vchip_opa_1st(int action); + std::string vchip_opa_fd(int action); + std::string vchip_ref_comp_fe(int action); + std::string versions(int action); + std::string veto(int action); + std::string vetoalg(int action); + std::string vetofile(int action); + std::string vetophoton(int action); + std::string vetoref(int action); + std::string vetostream(int action); + std::string virtualFunction(int action); + std::string vm_a(int action); + std::string vm_b(int action); + std::string vm_c(int action); + std::string vm_d(int action); + std::string vm_io(int action); + std::string zmqhwm(int action); + std::string zmqip(int action); + std::string zmqport(int action); + + std::vector args; + std::string cmd; + Detector *det; + int det_id{-1}; + int rx_id{-1}; + + private: + bool ReplaceIfDepreciated(std::string &command); + using FunctionMap = std::map; + using StringMap = std::map; + Detector *ptr; // pointer to the detector that executes the command + + FunctionMap functions{ + {"list", &Caller::list}, + + {"acquire", &Caller::acquire}, + {"activate", &Caller::activate}, + {"adcclk", &Caller::adcclk}, + {"adcenable", &Caller::adcenable}, + {"adcenable10g", &Caller::adcenable10g}, + {"adcindex", &Caller::adcindex}, + {"adcinvert", &Caller::adcinvert}, + {"adclist", &Caller::adclist}, + {"adcname", &Caller::adcname}, + {"adcphase", &Caller::adcphase}, + {"adcpipeline", &Caller::adcpipeline}, + {"adcreg", &Caller::adcreg}, + {"adcvpp", &Caller::adcvpp}, + {"apulse", &Caller::apulse}, + {"asamples", &Caller::asamples}, + {"autocompdisable", &Caller::autocompdisable}, + {"badchannels", &Caller::badchannels}, + {"blockingtrigger", &Caller::blockingtrigger}, + {"burstmode", &Caller::burstmode}, + {"burstperiod", &Caller::burstperiod}, + {"bursts", &Caller::bursts}, + {"burstsl", &Caller::burstsl}, + {"bustest", &Caller::bustest}, + {"cdsgain", &Caller::cdsgain}, + {"chipversion", &Caller::chipversion}, + {"clearbit", &Caller::clearbit}, + {"clearbusy", &Caller::clearbusy}, + {"clearroi", &Caller::clearroi}, + {"clientversion", &Caller::clientversion}, + {"clkdiv", &Caller::clkdiv}, + {"clkfreq", &Caller::clkfreq}, + {"clkphase", &Caller::clkphase}, + {"column", &Caller::column}, + {"compdisabletime", &Caller::compdisabletime}, + {"confadc", &Caller::confadc}, + {"config", &Caller::config}, + {"counters", &Caller::counters}, + {"currentsource", &Caller::currentsource}, + {"dac", &Caller::dac}, + {"dacindex", &Caller::dacindex}, + {"daclist", &Caller::daclist}, + {"dacname", &Caller::dacname}, + {"dacvalues", &Caller::dacvalues}, + {"datastream", &Caller::datastream}, + {"dbitclk", &Caller::dbitclk}, + {"dbitphase", &Caller::dbitphase}, + {"dbitpipeline", &Caller::dbitpipeline}, + {"defaultdac", &Caller::defaultdac}, + {"defaultpattern", &Caller::defaultpattern}, + {"delay", &Caller::delay}, + {"delayl", &Caller::delayl}, + {"detectorserverversion", &Caller::detectorserverversion}, + {"detsize", &Caller::detsize}, + {"diodelay", &Caller::diodelay}, + {"dpulse", &Caller::dpulse}, + {"dr", &Caller::dr}, + {"drlist", &Caller::drlist}, + {"dsamples", &Caller::dsamples}, + {"execcommand", &Caller::execcommand}, + {"exptime", &Caller::exptime}, + {"exptime1", &Caller::exptime1}, + {"exptime2", &Caller::exptime2}, + {"exptime3", &Caller::exptime3}, + {"exptimel", &Caller::exptimel}, + {"extrastoragecells", &Caller::extrastoragecells}, + {"extsampling", &Caller::extsampling}, + {"extsamplingsrc", &Caller::extsamplingsrc}, + {"extsig", &Caller::extsig}, + {"fformat", &Caller::fformat}, + {"filtercells", &Caller::filtercells}, + {"filterresistor", &Caller::filterresistor}, + {"findex", &Caller::findex}, + {"firmwaretest", &Caller::firmwaretest}, + {"firmwareversion", &Caller::firmwareversion}, + {"fliprows", &Caller::fliprows}, + {"flowcontrol10g", &Caller::flowcontrol10g}, + {"fmaster", &Caller::fmaster}, + {"fname", &Caller::fname}, + {"foverwrite", &Caller::foverwrite}, + {"fpath", &Caller::fpath}, + {"framecounter", &Caller::framecounter}, + {"frames", &Caller::frames}, + {"framesl", &Caller::framesl}, + {"frametime", &Caller::frametime}, + {"free", &Caller::free}, + {"fwrite", &Caller::fwrite}, + {"gaincaps", &Caller::gaincaps}, + {"gainmode", &Caller::gainmode}, + {"gappixels", &Caller::gappixels}, + {"gatedelay", &Caller::gatedelay}, + {"gatedelay1", &Caller::gatedelay1}, + {"gatedelay2", &Caller::gatedelay2}, + {"gatedelay3", &Caller::gatedelay3}, + {"gates", &Caller::gates}, + {"getbit", &Caller::getbit}, + {"hardwareversion", &Caller::hardwareversion}, + {"highvoltage", &Caller::highvoltage}, + {"hostname", &Caller::hostname}, + {"im_a", &Caller::im_a}, + {"im_b", &Caller::im_b}, + {"im_c", &Caller::im_c}, + {"im_d", &Caller::im_d}, + {"im_io", &Caller::im_io}, + {"imagetest", &Caller::imagetest}, + {"initialchecks", &Caller::initialchecks}, + {"inj_ch", &Caller::inj_ch}, + {"interpolation", &Caller::interpolation}, + {"interruptsubframe", &Caller::interruptsubframe}, + {"kernelversion", &Caller::kernelversion}, + {"lastclient", &Caller::lastclient}, + {"led", &Caller::led}, + {"lock", &Caller::lock}, + {"master", &Caller::master}, + {"maxadcphaseshift", &Caller::maxadcphaseshift}, + {"maxclkphaseshift", &Caller::maxclkphaseshift}, + {"maxdbitphaseshift", &Caller::maxdbitphaseshift}, + {"measuredperiod", &Caller::measuredperiod}, + {"measuredsubperiod", &Caller::measuredsubperiod}, + {"moduleid", &Caller::moduleid}, + {"nextframenumber", &Caller::nextframenumber}, + {"nmod", &Caller::nmod}, + {"numinterfaces", &Caller::numinterfaces}, + {"overflow", &Caller::overflow}, + {"packageversion", &Caller::packageversion}, + {"parallel", &Caller::parallel}, + {"parameters", &Caller::parameters}, + {"partialreset", &Caller::partialreset}, + {"patfname", &Caller::patfname}, + {"patioctrl", &Caller::patioctrl}, + {"patlimits", &Caller::patlimits}, + {"patloop", &Caller::patloop}, + {"patloop0", &Caller::patloop0}, + {"patloop1", &Caller::patloop1}, + {"patloop2", &Caller::patloop2}, + {"patmask", &Caller::patmask}, + {"patnloop", &Caller::patnloop}, + {"patnloop0", &Caller::patnloop0}, + {"patnloop1", &Caller::patnloop1}, + {"patnloop2", &Caller::patnloop2}, + {"patsetbit", &Caller::patsetbit}, + {"patternX", &Caller::pattern}, + {"patternstart", &Caller::patternstart}, + {"patwait", &Caller::patwait}, + {"patwait0", &Caller::patwait0}, + {"patwait1", &Caller::patwait1}, + {"patwait2", &Caller::patwait2}, + {"patwaittime", &Caller::patwaittime}, + {"patwaittime0", &Caller::patwaittime0}, + {"patwaittime1", &Caller::patwaittime1}, + {"patwaittime2", &Caller::patwaittime2}, + {"patword", &Caller::patword}, + {"pedestalmode", &Caller::pedestalmode}, + {"period", &Caller::period}, + {"periodl", &Caller::periodl}, + {"polarity", &Caller::polarity}, + {"port", &Caller::port}, + {"powerchip", &Caller::powerchip}, + {"powerindex", &Caller::powerindex}, + {"powerlist", &Caller::powerlist}, + {"powername", &Caller::powername}, + {"powervalues", &Caller::powervalues}, + {"programfpga", &Caller::programfpga}, + {"pulse", &Caller::pulse}, + {"pulsechip", &Caller::pulsechip}, + {"pulsenmove", &Caller::pulsenmove}, + {"pumpprobe", &Caller::pumpprobe}, + {"quad", &Caller::quad}, + {"ratecorr", &Caller::ratecorr}, + {"readnrows", &Caller::readnrows}, + {"readout", &Caller::readout}, + {"readoutspeed", &Caller::readoutspeed}, + {"readoutspeedlist", &Caller::readoutspeedlist}, + {"rebootcontroller", &Caller::rebootcontroller}, + {"reg", &Caller::reg}, + {"resetdacs", &Caller::resetdacs}, + {"resetfpga", &Caller::resetfpga}, + {"roi", &Caller::roi}, + {"romode", &Caller::romode}, + {"row", &Caller::row}, + {"runclk", &Caller::runclk}, + {"runtime", &Caller::runtime}, + {"rx_arping", &Caller::rx_arping}, + {"rx_clearroi", &Caller::rx_clearroi}, + {"rx_dbitlist", &Caller::rx_dbitlist}, + {"rx_dbitoffset", &Caller::rx_dbitoffset}, + {"rx_discardpolicy", &Caller::rx_discardpolicy}, + {"rx_fifodepth", &Caller::rx_fifodepth}, + {"rx_frameindex", &Caller::rx_frameindex}, + {"rx_framescaught", &Caller::rx_framescaught}, + {"rx_framesperfile", &Caller::rx_framesperfile}, + {"rx_hostname", &Caller::rx_hostname}, + {"rx_jsonaddheader", &Caller::rx_jsonaddheader}, + {"rx_jsonpara", &Caller::rx_jsonpara}, + {"rx_lastclient", &Caller::rx_lastclient}, + {"rx_lock", &Caller::rx_lock}, + {"rx_missingpackets", &Caller::rx_missingpackets}, + {"rx_padding", &Caller::rx_padding}, + {"rx_printconfig", &Caller::rx_printconfig}, + {"rx_realudpsocksize", &Caller::rx_realudpsocksize}, + {"rx_roi", &Caller::rx_roi}, + {"rx_silent", &Caller::rx_silent}, + {"rx_start", &Caller::rx_start}, + {"rx_status", &Caller::rx_status}, + {"rx_stop", &Caller::rx_stop}, + {"rx_tcpport", &Caller::rx_tcpport}, + {"rx_threads", &Caller::rx_threads}, + {"rx_udpsocksize", &Caller::rx_udpsocksize}, + {"rx_version", &Caller::rx_version}, + {"rx_zmqfreq", &Caller::rx_zmqfreq}, + {"rx_zmqhwm", &Caller::rx_zmqhwm}, + {"rx_zmqip", &Caller::rx_zmqip}, + {"rx_zmqport", &Caller::rx_zmqport}, + {"rx_zmqstartfnum", &Caller::rx_zmqstartfnum}, + {"rx_zmqstream", &Caller::rx_zmqstream}, + {"samples", &Caller::samples}, + {"savepattern", &Caller::savepattern}, + {"scan", &Caller::scan}, + {"scanerrmsg", &Caller::scanerrmsg}, + {"selinterface", &Caller::selinterface}, + {"serialnumber", &Caller::serialnumber}, + {"setbit", &Caller::setbit}, + {"settings", &Caller::settings}, + {"settingslist", &Caller::settingslist}, + {"settingspath", &Caller::settingspath}, + {"signalindex", &Caller::signalindex}, + {"signallist", &Caller::signallist}, + {"signalname", &Caller::signalname}, + {"slowadc", &Caller::slowadc}, + {"slowadcindex", &Caller::slowadcindex}, + {"slowadclist", &Caller::slowadclist}, + {"slowadcname", &Caller::slowadcname}, + {"slowadcvalues", &Caller::slowadcvalues}, + {"start", &Caller::start}, + {"status", &Caller::status}, + {"stop", &Caller::stop}, + {"stopport", &Caller::stopport}, + {"storagecell_delay", &Caller::storagecell_delay}, + {"storagecell_start", &Caller::storagecell_start}, + {"subdeadtime", &Caller::subdeadtime}, + {"subexptime", &Caller::subexptime}, + {"sync", &Caller::sync}, + {"syncclk", &Caller::syncclk}, + {"temp_10ge", &Caller::temp_10ge}, + {"temp_adc", &Caller::temp_adc}, + {"temp_control", &Caller::temp_control}, + {"temp_dcdc", &Caller::temp_dcdc}, + {"temp_event", &Caller::temp_event}, + {"temp_fpga", &Caller::temp_fpga}, + {"temp_fpgaext", &Caller::temp_fpgaext}, + {"temp_fpgafl", &Caller::temp_fpgafl}, + {"temp_fpgafr", &Caller::temp_fpgafr}, + {"temp_slowadc", &Caller::temp_slowadc}, + {"temp_sodl", &Caller::temp_sodl}, + {"temp_sodr", &Caller::temp_sodr}, + {"temp_threshold", &Caller::temp_threshold}, + {"templist", &Caller::templist}, + {"tempvalues", &Caller::tempvalues}, + {"tengiga", &Caller::tengiga}, + {"threshold", &Caller::threshold}, + {"thresholdnotb", &Caller::threshold}, + {"timing", &Caller::timing}, + {"timinglist", &Caller::timinglist}, + {"timingsource", &Caller::timingsource}, + {"top", &Caller::top}, + {"transceiverenable", &Caller::transceiverenable}, + {"trigger", &Caller::trigger}, + {"triggers", &Caller::triggers}, + {"triggersl", &Caller::triggersl}, + {"trimbits", &Caller::trimbits}, + {"trimen", &Caller::trimen}, + {"trimval", &Caller::trimval}, + {"tsamples", &Caller::tsamples}, + {"txdelay", &Caller::txdelay}, + {"txdelay_frame", &Caller::txdelay_frame}, + {"txdelay_left", &Caller::txdelay_left}, + {"txdelay_right", &Caller::txdelay_right}, + {"type", &Caller::type}, + {"udp_cleardst", &Caller::udp_cleardst}, + {"udp_dstip", &Caller::udp_dstip}, + {"udp_dstip2", &Caller::udp_dstip2}, + {"udp_dstlist", &Caller::udp_dstlist}, + {"udp_dstmac", &Caller::udp_dstmac}, + {"udp_dstmac2", &Caller::udp_dstmac2}, + {"udp_dstport", &Caller::udp_dstport}, + {"udp_dstport2", &Caller::udp_dstport2}, + {"udp_firstdst", &Caller::udp_firstdst}, + {"udp_numdst", &Caller::udp_numdst}, + {"udp_reconfigure", &Caller::udp_reconfigure}, + {"udp_srcip", &Caller::udp_srcip}, + {"udp_srcip2", &Caller::udp_srcip2}, + {"udp_srcmac", &Caller::udp_srcmac}, + {"udp_srcmac2", &Caller::udp_srcmac2}, + {"udp_validate", &Caller::udp_validate}, + {"update", &Caller::update}, + {"updatedetectorserver", &Caller::updatedetectorserver}, + {"updatekernel", &Caller::updatekernel}, + {"updatemode", &Caller::updatemode}, + {"user", &Caller::user}, + {"v_a", &Caller::v_a}, + {"v_b", &Caller::v_b}, + {"v_c", &Caller::v_c}, + {"v_chip", &Caller::v_chip}, + {"v_d", &Caller::v_d}, + {"v_io", &Caller::v_io}, + {"v_limit", &Caller::v_limit}, + {"vchip_comp_adc", &Caller::vchip_comp_adc}, + {"vchip_comp_fe", &Caller::vchip_comp_fe}, + {"vchip_cs", &Caller::vchip_cs}, + {"vchip_opa_1st", &Caller::vchip_opa_1st}, + {"vchip_opa_fd", &Caller::vchip_opa_fd}, + {"vchip_ref_comp_fe", &Caller::vchip_ref_comp_fe}, + {"versions", &Caller::versions}, + {"veto", &Caller::veto}, + {"vetoalg", &Caller::vetoalg}, + {"vetofile", &Caller::vetofile}, + {"vetophoton", &Caller::vetophoton}, + {"vetoref", &Caller::vetoref}, + {"vetostream", &Caller::vetostream}, + {"virtual", &Caller::virtualFunction}, + {"vm_a", &Caller::vm_a}, + {"vm_b", &Caller::vm_b}, + {"vm_c", &Caller::vm_c}, + {"vm_d", &Caller::vm_d}, + {"vm_io", &Caller::vm_io}, + {"zmqhwm", &Caller::zmqhwm}, + {"zmqip", &Caller::zmqip}, + {"zmqport", &Caller::zmqport} + + }; + + StringMap depreciated_functions{ + + {"detectorversion", "firmwareversion"}, + {"softwareversion", "detectorserverversion"}, + {"receiverversion", "rx_version"}, + {"detectornumber", "serialnumber"}, + {"thisversion", "clientversion"}, + {"detsizechan", "detsize"}, + {"trimdir", "settingspath"}, + {"settingsdir", "settingspath"}, + {"flippeddatax", "fliprows"}, + {"cycles", "triggers"}, + {"cyclesl", "triggersl"}, + {"clkdivider", "readoutspeed"}, + {"speed", "readoutspeed"}, + {"vhighvoltage", "highvoltage"}, + {"digitest", "imagetest"}, + {"filter", "filterresistor"}, + {"readnlines", "readnrows"}, + {"vtr", "vtrim"}, + {"vrf", "vrpreamp"}, + {"vrs", "vrshaper"}, + {"vcall", "vcal"}, + {"vis", "vishaper"}, + {"vshaper", "vrshaper"}, + {"vpreamp", "vrpreamp"}, + {"vshaperneg", "vrshaper_n"}, + {"viinsh", "vishaper"}, + {"vpl", "vcal_n"}, + {"vph", "vcal_p"}, + {"vthreshold", "dac"}, + {"vsvp", "dac"}, + {"vsvn", "dac"}, + {"vtrim", "dac"}, + {"vrpreamp", "dac"}, + {"vrshaper", "dac"}, + {"vtgstv", "dac"}, + {"vcmp_ll", "dac"}, + {"vcmp_lr", "dac"}, + {"vcal", "dac"}, + {"vcmp_rl", "dac"}, + {"vcmp_rr", "dac"}, + {"rxb_rb", "dac"}, + {"rxb_lb", "dac"}, + {"vcp", "dac"}, + {"vcn", "dac"}, + {"vishaper", "dac"}, + {"iodelay", "dac"}, + {"vref_ds", "dac"}, + {"vcascn_pb", "dac"}, + {"vcascp_pb", "dac"}, + {"vout_cm", "dac"}, + {"vcasc_out", "dac"}, + {"vin_cm", "dac"}, + {"vref_comp", "dac"}, + {"ib_test_c", "dac"}, + {"vrshaper_n", "dac"}, + {"vipre", "dac"}, + {"vdcsh", "dac"}, + {"vth1", "dac"}, + {"vth2", "dac"}, + {"vth3", "dac"}, + {"vcal_n", "dac"}, + {"vcal_p", "dac"}, + {"vcassh", "dac"}, + {"vcas", "dac"}, + {"vicin", "dac"}, + {"vipre_out", "dac"}, + {"vref_h_adc", "dac"}, + {"vb_comp_fe", "dac"}, + {"vb_comp_adc", "dac"}, + {"vcom_cds", "dac"}, + {"vref_rstore", "dac"}, + {"vb_opa_1st", "dac"}, + {"vref_comp_fe", "dac"}, + {"vcom_adc1", "dac"}, + {"vref_prech", "dac"}, + {"vref_l_adc", "dac"}, + {"vref_cds", "dac"}, + {"vb_cs", "dac"}, + {"vb_opa_fd", "dac"}, + {"vcom_adc2", "dac"}, + {"vb_ds", "dac"}, + {"vb_comp", "dac"}, + {"vb_pixbuf", "dac"}, + {"vin_com", "dac"}, + {"vdd_prot", "dac"}, + {"vbp_colbuf", "dac"}, + {"vb_sda", "dac"}, + {"vcasc_sfp", "dac"}, + {"vipre_cds", "dac"}, + {"ibias_sfp", "dac"}, + {"defaultdacs", "resetdacs"}, + {"busy", "clearbusy"}, + {"receiver", "rx_status"}, + {"framescaught", "rx_framescaught"}, + {"startingfnum", "nextframenumber"}, + {"detectorip", "udp_srcip"}, + {"detectorip2", "udp_srcip2"}, + {"detectormac", "udp_srcmac"}, + {"detectormac2", "udp_srcmac2"}, + {"rx_udpip", "udp_dstip"}, + {"rx_udpip2", "udp_dstip2"}, + {"rx_udpmac", "udp_dstmac"}, + {"rx_udpmac2", "udp_dstmac2"}, + {"rx_udpport", "udp_dstport"}, + {"rx_udpport2", "udp_dstport2"}, + {"flowcontrol_10g", "flowcontrol10g"}, + {"txndelay_frame", "txdelay_frame"}, + {"txndelay_left", "txdelay_left"}, + {"txndelay_right", "txdelay_right"}, + {"r_silent", "rx_silent"}, + {"r_discardpolicy", "rx_discardpolicy"}, + {"r_padding", "rx_padding"}, + {"r_lock", "rx_lock"}, + {"r_lastclient", "rx_lastclient"}, + {"fileformat", "fformat"}, + {"outdir", "fpath"}, + {"index", "findex"}, + {"enablefwrite", "fwrite"}, + {"masterfile", "fmaster"}, + {"overwrite", "foverwrite"}, + {"r_framesperfile", "rx_framesperfile"}, + {"r_readfreq", "rx_zmqfreq"}, + {"rx_readfreq", "rx_zmqfreq"}, + {"rx_datastream", "rx_zmqstream"}, + {"resmat", "partialreset"}, + {"storagecells", "extrastoragecells"}, + {"auto_comp_disable", "autocompdisable"}, + {"comp_disable_time", "compdisabletime"}, + {"adc", "slowadc"}, + {"flags", "romode"}, + {"i_a", "im_a"}, + {"i_b", "im_b"}, + {"i_c", "im_c"}, + {"i_d", "im_d"}, + {"i_io", "im_io"}, + {"copydetectorserver", "updatedetectorserver"}, + {"nframes", "framecounter"}, + {"now", "runtime"}, + {"timestamp", "frametime"}, + {"frameindex", "rx_frameindex"}, + + }; +}; + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/src/CallerSpecial.cpp b/slsDetectorSoftware/src/CallerSpecial.cpp new file mode 100644 index 000000000..dfd5a0d68 --- /dev/null +++ b/slsDetectorSoftware/src/CallerSpecial.cpp @@ -0,0 +1,1154 @@ +#include "Caller.h" +#include "sls/bit_utils.h" +#include "sls/file_utils.h" +#include "sls/logger.h" +#include "sls/string_utils.h" +#include +namespace sls { +// some helper functions to print + +std::vector Caller::getAllCommands() { + std::vector ret; + for (auto it : functions) + ret.push_back(it.first); + return ret; +} + +void Caller::call(const std::string &command, + const std::vector &arguments, int detector_id, + int action, std::ostream &os, int receiver_id) { + cmd = command; + args = arguments; // copy args before replacing + std::string temp; + while (temp != cmd) { + temp = cmd; + ReplaceIfDepreciated(cmd); + } + + det_id = detector_id; + rx_id = receiver_id; + auto it = functions.find(cmd); + if (it != functions.end()) { + auto ret = ((*this).*(it->second))(action); + os << cmd << ' ' << ret; + } else { + throw RuntimeError(cmd + + " Unknown command, use list to list all commands"); + } +} + +bool Caller::ReplaceIfDepreciated(std::string &command) { + auto d_it = depreciated_functions.find(command); + if (d_it != depreciated_functions.end()) { + + // insert old command into arguments (for dacs) + if (d_it->second == "dac") { + args.insert(args.begin(), command); + LOG(logWARNING) + << command + << " is deprecated and will be removed. Please migrate to: " + << d_it->second << " " << command; + } else { + LOG(logWARNING) + << command + << " is deprecated and will be removed. Please migrate to: " + << d_it->second; + } + command = d_it->second; + return true; + } + return false; +} + +std::string Caller::list(int action) { + std::string ret = "free\n"; + for (auto &f : functions) { + ret += f.first + "\n"; + } + + return ret; +} + +/* Network Configuration (Detector<->Receiver) */ + +IpAddr Caller::getDstIpFromAuto() { + std::string rxHostname = + det->getRxHostname(std::vector{det_id}).squash("none"); + // Hostname could be ip try to decode otherwise look up the hostname + auto val = IpAddr{rxHostname}; + if (val == 0) { + val = HostnameToIp(rxHostname.c_str()); + } + return val; +} + +IpAddr Caller::getSrcIpFromAuto() { + if (det->getDetectorType().squash() == defs::GOTTHARD) { + throw RuntimeError( + "Cannot use 'auto' for udp_srcip for GotthardI Detector."); + } + std::string hostname = + det->getHostname(std::vector{det_id}).squash("none"); + // Hostname could be ip try to decode otherwise look up the hostname + auto val = IpAddr{hostname}; + if (val == 0) { + val = HostnameToIp(hostname.c_str()); + } + return val; +} + +UdpDestination Caller::getUdpEntry() { + UdpDestination udpDestination{}; + udpDestination.entry = rx_id; + + for (auto it : args) { + size_t pos = it.find('='); + std::string key = it.substr(0, pos); + std::string value = it.substr(pos + 1); + if (key == "ip") { + if (value == "auto") { + auto val = getDstIpFromAuto(); + LOG(logINFO) << "Setting udp_dstip of detector " << det_id + << " to " << val; + udpDestination.ip = val; + } else { + udpDestination.ip = IpAddr(value); + } + } else if (key == "ip2") { + if (value == "auto") { + auto val = getDstIpFromAuto(); + LOG(logINFO) << "Setting udp_dstip2 of detector " << det_id + << " to " << val; + udpDestination.ip2 = val; + } else { + udpDestination.ip2 = IpAddr(value); + } + } else if (key == "mac") { + udpDestination.mac = MacAddr(value); + } else if (key == "mac2") { + udpDestination.mac2 = MacAddr(value); + } else if (key == "port") { + udpDestination.port = StringTo(value); + } else if (key == "port2") { + udpDestination.port2 = StringTo(value); + } + } + return udpDestination; +} +void Caller::WrongNumberOfParameters(size_t expected) { + if (expected == 0) { + throw RuntimeError("Command " + cmd + + " expected no parameter/s but got " + + std::to_string(args.size()) + "\n"); + } + throw RuntimeError("Command " + cmd + " expected (or >=) " + + std::to_string(expected) + " parameter/s but got " + + std::to_string(args.size()) + "\n"); +} + +void Caller::GetLevelAndUpdateArgIndex(int action, + std::string levelSeparatedCommand, + int &level, int &iArg, size_t nGetArgs, + size_t nPutArgs) { + if (cmd == levelSeparatedCommand) { + ++nGetArgs; + ++nPutArgs; + } else { + LOG(logWARNING) << "This command is deprecated and will be removed. " + "Please migrate to " + << levelSeparatedCommand; + } + if (action == defs::GET_ACTION && args.size() != nGetArgs) { + WrongNumberOfParameters(nGetArgs); + } else if (action == defs::PUT_ACTION && args.size() != nPutArgs) { + WrongNumberOfParameters(nPutArgs); + } + if (cmd == levelSeparatedCommand) { + level = StringTo(args[iArg++]); + } else { + level = cmd[cmd.find_first_of("012")] - '0'; + } +} + +std::string Caller::free(int action) { + // This function is purely for help, actual functionality is in the caller + return "free\n\tFree detector shared memory\n"; +} + +std::string Caller::hostname(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "\n\tFrees shared memory and sets hostname (or IP address) of " + "all modules concatenated by +.\n\t Virtual servers can already " + "use the port in hostname separated by ':' and ports incremented " + "by 2 to accomodate the stop server as well." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getHostname(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.empty()) { + WrongNumberOfParameters(1); + } + if (det_id != -1) { + throw RuntimeError("Cannot execute this at module level"); + } + // only args[0], but many hostames concatenated with + + if (args[0].find('+') != std::string::npos) { + auto t = split(args[0], '+'); + det->setHostname(t); + os << ToString(t) << '\n'; + } + // either hostnames separated by space, or single hostname + else { + det->setHostname(args); + os << ToString(args) << '\n'; + } + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::acquire(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << cmd + << "\n\tAcquire the number of frames set up.\n\tBlocking command, " + "where control server is blocked and cannot accept other " + "commands until acquisition is done. \n\t- sets acquiring " + "flag\n\t- starts the receiver listener (if enabled)\n\t- starts " + "detector acquisition for number of frames set\n\t- monitors " + "detector status from running to idle\n\t- stops the receiver " + "listener (if enabled)\n\t- increments file index if file write " + "enabled\n\t- resets acquiring flag" + << '\n'; + } else { + if (det->empty()) { + throw RuntimeError("This shared memory has no detectors added."); + } + if (det_id >= 0) { + throw RuntimeError("Individual detectors not allowed for readout."); + } + + det->acquire(); + + if (det->getUseReceiverFlag().squash(false)) { + os << "\nAcquired "; + os << det->getFramesCaught() << '\n'; + } + } + return os.str(); +} +std::string Caller::versions(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "\n\tPrint all versions and detector type" << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + bool eiger = (det->getDetectorType().squash() == defs::EIGER); + auto t = det->getFirmwareVersion(std::vector{det_id}); + os << "\nType : " << OutString(det->getDetectorType()) + << "\nRelease : " << det->getPackageVersion() << std::hex + << "\nClient : " << det->getClientVersion(); + + if (eiger) { + os << "\nFirmware (Beb) : " + << OutString(det->getFirmwareVersion(std::vector{det_id})); + os << "\nFirmware (Febl) : " + << OutString(det->getFrontEndFirmwareVersion( + defs::FRONT_LEFT, std::vector{det_id})); + os << "\nFirmware (Febr) : " + << OutString(det->getFrontEndFirmwareVersion( + defs::FRONT_RIGHT, std::vector{det_id})); + } else { + os << "\nFirmware : " + << OutStringHex( + det->getFirmwareVersion(std::vector{det_id})); + } + + os << "\nServer : " + << OutString(det->getDetectorServerVersion(std::vector{det_id})) + << "\nKernel : " + << OutString(det->getKernelVersion({std::vector{det_id}})) + << "\nHardware : " + << OutString(det->getHardwareVersion(std::vector{det_id})); + + if (det->getUseReceiverFlag().squash(true)) { + os << "\nReceiver : " + << OutString(det->getReceiverVersion(std::vector{det_id})); + } + os << std::dec << '\n'; + } else if (action == defs::PUT_ACTION) { + throw RuntimeError("cannot put"); + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::threshold(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[eV] [(optinal settings)" + "\n\t[Eiger][Mythen3] Threshold in eV. It loads trim files from " + "settingspath."; + if (cmd == "thresholdnotb") { + os << "Trimbits are not loaded."; + } + os << "\n\nthreshold [eV1] [eV2] [eV3] [(optional settings)]" + "\n\t[Mythen3] Threshold in eV for each counter. It loads trim " + "files from settingspath. An energy of -1 will pick up values " + " from detector."; + if (cmd == "thresholdnotb") { + os << "Trimbits are not loaded."; + } + os << '\n'; + } else if (action == defs::GET_ACTION) { + if (cmd == "thresholdnotb") { + throw RuntimeError("cannot get"); + } + if (!args.empty()) { + WrongNumberOfParameters(0); + } + defs::detectorType type = det->getDetectorType().squash(); + if (type == defs::EIGER) { + auto t = det->getThresholdEnergy(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (type == defs::MYTHEN3) { + auto t = det->getAllThresholdEnergy(std::vector{det_id}); + os << OutString(t) << '\n'; + } else { + throw RuntimeError("Not implemented for this detector\n"); + } + } else if (action == defs::PUT_ACTION) { + defs::detectorType type = det->getDetectorType().squash(); + if (type == defs::EIGER && args.size() != 1 && args.size() != 2) { + WrongNumberOfParameters(1); + } + if (type == defs::MYTHEN3 && (args.size() < 1 || args.size() > 4)) { + WrongNumberOfParameters(1); + } + + bool trimbits = (cmd == "thresholdnotb") ? false : true; + std::array energy = {StringTo(args[0]), 0, 0}; + energy[1] = energy[0]; + energy[2] = energy[0]; + defs::detectorSettings sett = defs::STANDARD; + + // check if argument has settings or get it + if (args.size() == 2 || args.size() == 4) { + sett = StringTo(args[args.size() - 1]); + } else { + sett = det->getSettings(std::vector{det_id}) + .tsquash("Inconsistent settings between detectors"); + } + + // get other threshold values + if (args.size() > 2) { + energy[1] = StringTo(args[1]); + energy[2] = StringTo(args[2]); + } + switch (type) { + case defs::EIGER: + det->setThresholdEnergy(energy[0], sett, trimbits, + std::vector{det_id}); + break; + case defs::MYTHEN3: + det->setThresholdEnergy(energy, sett, trimbits, + std::vector{det_id}); + break; + default: + throw RuntimeError("Not implemented for this detector\n"); + } + os << ToString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} + +std::string Caller::trimen(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[trim_ev1] [trim_Ev2 (optional)] [trim_ev3 (optional)] " + "...\n\t[Eiger][Mythen3] Number of trim energies and list of " + "trim " + "energies, where corresponding default trim files exist in " + "corresponding trim folders." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getTrimEnergies(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + std::vector t(args.size()); + if (!args.empty()) { + for (size_t i = 0; i < t.size(); ++i) { + t[i] = StringTo(args[i]); + } + } + det->setTrimEnergies(t, std::vector{det_id}); + os << ToString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::badchannels(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[fname|none|0]\n\t[Gotthard2][Mythen3] Sets the bad channels " + "(from file of bad channel numbers) to be masked out. None or 0 " + "unsets all the badchannels.\n\t[Mythen3] Also does trimming" + << '\n'; + } else if (action == defs::GET_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + det->getBadChannels(args[0], std::vector{det_id}); + os << "successfully retrieved" << '\n'; + } else if (action == defs::PUT_ACTION) { + bool parse = false; + if (args.size() == 0) { + WrongNumberOfParameters(1); + } else if (args.size() == 1) { + if (args[0] == "none" || args[0] == "0") { + det->setBadChannels(std::vector{}, + std::vector{det_id}); + } else if (args[0].find(".") != std::string::npos) { + det->setBadChannels(args[0], std::vector{det_id}); + } else { + parse = true; + } + } + // parse multi args or single one with range or single value + if (parse || args.size() > 1) { + // get channels + auto list = getChannelsFromStringList(args); + det->setBadChannels(list, std::vector{det_id}); + } + os << "successfully loaded" << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::udp_srcip(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[x.x.x.x] or auto\n\tIp address of the detector (source) udp " + "interface. Must be same subnet as destination udp " + "ip.\n\t[Eiger] Set only for 10G. For 1G, detector will replace " + "with its own DHCP IP address. \n\tOne can also set this to " + "'auto' for 1 GbE data and virtual detectors. It will set to IP " + "of detector. Not available for GotthardI" + << '\n'; + } else if (action == defs::GET_ACTION) { + auto t = det->getSourceUDPIP(std::vector{det_id}); + if (!args.empty()) { + WrongNumberOfParameters(0); + } + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + IpAddr val; + if (args[0] == "auto") { + val = getSrcIpFromAuto(); + LOG(logINFO) << "Setting udp_srcip of detector " << det_id << " to " + << val; + } else { + val = IpAddr(args[0]); + } + det->setSourceUDPIP(val, std::vector{det_id}); + os << val << '\n'; + + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::udp_srcip2(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[x.x.x.x] or auto\n\t[Jungfrau][Moench][Gotthard2] Ip address " + "of the " + "detector (source) udp interface 2. Must be same subnet as " + "destination udp ip2.\n\t [Jungfrau][Moench] top half or inner " + "interface\n\t [Gotthard2] veto debugging. \n\tOne can also set " + "this to 'auto' for 1 GbE data and virtual detectors. It will " + "set to IP of detector." + << '\n'; + } else if (action == defs::GET_ACTION) { + auto t = det->getSourceUDPIP2(std::vector{det_id}); + if (!args.empty()) { + WrongNumberOfParameters(0); + } + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + IpAddr val; + if (args[0] == "auto") { + val = getSrcIpFromAuto(); + LOG(logINFO) << "Setting udp_srcip2 of detector " << det_id + << " to " << val; + } else { + val = IpAddr(args[0]); + } + det->setSourceUDPIP2(val, std::vector{det_id}); + os << val << '\n'; + + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::udp_dstip(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[x.x.x.x] or auto\n\tIp address of the receiver (destination) " + "udp interface. If 'auto' used, then ip is set to ip of " + "rx_hostname." + << '\n'; + } else if (action == defs::GET_ACTION) { + auto t = det->getDestinationUDPIP(std::vector{det_id}); + if (!args.empty()) { + WrongNumberOfParameters(0); + } + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + if (args[0] == "auto") { + auto val = getDstIpFromAuto(); + LOG(logINFO) << "Setting udp_dstip of detector " << det_id << " to " + << val; + det->setDestinationUDPIP(val, std::vector{det_id}); + os << val << '\n'; + } else { + auto val = IpAddr(args[0]); + det->setDestinationUDPIP(val, std::vector{det_id}); + os << args.front() << '\n'; + } + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::udp_dstip2(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[x.x.x.x] or auto\n\t[Jungfrau][Moench][Gotthard2] Ip address " + "of the " + "receiver (destination) udp interface 2. If 'auto' used, then ip " + "is set to ip of rx_hostname.\n\t[Jungfrau][Moench] bottom half " + "\n\t[Gotthard2] veto debugging. " + << '\n'; + } else if (action == defs::GET_ACTION) { + auto t = det->getDestinationUDPIP2(std::vector{det_id}); + if (!args.empty()) { + WrongNumberOfParameters(0); + } + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + if (args[0] == "auto") { + auto val = getDstIpFromAuto(); + LOG(logINFO) << "Setting udp_dstip2 of detector " << det_id + << " to " << val; + det->setDestinationUDPIP2(val, std::vector{det_id}); + os << val << '\n'; + } else { + auto val = IpAddr(args[0]); + det->setDestinationUDPIP2(val, std::vector{det_id}); + os << args.front() << '\n'; + } + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::rx_hostname(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[hostname or ip address]\n\t" + "[hostname or ip address]:[tcp port]\n\t" + "[hostname1]:[tcp_port1]+[hostname2]:[tcp_port2]+\n\t" + "Receiver hostname or IP. If port included, then the receiver " + "tcp port.\n\t" + "Used for TCP control communication between client and receiver " + "to configure receiver. Also updates receiver with detector " + "parameters. Also resets any prior receiver property (not on " + "detector). " + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getRxHostname(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() < 1) { + WrongNumberOfParameters(1); + } + // multiple arguments + if (args.size() > 1) { + // multiple in mulitple + if (args[0].find('+') != std::string::npos) { + throw RuntimeError( + "Cannot add multiple receivers at module level"); + } + if (det_id != -1) { + throw RuntimeError( + "Cannot add multiple receivers at module level"); + } + det->setRxHostname(args); + os << ToString(args) << '\n'; + } + // single argument + else { + // multiple receivers concatenated with + + if (args[0].find('+') != std::string::npos) { + if (det_id != -1) { + throw RuntimeError( + "Cannot add multiple receivers at module level"); + } + auto t = split(args[0], '+'); + det->setRxHostname(t); + os << ToString(t) << '\n'; + } + // single receiver + else { + det->setRxHostname(args[0], std::vector{det_id}); + os << ToString(args) << '\n'; + } + } + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::rx_roi(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[xmin] [xmax] [ymin] [ymax]\n\tRegion of interest in " + "receiver.\n\tOnly allowed at multi module level and without gap " + "pixels." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + if (det_id == -1) { + auto t = det->getRxROI(); + os << t << '\n'; + } else { + auto t = det->getIndividualRxROIs(std::vector{det_id}); + os << t << '\n'; + } + } else if (action == defs::PUT_ACTION) { + defs::ROI t; + // 2 or 4 arguments + if (args.size() != 2 && args.size() != 4) { + WrongNumberOfParameters(2); + } + if (args.size() == 2 || args.size() == 4) { + t.xmin = StringTo(args[0]); + t.xmax = StringTo(args[1]); + } + if (args.size() == 4) { + t.ymin = StringTo(args[2]); + t.ymax = StringTo(args[3]); + } + // only multi level + if (det_id != -1) { + throw RuntimeError("Cannot execute receiver ROI at module level"); + } + det->setRxROI(t); + os << t << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::ratecorr(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[n_rate (in ns)]\n\t[Eiger] Dead time correction constant in " + "ns. -1 will set to default tau of settings from trimbit file. 0 " + "will unset rate correction." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getRateCorrection(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + int tau = StringTo(args[0]); + if (tau == -1) { + det->setDefaultRateCorrection(std::vector{det_id}); + auto t = det->getRateCorrection(std::vector{det_id}); + os << OutString(t) << '\n'; + } else { + auto t = StringTo(args[0], "ns"); + det->setRateCorrection(t, std::vector{det_id}); + os << args.front() << "ns\n"; + } + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::burstmode(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[burst_internal or 0, burst_external or 1, cw_internal or 2, " + "cw_external or 3]\n\t[Gotthard2] Default is burst_internal " + "type. Also changes clkdiv 2, 3, 4" + << '\n'; + } else { + if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getBurstMode(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + defs::burstMode t; + try { + int ival = StringTo(args[0]); + switch (ival) { + case 0: + t = defs::BURST_INTERNAL; + break; + case 1: + t = defs::BURST_EXTERNAL; + break; + case 2: + t = defs::CONTINUOUS_INTERNAL; + break; + case 3: + t = defs::CONTINUOUS_EXTERNAL; + break; + default: + throw RuntimeError("Unknown burst mode " + args[0]); + } + } catch (...) { + t = StringTo(args[0]); + } + det->setBurstMode(t, std::vector{det_id}); + os << ToString(t) << '\n'; // no args to convert 0,1,2 as well + } else { + throw RuntimeError("Unknown action"); + } + } + return os.str(); +} +std::string Caller::vetostream(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[none|lll|10gbe|...]\n\t[Gotthard2] Enable or disable the 2 " + "veto streaming interfaces available. Can include more than one " + "interface. \n\tDefault: none. lll (low latency link) is the " + "default interface to work with. \n\t10GbE is for debugging and " + "also enables second interface in receiver for listening to veto " + "packets (writes a separate file if writing enabled). Also " + "restarts client and receiver zmq sockets if zmq streaming " + "enabled." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getVetoStream(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.empty()) { + WrongNumberOfParameters(1); + } + defs::streamingInterface interface = defs::streamingInterface::NONE; + for (const auto &arg : args) { + if (arg == "none") { + if (args.size() > 1) { + throw RuntimeError( + std::string( + "cannot have other arguments with 'none'. args: ") + + ToString(args)); + } + break; + } + interface = interface | (StringTo(arg)); + } + det->setVetoStream(interface, std::vector{det_id}); + os << ToString(interface) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::counters(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[i0] [i1] [i2]... \n\t[Mythen3] List of counters indices " + "enabled. Each element in list can be 0 - 2 and must be non " + "repetitive. Enabling counters sets vth dacs to remembered " + "values and disabling sets them to disabled values." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto mask = det->getCounterMask(std::vector{det_id}).squash(-1); + os << ToString(getSetBits(mask)) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.empty()) { + WrongNumberOfParameters(1); + } + if (std::any_of(args.cbegin(), args.cend(), [](std::string s) { + return (StringTo(s) < 0 || StringTo(s) > 2); + })) { + throw RuntimeError("Invalid counter indices list. Example: 0 1 2"); + } + // convert vector to counter enable mask + uint32_t mask = 0; + for (size_t i = 0; i < args.size(); ++i) { + int val = StringTo(args[i]); + // already enabled earlier + if (mask & (1 << val)) { + std::ostringstream oss; + oss << "Duplicate counter values (" << val << ") in arguments"; + throw RuntimeError(oss.str()); + } + mask |= (1 << val); + } + det->setCounterMask(mask, std::vector{det_id}); + os << ToString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::samples(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[n_samples]\n\t[Ctb][Xilinx_Ctb] Number of samples (analog, " + "digitial and " + "transceiver) expected.\n" + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto a = det->getNumberOfAnalogSamples(std::vector{det_id}); + // get also digital samples for ctb and compare with analog + auto det_type = det->getDetectorType().squash(defs::GENERIC); + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { + auto d = det->getNumberOfDigitalSamples(std::vector{det_id}); + auto t = + det->getNumberOfTransceiverSamples(std::vector{det_id}); + int as = a.squash(-1); + int ds = d.squash(-1); + int ts = t.squash(-1); + if (as == -1 || ds == -1 || ts == -1 || as != ds || + as != ts) { // check if a == d? + throw RuntimeError( + "Different samples. Use asamples, dsamples or tsamples."); + } + } + os << OutString(a) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(1); + } + det->setNumberOfAnalogSamples(StringTo(args[0]), + std::vector{det_id}); + // set also digital samples for ctb + auto det_type = det->getDetectorType().squash(defs::GENERIC); + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { + det->setNumberOfDigitalSamples(StringTo(args[0]), + std::vector{det_id}); + det->setNumberOfTransceiverSamples(StringTo(args[0]), + std::vector{det_id}); + } + os << args.front() << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::slowadc(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[n_channel (0-7 for channel]\n\t[Ctb] Slow " + "ADC channel in mV" + << '\n'; + } else if (action == defs::GET_ACTION) { + if (args.size() != 1) { + WrongNumberOfParameters(0); + } + int nchan = StringTo(args[0]); + if (nchan < 0 || nchan > 7) { + throw RuntimeError("Unknown adc argument " + args[0]); + } + auto t = det->getSlowADC( + static_cast(nchan + defs::SLOW_ADC0), + std::vector{det_id}); + Result result(t.size()); + for (unsigned int i = 0; i < t.size(); ++i) { + result[i] = t[i] / 1000.00; + } + os << OutString(result) << " mV\n"; + + } else if (action == defs::PUT_ACTION) { + throw RuntimeError("cannot put"); + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::rx_dbitlist(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[all] or [i0] [i1] [i2]... \n\t[Ctb] List of digital signal " + "bits read out. If all is used instead of a list, all digital " + "bits (64) enabled. Each element in list can be 0 - 63 and must " + "be non repetitive." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getRxDbitList(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.empty()) { + WrongNumberOfParameters(1); + } + std::vector t; + if (args[0] == "all") { + t.resize(64); + for (unsigned int i = 0; i < 64; ++i) { + t[i] = i; + } + } else { + unsigned int ntrim = args.size(); + t.resize(ntrim); + for (unsigned int i = 0; i < ntrim; ++i) { + t[i] = StringTo(args[i]); + } + } + det->setRxDbitList(t, std::vector{det_id}); + os << ToString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::rx_jsonaddheader(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[key1] [value1] [key2] [value2]...[keyn] [valuen]\n\tAdditional " + "json header to be streamed out from receiver via zmq. Default " + "is empty. Max 20 characters for each key/value. Use only if to " + "be processed by an intermediate user process listening to " + "receiver zmq packets. Empty value deletes header. " + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) { + WrongNumberOfParameters(0); + } + auto t = det->getAdditionalJsonHeader(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + // arguments can be empty + std::map json; + for (size_t i = 0; i < args.size(); i = i + 2) { + // last value is empty + if (i + 1 >= args.size()) { + json[args[i]] = ""; + } else { + json[args[i]] = args[i + 1]; + } + } + det->setAdditionalJsonHeader(json, std::vector{det_id}); + os << ToString(json) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::execcommand(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[command]\n\tExecutes command on detector server console." + << '\n'; + } else if (action == defs::GET_ACTION) { + throw RuntimeError("Cannot get."); + } else if (action == defs::PUT_ACTION) { + std::string command; + for (auto &i : args) { + command += (i + ' '); + } + auto t = det->executeCommand(command, std::vector{det_id}); + os << OutString(t) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::dacvalues(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[(optional unit) mV] \n\tGets the values for every " + "dac for this detector." + << '\n'; + } else if (action == defs::GET_ACTION) { + bool mv = false; + if (args.size() == 1) { + if ((args[0] != "mv") && (args[0] != "mV")) { + throw RuntimeError("Unknown argument " + args[0] + + ". Did you mean mV?"); + } + mv = true; + } else if (args.size() > 1) { + WrongNumberOfParameters(1); + } + auto t = det->getDacList(); + auto names = det->getDacNames(); + auto name_it = names.begin(); + os << '['; + auto it = t.cbegin(); + os << ToString(*name_it++) << ' '; + os << OutString(det->getDAC(*it++, mv, std::vector{det_id})) + << (!args.empty() ? " mV" : ""); + while (it != t.cend()) { + os << ", " << ToString(*name_it++) << ' '; + os << OutString(det->getDAC(*it++, mv, std::vector{det_id})) + << (!args.empty() ? " mV" : ""); + } + os << "]\n"; + } else if (action == defs::PUT_ACTION) { + throw RuntimeError("Cannot put"); + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::currentsource(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "\n\t[0|1]\n\t\t[Gotthard2] Enable or disable current source. " + "Default " + "is disabled.\n\t[0|1] [fix|nofix] [select source] [(only for " + "chipv1.1)normal|low]\n\t\t[Jungfrau] Disable or enable current " + "source with some parameters. The select source is 0-63 for " + "chipv1.0 and a 64 bit mask for chipv1.1. To disable, one needs " + "only one argument '0'." + << '\n'; + } else if (action == defs::GET_ACTION) { + if (args.size() != 0) { + WrongNumberOfParameters(0); + } + auto t = det->getCurrentSource(std::vector{det_id}); + os << OutString(t) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() == 1) { + det->setCurrentSource( + defs::currentSrcParameters(StringTo(args[0]))); + } else if (args.size() >= 3) { + // scan fix + bool fix = false; + if (args[1] == "fix") { + fix = true; + } else if (args[1] == "nofix") { + fix = false; + } else { + throw RuntimeError("Invalid argument: " + args[1] + + ". Did you mean fix or nofix?"); + } + if (args.size() == 3) { + det->setCurrentSource(defs::currentSrcParameters( + fix, StringTo(args[2]))); + } else if (args.size() == 4) { + bool normalCurrent = false; + if (args[3] == "normal") { + normalCurrent = true; + } else if (args[3] == "low") { + normalCurrent = false; + } else { + throw RuntimeError("Invalid argument: " + args[3] + + ". Did you mean normal or low?"); + } + det->setCurrentSource(defs::currentSrcParameters( + fix, StringTo(args[2]), normalCurrent)); + } else { + throw RuntimeError( + "Invalid number of parareters for this command."); + } + } else { + throw RuntimeError( + "Invalid number of parareters for this command."); + } + os << ToString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +std::string Caller::gaincaps(int action) { + std::ostringstream os; + if (action == defs::HELP_ACTION) { + os << "[cap1, cap2, ...]\n\t[Mythen3] gain, options: C10pre, C15sh, " + "C30sh, C50sh, C225ACsh, C15pre" + << '\n'; + } else if (action == defs::GET_ACTION) { + if (!args.empty()) + WrongNumberOfParameters(0); + + auto tmp = det->getGainCaps(); + Result csr; + for (auto val : tmp) { + if (val) + csr.push_back(static_cast(val)); + } + + os << OutString(csr) << '\n'; + } else if (action == defs::PUT_ACTION) { + if (args.size() < 1) { + WrongNumberOfParameters(1); + } + int caps = 0; + for (const auto &arg : args) { + if (arg != "0") + caps |= StringTo(arg); + } + + det->setGainCaps(caps); + os << OutString(args) << '\n'; + } else { + throw RuntimeError("Unknown action"); + } + return os.str(); +} +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/src/CmdLineApp.cpp b/slsDetectorSoftware/src/CmdApp.cpp similarity index 68% rename from slsDetectorSoftware/src/CmdLineApp.cpp rename to slsDetectorSoftware/src/CmdApp.cpp index c1955f528..9a616e19b 100644 --- a/slsDetectorSoftware/src/CmdLineApp.cpp +++ b/slsDetectorSoftware/src/CmdApp.cpp @@ -1,22 +1,12 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package - -/* -This file is used to generate the command line binaries -(sls_detector_get/put/acquire/help). By defines in CMake -we get the different files. - -*/ -#include "sls/Detector.h" - +#include "Caller.h" #include "CmdParser.h" -#include "CmdProxy.h" -#include "sls/sls_detector_defs.h" +#include "inferAction.h" +#include "sls/Detector.h" +#include "sls/logger.h" #include "sls/versionAPI.h" -#include //strcmp + #include int main(int argc, char *argv[]) { - // To genereate sepereate binaries for put, get, acquire and help #ifdef PUT int action = slsDetectorDefs::PUT_ACTION; @@ -33,6 +23,9 @@ int main(int argc, char *argv[]) { #ifdef HELP int action = slsDetectorDefs::HELP_ACTION; #endif +#ifdef INFER + int action = -1; +#endif // Check for --version in the arguments for (int i = 1; i < argc; ++i) { @@ -45,14 +38,12 @@ int main(int argc, char *argv[]) { sls::CmdParser parser; parser.Parse(argc, argv); - // If we called sls_detector_acquire, add the acquire command if (action == slsDetectorDefs::READOUT_ACTION) parser.setCommand("acquire"); if (parser.isHelp()) action = slsDetectorDefs::HELP_ACTION; else { - // Free shared memory should work also without a detector // if we have an option for verify in the detector constructor // we could avoid this but clutter the code @@ -65,22 +56,30 @@ int main(int argc, char *argv[]) { } } - // prevent mem size check if (parser.command() == "config" && action == slsDetectorDefs::PUT_ACTION) { sls::freeSharedMemory(parser.multi_id()); } + sls::InferAction inferAction = sls::InferAction(); + try { - std::unique_ptr det{nullptr}; - if (action != slsDetectorDefs::HELP_ACTION) { - det = sls::make_unique(parser.multi_id()); + if (action == -1) { + action = inferAction.infer(parser); + std::string actionString = + (action == slsDetectorDefs::GET_ACTION) ? "GET" : "PUT"; + std::cout << "inferred action: " << actionString << std::endl; } - sls::CmdProxy proxy(det.get()); - proxy.Call(parser.command(), parser.arguments(), parser.detector_id(), - action, std::cout, parser.receiver_id()); - } catch (const sls::RuntimeError &e) { + + std::unique_ptr d{nullptr}; + if (action != slsDetectorDefs::HELP_ACTION) { + d = sls::make_unique(parser.multi_id()); + } + sls::Caller c(d.get()); + + c.call(parser.command(), parser.arguments(), parser.detector_id(), + action, std::cout, parser.receiver_id()); + } catch (sls::RuntimeError &e) { exit(EXIT_FAILURE); } - exit(EXIT_SUCCESS); } \ No newline at end of file diff --git a/slsDetectorSoftware/src/CmdParser.h b/slsDetectorSoftware/src/CmdParser.h index 47a1703ea..701b95a45 100644 --- a/slsDetectorSoftware/src/CmdParser.h +++ b/slsDetectorSoftware/src/CmdParser.h @@ -20,7 +20,6 @@ reason that the header file is not exposed. #include namespace sls { - class CmdParser { public: void Parse(int argc, const char *const argv[]); diff --git a/slsDetectorSoftware/src/CmdProxy.cpp b/slsDetectorSoftware/src/CmdProxy.cpp deleted file mode 100644 index d56bd0f96..000000000 --- a/slsDetectorSoftware/src/CmdProxy.cpp +++ /dev/null @@ -1,3431 +0,0 @@ - -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" -#include "HelpDacs.h" -#include "sls/TimeHelper.h" -#include "sls/ToString.h" -#include "sls/bit_utils.h" -#include "sls/container_utils.h" -#include "sls/file_utils.h" -#include "sls/logger.h" -#include "sls/sls_detector_defs.h" - -#include -#include -#include -#include - -namespace sls { - -using defs = slsDetectorDefs; - -std::ostream &operator<<(std::ostream &os, - const std::vector &vec) { - if (!vec.empty()) { - auto it = vec.begin(); - os << *it++; - while (it != vec.end()) - os << ' ' << *it++; - } - return os; -} - -void CmdProxy::Call(const std::string &command, - const std::vector &arguments, int detector_id, - int action, std::ostream &os, int receiver_id) { - cmd = command; - args = arguments; - det_id = detector_id; - rx_id = receiver_id; - - std::string temp; - while (temp != cmd) { - temp = cmd; - ReplaceIfDepreciated(cmd); - } - - auto it = functions.find(cmd); - if (it != functions.end()) { - os << ((*this).*(it->second))(action); - } else { - throw RuntimeError(cmd + - " Unknown command, use list to list all commands"); - } -} - -bool CmdProxy::ReplaceIfDepreciated(std::string &command) { - auto d_it = depreciated_functions.find(command); - if (d_it != depreciated_functions.end()) { - LOG(logWARNING) - << command - << " is deprecated and will be removed. Please migrate to: " - << d_it->second; - // insert old command into arguments (for dacs) - if (d_it->second == "dac") { - args.insert(args.begin(), command); - } - command = d_it->second; - return true; - } - return false; -} - -std::vector CmdProxy::GetProxyCommands() { - std::vector commands; - for (const auto &it : functions) - commands.emplace_back(it.first); - std::sort(begin(commands), end(commands)); - return commands; -} - -std::map CmdProxy::GetDepreciatedCommands() { - return depreciated_functions; -} - -void CmdProxy::WrongNumberOfParameters(size_t expected) { - if (expected == 0) { - throw RuntimeError("Command " + cmd + - " expected no parameter/s but got " + - std::to_string(args.size()) + "\n"); - } - throw RuntimeError("Command " + cmd + " expected (or >=) " + - std::to_string(expected) + " parameter/s but got " + - std::to_string(args.size()) + "\n"); -} - -/************************************************ - * * - * COMMANDS * - * * - ************************************************/ - -std::string CmdProxy::ListCommands(int action) { - if (action == defs::HELP_ACTION) - return "list\n\tlists all available commands, list deprecated - " - "list deprecated commands\n"; - - if (args.empty()) { - auto commands = GetProxyCommands(); - std::cout << "These " << commands.size() << " commands are available\n"; - for (auto &c : commands) - std::cout << c << '\n'; - return ""; - } else if (args.size() == 1) { - if (args[0] == "deprecated") { - std::cout << "The following " << depreciated_functions.size() - << " commands are deprecated\n"; - const size_t field_width = 20; - for (const auto &it : depreciated_functions) { - std::cout << std::right << std::setw(field_width) << it.first - << " -> " << it.second << '\n'; - } - return ""; - } else if (args[0] == "migrated") { - std::cout << "The following " << functions.size() - << " commands have been migrated to the new API\n"; - for (const auto &it : functions) { - std::cout << it.first << '\n'; - } - return ""; - } else { - throw RuntimeError( - "Could not decode argument. Possible options: deprecated"); - } - } else { - WrongNumberOfParameters(1); - return ""; - } -} - -/* configuration */ - -std::string CmdProxy::Hostname(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tFrees shared memory and sets hostname (or IP address) of " - "all modules concatenated by +.\n\t Virtual servers can already " - "use the port in hostname separated by ':' and ports incremented " - "by 2 to accomodate the stop server as well." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getHostname(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.empty()) { - WrongNumberOfParameters(1); - } - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - // only args[0], but many hostames concatenated with + - if (args[0].find('+') != std::string::npos) { - auto t = split(args[0], '+'); - det->setHostname(t); - os << ToString(t) << '\n'; - } - // either hostnames separated by space, or single hostname - else { - det->setHostname(args); - os << ToString(args) << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::VirtualServer(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_servers] [starting_port_number]\n\tConnecs to n virtual " - "server at local host starting at specific control port. Every " - "virtual server will have a stop port (control port + 1)" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - det->setVirtualDetectorServers(StringTo(args[0]), - StringTo(args[1])); - os << ToString(args); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Acquire(int action) { - std::ostringstream os; - if (action == defs::HELP_ACTION) { - os << cmd - << "\n\tAcquire the number of frames set up.\n\tBlocking command, " - "where control server is blocked and cannot accept other " - "commands until acquisition is done. \n\t- sets acquiring " - "flag\n\t- starts the receiver listener (if enabled)\n\t- starts " - "detector acquisition for number of frames set\n\t- monitors " - "detector status from running to idle\n\t- stops the receiver " - "listener (if enabled)\n\t- increments file index if file write " - "enabled\n\t- resets acquiring flag" - << '\n'; - } else { - if (det->empty()) { - throw RuntimeError("This shared memory has no detectors added."); - } - if (det_id >= 0) { - throw RuntimeError("Individual detectors not allowed for readout."); - } - - det->acquire(); - - if (det->getUseReceiverFlag().squash(false)) { - os << "\nAcquired "; - os << det->getFramesCaught() << '\n'; - } - } - return os.str(); -} - -std::string CmdProxy::Free(int action) { - // This function is purely for help, actual functionality is in the caller - return "free\n\tFree detector shared memory\n"; -} - -std::string CmdProxy::FirmwareVersion(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tFimware version of detector in format [0xYYMMDD] or an " - "increasing 2 digit number for Eiger." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getFirmwareVersion(std::vector{det_id}); - if (det->getDetectorType().squash() == defs::EIGER) { - os << OutString(t) << '\n'; - } else { - os << OutStringHex(t) << '\n'; - } - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Versions(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tPrint all versions and detector type" << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - bool eiger = (det->getDetectorType().squash() == defs::EIGER); - auto t = det->getFirmwareVersion(std::vector{det_id}); - os << "\nType : " << OutString(det->getDetectorType()) - << "\nRelease : " << det->getPackageVersion() << std::hex - << "\nClient : " << det->getClientVersion(); - - if (eiger) { - os << "\nFirmware (Beb) : " - << OutString(det->getFirmwareVersion(std::vector{det_id})); - os << "\nFirmware (Febl) : " - << OutString(det->getFrontEndFirmwareVersion( - defs::FRONT_LEFT, std::vector{det_id})); - os << "\nFirmware (Febr) : " - << OutString(det->getFrontEndFirmwareVersion( - defs::FRONT_RIGHT, std::vector{det_id})); - } else { - os << "\nFirmware : " - << OutStringHex( - det->getFirmwareVersion(std::vector{det_id})); - } - - os << "\nServer : " - << OutString(det->getDetectorServerVersion(std::vector{det_id})) - << "\nKernel : " - << OutString(det->getKernelVersion({std::vector{det_id}})) - << "\nHardware : " - << OutString(det->getHardwareVersion(std::vector{det_id})); - - if (det->getUseReceiverFlag().squash(true)) { - os << "\nReceiver : " - << OutString(det->getReceiverVersion(std::vector{det_id})); - } - os << std::dec << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PackageVersion(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tPackage version (git branch)." << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << det->getPackageVersion() << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ClientVersion(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tClient software version" << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << det->getClientVersion() << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DetectorSize(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[nx] [ny]\n\tDetector size, ie. Number of channels in x and y " - "dim. This is used to calculate module coordinates included in " - "UDP data. \n\tBy default, it adds module in y dimension for 2d " - "detectors and in x dimension for 1d detectors packet header." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getDetectorSize(); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - defs::xy t; - t.x = StringTo(args[0]); - t.y = StringTo(args[1]); - det->setDetectorSize(t); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Threshold(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[eV] [(optinal settings)" - "\n\t[Eiger][Mythen3] Threshold in eV. It loads trim files from " - "settingspath."; - if (cmd == "thresholdnotb") { - os << "Trimbits are not loaded."; - } - os << "\n\nthreshold [eV1] [eV2] [eV3] [(optional settings)]" - "\n\t[Mythen3] Threshold in eV for each counter. It loads trim " - "files from settingspath. An energy of -1 will pick up values " - " from detector."; - if (cmd == "thresholdnotb") { - os << "Trimbits are not loaded."; - } - os << '\n'; - } else if (action == defs::GET_ACTION) { - if (cmd == "thresholdnotb") { - throw RuntimeError("cannot get"); - } - if (!args.empty()) { - WrongNumberOfParameters(0); - } - defs::detectorType type = det->getDetectorType().squash(); - if (type == defs::EIGER) { - auto t = det->getThresholdEnergy(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (type == defs::MYTHEN3) { - auto t = det->getAllThresholdEnergy(std::vector{det_id}); - os << OutString(t) << '\n'; - } else { - throw RuntimeError("Not implemented for this detector\n"); - } - } else if (action == defs::PUT_ACTION) { - defs::detectorType type = det->getDetectorType().squash(); - if (type == defs::EIGER && args.size() != 1 && args.size() != 2) { - WrongNumberOfParameters(1); - } - if (type == defs::MYTHEN3 && (args.size() < 1 || args.size() > 4)) { - WrongNumberOfParameters(1); - } - - bool trimbits = (cmd == "thresholdnotb") ? false : true; - std::array energy = {StringTo(args[0]), 0, 0}; - energy[1] = energy[0]; - energy[2] = energy[0]; - defs::detectorSettings sett = defs::STANDARD; - - // check if argument has settings or get it - if (args.size() == 2 || args.size() == 4) { - sett = StringTo(args[args.size() - 1]); - } else { - sett = det->getSettings(std::vector{det_id}) - .tsquash("Inconsistent settings between detectors"); - } - - // get other threshold values - if (args.size() > 2) { - energy[1] = StringTo(args[1]); - energy[2] = StringTo(args[2]); - } - switch (type) { - case defs::EIGER: - det->setThresholdEnergy(energy[0], sett, trimbits, - std::vector{det_id}); - break; - case defs::MYTHEN3: - det->setThresholdEnergy(energy, sett, trimbits, - std::vector{det_id}); - break; - default: - throw RuntimeError("Not implemented for this detector\n"); - } - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Trimbits(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[fname]\n\t[Eiger][Mythen3] Put will load the trimbit file to " - "detector. If no extension specified, serial number of each " - "module is attached. Get will save the trimbits from the " - "detector to file with serial number added to file name." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->saveTrimbits(args[0], std::vector{det_id}); - os << args << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->loadTrimbits(args[0], std::vector{det_id}); - os << args << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::TrimEnergies(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[trim_ev1] [trim_Ev2 (optional)] [trim_ev3 (optional)] " - "...\n\t[Eiger][Mythen3] Number of trim energies and list of " - "trim " - "energies, where corresponding default trim files exist in " - "corresponding trim folders." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getTrimEnergies(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - std::vector t(args.size()); - if (!args.empty()) { - for (size_t i = 0; i < t.size(); ++i) { - t[i] = StringTo(args[i]); - } - } - det->setTrimEnergies(t, std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::GapPixels(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[0, 1]\n\t[Eiger][Jungfrau][Moench] Include Gap pixels in " - "client data " - "call back in Detecor api. Will not be in detector streaming, " - "receiver file or streaming. Default is 0. " - << '\n'; - } else if (action == defs::GET_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot get gap pixels at module level"); - } - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getGapPixelsinCallback(); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot add gap pixels at module level"); - } - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setGapPixelsinCallback(StringTo(args[0])); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::BadChannels(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[fname|none|0]\n\t[Gotthard2][Mythen3] Sets the bad channels " - "(from file of bad channel numbers) to be masked out. None or 0 " - "unsets all the badchannels.\n\t[Mythen3] Also does trimming" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->getBadChannels(args[0], std::vector{det_id}); - os << "successfully retrieved" << '\n'; - } else if (action == defs::PUT_ACTION) { - bool parse = false; - if (args.size() == 0) { - WrongNumberOfParameters(1); - } else if (args.size() == 1) { - if (args[0] == "none" || args[0] == "0") { - det->setBadChannels(std::vector{}, - std::vector{det_id}); - } else if (args[0].find(".") != std::string::npos) { - det->setBadChannels(args[0], std::vector{det_id}); - } else { - parse = true; - } - } - // parse multi args or single one with range or single value - if (parse || args.size() > 1) { - // get channels - auto list = getChannelsFromStringList(args); - det->setBadChannels(list, std::vector{det_id}); - } - os << "successfully loaded" << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* acquisition parameters */ - -std::string CmdProxy::Exptime(int action) { - int gateIndex = -1; - if (cmd == "exptime") { - gateIndex = -1; - } else if (cmd == "exptime1") { - gateIndex = 0; - } else if (cmd == "exptime2") { - gateIndex = 1; - } else if (cmd == "exptime3") { - gateIndex = 2; - } else { - throw RuntimeError("Unknown command, use list to list all commands"); - } - - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "exptime") { - os << "[duration] [(optional unit) " - "ns|us|ms|s]\n\t[Eiger][Jungfrau][Moench][Gotthard][" - "Gotthard2][Ctb] Exposure time" - "\n\t[Mythen3] Exposure time of all gate signals in auto and " - "trigger mode (internal gating). To specify gate index, use " - "exptime1, exptime2, exptime3." - << '\n'; - } else if (cmd == "exptime1") { - os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 1 in " - "auto and trigger mode (internal gating)." - << '\n'; - } else if (cmd == "exptime2") { - os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 2 in " - "auto and trigger mode (internal gating)." - << '\n'; - } else { - os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 3 in " - "auto and trigger mode (internal gating)." - << '\n'; - } - } else if (action == defs::GET_ACTION) { - if (args.size() > 1) { - WrongNumberOfParameters(1); - } - // vector of exptimes - if (gateIndex == -1 && - det->getDetectorType().squash() == defs::MYTHEN3) { - auto t = det->getExptimeForAllGates(std::vector{det_id}); - if (args.empty()) { - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - os << OutString(t, args[0]) << '\n'; - } - } - // single exptime - else { - Result t; - if (gateIndex == -1) { - t = det->getExptime(std::vector{det_id}); - } else { - t = det->getExptime(gateIndex, std::vector{det_id}); - } - if (args.empty()) { - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - os << OutString(t, args[0]) << '\n'; - } - } - } else if (action == defs::PUT_ACTION) { - defs::detectorType type = det->getDetectorType().squash(); - if (args.size() == 1) { - std::string time_str(args[0]); - std::string unit = RemoveUnit(time_str); - auto t = StringTo(time_str, unit); - if (type == defs::MYTHEN3) { - det->setExptime(gateIndex, t, std::vector{det_id}); - } else { - det->setExptime(t, std::vector{det_id}); - } - } else if (args.size() == 2) { - auto t = StringTo(args[0], args[1]); - if (type == defs::MYTHEN3) { - det->setExptime(gateIndex, t, std::vector{det_id}); - } else { - det->setExptime(t, std::vector{det_id}); - } - } else { - WrongNumberOfParameters(2); - } - /* TODO: os << args << '\n'; (doesnt work for vectors in .h)*/ - if (args.size() > 1) { - os << args[0] << args[1] << '\n'; - } else { - os << args[0] << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ReadoutSpeed(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\t[0 or full_speed|1 or half_speed|2 or " - "quarter_speed]\n\t\t[Eiger][Jungfrau][Moench] Readout speed of " - "chip.\n\t\t[Eiger][Moench] Default speed is " - "full_speed.\n\t\t[Jungfrau] Default speed is half_speed. " - "full_speed option only available from v2.0 boards and is " - "recommended to set number of interfaces to 2. Also overwrites " - "adcphase to recommended default.\n\t [144|108]\n\t\t[Gotthard2] " - "Readout speed of chip in MHz. Default is 108." - << '\n'; - } else { - defs::detectorType type = det->getDetectorType().squash(); - if (type == defs::CHIPTESTBOARD) { - throw RuntimeError( - "ReadoutSpeed not implemented. Did you mean runclk?"); - } - if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getReadoutSpeed(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - defs::speedLevel t = StringTo(args[0]); - det->setReadoutSpeed(t, std::vector{det_id}); - os << ToString(t) << '\n'; // no args to convert 0,1,2 as well - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::Adcphase(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_value] " - "[(optional)deg]\n\t[Jungfrau][Moench][Ctb][Gotthard] " - "Phase shift of ADC clock. \n\t[Jungfrau][Moench] Absolute phase " - "shift. " - "If deg used, then shift in degrees. Changing Speed also resets " - "adcphase to recommended defaults.\n\t[Ctb] Absolute " - "phase shift. If deg used, then shift in degrees. Changing " - "adcclk also resets adcphase and sets it to previous " - "values.\n\t[Gotthard] Relative phase shift. Cannot get" - << '\n'; - } else { - auto det_type = det->getDetectorType().squash(defs::GENERIC); - if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || - det_type == defs::GOTTHARD2) { - throw RuntimeError("adcphase not implemented for this detector"); - } - if (action == defs::GET_ACTION) { - Result t; - if (args.empty()) { - t = det->getADCPhase(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - if (args[0] != "deg") { - throw RuntimeError("Unknown adcphase argument " + - args[0] + ". Did you mean deg? "); - } - t = det->getADCPhaseInDegrees(std::vector{det_id}); - os << OutString(t) << " deg\n"; - } else { - WrongNumberOfParameters(0); - } - } else if (action == defs::PUT_ACTION) { - if (args.size() == 1) { - det->setADCPhase(StringTo(args[0]), - std::vector{det_id}); - os << args.front() << '\n'; - } else if (args.size() == 2) { - if (args[1] != "deg") { - throw RuntimeError("Unknown adcphase 2nd argument " + - args[1] + ". Did you mean deg?"); - } - det->setADCPhaseInDegrees(StringTo(args[0]), - std::vector{det_id}); - os << args[0] << " " << args[1] << '\n'; - } else { - WrongNumberOfParameters(1); - } - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::Dbitphase(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_value] [(optional)deg]\n\t[Ctb][Jungfrau] Phase shift of " - "clock to latch digital bits. Absolute phase shift. If deg used, " - "then shift in degrees. \n\t[Ctb]Changing dbitclk also resets " - "dbitphase and sets to previous values." - << '\n'; - } else { - auto det_type = det->getDetectorType().squash(defs::GENERIC); - if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || - det_type == defs::GOTTHARD2 || det_type == defs::MOENCH) { - throw RuntimeError("dbitphase not implemented for this detector"); - } - if (action == defs::GET_ACTION) { - Result t; - if (args.empty()) { - t = det->getDBITPhase(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - if (args[0] != "deg") { - throw RuntimeError("Unknown dbitphase argument " + args[0] + - ". Did you mean deg? "); - } - t = det->getDBITPhaseInDegrees(std::vector{det_id}); - os << OutString(t) << " deg\n"; - } else { - WrongNumberOfParameters(0); - } - } else if (action == defs::PUT_ACTION) { - if (args.size() == 1) { - det->setDBITPhase(StringTo(args[0]), - std::vector{det_id}); - os << args.front() << '\n'; - } else if (args.size() == 2) { - if (args[1] != "deg") { - throw RuntimeError("Unknown dbitphase 2nd argument " + - args[1] + ". Did you mean deg? "); - } - det->setDBITPhaseInDegrees(StringTo(args[0]), - std::vector{det_id}); - os << args[0] << " " << args[1] << '\n'; - } else { - WrongNumberOfParameters(1); - } - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::ClockFrequency(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_clock (0-5)] [freq_in_Hz]\n\t[Gotthard2][Mythen3] Frequency " - "of clock n_clock in Hz. Use clkdiv to set frequency." - << '\n'; - } else { - defs::detectorType type = det->getDetectorType().squash(defs::GENERIC); - if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { - throw RuntimeError("clkfreq not implemented for this detector."); - } - if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->getClockFrequency(StringTo(args[0]), - std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::ClockPhase(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_clock (0-5)] [phase] [deg " - "(optional)]\n\t[Gotthard2][Mythen3] Phase of clock n_clock. If " - "deg, then phase shift in degrees, else absolute phase shift " - "values." - << '\n'; - } else { - defs::detectorType type = det->getDetectorType().squash(defs::GENERIC); - if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { - throw RuntimeError("clkphase not implemented for this detector."); - } - if (action == defs::GET_ACTION) { - if (args.size() == 1) { - auto t = det->getClockPhase(StringTo(args[0]), - std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (args.size() == 2) { - if (args[1] != "deg") { - throw RuntimeError("Cannot scan argument" + args[1] + - ". Did you mean deg?"); - } - auto t = det->getClockPhaseinDegrees(StringTo(args[0]), - {det_id}); - os << OutString(t) << " deg\n"; - } else { - WrongNumberOfParameters(1); - } - } else if (action == defs::PUT_ACTION) { - if (args.size() == 2) { - det->setClockPhase(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << args[1] << '\n'; - } else if (args.size() == 3) { - if (args[2] != "deg") { - throw RuntimeError("Cannot scan argument" + args[2] + - ". Did you mean deg?"); - } - det->setClockPhaseinDegrees(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << args[1] << " " << args[2] << '\n'; - } else { - WrongNumberOfParameters(1); - } - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::MaxClockPhaseShift(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_clock (0-5)]\n\t[Gotthard2][Mythen3] Absolute Maximum Phase " - "shift of clock n_clock." - << '\n'; - } else { - defs::detectorType type = det->getDetectorType().squash(defs::GENERIC); - if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { - throw RuntimeError( - "maxclkphaseshift not implemented for this detector."); - } - if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->getMaxClockPhaseShift(StringTo(args[0]), - std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("Cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::ClockDivider(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_clock (0-5)] [n_divider]\n\t[Gotthard2][Mythen3] Clock " - "Divider of clock n_clock. Must be greater than 1." - << '\n'; - } else { - defs::detectorType type = det->getDetectorType().squash(defs::GENERIC); - if (type != defs::GOTTHARD2 && type != defs::MYTHEN3) { - throw RuntimeError("clkdiv not implemented for this detector."); - } - if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->getClockDivider(StringTo(args[0]), - std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setClockDivider(StringTo(args[0]), StringTo(args[1]), - {det_id}); - os << args[1] << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::ExternalSignal(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_signal] [signal_type] External signal mode for trigger " - "timing mode." - "\n\t[Gotthard] [0] " - "[trigger_in_rising_edge|trigger_in_falling_edge]" - "\n\t[Mythen3] [0-7] " - "[trigger_in_rising_edge|trigger_in_falling_edge|inversion_on|" - "inversion_off]\n\t where 0 is master input trigger signal, 1-3 " - "is master input gate signals, 4 is busy out signal and 5-7 is " - "master output gate signals." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->getExternalSignalFlags(StringTo(args[0]), - std::vector{det_id}); - os << args[0] << " " << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setExternalSignalFlags( - StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << args[0] << " " << args[1] << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::CurrentSource(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\t[0|1]\n\t\t[Gotthard2] Enable or disable current source. " - "Default " - "is disabled.\n\t[0|1] [fix|nofix] [select source] [(only for " - "chipv1.1)normal|low]\n\t\t[Jungfrau] Disable or enable current " - "source with some parameters. The select source is 0-63 for " - "chipv1.0 and a 64 bit mask for chipv1.1. To disable, one needs " - "only one argument '0'." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 0) { - WrongNumberOfParameters(0); - } - auto t = det->getCurrentSource(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() == 1) { - det->setCurrentSource( - defs::currentSrcParameters(StringTo(args[0]))); - } else if (args.size() >= 3) { - // scan fix - bool fix = false; - if (args[1] == "fix") { - fix = true; - } else if (args[1] == "nofix") { - fix = false; - } else { - throw RuntimeError("Invalid argument: " + args[1] + - ". Did you mean fix or nofix?"); - } - if (args.size() == 3) { - det->setCurrentSource(defs::currentSrcParameters( - fix, StringTo(args[2]))); - } else if (args.size() == 4) { - bool normalCurrent = false; - if (args[3] == "normal") { - normalCurrent = true; - } else if (args[3] == "low") { - normalCurrent = false; - } else { - throw RuntimeError("Invalid argument: " + args[3] + - ". Did you mean normal or low?"); - } - det->setCurrentSource(defs::currentSrcParameters( - fix, StringTo(args[2]), normalCurrent)); - } else { - throw RuntimeError( - "Invalid number of parareters for this command."); - } - } else { - throw RuntimeError( - "Invalid number of parareters for this command."); - } - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/** temperature */ -std::string CmdProxy::TemperatureValues(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tGets the values for every temperature for this detector." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 0) { - WrongNumberOfParameters(0); - } - auto t = det->getTemperatureList(); - os << '['; - if (t.size() > 0) { - auto it = t.cbegin(); - os << ToString(*it) << ' '; - os << OutString( - det->getTemperature(*it++, std::vector{det_id})) - << " °C"; - while (it != t.cend()) { - os << ", " << ToString(*it) << ' '; - os << OutString( - det->getTemperature(*it++, std::vector{det_id})) - << " °C"; - } - } - os << "]\n"; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("Cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* list */ - -/* dacs */ -std::string CmdProxy::Dac(int action) { - std::ostringstream os; - os << cmd << ' '; - - if (action == defs::HELP_ACTION) { - if (args.size() == 0) { - os << GetHelpDac(std::to_string(0)) << '\n'; - } else { - os << args[0] << ' ' << GetHelpDac(args[0]) << '\n'; - } - return os.str(); - } - - auto type = det->getDetectorType().squash(); - - // dac indices only for ctb - if (args.size() > 0 && action != defs::HELP_ACTION) { - if (is_int(args[0]) && type != defs::CHIPTESTBOARD) { - throw RuntimeError( - "Dac indices can only be used for chip test board. Use daclist " - "to get list of dac names for current detector."); - } - } - - if (action == defs::GET_ACTION) { - if (args.empty()) - WrongNumberOfParameters(1); // This prints slightly wrong - - defs::dacIndex dacIndex{}; - // TODO! Remove if - if (type == defs::CHIPTESTBOARD && !is_int(args[0])) { - dacIndex = det->getDacIndex(args[0]); - } else { - dacIndex = StringTo(args[0]); - } - - bool mV = false; - - if (args.size() == 2) { - if ((args[1] != "mv") && (args[1] != "mV")) { - throw RuntimeError("Unknown argument " + args[1] + - ". Did you mean mV?"); - } - mV = true; - } else if (args.size() > 2) { - WrongNumberOfParameters(1); - } - auto t = det->getDAC(dacIndex, mV, std::vector{det_id}); - os << args[0] << ' ' << OutString(t) << (mV ? " mV\n" : "\n"); - } else if (action == defs::PUT_ACTION) { - if (args.empty()) - WrongNumberOfParameters(1); // This prints slightly wrong - - defs::dacIndex dacIndex{}; - if (type == defs::CHIPTESTBOARD && !is_int(args[0])) - dacIndex = det->getDacIndex(args[0]); - else - dacIndex = StringTo(args[0]); - bool mV = false; - if (args.size() == 3) { - if ((args[2] != "mv") && (args[2] != "mV")) { - throw RuntimeError("Unknown argument " + args[2] + - ". Did you mean mV?"); - } - mV = true; - } else if (args.size() > 3 || args.size() < 2) { - WrongNumberOfParameters(2); - } - det->setDAC(dacIndex, StringTo(args[1]), mV, - std::vector{det_id}); - os << args[0] << ' ' << args[1] << (mV ? " mV\n" : "\n"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DacValues(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[(optional unit) mV] \n\tGets the values for every " - "dac for this detector." - << '\n'; - } else if (action == defs::GET_ACTION) { - bool mv = false; - if (args.size() == 1) { - if ((args[0] != "mv") && (args[0] != "mV")) { - throw RuntimeError("Unknown argument " + args[0] + - ". Did you mean mV?"); - } - mv = true; - } else if (args.size() > 1) { - WrongNumberOfParameters(1); - } - auto t = det->getDacList(); - auto names = det->getDacNames(); - auto name_it = names.begin(); - os << '['; - auto it = t.cbegin(); - os << ToString(*name_it++) << ' '; - os << OutString(det->getDAC(*it++, mv, std::vector{det_id})) - << (!args.empty() ? " mV" : ""); - while (it != t.cend()) { - os << ", " << ToString(*name_it++) << ' '; - os << OutString(det->getDAC(*it++, mv, std::vector{det_id})) - << (!args.empty() ? " mV" : ""); - } - os << "]\n"; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("Cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ResetDacs(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[(optional) hard] " - "\n\t[Eiger][Jungfrau][Moench][Gotthard][Gotthard2][" - "Mythen3]Reset dac values to the defaults. A 'hard' optional " - "reset will reset the dacs to the hardcoded defaults in on-board " - "detector server." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - bool hardReset = false; - if (args.size() == 1) { - if (args[0] != "hard") { - throw RuntimeError("Unknown argument " + args[0] + - ". Did you mean hard?"); - } - hardReset = true; - } else if (args.size() > 1) { - WrongNumberOfParameters(1); - } - det->resetToDefaultDacs(hardReset, std::vector{det_id}); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DefaultDac(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[dac name][value][(optional)setting]\n\tSets the default for " - "that dac to this value.\n\t[Jungfrau][Moench][Mythen3] When " - "settings is " - "provided, it sets the default value only for that setting" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() < 1) { - WrongNumberOfParameters(1); - } - // optional settings - if (args.size() == 2) { - auto t = det->getDefaultDac( - StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << args[0] << ' ' << args[1] << ' ' << OutString(t) << '\n'; - } else { - auto t = det->getDefaultDac(StringTo(args[0]), - std::vector{det_id}); - os << args[0] << ' ' << OutString(t) << '\n'; - } - } else if (action == defs::PUT_ACTION) { - if (args.size() < 2) { - WrongNumberOfParameters(2); - } - // optional settings - if (args.size() == 3) { - det->setDefaultDac( - StringTo(args[0]), StringTo(args[1]), - StringTo(args[2]), - std::vector{det_id}); - os << args[0] << ' ' << args[2] << ' ' << args[1] << '\n'; - } else { - det->setDefaultDac(StringTo(args[0]), - StringTo(args[1])); - os << args[0] << ' ' << args[1] << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} -/* acquisition */ - -std::string CmdProxy::ReceiverStatus(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "running, idle, transmitting]\n\tReceiver listener status." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getReceiverStatus(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError( - "Cannot put. Did you mean to use command 'rx_start' or 'rx_stop'?"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DetectorStatus(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[running, error, transmitting, finished, waiting, " - "idle]\n\tDetector status. Goes to stop server. " - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getDetectorStatus(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError( - "Cannot put. Did you mean to use command 'start' or 'stop'?"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Scan(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[dac_name|0|trimbits] [start_val] [stop_val] " - "[step_size] [dac settling time ns|us|ms|s]\n\tEnables/ disables " - "scans for dac and trimbits \n\tEnabling scan sets number of " - "frames to number of steps in receiver. \n\tTo cancel scan " - "configuration, set dac to '0', which also sets number of frames " - "to 1. \n\t[Eiger][Mythen3] Use trimbits as dac name for a " - "trimbit scan." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 0) { - WrongNumberOfParameters(0); - } - auto t = det->getScan(); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot configure scan at module level"); - } - // disable - if (args.size() == 1) { - if (StringTo(args[0]) != 0) { - throw RuntimeError("Did you mean '0' to disable?"); - } - det->setScan(defs::scanParameters()); - } - // enable without settling time - else if (args.size() == 4) { - det->setScan(defs::scanParameters( - StringTo(args[0]), StringTo(args[1]), - StringTo(args[2]), StringTo(args[3]))); - } - // enable with all parameters - else if (args.size() == 5) { - std::string time_str(args[4]); - std::string unit = RemoveUnit(time_str); - auto t = StringTo(time_str, unit); - det->setScan(defs::scanParameters( - StringTo(args[0]), StringTo(args[1]), - StringTo(args[2]), StringTo(args[3]), t)); - } else { - WrongNumberOfParameters(4); - } - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Trigger(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "trigger") { - os << "\n\t[Eiger][Mythen3][Jungfrau][Moench] Sends software " - "trigger " - "signal to detector"; - } else if (cmd == "blockingtrigger") { - os << "\n\t[Eiger][Jungfrau][Moench] Sends software trigger signal " - "to " - "detector and blocks till the frames are sent out for that " - "trigger."; - } else { - throw RuntimeError("unknown command " + cmd); - } - os << '\n'; - } else if (action == slsDetectorDefs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == slsDetectorDefs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - if (!args.empty()) { - WrongNumberOfParameters(0); - } - bool block = false; - if (cmd == "blockingtrigger") { - block = true; - } - det->sendSoftwareTrigger(block); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Network Configuration (Detector<->Receiver) */ - -IpAddr CmdProxy::getDstIpFromAuto() { - std::string rxHostname = - det->getRxHostname(std::vector{det_id}).squash("none"); - // Hostname could be ip try to decode otherwise look up the hostname - auto val = IpAddr{rxHostname}; - if (val == 0) { - val = HostnameToIp(rxHostname.c_str()); - } - return val; -} - -IpAddr CmdProxy::getSrcIpFromAuto() { - if (det->getDetectorType().squash() == defs::GOTTHARD) { - throw RuntimeError( - "Cannot use 'auto' for udp_srcip for GotthardI Detector."); - } - std::string hostname = - det->getHostname(std::vector{det_id}).squash("none"); - // Hostname could be ip try to decode otherwise look up the hostname - auto val = IpAddr{hostname}; - if (val == 0) { - val = HostnameToIp(hostname.c_str()); - } - return val; -} - -UdpDestination CmdProxy::getUdpEntry() { - UdpDestination udpDestination{}; - udpDestination.entry = rx_id; - - for (auto it : args) { - size_t pos = it.find('='); - std::string key = it.substr(0, pos); - std::string value = it.substr(pos + 1); - if (key == "ip") { - if (value == "auto") { - auto val = getDstIpFromAuto(); - LOG(logINFO) << "Setting udp_dstip of detector " << det_id - << " to " << val; - udpDestination.ip = val; - } else { - udpDestination.ip = IpAddr(value); - } - } else if (key == "ip2") { - if (value == "auto") { - auto val = getDstIpFromAuto(); - LOG(logINFO) << "Setting udp_dstip2 of detector " << det_id - << " to " << val; - udpDestination.ip2 = val; - } else { - udpDestination.ip2 = IpAddr(value); - } - } else if (key == "mac") { - udpDestination.mac = MacAddr(value); - } else if (key == "mac2") { - udpDestination.mac2 = MacAddr(value); - } else if (key == "port") { - udpDestination.port = StringTo(value); - } else if (key == "port2") { - udpDestination.port2 = StringTo(value); - } - } - return udpDestination; -} - -std::string CmdProxy::UDPDestinationList(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[ip=x.x.x.x] [(optional)ip2=x.x.x.x] " - "\n\t[mac=xx:xx:xx:xx:xx:xx] " - "[(optional)mac2=xx:xx:xx:xx:xx:xx]\n\t[port=value] " - "[(optional)port2=value\n\tThe order of ip, mac and port does " - "not matter. entry_value can be >0 only for " - "[Eiger][Jungfrau][Moench][Mythen3][Gotthard2] where round robin " - "is " - "implemented. If 'auto' used, then ip is set to ip of " - "rx_hostname." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - if (det_id == -1) { - throw RuntimeError("udp_dstlist must be at module level."); - } - if (rx_id < 0 || rx_id >= MAX_UDP_DESTINATION) { - throw RuntimeError(std::string("Invalid receiver index ") + - std::to_string(rx_id) + - std::string(" to set round robin entry.")); - } - auto t = det->getDestinationUDPList(rx_id, std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.empty()) { - WrongNumberOfParameters(1); - } - if (det_id == -1) { - throw RuntimeError("udp_dstlist must be at module level."); - } - if (rx_id < 0 || rx_id >= MAX_UDP_DESTINATION) { - throw RuntimeError( - "Invalid receiver index to set round robin entry."); - } - auto t = getUdpEntry(); - det->setDestinationUDPList(t, det_id); - os << ToString(args) << std::endl; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UDPSourceIP(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[x.x.x.x] or auto\n\tIp address of the detector (source) udp " - "interface. Must be same subnet as destination udp " - "ip.\n\t[Eiger] Set only for 10G. For 1G, detector will replace " - "with its own DHCP IP address. \n\tOne can also set this to " - "'auto' for 1 GbE data and virtual detectors. It will set to IP " - "of detector. Not available for GotthardI" - << '\n'; - } else if (action == defs::GET_ACTION) { - auto t = det->getSourceUDPIP(std::vector{det_id}); - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - IpAddr val; - if (args[0] == "auto") { - val = getSrcIpFromAuto(); - LOG(logINFO) << "Setting udp_srcip of detector " << det_id << " to " - << val; - } else { - val = IpAddr(args[0]); - } - det->setSourceUDPIP(val, std::vector{det_id}); - os << val << '\n'; - - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UDPSourceIP2(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[x.x.x.x] or auto\n\t[Jungfrau][Moench][Gotthard2] Ip address " - "of the " - "detector (source) udp interface 2. Must be same subnet as " - "destination udp ip2.\n\t [Jungfrau][Moench] top half or inner " - "interface\n\t [Gotthard2] veto debugging. \n\tOne can also set " - "this to 'auto' for 1 GbE data and virtual detectors. It will " - "set to IP of detector." - << '\n'; - } else if (action == defs::GET_ACTION) { - auto t = det->getSourceUDPIP2(std::vector{det_id}); - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - IpAddr val; - if (args[0] == "auto") { - val = getSrcIpFromAuto(); - LOG(logINFO) << "Setting udp_srcip2 of detector " << det_id - << " to " << val; - } else { - val = IpAddr(args[0]); - } - det->setSourceUDPIP2(val, std::vector{det_id}); - os << val << '\n'; - - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UDPDestinationIP(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[x.x.x.x] or auto\n\tIp address of the receiver (destination) " - "udp interface. If 'auto' used, then ip is set to ip of " - "rx_hostname." - << '\n'; - } else if (action == defs::GET_ACTION) { - auto t = det->getDestinationUDPIP(std::vector{det_id}); - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - if (args[0] == "auto") { - auto val = getDstIpFromAuto(); - LOG(logINFO) << "Setting udp_dstip of detector " << det_id << " to " - << val; - det->setDestinationUDPIP(val, std::vector{det_id}); - os << val << '\n'; - } else { - auto val = IpAddr(args[0]); - det->setDestinationUDPIP(val, std::vector{det_id}); - os << args.front() << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UDPDestinationIP2(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[x.x.x.x] or auto\n\t[Jungfrau][Moench][Gotthard2] Ip address " - "of the " - "receiver (destination) udp interface 2. If 'auto' used, then ip " - "is set to ip of rx_hostname.\n\t[Jungfrau][Moench] bottom half " - "\n\t[Gotthard2] veto debugging. " - << '\n'; - } else if (action == defs::GET_ACTION) { - auto t = det->getDestinationUDPIP2(std::vector{det_id}); - if (!args.empty()) { - WrongNumberOfParameters(0); - } - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - if (args[0] == "auto") { - auto val = getDstIpFromAuto(); - LOG(logINFO) << "Setting udp_dstip2 of detector " << det_id - << " to " << val; - det->setDestinationUDPIP2(val, std::vector{det_id}); - os << val << '\n'; - } else { - auto val = IpAddr(args[0]); - det->setDestinationUDPIP2(val, std::vector{det_id}); - os << args.front() << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::TransmissionDelay(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Set " - "transmission delay " - "for all modules in the detector using the step size " - "provided.Sets up \n\t\t[Eiger] txdelay_left to (2 * mod_index * " - "n_delay), \n\t\t[Eiger] txdelay_right to ((2 * mod_index + 1) * " - "n_delay) and \n\t\t[Eiger] txdelay_frame to (2 *num_modules * " - "n_delay) \n\t\t[Jungfrau][Moench][Mythen3] txdelay_frame to " - "(num_modules * n_delay) \nfor every module." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - if (args.size() != 0) { - WrongNumberOfParameters(0); - } - auto t = det->getTransmissionDelay(); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setTransmissionDelay(StringTo(args[0])); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Receiver Config */ -std::string CmdProxy::ReceiverHostname(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[hostname or ip address]\n\t" - "[hostname or ip address]:[tcp port]\n\t" - "[hostname1]:[tcp_port1]+[hostname2]:[tcp_port2]+\n\t" - "Receiver hostname or IP. If port included, then the receiver " - "tcp port.\n\t" - "Used for TCP control communication between client and receiver " - "to configure receiver. Also updates receiver with detector " - "parameters. Also resets any prior receiver property (not on " - "detector). " - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getRxHostname(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() < 1) { - WrongNumberOfParameters(1); - } - // multiple arguments - if (args.size() > 1) { - // multiple in mulitple - if (args[0].find('+') != std::string::npos) { - throw RuntimeError( - "Cannot add multiple receivers at module level"); - } - if (det_id != -1) { - throw RuntimeError( - "Cannot add multiple receivers at module level"); - } - det->setRxHostname(args); - os << ToString(args) << '\n'; - } - // single argument - else { - // multiple receivers concatenated with + - if (args[0].find('+') != std::string::npos) { - if (det_id != -1) { - throw RuntimeError( - "Cannot add multiple receivers at module level"); - } - auto t = split(args[0], '+'); - det->setRxHostname(t); - os << ToString(t) << '\n'; - } - // single receiver - else { - det->setRxHostname(args[0], std::vector{det_id}); - os << ToString(args) << '\n'; - } - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Rx_ROI(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[xmin] [xmax] [ymin] [ymax]\n\tRegion of interest in " - "receiver.\n\tOnly allowed at multi module level and without gap " - "pixels." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - if (det_id == -1) { - auto t = det->getRxROI(); - os << t << '\n'; - } else { - auto t = det->getIndividualRxROIs(std::vector{det_id}); - os << t << '\n'; - } - } else if (action == defs::PUT_ACTION) { - defs::ROI t; - // 2 or 4 arguments - if (args.size() != 2 && args.size() != 4) { - WrongNumberOfParameters(2); - } - if (args.size() == 2 || args.size() == 4) { - t.xmin = StringTo(args[0]); - t.xmax = StringTo(args[1]); - } - if (args.size() == 4) { - t.ymin = StringTo(args[2]); - t.ymax = StringTo(args[3]); - } - // only multi level - if (det_id != -1) { - throw RuntimeError("Cannot execute receiver ROI at module level"); - } - det->setRxROI(t); - os << t << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* File */ - -/* ZMQ Streaming Parameters (Receiver<->Client) */ - -std::string CmdProxy::ZMQHWM(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_limit] \n\tClient's zmq receive high water mark. Default is " - "the zmq library's default (1000), can also be set here using " - "-1. \n\tThis is a high number and can be set to 2 for gui " - "purposes. \n\tOne must also set the receiver's send high water " - "mark to similar value. Final effect is sum of them.\n\t Setting " - "it via command line is useful only before zmq enabled (before " - "opening gui)." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getClientZmqHwm(); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - int t = StringTo(args[0]); - det->setClientZmqHwm(t); - os << det->getClientZmqHwm() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Eiger Specific */ - -std::string CmdProxy::RateCorrection(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_rate (in ns)]\n\t[Eiger] Dead time correction constant in " - "ns. -1 will set to default tau of settings from trimbit file. 0 " - "will unset rate correction." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getRateCorrection(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - int tau = StringTo(args[0]); - if (tau == -1) { - det->setDefaultRateCorrection(std::vector{det_id}); - auto t = det->getRateCorrection(std::vector{det_id}); - os << OutString(t) << '\n'; - } else { - auto t = StringTo(args[0], "ns"); - det->setRateCorrection(t, std::vector{det_id}); - os << args.front() << "ns\n"; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PulsePixel(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times at " - "coordinates (x, y). Advanced User!" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 3) { - WrongNumberOfParameters(3); - } - int n = StringTo(args[0]); - defs::xy c; - c.x = StringTo(args[1]); - c.y = StringTo(args[2]); - det->pulsePixel(n, c, std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PulsePixelAndMove(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_times] [x] [y]\n\t[Eiger] Pulse pixel n number of times and " - "moves relatively by (x, y). Advanced User!" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 3) { - WrongNumberOfParameters(3); - } - int n = StringTo(args[0]); - defs::xy c; - c.x = StringTo(args[1]); - c.y = StringTo(args[2]); - det->pulsePixelNMove(n, c, std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PulseChip(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_times] \n\t[Eiger] Pulse chip n times. If n is -1, resets to " - "normal mode (reset chip completely at start of acquisition, " - "where partialreset = 0). Advanced User!" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->pulseChip(StringTo(args[0]), std::vector{det_id}); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Quad(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[0, 1]\n\t[Eiger] Sets detector size to a quad. 0 (disabled) is " - "default. (Specific hardware required)." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getQuad(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot execute quad at module level"); - } - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setQuad(StringTo(args[0])); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DataStream(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[left|right] [0, 1]\n\t[Eiger] Enables or disables data " - "streaming from left or/and right side of detector for 10 GbE " - "mode. " - "1 (enabled) " - "by default." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->getDataStream(StringTo(args[0]), - std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setDataStream(StringTo(args[0]), - StringTo(args[1]), std::vector{det_id}); - os << args << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Jungfrau Specific */ - -std::string CmdProxy::TemperatureEvent(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[0]\n\t[Jungfrau][Moench] 1, if a temperature event occured. To " - "clear " - "this event, set it to 0.\n\tIf temperature crosses threshold " - "temperature and temperature control is enabled, power to chip " - "will be switched off and temperature event occurs. To power on " - "chip again, temperature has to be less than threshold " - "temperature and temperature event has to be cleared." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getTemperatureEvent(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - if (StringTo(args[0]) != 0) { - throw RuntimeError("Unknown argument for temp event. Did you " - "mean 0 to reset event?"); - } - det->resetTemperatureEvent(std::vector{det_id}); - os << "cleared" << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PedestalMode(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << " [frames] [loops]\n\t\t[Jungfrau] " - "Enable pedestal mode. \n\t\tThe number of frames or triggers is " - "overwritten by: \n\t\t(#pedestal_frames x #pedestal_loops x 2). " - "\n\t\tIn auto timing mode or in trigger mode with #frames > 1, " - "\n\t\t#frames is overwritten and #triggers = 1, \n\t\telse " - "#triggers is overwritten and #frames = 1. \n\t\tOne cannot set " - "#frames, #triggers or timing mode in pedestal mode (exception " - "thrown).\n\n"; - os << cmd - << " [0]\n\t\t[Jungfrau] Disable pedestal " - "mode.\n\t\tDisabling pedestal mode will set back the normal " - "mode values of #frames and #triggers." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 0) { - WrongNumberOfParameters(0); - } - auto t = det->getPedestalMode(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - // disable - if (args.size() == 1) { - if (args[0] != "0") { - throw RuntimeError( - "Unknown argument " + args[0] + - ". Did you mean '0' to disable pedestal mode?"); - } - det->setPedestalMode(defs::pedestalParameters()); - } - // enable - else if (args.size() == 2) { - uint8_t frames = StringTo(args[0]); - uint16_t loops = StringTo(args[1]); - det->setPedestalMode(defs::pedestalParameters(frames, loops)); - } else { - throw RuntimeError( - "Invalid number of parareters for this command."); - } - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Gotthard Specific */ - -std::string CmdProxy::ROI(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[xmin] [xmax] \n\t[Gotthard] Region of interest in detector.\n\t" - "Options: Only a single ROI per module. \n\tEither all channels " - "or a single adc or 2 chips (256 channels). Default is all " - "channels enabled (-1 -1). " - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getROI(std::vector{det_id}); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id == -1 && det->size() > 1) { - throw RuntimeError("Cannot execute ROI at multi module level"); - } - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - defs::ROI t(StringTo(args[0]), StringTo(args[1])); - det->setROI(t, det_id); - os << t << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Gotthard2 Specific */ - -std::string CmdProxy::InjectChannel(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[offset] [increment]\n\t[Gotthard2] Inject channels with " - "current source for calibration. Offset is starting channel that " - "is injected, increment determines succeeding channels to be " - "injected." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getInjectChannel(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setInjectChannel(StringTo(args[0]), StringTo(args[1]), - {det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::VetoPhoton(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[ichip] [#photons] [energy in keV] [reference " - "file]\n\t[Gotthard2] Set veto reference for 128 channels for " - "chip ichip according to reference file and #photons and energy " - "in keV.\n[ichip] [output file]\n\t Get gain indices and veto " - "reference for 128 channels for chip ichip, saved to file." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->getVetoPhoton(StringTo(args[0]), args[1], - std::vector{det_id}); - os << "saved to file " << args[1] << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 4) { - WrongNumberOfParameters(4); - } - det->setVetoPhoton(StringTo(args[0]), StringTo(args[1]), - StringTo(args[2]), args[3], - std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::VetoReference(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[gain index] [12 bit value] \n\t[Gotthard2] Set veto " - "reference for all 128 channels for all chips." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get vetoref. Did you mean vetophoton?"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setVetoReference(StringTo(args[0]), StringTo(args[1]), - {det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::VetoFile(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[chip index 0-10, -1 for all] [file name] \n\t[Gotthard2] Set " - "veto reference for each 128 channels for specific chip. The " - "file should have 128 rows of gain index and 12 bit value in dec" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("cannot get vetofile. Did you mean vetophoton?"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setVetoFile(StringTo(args[0]), args[1], - std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::BurstMode(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[burst_internal or 0, burst_external or 1, cw_internal or 2, " - "cw_external or 3]\n\t[Gotthard2] Default is burst_internal " - "type. Also changes clkdiv 2, 3, 4" - << '\n'; - } else { - if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getBurstMode(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - defs::burstMode t; - try { - int ival = StringTo(args[0]); - switch (ival) { - case 0: - t = defs::BURST_INTERNAL; - break; - case 1: - t = defs::BURST_EXTERNAL; - break; - case 2: - t = defs::CONTINUOUS_INTERNAL; - break; - case 3: - t = defs::CONTINUOUS_EXTERNAL; - break; - default: - throw RuntimeError("Unknown burst mode " + args[0]); - } - } catch (...) { - t = StringTo(args[0]); - } - det->setBurstMode(t, std::vector{det_id}); - os << ToString(t) << '\n'; // no args to convert 0,1,2 as well - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::VetoStreaming(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[none|lll|10gbe|...]\n\t[Gotthard2] Enable or disable the 2 " - "veto streaming interfaces available. Can include more than one " - "interface. \n\tDefault: none. lll (low latency link) is the " - "default interface to work with. \n\t10GbE is for debugging and " - "also enables second interface in receiver for listening to veto " - "packets (writes a separate file if writing enabled). Also " - "restarts client and receiver zmq sockets if zmq streaming " - "enabled." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getVetoStream(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.empty()) { - WrongNumberOfParameters(1); - } - defs::streamingInterface interface = defs::streamingInterface::NONE; - for (const auto &arg : args) { - if (arg == "none") { - if (args.size() > 1) { - throw RuntimeError( - std::string( - "cannot have other arguments with 'none'. args: ") + - ToString(args)); - } - break; - } - interface = interface | (StringTo(arg)); - } - det->setVetoStream(interface, std::vector{det_id}); - os << ToString(interface) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::VetoAlgorithm(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[hits|raw] [lll|10gbe]\n\t[Gotthard2] Set the veto " - "algorithm. Default is hits." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - defs::streamingInterface interface = - StringTo(args[0]); - if (interface == defs::streamingInterface::NONE) { - throw RuntimeError("Must specify an interface to set algorithm"); - } - auto t = det->getVetoAlgorithm(interface, std::vector{det_id}); - os << OutString(t) << ' ' << ToString(interface) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - defs::vetoAlgorithm alg = StringTo(args[0]); - defs::streamingInterface interface = - StringTo(args[1]); - if (interface == defs::streamingInterface::NONE) { - throw RuntimeError("Must specify an interface to set algorithm"); - } - det->setVetoAlgorithm(alg, interface, std::vector{det_id}); - os << ToString(alg) << ' ' << ToString(interface) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ConfigureADC(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[chip index 0-9, -1 for all] [adc index 0-31, -1 for all] [7 " - "bit configuration value in hex]\n\t[Gotthard2] Sets " - "configuration for specific chip and adc, but configures 1 chip " - "(all adcs for that chip) at a time." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - auto t = det->getADCConfiguration(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << OutStringHex(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 3) { - WrongNumberOfParameters(3); - } - int value = StringTo(args[2]); - det->setADCConfiguration(StringTo(args[0]), StringTo(args[1]), - value, std::vector{det_id}); - os << '[' << args[0] << ", " << args[1] << ", " << ToStringHex(value) - << "]\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Mythen3 Specific */ - -std::string CmdProxy::Counters(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[i0] [i1] [i2]... \n\t[Mythen3] List of counters indices " - "enabled. Each element in list can be 0 - 2 and must be non " - "repetitive. Enabling counters sets vth dacs to remembered " - "values and disabling sets them to disabled values." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto mask = det->getCounterMask(std::vector{det_id}).squash(-1); - os << ToString(getSetBits(mask)) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.empty()) { - WrongNumberOfParameters(1); - } - if (std::any_of(args.cbegin(), args.cend(), [](std::string s) { - return (StringTo(s) < 0 || StringTo(s) > 2); - })) { - throw RuntimeError("Invalid counter indices list. Example: 0 1 2"); - } - // convert vector to counter enable mask - uint32_t mask = 0; - for (size_t i = 0; i < args.size(); ++i) { - int val = StringTo(args[i]); - // already enabled earlier - if (mask & (1 << val)) { - std::ostringstream oss; - oss << "Duplicate counter values (" << val << ") in arguments"; - throw RuntimeError(oss.str()); - } - mask |= (1 << val); - } - det->setCounterMask(mask, std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::GateDelay(int action) { - int gateIndex = -1; - if (cmd == "gatedelay") { - gateIndex = -1; - } else if (cmd == "gatedelay1") { - gateIndex = 0; - } else if (cmd == "gatedelay2") { - gateIndex = 1; - } else if (cmd == "gatedelay3") { - gateIndex = 2; - } else { - throw RuntimeError("Unknown command, use list to list all commands"); - } - - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "gatedelay") { - os << "[duration] [(optional unit) ns|us|ms|s]\n\t[Mythen3] Gate " - "Delay of all gate signals in auto and trigger mode " - "(internal gating)." - << '\n'; - } else if (cmd == "gatedelay1") { - os << "[n_value]\n\t[Mythen3] Gate Delay of gate signal 1 in auto " - "and trigger mode (internal gating)." - << '\n'; - } else if (cmd == "gatedelay2") { - os << "[n_value]\n\t[Mythen3] Gate Delay of gate signal 2 in auto " - "and trigger mode (internal gating)." - << '\n'; - } else { - os << "[n_value]\n\t[Mythen3] Gate Delay of gate signal 3 in auto " - "and trigger mode (internal gating)." - << '\n'; - } - } else if (action == defs::GET_ACTION) { - if (args.size() > 1) { - WrongNumberOfParameters(1); - } - // vector of gate delays - if (gateIndex == -1) { - auto t = det->getGateDelayForAllGates(std::vector{det_id}); - if (args.empty()) { - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - os << OutString(t, args[0]) << '\n'; - } - } - // single gate delay - else { - auto t = det->getGateDelay(gateIndex, std::vector{det_id}); - if (args.empty()) { - os << OutString(t) << '\n'; - } else if (args.size() == 1) { - os << OutString(t, args[0]) << '\n'; - } - } - } else if (action == defs::PUT_ACTION) { - if (args.size() == 1) { - std::string time_str(args[0]); - std::string unit = RemoveUnit(time_str); - auto t = StringTo(time_str, unit); - det->setGateDelay(gateIndex, t, std::vector{det_id}); - } else if (args.size() == 2) { - auto t = StringTo(args[0], args[1]); - det->setGateDelay(gateIndex, t, std::vector{det_id}); - } else { - WrongNumberOfParameters(2); - } - /* TODO: os << args << '\n'; (doesnt work for vectors in .h)*/ - if (args.size() > 1) { - os << args[0] << args[1] << '\n'; - } else { - os << args[0] << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::GainCaps(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[cap1, cap2, ...]\n\t[Mythen3] gain, options: C10pre, C15sh, " - "C30sh, C50sh, C225ACsh, C15pre" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) - WrongNumberOfParameters(0); - - auto tmp = det->getGainCaps(); - Result csr; - for (auto val : tmp) { - if (val) - csr.push_back(static_cast(val)); - } - - os << OutString(csr) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() < 1) { - WrongNumberOfParameters(1); - } - int caps = 0; - for (const auto &arg : args) { - if (arg != "0") - caps |= StringTo(arg); - } - - det->setGainCaps(caps); - os << OutString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* CTB Specific */ - -std::string CmdProxy::Samples(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_samples]\n\t[CTB] Number of samples (analog, digitial and " - "transceiver) expected.\n" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto a = det->getNumberOfAnalogSamples(std::vector{det_id}); - // get also digital samples for ctb and compare with analog - if (det->getDetectorType().squash() == defs::CHIPTESTBOARD) { - auto d = det->getNumberOfDigitalSamples(std::vector{det_id}); - auto t = - det->getNumberOfTransceiverSamples(std::vector{det_id}); - int as = a.squash(-1); - int ds = d.squash(-1); - int ts = t.squash(-1); - if (as == -1 || ds == -1 || ts == -1 || as != ds || - as != ts) { // check if a == d? - throw RuntimeError( - "Different samples. Use asamples, dsamples or tsamples."); - } - } - os << OutString(a) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setNumberOfAnalogSamples(StringTo(args[0]), - std::vector{det_id}); - // set also digital samples for ctb - if (det->getDetectorType().squash() == defs::CHIPTESTBOARD) { - det->setNumberOfDigitalSamples(StringTo(args[0]), - std::vector{det_id}); - det->setNumberOfTransceiverSamples(StringTo(args[0]), - std::vector{det_id}); - } - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* CTB Specific */ -std::string CmdProxy::AdcVpp(int action) { - std::ostringstream os; - os << cmd << ' '; - - if (action == defs::HELP_ACTION) { - os << "[dac or mV value][(optional unit) mV] \n\t[Ctb] Vpp of " - "ADC.\n\t 0 -> 1V ; 1 -> 1.14V ; 2 -> 1.33V ; 3 -> 1.6V ; 4 -> " - "2V. \n\tAdvanced User function!\n" - << '\n'; - return os.str(); - } - - if (action == defs::GET_ACTION) { - bool mV = false; - - if (args.size() == 1) { - if ((args[0] != "mv") && (args[0] != "mV")) { - throw RuntimeError("Unknown argument " + args[0] + - ". Did you mean mV?"); - } - mV = true; - } else if (args.size() > 1) { - WrongNumberOfParameters(1); - } - auto t = det->getADCVpp(mV, std::vector{det_id}); - os << OutString(t) << (mV ? " mV\n" : "\n"); - } else if (action == defs::PUT_ACTION) { - bool mV = false; - if (args.size() == 2) { - if ((args[1] != "mv") && (args[1] != "mV")) { - throw RuntimeError("Unknown argument " + args[1] + - ". Did you mean mV?"); - } - mV = true; - } else if (args.size() > 2 || args.size() < 1) { - WrongNumberOfParameters(1); - } - det->setADCVpp(StringTo(args[0]), mV, std::vector{det_id}); - os << args[0] << (mV ? " mV\n" : "\n"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::SlowADC(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[n_channel (0-7 for channel]\n\t[Ctb] Slow " - "ADC channel in mV" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(0); - } - int nchan = StringTo(args[0]); - if (nchan < 0 || nchan > 7) { - throw RuntimeError("Unknown adc argument " + args[0]); - } - auto t = det->getSlowADC( - static_cast(nchan + defs::SLOW_ADC0), - std::vector{det_id}); - Result result(t.size()); - for (unsigned int i = 0; i < t.size(); ++i) { - result[i] = t[i] / 1000.00; - } - os << OutString(result) << " mV\n"; - - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("cannot put"); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ReceiverDbitList(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[all] or [i0] [i1] [i2]... \n\t[Ctb] List of digital signal " - "bits read out. If all is used instead of a list, all digital " - "bits (64) enabled. Each element in list can be 0 - 63 and must " - "be non repetitive." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getRxDbitList(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.empty()) { - WrongNumberOfParameters(1); - } - std::vector t; - if (args[0] == "all") { - t.resize(64); - for (unsigned int i = 0; i < 64; ++i) { - t[i] = i; - } - } else { - unsigned int ntrim = args.size(); - t.resize(ntrim); - for (unsigned int i = 0; i < ntrim; ++i) { - t[i] = StringTo(args[i]); - } - } - det->setRxDbitList(t, std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::DigitalIODelay(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[64 bit bitmask] [0-775]\n\t[Ctb] Delay for digital IO pins " - "selected by the bitmask. Delay is in ps and max of 775 ps. " - "Resolution is 25 ps." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->setDigitalIODelay(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Pattern */ - -std::string CmdProxy::Pattern(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[fname]\n\t[Mythen3][Ctb] Loads ASCII pattern file " - "directly to server (instead of executing line by line)" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setPattern(args[0], std::vector{det_id}); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::PatternWord(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[step or address] [64 bit mask]\n\t[Ctb][Mythen3] 64 " - "bit pattern at address of pattern memory.\n\t[Ctb] read " - "is same as executing pattern" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - int addr = StringTo(args[0]); - auto t = det->getPatternWord(addr, std::vector{det_id}); - os << '[' << ToStringHex(addr, 4) << ", " << OutStringHex(t, 16) - << "]\n"; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - int addr = StringTo(args[0]); - uint64_t word = StringTo(args[1]); - det->setPatternWord(addr, word, std::vector{det_id}); - os << '[' << ToStringHex(addr, 4) << ", " << ToStringHex(word, 16) - << "]\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -void CmdProxy::GetLevelAndUpdateArgIndex(int action, - std::string levelSeparatedCommand, - int &level, int &iArg, size_t nGetArgs, - size_t nPutArgs) { - if (cmd == levelSeparatedCommand) { - ++nGetArgs; - ++nPutArgs; - } else { - LOG(logWARNING) << "This command is deprecated and will be removed. " - "Please migrate to " - << levelSeparatedCommand; - } - if (action == defs::GET_ACTION && args.size() != nGetArgs) { - WrongNumberOfParameters(nGetArgs); - } else if (action == defs::PUT_ACTION && args.size() != nPutArgs) { - WrongNumberOfParameters(nPutArgs); - } - if (cmd == levelSeparatedCommand) { - level = StringTo(args[iArg++]); - } else { - level = cmd[cmd.find_first_of("012")] - '0'; - } -} - -std::string CmdProxy::PatternLoopAddresses(int action) { - if (cmd != "patlimits" && cmd != "patloop0" && cmd != "patloop1" && - cmd != "patloop2" && cmd != "patloop") { - throw RuntimeError("Unknown command, use list to list all commands"); - } - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "patlimits") { - os << "[start addr] [stop addr] \n\t[Ctb][Mythen3] Limits " - "of complete pattern." - << '\n'; - } else if (cmd == "patloop") { - os << "[0-6] [start addr] [stop addr] \n\t[Ctb][Mythen3] " - "Limits of the loop level provided." - << "\n\t[Mythen3] Level options: 0-3 only." << '\n'; - } else { - os << "Depreciated command. Use patloop." << '\n'; - } - } else { - int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 2; - if (cmd != "patlimits") { - GetLevelAndUpdateArgIndex(action, "patloop", level, iArg, nGetArgs, - nPutArgs); - if (cmd != "patloop0" && cmd != "patloop1" && cmd != "patloop2") - os << level << ' '; - } - if (action == defs::GET_ACTION) { - auto t = - det->getPatternLoopAddresses(level, std::vector{det_id}); - os << OutStringHex(t, 4) << '\n'; - } else if (action == defs::PUT_ACTION) { - int start = StringTo(args[iArg++]); - int stop = StringTo(args[iArg++]); - det->setPatternLoopAddresses(level, start, stop, - std::vector{det_id}); - os << '[' << ToStringHex(start, 4) << ", " << ToStringHex(stop, 4) - << "]\n"; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::PatternLoopCycles(int action) { - if (cmd != "patnloop0" && cmd != "patnloop1" && cmd != "patnloop2" && - cmd != "patnloop") { - throw RuntimeError("Unknown command, use list to list all commands"); - } - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "patnloop") { - os << "[0-6] [n_cycles] \n\t[Ctb][Mythen3] Number of " - "cycles of " - "the loop level provided." - << "\n\t[Mythen3] Level options: 0-3 only." << '\n'; - } else { - os << "Depreciated command. Use patnloop." << '\n'; - } - } else { - int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; - GetLevelAndUpdateArgIndex(action, "patnloop", level, iArg, nGetArgs, - nPutArgs); - if (cmd != "patnloop0" && cmd != "patnloop1" && cmd != "patnloop2") - os << level << ' '; - if (action == defs::GET_ACTION) { - auto t = det->getPatternLoopCycles(level, std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - int nloops = StringTo(args[iArg++]); - det->setPatternLoopCycles(level, nloops, std::vector{det_id}); - os << nloops << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::PatternWaitAddress(int action) { - if (cmd != "patwait0" && cmd != "patwait1" && cmd != "patwait2" && - cmd != "patwait") { - throw RuntimeError("Unknown command, use list to list all commands"); - } - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "patwait") { - os << "[0-6] [addr] \n\t[Ctb][Mythen3] Wait address for " - "loop level provided." - << "\n\t[Mythen3] Level options: 0-3 only."; - } else { - os << "Depreciated command. Use patwait."; - } - os << '\n'; - } else { - int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; - GetLevelAndUpdateArgIndex(action, "patwait", level, iArg, nGetArgs, - nPutArgs); - if (cmd != "patwait0" && cmd != "patwait1" && cmd != "patwait2") - os << level << ' '; - if (action == defs::GET_ACTION) { - auto t = det->getPatternWaitAddr(level, std::vector{det_id}); - os << OutStringHex(t, 4) << '\n'; - } else if (action == defs::PUT_ACTION) { - int addr = StringTo(args[iArg++]); - det->setPatternWaitAddr(level, addr, std::vector{det_id}); - os << ToStringHex(addr, 4) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::PatternWaitTime(int action) { - if (cmd != "patwaittime0" && cmd != "patwaittime1" && - cmd != "patwaittime2" && cmd != "patwaittime") { - throw RuntimeError("Unknown command, use list to list all commands"); - } - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "patwaittime") { - os << "[0-6] [n_clk] \n\t[Ctb][Mythen3] Wait time in clock " - "cycles for the loop provided." - << "\n\t[Mythen3] Level options: 0-3 only." << '\n'; - } else { - os << "Depreciated command. Use patwaittime." << '\n'; - } - } else { - int level = -1, iArg = 0, nGetArgs = 0, nPutArgs = 1; - GetLevelAndUpdateArgIndex(action, "patwaittime", level, iArg, nGetArgs, - nPutArgs); - if (cmd != "patwaittime0" && cmd != "patwaittime1" && - cmd != "patwaittime2") - os << level << ' '; - if (action == defs::GET_ACTION) { - auto t = det->getPatternWaitTime(level, std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - uint64_t waittime = StringTo(args[iArg++]); - det->setPatternWaitTime(level, waittime, {det_id}); - os << waittime << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -/* Advanced */ - -std::string CmdProxy::AdditionalJsonHeader(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[key1] [value1] [key2] [value2]...[keyn] [valuen]\n\tAdditional " - "json header to be streamed out from receiver via zmq. Default " - "is empty. Max 20 characters for each key/value. Use only if to " - "be processed by an intermediate user process listening to " - "receiver zmq packets. Empty value deletes header. " - << '\n'; - } else if (action == defs::GET_ACTION) { - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getAdditionalJsonHeader(std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - // arguments can be empty - std::map json; - for (size_t i = 0; i < args.size(); i = i + 2) { - // last value is empty - if (i + 1 >= args.size()) { - json[args[i]] = ""; - } else { - json[args[i]] = args[i + 1]; - } - } - det->setAdditionalJsonHeader(json, std::vector{det_id}); - os << ToString(json) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::JsonParameter(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[key1] [value1]\n\tAdditional json header parameter streamed " - "out from receiver. If not found in header, the pair is " - "appended. An empty values deletes parameter. Max 20 characters " - "for each key/value." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = - det->getAdditionalJsonParameter(args[0], std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - switch (args.size()) { - case 1: - det->setAdditionalJsonParameter(args[0], "", - std::vector{det_id}); - break; - case 2: - det->setAdditionalJsonParameter(args[0], args[1], - std::vector{det_id}); - break; - default: - WrongNumberOfParameters(1); - } - if (args.size() == 1) { - os << args[0] << " deleted" << '\n'; - } else { - os << "{" << args[0] << ": " << args[1] << "}" << '\n'; - } - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::ProgramFpga(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[fname.pof | fname.rbf (full " - "path)][(opitonal)--force-delete-normal-file]\n\t[Jungfrau][" - "Moench][Ctb] " - "Programs FPGA from pof file (full path). Then, detector " - "controller is rebooted. \n\t\tUse --force-delete-normal-file " - "argument, if normal file found in device tree, it must be " - "deleted, a new device drive created and programming " - "continued.\n\t[Mythen3][Gotthard2] Programs FPGA from rbf file " - "(full path). Then, detector controller is rebooted." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - bool forceDeteleNormalFile = false; - if (args.size() == 2) { - if (args[1] != "--force-delete-normal-file") { - throw RuntimeError("Could not scan second argument. Did you " - "mean --force-delete-normal-file?"); - } - forceDeteleNormalFile = true; - } else if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->programFPGA(args[0], forceDeteleNormalFile, - std::vector{det_id}); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UpdateDetectorServer(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[server_name with full " - "path]\n\t[Jungfrau][Moench][Eiger][Ctb][Mythen3][Gotthard2] " - "Copies detector server via TCP (without tftp). Makes a symbolic " - "link with a shorter name (without vx.x.x). Then, detector " - "controller reboots (except " - "Eiger).\n\t[Jungfrau][Moench][Ctb]Also changes respawn server " - "to the link, which is effective after a reboot." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->updateDetectorServer(args[0], std::vector{det_id}); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UpdateKernel(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[kernel_name with full " - "path]\n\t[Jungfrau][Moench][Ctb][Mythen3][Gotthard2] Advanced " - "Command!! You could damage the detector. Please use with " - "caution.\n\tUpdates the kernel image. Then, detector controller " - "reboots with new kernel." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->updateKernel(args[0], std::vector{det_id}); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UpdateFirmwareAndDetectorServer(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tWithout tftp: [server_name (incl fullpath)] [fname.pof " - "(incl full path)] This does not use " - "tftp.\n\t\t[Jungfrau][Moench][Gotthard][CTB] Updates the " - "firmware, detector server, deletes old server, creates the " - "symbolic link and then reboots detector controller. " - "\n\t\t[Mythen3][Gotthard2] will require a script to start up " - "the shorter named server link at start up. \n\t\tserver_name is " - "full path name of detector server binary\n\t\tfname is full " - "path of programming file" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get"); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - int fpos = args.size() - 1; - if (args[fpos].find(".pof") == std::string::npos && - args[fpos].find(".rbf") == std::string::npos) { - throw RuntimeError("Programming file must be a pof/rbf file."); - } - det->updateFirmwareAndServer(args[0], args[1], - std::vector{det_id}); - os << "successful\n"; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::Register(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[address] [32 bit value]\n\tReads/writes to a 32 bit register " - "in hex. Advanced Function!\n\tGoes to stop server. Hence, can " - "be called while calling blocking acquire(). \n\t[Eiger] +0x100 " - "for only left, +0x200 for only right." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - auto t = det->readRegister(StringTo(args[0]), - std::vector{det_id}); - os << OutStringHex(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->writeRegister(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::AdcRegister(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[address] [value]\n\t[Jungfrau][Moench][Ctb][Gotthard] Writes " - "to an adc register in hex. Advanced user Function!" - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get."); - } else if (action == defs::PUT_ACTION) { - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - det->writeAdcRegister(StringTo(args[0]), - StringTo(args[1]), - std::vector{det_id}); - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::BitOperations(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - if (cmd == "setbit") { - os << "[reg address in hex] [bit index]\n\tSets bit in address." - << '\n'; - } else if (cmd == "clearbit") { - os << "[reg address in hex] [bit index]\n\tClears bit in address." - << '\n'; - } else if (cmd == "getbit") { - os << "[reg address in hex] [bit index]\n\tGets bit in address." - << '\n'; - } else { - throw RuntimeError( - "Unknown command, use list to list all commands"); - } - } else { - if (cmd != "setbit" && cmd != "clearbit" && cmd != "getbit") { - throw RuntimeError( - "Unknown command, use list to list all commands"); - } - if (args.size() != 2) { - WrongNumberOfParameters(2); - } - auto addr = StringTo(args[0]); - auto bitnr = StringTo(args[1]); - if (bitnr < 0 || bitnr > 31) { - return std::string("Bit number out of range") + - std::to_string(bitnr); - } - if (action == defs::GET_ACTION) { - if (cmd == "setbit" || cmd == "clearbit") { - throw RuntimeError("Cannot get"); - } - auto t = det->getBit(addr, bitnr, std::vector{det_id}); - os << OutString(t) << '\n'; - } else if (action == defs::PUT_ACTION) { - if (cmd == "getbit") { - throw RuntimeError("Cannot put"); - } - if (cmd == "setbit") { - det->setBit(addr, bitnr, std::vector{det_id}); - } else if (cmd == "clearbit") { - det->clearBit(addr, bitnr, std::vector{det_id}); - } - os << ToString(args) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - } - return os.str(); -} - -std::string CmdProxy::InitialChecks(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[0, 1]\n\tEnable or disable intial compatibility and other " - "checks at detector start up. It is enabled by default. Must " - "come before 'hostname' command to take effect. Can be used to " - "reprogram fpga when current firmware is " - "incompatible.\n\tAdvanced User function!" - << '\n'; - } else if (action == defs::GET_ACTION) { - if (det_id != -1) { - throw RuntimeError( - "Cannot enable/disable initial checks at module level"); - } - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getInitialChecks(); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - if (det_id != -1) { - throw RuntimeError( - "Cannot get initial checks enable at module level"); - } - if (args.size() != 1) { - WrongNumberOfParameters(1); - } - det->setInitialChecks(StringTo(args[0])); - os << args.front() << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -/* Insignificant */ - -std::string CmdProxy::ExecuteCommand(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "[command]\n\tExecutes command on detector server console." - << '\n'; - } else if (action == defs::GET_ACTION) { - throw RuntimeError("Cannot get."); - } else if (action == defs::PUT_ACTION) { - std::string command; - for (auto &i : args) { - command += (i + ' '); - } - auto t = det->executeCommand(command, std::vector{det_id}); - os << OutString(t) << '\n'; - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -std::string CmdProxy::UserDetails(int action) { - std::ostringstream os; - os << cmd << ' '; - if (action == defs::HELP_ACTION) { - os << "\n\tUser details from shared memory (hostname, type, PID, User, " - "Date)." - << '\n'; - } else if (action == defs::GET_ACTION) { - if (det_id != -1) { - throw RuntimeError("Cannot execute this at module level"); - } - if (!args.empty()) { - WrongNumberOfParameters(0); - } - auto t = det->getUserDetails(); - os << t << '\n'; - } else if (action == defs::PUT_ACTION) { - throw RuntimeError("Cannot put."); - } else { - throw RuntimeError("Unknown action"); - } - return os.str(); -} - -} // namespace sls diff --git a/slsDetectorSoftware/src/CmdProxy.h b/slsDetectorSoftware/src/CmdProxy.h deleted file mode 100644 index f53cd6407..000000000 --- a/slsDetectorSoftware/src/CmdProxy.h +++ /dev/null @@ -1,2654 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#pragma once - -#include "sls/Detector.h" -#include "sls/Result.h" -#include "sls/network_utils.h" -#include "sls/sls_detector_exceptions.h" -#include -#include -#include -#include - -namespace sls { - -/** Macro to make an integer command. - * CMDNAME name of the function that does the command - * GETFCN Detector function to get - * SETFCN Detector function to set - * CONV Function to convert from string to the correct integer type - * HLPSTR Help string for --help and docs - */ - -#define TIME_COMMAND(CMDNAME, GETFCN, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - auto t = det->GETFCN(std::vector{det_id}); \ - if (args.empty()) { \ - os << OutString(t) << '\n'; \ - } else if (args.size() == 1) { \ - os << OutString(t, args[0]) << '\n'; \ - } else { \ - WrongNumberOfParameters(1); \ - } \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() == 1) { \ - std::string time_str(args[0]); \ - std::string unit = RemoveUnit(time_str); \ - auto t = StringTo(time_str, unit); \ - det->SETFCN(t, std::vector{det_id}); \ - } else if (args.size() == 2) { \ - auto t = StringTo(args[0], args[1]); \ - det->SETFCN(t, std::vector{det_id}); \ - } else { \ - WrongNumberOfParameters(2); \ - } \ - /* TODO: os << args << '\n'; (doesnt work for vectors in .h)*/ \ - if (args.size() > 1) { \ - os << args[0] << args[1] << '\n'; \ - } else { \ - os << args[0] << '\n'; \ - } \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** time get only */ -#define TIME_GET_COMMAND(CMDNAME, GETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - auto t = det->GETFCN(std::vector{det_id}); \ - if (args.empty()) { \ - os << OutString(t) << '\n'; \ - } else if (args.size() == 1) { \ - os << OutString(t, args[0]) << '\n'; \ - } else { \ - WrongNumberOfParameters(1); \ - } \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** string */ -#define STRING_COMMAND(CMDNAME, GETFCN, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - det->SETFCN(args[0], std::vector{det_id}); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int or enum hex with 16 bit width (64 bit)*/ -#define INTEGER_COMMAND_HEX_WIDTH16(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutStringHex(t, 16) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val, std::vector{det_id}); \ - os << ToStringHex(val, 16) << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int or enum hex */ -#define INTEGER_COMMAND_HEX(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutStringHex(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val, std::vector{det_id}); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int or enum */ -#define INTEGER_COMMAND_VEC_ID(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val, std::vector{det_id}); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define INTEGER_COMMAND_VEC_ID_GET(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val, det_id); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int or enum */ -#define INTEGER_COMMAND_SINGLE_ID(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(det_id); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val, det_id); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int, set no id, get id */ -#define INTEGER_COMMAND_SET_NOID_GET_ID(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (det_id != -1) { \ - throw RuntimeError("Cannot execute this at module level"); \ - } \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int, no id */ -#define INTEGER_COMMAND_NOID(CMDNAME, GETFCN, SETFCN, CONV, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (det_id != -1) { \ - throw RuntimeError("Cannot execute this at module level"); \ - } \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(val); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int with index */ -#define INTEGER_IND_COMMAND(CMDNAME, GETFCN, SETFCN, CONV, INDEX, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(INDEX, std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto val = CONV(args[0]); \ - det->SETFCN(INDEX, val, std::vector{det_id}); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** int with user index */ -#define INTEGER_USER_IND_COMMAND(CMDNAME, GETFCN, SETFCN, CONV, INDEX, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto t = det->GETFCN(INDEX, StringTo(args[0]), \ - std::vector{det_id}); \ - os << args[0] << ' ' << OutStringHex(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 2) { \ - WrongNumberOfParameters(2); \ - } \ - auto val = CONV(args[1]); \ - det->SETFCN(INDEX, StringTo(args[0]), val, \ - std::vector{det_id}); \ - os << args[0] << ' ' << args[1] << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** set only, no arguments, no id */ -#define EXECUTE_SET_COMMAND_NOID(CMDNAME, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (det_id != -1) { \ - throw RuntimeError("Cannot execute this at module level"); \ - } \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - throw RuntimeError("Cannot get"); \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - det->SETFCN(); \ - os << "successful\n"; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** set only, no arguments */ -#define EXECUTE_SET_COMMAND(CMDNAME, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - throw RuntimeError("Cannot get"); \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - det->SETFCN(std::vector{det_id}); \ - os << "successful\n"; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** set only, 1 argument, no id */ -#define EXECUTE_SET_COMMAND_NOID_1ARG(CMDNAME, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (det_id != -1) { \ - throw RuntimeError("Cannot execute this at module level"); \ - } \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - throw RuntimeError("Cannot get"); \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - det->SETFCN(args[0]); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** set only, 1 argument */ -#define EXECUTE_SET_COMMAND_1ARG(CMDNAME, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - throw RuntimeError("Cannot get"); \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - det->SETFCN(args[0], std::vector{det_id}); \ - os << args.front() << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** get only */ -#define GET_COMMAND(CMDNAME, GETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** get only no id (vector, not result) */ -#define GET_COMMAND_NOID(CMDNAME, GETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(); \ - os << ToString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -/** get only hex*/ -#define GET_COMMAND_HEX(CMDNAME, GETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(std::vector{det_id}); \ - os << OutStringHex(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define GET_IND_COMMAND(CMDNAME, GETFCN, VAL, APPEND, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) \ - os << HLPSTR << '\n'; \ - else if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(VAL, std::vector{det_id}); \ - os << OutString(t) << APPEND << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_NAMED_LIST(CMDNAME, GETFCN, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (cmd != "daclist" && \ - det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError(cmd + " only allowed for CTB."); \ - } \ - if (det_id != -1) { \ - throw RuntimeError("Cannot configure " + cmd + \ - " at module level"); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - auto t = det->GETFCN(); \ - os << ToString(t) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (cmd == "daclist" && \ - det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError("This detector already has fixed dac " \ - "names. Cannot change them."); \ - } \ - det->SETFCN(args); \ - os << ToString(args) << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_VALUES(CMDNAME, GETFCN, GETFCNLIST, GETFCNNAME, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (!args.empty()) { \ - WrongNumberOfParameters(0); \ - } \ - std::string suffix = " mV"; \ - auto t = det->GETFCNLIST(); \ - auto names = det->GETFCNNAME(); \ - auto name_it = names.begin(); \ - os << '['; \ - auto it = t.cbegin(); \ - os << ToString(*name_it++) << ' '; \ - os << OutString(det->GETFCN(*it++, std::vector{det_id})) \ - << suffix; \ - while (it != t.cend()) { \ - os << ", " << ToString(*name_it++) << ' '; \ - os << OutString(det->GETFCN(*it++, std::vector{det_id})) \ - << suffix; \ - } \ - os << "]\n"; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_SINGLE_DACNAME(CMDNAME, GETFCN, SETFCN, STARTINDEX, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError(cmd + " only allowed for CTB."); \ - } \ - if (det_id != -1) { \ - throw RuntimeError("Cannot configure " + cmd + \ - " at module level"); \ - } \ - defs::dacIndex index = defs::DAC_0; \ - if (args.size() > 0) { \ - index = static_cast(StringTo(args[0]) + \ - STARTINDEX); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto t = det->GETFCN(index); \ - os << args[0] << ' ' << t << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 2) { \ - WrongNumberOfParameters(2); \ - } \ - det->SETFCN(index, args[1]); \ - os << ToString(args) << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_GET_DACINDEX(CMDNAME, GETFCN, STARTINDEX, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError(cmd + " only allowed for CTB."); \ - } \ - if (det_id != -1) { \ - throw RuntimeError("Cannot configure " + cmd + \ - " at module level"); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto t = det->GETFCN(args[0]); \ - os << ToString(static_cast(t) - STARTINDEX) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_SINGLE_NAME(CMDNAME, GETFCN, SETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError(cmd + " only allowed for CTB."); \ - } \ - if (det_id != -1) { \ - throw RuntimeError("Cannot configure " + cmd + \ - " at module level"); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto t = det->GETFCN(StringTo(args[0])); \ - os << args[0] << ' ' << t << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - if (args.size() != 2) { \ - WrongNumberOfParameters(2); \ - } \ - det->SETFCN(StringTo(args[0]), args[1]); \ - os << ToString(args) << '\n'; \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -#define CTB_GET_INDEX(CMDNAME, GETFCN, HLPSTR) \ - std::string CMDNAME(const int action) { \ - std::ostringstream os; \ - os << cmd << ' '; \ - if (action == slsDetectorDefs::HELP_ACTION) { \ - os << HLPSTR << '\n'; \ - return os.str(); \ - } \ - if (det->getDetectorType().squash() != defs::CHIPTESTBOARD) { \ - throw RuntimeError(cmd + " only allowed for CTB."); \ - } \ - if (det_id != -1) { \ - throw RuntimeError("Cannot configure " + cmd + \ - " at module level"); \ - } \ - if (action == slsDetectorDefs::GET_ACTION) { \ - if (args.size() != 1) { \ - WrongNumberOfParameters(1); \ - } \ - auto t = det->GETFCN(args[0]); \ - os << ToString(static_cast(t)) << '\n'; \ - } else if (action == slsDetectorDefs::PUT_ACTION) { \ - throw RuntimeError("Cannot put"); \ - } else { \ - throw RuntimeError("Unknown action"); \ - } \ - return os.str(); \ - } - -class CmdProxy { - public: - explicit CmdProxy(Detector *ptr) : det(ptr) {} - - void Call(const std::string &command, - const std::vector &arguments, int detector_id = -1, - int action = -1, std::ostream &os = std::cout, - int receiver_id = -1); - - bool ReplaceIfDepreciated(std::string &command); - size_t GetFunctionMapSize() const noexcept { return functions.size(); }; - std::vector GetProxyCommands(); - std::map GetDepreciatedCommands(); - - private: - Detector *det; - std::string cmd; - std::vector args; - int det_id{-1}; - int rx_id{-1}; - - template std::string OutStringHex(const V &value) { - if (value.equal()) - return ToStringHex(value.front()); - return ToStringHex(value); - } - - template std::string OutStringHex(const V &value, int width) { - if (value.equal()) - return ToStringHex(value.front(), width); - return ToStringHex(value, width); - } - - template std::string OutString(const Result &value) { - if (value.equal()) - return ToString(value.front()); - return ToString(value); - } - - template std::string OutString(const V &value) { - return ToString(value); - } - - template - std::string OutString(const V &value, const std::string &unit) { - if (value.equal()) - return ToString(value.front(), unit); - return ToString(value, unit); - } - - using FunctionMap = std::map; - using StringMap = std::map; - - StringMap depreciated_functions{ - /* configuration */ - {"detectorversion", "firmwareversion"}, - {"softwareversion", "detectorserverversion"}, - {"receiverversion", "rx_version"}, - {"detectornumber", "serialnumber"}, - {"thisversion", "clientversion"}, - {"detsizechan", "detsize"}, - {"trimdir", "settingspath"}, - {"settingsdir", "settingspath"}, - {"flippeddatax", "fliprows"}, - - /* acquisition parameters */ - {"cycles", "triggers"}, - {"cyclesl", "triggersl"}, - {"clkdivider", "readoutspeed"}, - {"speed", "readoutspeed"}, - {"vhighvoltage", "highvoltage"}, - {"digitest", "imagetest"}, - {"filter", "filterresistor"}, - {"readnlines", "readnrows"}, - - /** temperature */ - - /** super old dacs */ - {"vtr", "vtrim"}, - {"vrf", "vrpreamp"}, - {"vrs", "vrshaper"}, - {"vcall", "vcal"}, - {"vis", "vishaper"}, - {"vshaper", "vrshaper"}, - {"vpreamp", "vrpreamp"}, - {"vshaperneg", "vrshaper_n"}, - {"viinsh", "vishaper"}, - {"vpl", "vcal_n"}, - {"vph", "vcal_p"}, - /** dacs */ - {"vthreshold", "dac"}, - {"vsvp", "dac"}, - {"vsvn", "dac"}, - {"vtrim", "dac"}, - {"vrpreamp", "dac"}, - {"vrshaper", "dac"}, - {"vtgstv", "dac"}, - {"vcmp_ll", "dac"}, - {"vcmp_lr", "dac"}, - {"vcal", "dac"}, - {"vcmp_rl", "dac"}, - {"vcmp_rr", "dac"}, - {"rxb_rb", "dac"}, - {"rxb_lb", "dac"}, - {"vcp", "dac"}, - {"vcn", "dac"}, - {"vishaper", "dac"}, - {"iodelay", "dac"}, - {"vref_ds", "dac"}, - {"vcascn_pb", "dac"}, - {"vcascp_pb", "dac"}, - {"vout_cm", "dac"}, - {"vcasc_out", "dac"}, - {"vin_cm", "dac"}, - {"vref_comp", "dac"}, - {"ib_test_c", "dac"}, - {"vrshaper_n", "dac"}, - {"vipre", "dac"}, - {"vdcsh", "dac"}, - {"vth1", "dac"}, - {"vth2", "dac"}, - {"vth3", "dac"}, - {"vcal_n", "dac"}, - {"vcal_p", "dac"}, - {"vcassh", "dac"}, - {"vcas", "dac"}, - {"vicin", "dac"}, - {"vipre_out", "dac"}, - {"vref_h_adc", "dac"}, - {"vb_comp_fe", "dac"}, - {"vb_comp_adc", "dac"}, - {"vcom_cds", "dac"}, - {"vref_rstore", "dac"}, - {"vb_opa_1st", "dac"}, - {"vref_comp_fe", "dac"}, - {"vcom_adc1", "dac"}, - {"vref_prech", "dac"}, - {"vref_l_adc", "dac"}, - {"vref_cds", "dac"}, - {"vb_cs", "dac"}, - {"vb_opa_fd", "dac"}, - {"vcom_adc2", "dac"}, - {"vb_ds", "dac"}, - {"vb_comp", "dac"}, - {"vb_pixbuf", "dac"}, - {"vin_com", "dac"}, - {"vdd_prot", "dac"}, - {"vbp_colbuf", "dac"}, - {"vb_sda", "dac"}, - {"vcasc_sfp", "dac"}, - {"vipre_cds", "dac"}, - {"ibias_sfp", "dac"}, - - {"defaultdacs", "resetdacs"}, - - /* acquisition */ - {"busy", "clearbusy"}, - {"receiver", "rx_status"}, - {"framescaught", "rx_framescaught"}, - {"startingfnum", "nextframenumber"}, - - /* Network Configuration (Detector<->Receiver) */ - {"detectorip", "udp_srcip"}, - {"detectorip2", "udp_srcip2"}, - {"detectormac", "udp_srcmac"}, - {"detectormac2", "udp_srcmac2"}, - {"rx_udpip", "udp_dstip"}, - {"rx_udpip2", "udp_dstip2"}, - {"rx_udpmac", "udp_dstmac"}, - {"rx_udpmac2", "udp_dstmac2"}, - {"rx_udpport", "udp_dstport"}, - {"rx_udpport2", "udp_dstport2"}, - {"flowcontrol_10g", "flowcontrol10g"}, - {"txndelay_frame", "txdelay_frame"}, - {"txndelay_left", "txdelay_left"}, - {"txndelay_right", "txdelay_right"}, - - /* Receiver Config */ - {"r_silent", "rx_silent"}, - {"r_discardpolicy", "rx_discardpolicy"}, - {"r_padding", "rx_padding"}, - {"r_lock", "rx_lock"}, - {"r_lastclient", "rx_lastclient"}, - - /* File */ - {"fileformat", "fformat"}, - {"outdir", "fpath"}, - {"index", "findex"}, - {"enablefwrite", "fwrite"}, - {"masterfile", "fmaster"}, - {"overwrite", "foverwrite"}, - {"r_framesperfile", "rx_framesperfile"}, - - /* ZMQ Streaming Parameters (Receiver<->Client) */ - {"r_readfreq", "rx_zmqfreq"}, - {"rx_readfreq", "rx_zmqfreq"}, - {"rx_datastream", "rx_zmqstream"}, - - /* Eiger Specific */ - {"resmat", "partialreset"}, - - /* Jungfrau Specific */ - {"storagecells", "extrastoragecells"}, - {"auto_comp_disable", "autocompdisable"}, - {"comp_disable_time", "compdisabletime"}, - - /* Gotthard Specific */ - /* Gotthard2 Specific */ - /* Mythen3 Specific */ - /* CTB Specific */ - {"adc", "slowadc"}, - {"flags", "romode"}, - {"i_a", "im_a"}, - {"i_b", "im_b"}, - {"i_c", "im_c"}, - {"i_d", "im_d"}, - {"i_io", "im_io"}, - - /* Pattern */ - /* Moench */ - - /* Advanced */ - {"copydetectorserver", "updatedetectorserver"}, - - /* Insignificant */ - {"nframes", "framecounter"}, - {"now", "runtime"}, - {"timestamp", "frametime"}, - {"frameindex", "rx_frameindex"} - - }; - - // Initialize maps for translating name and function - FunctionMap functions{ - {"list", &CmdProxy::ListCommands}, - - /* configuration */ - {"config", &CmdProxy::config}, - {"free", &CmdProxy::Free}, - {"parameters", &CmdProxy::parameters}, - {"hostname", &CmdProxy::Hostname}, - {"virtual", &CmdProxy::VirtualServer}, - {"versions", &CmdProxy::Versions}, - {"packageversion", &CmdProxy::PackageVersion}, - {"clientversion", &CmdProxy::ClientVersion}, - {"firmwareversion", &CmdProxy::FirmwareVersion}, - {"hardwareversion", &CmdProxy::hardwareversion}, - {"detectorserverversion", &CmdProxy::detectorserverversion}, - {"kernelversion", &CmdProxy::kernelversion}, - {"rx_version", &CmdProxy::rx_version}, - {"serialnumber", &CmdProxy::serialnumber}, - {"moduleid", &CmdProxy::moduleid}, - {"type", &CmdProxy::type}, - {"nmod", &CmdProxy::nmod}, - {"detsize", &CmdProxy::DetectorSize}, - {"settingslist", &CmdProxy::settingslist}, - {"settings", &CmdProxy::settings}, - {"threshold", &CmdProxy::Threshold}, - {"thresholdnotb", &CmdProxy::Threshold}, - {"settingspath", &CmdProxy::settingspath}, - {"trimbits", &CmdProxy::Trimbits}, - {"trimval", &CmdProxy::trimval}, - {"trimen", &CmdProxy::TrimEnergies}, - {"gappixels", &CmdProxy::GapPixels}, - {"fliprows", &CmdProxy::fliprows}, - {"master", &CmdProxy::master}, - {"sync", &CmdProxy::sync}, - {"badchannels", &CmdProxy::BadChannels}, - {"row", &CmdProxy::row}, - {"column", &CmdProxy::column}, - - /* acquisition parameters */ - {"acquire", &CmdProxy::Acquire}, - {"frames", &CmdProxy::frames}, - {"triggers", &CmdProxy::triggers}, - {"exptime", &CmdProxy::Exptime}, - {"period", &CmdProxy::period}, - {"delay", &CmdProxy::delay}, - {"framesl", &CmdProxy::framesl}, - {"triggersl", &CmdProxy::triggersl}, - {"delayl", &CmdProxy::delayl}, - {"periodl", &CmdProxy::periodl}, - {"dr", &CmdProxy::dr}, - {"drlist", &CmdProxy::drlist}, - {"timing", &CmdProxy::timing}, - {"timinglist", &CmdProxy::timinglist}, - {"readoutspeed", &CmdProxy::ReadoutSpeed}, - {"readoutspeedlist", &CmdProxy::readoutspeedlist}, - {"adcphase", &CmdProxy::Adcphase}, - {"maxadcphaseshift", &CmdProxy::maxadcphaseshift}, - {"dbitphase", &CmdProxy::Dbitphase}, - {"maxdbitphaseshift", &CmdProxy::maxdbitphaseshift}, - {"clkfreq", &CmdProxy::ClockFrequency}, - {"clkphase", &CmdProxy::ClockPhase}, - {"maxclkphaseshift", &CmdProxy::MaxClockPhaseShift}, - {"clkdiv", &CmdProxy::ClockDivider}, - {"highvoltage", &CmdProxy::highvoltage}, - {"powerchip", &CmdProxy::powerchip}, - {"imagetest", &CmdProxy::imagetest}, - {"extsig", &CmdProxy::ExternalSignal}, - {"parallel", &CmdProxy::parallel}, - {"filterresistor", &CmdProxy::filterresistor}, - {"currentsource", &CmdProxy::CurrentSource}, - {"dbitpipeline", &CmdProxy::dbitpipeline}, - {"readnrows", &CmdProxy::readnrows}, - - /** temperature */ - {"templist", &CmdProxy::templist}, - {"tempvalues", &CmdProxy::TemperatureValues}, - {"temp_adc", &CmdProxy::temp_adc}, - {"temp_fpga", &CmdProxy::temp_fpga}, - {"temp_fpgaext", &CmdProxy::temp_fpgaext}, - {"temp_10ge", &CmdProxy::temp_10ge}, - {"temp_dcdc", &CmdProxy::temp_dcdc}, - {"temp_sodl", &CmdProxy::temp_sodl}, - {"temp_sodr", &CmdProxy::temp_sodr}, - {"temp_fpgafl", &CmdProxy::temp_fpgafl}, - {"temp_fpgafr", &CmdProxy::temp_fpgafr}, - {"temp_slowadc", &CmdProxy::temp_slowadc}, - - /* lists */ - {"daclist", &CmdProxy::daclist}, - {"dacname", &CmdProxy::dacname}, - {"dacindex", &CmdProxy::dacindex}, - {"adclist", &CmdProxy::adclist}, - {"adcname", &CmdProxy::adcname}, - {"adcindex", &CmdProxy::adcindex}, - {"signallist", &CmdProxy::signallist}, - {"signalname", &CmdProxy::signalname}, - {"signalindex", &CmdProxy::signalindex}, - {"powerlist", &CmdProxy::powerlist}, - {"powername", &CmdProxy::powername}, - {"powerindex", &CmdProxy::powerindex}, - {"powervalues", &CmdProxy::powervalues}, - {"slowadclist", &CmdProxy::slowadclist}, - {"slowadcname", &CmdProxy::slowadcname}, - {"slowadcindex", &CmdProxy::slowadcindex}, - {"slowadcvalues", &CmdProxy::slowadcvalues}, - - /* dacs */ - {"dac", &CmdProxy::Dac}, - {"dacvalues", &CmdProxy::DacValues}, - {"resetdacs", &CmdProxy::ResetDacs}, - {"defaultdac", &CmdProxy::DefaultDac}, - - /* on chip dacs */ - {"vchip_comp_fe", &CmdProxy::vchip_comp_fe}, - {"vchip_opa_1st", &CmdProxy::vchip_opa_1st}, - {"vchip_opa_fd", &CmdProxy::vchip_opa_fd}, - {"vchip_comp_adc", &CmdProxy::vchip_comp_adc}, - {"vchip_ref_comp_fe", &CmdProxy::vchip_ref_comp_fe}, - {"vchip_cs", &CmdProxy::vchip_cs}, - - /* acquisition */ - {"clearbusy", &CmdProxy::clearbusy}, - {"rx_start", &CmdProxy::rx_start}, - {"rx_stop", &CmdProxy::rx_stop}, - {"start", &CmdProxy::start}, - {"readout", &CmdProxy::readout}, - {"stop", &CmdProxy::stop}, - {"rx_status", &CmdProxy::ReceiverStatus}, - {"status", &CmdProxy::DetectorStatus}, - {"rx_framescaught", &CmdProxy::rx_framescaught}, - {"rx_missingpackets", &CmdProxy::rx_missingpackets}, - {"rx_frameindex", &CmdProxy::rx_frameindex}, - {"nextframenumber", &CmdProxy::nextframenumber}, - {"trigger", &CmdProxy::Trigger}, - {"scan", &CmdProxy::Scan}, - {"scanerrmsg", &CmdProxy::scanerrmsg}, - - /* Network Configuration (Detector<->Receiver) */ - {"numinterfaces", &CmdProxy::numinterfaces}, - {"selinterface", &CmdProxy::selinterface}, - {"udp_dstlist", &CmdProxy::UDPDestinationList}, - {"udp_numdst", &CmdProxy::udp_numdst}, - {"udp_cleardst", &CmdProxy::udp_cleardst}, - {"udp_firstdst", &CmdProxy::udp_firstdst}, - {"udp_srcip", &CmdProxy::UDPSourceIP}, - {"udp_srcip2", &CmdProxy::UDPSourceIP2}, - {"udp_dstip", &CmdProxy::UDPDestinationIP}, - {"udp_dstip2", &CmdProxy::UDPDestinationIP2}, - {"udp_srcmac", &CmdProxy::udp_srcmac}, - {"udp_srcmac2", &CmdProxy::udp_srcmac2}, - {"udp_dstmac", &CmdProxy::udp_dstmac}, - {"udp_dstmac2", &CmdProxy::udp_dstmac2}, - {"udp_dstport", &CmdProxy::udp_dstport}, - {"udp_dstport2", &CmdProxy::udp_dstport2}, - {"udp_reconfigure", &CmdProxy::udp_reconfigure}, - {"udp_validate", &CmdProxy::udp_validate}, - {"rx_printconfig", &CmdProxy::rx_printconfig}, - {"tengiga", &CmdProxy::tengiga}, - {"flowcontrol10g", &CmdProxy::flowcontrol10g}, - {"txdelay_frame", &CmdProxy::txdelay_frame}, - {"txdelay_left", &CmdProxy::txdelay_left}, - {"txdelay_right", &CmdProxy::txdelay_right}, - {"txdelay", &CmdProxy::TransmissionDelay}, - - /* Receiver Config */ - {"rx_hostname", &CmdProxy::ReceiverHostname}, - {"rx_tcpport", &CmdProxy::rx_tcpport}, - {"rx_fifodepth", &CmdProxy::rx_fifodepth}, - {"rx_silent", &CmdProxy::rx_silent}, - {"rx_discardpolicy", &CmdProxy::rx_discardpolicy}, - {"rx_padding", &CmdProxy::rx_padding}, - {"rx_udpsocksize", &CmdProxy::rx_udpsocksize}, - {"rx_realudpsocksize", &CmdProxy::rx_realudpsocksize}, - {"rx_lock", &CmdProxy::rx_lock}, - {"rx_lastclient", &CmdProxy::rx_lastclient}, - {"rx_threads", &CmdProxy::rx_threads}, - {"rx_arping", &CmdProxy::rx_arping}, - {"rx_roi", &CmdProxy::Rx_ROI}, - {"rx_clearroi", &CmdProxy::rx_clearroi}, - - /* File */ - {"fformat", &CmdProxy::fformat}, - {"fpath", &CmdProxy::fpath}, - {"fname", &CmdProxy::fname}, - {"findex", &CmdProxy::findex}, - {"fwrite", &CmdProxy::fwrite}, - {"fmaster", &CmdProxy::fmaster}, - {"foverwrite", &CmdProxy::foverwrite}, - {"rx_framesperfile", &CmdProxy::rx_framesperfile}, - - /* ZMQ Streaming Parameters (Receiver<->Client) */ - {"rx_zmqstream", &CmdProxy::rx_zmqstream}, - {"rx_zmqfreq", &CmdProxy::rx_zmqfreq}, - {"rx_zmqstartfnum", &CmdProxy::rx_zmqstartfnum}, - {"rx_zmqport", &CmdProxy::rx_zmqport}, - {"zmqport", &CmdProxy::zmqport}, - {"rx_zmqip", &CmdProxy::rx_zmqip}, - {"zmqip", &CmdProxy::zmqip}, - {"zmqhwm", &CmdProxy::ZMQHWM}, - {"rx_zmqhwm", &CmdProxy::rx_zmqhwm}, - - /* Eiger Specific */ - {"blockingtrigger", &CmdProxy::Trigger}, - {"subexptime", &CmdProxy::subexptime}, - {"subdeadtime", &CmdProxy::subdeadtime}, - {"overflow", &CmdProxy::overflow}, - {"ratecorr", &CmdProxy::RateCorrection}, - {"interruptsubframe", &CmdProxy::interruptsubframe}, - {"measuredperiod", &CmdProxy::measuredperiod}, - {"measuredsubperiod", &CmdProxy::measuredsubperiod}, - {"activate", &CmdProxy::activate}, - {"partialreset", &CmdProxy::partialreset}, - {"pulse", &CmdProxy::PulsePixel}, - {"pulsenmove", &CmdProxy::PulsePixelAndMove}, - {"pulsechip", &CmdProxy::PulseChip}, - {"quad", &CmdProxy::Quad}, - {"datastream", &CmdProxy::DataStream}, - {"top", &CmdProxy::top}, - - /* Jungfrau Specific */ - {"chipversion", &CmdProxy::chipversion}, - {"temp_threshold", &CmdProxy::temp_threshold}, - {"temp_control", &CmdProxy::temp_control}, - {"temp_event", &CmdProxy::TemperatureEvent}, - {"autocompdisable", &CmdProxy::autocompdisable}, - {"compdisabletime", &CmdProxy::compdisabletime}, - {"extrastoragecells", &CmdProxy::extrastoragecells}, - {"storagecell_start", &CmdProxy::storagecell_start}, - {"storagecell_delay", &CmdProxy::storagecell_delay}, - {"gainmode", &CmdProxy::gainmode}, - {"filtercells", &CmdProxy::filtercells}, - {"pedestalmode", &CmdProxy::PedestalMode}, - - /* Gotthard Specific */ - {"roi", &CmdProxy::ROI}, - {"clearroi", &CmdProxy::clearroi}, - {"exptimel", &CmdProxy::exptimel}, - - /* Gotthard2 Specific */ - {"bursts", &CmdProxy::bursts}, - {"burstperiod", &CmdProxy::burstperiod}, - {"burstsl", &CmdProxy::burstsl}, - {"inj_ch", &CmdProxy::InjectChannel}, - {"vetophoton", &CmdProxy::VetoPhoton}, - {"vetoref", &CmdProxy::VetoReference}, - {"vetofile", &CmdProxy::VetoFile}, - {"burstmode", &CmdProxy::BurstMode}, - {"cdsgain", &CmdProxy::cdsgain}, - {"timingsource", &CmdProxy::timingsource}, - {"veto", &CmdProxy::veto}, - {"vetostream", &CmdProxy::VetoStreaming}, - {"vetoalg", &CmdProxy::VetoAlgorithm}, - {"confadc", &CmdProxy::ConfigureADC}, - - /* Mythen3 Specific */ - {"counters", &CmdProxy::Counters}, - {"gates", &CmdProxy::gates}, - {"exptime1", &CmdProxy::Exptime}, - {"exptime2", &CmdProxy::Exptime}, - {"exptime3", &CmdProxy::Exptime}, - {"gatedelay", &CmdProxy::GateDelay}, - {"gatedelay1", &CmdProxy::GateDelay}, - {"gatedelay2", &CmdProxy::GateDelay}, - {"gatedelay3", &CmdProxy::GateDelay}, - {"gaincaps", &CmdProxy::GainCaps}, - {"polarity", &CmdProxy::polarity}, - {"interpolation", &CmdProxy::interpolation}, - {"pumpprobe", &CmdProxy::pumpprobe}, - {"apulse", &CmdProxy::apulse}, - {"dpulse", &CmdProxy::dpulse}, - - /* CTB Specific */ - {"samples", &CmdProxy::Samples}, - {"asamples", &CmdProxy::asamples}, - {"adcclk", &CmdProxy::adcclk}, - {"runclk", &CmdProxy::runclk}, - {"syncclk", &CmdProxy::syncclk}, - {"v_limit", &CmdProxy::v_limit}, - {"adcenable", &CmdProxy::adcenable}, - {"adcenable10g", &CmdProxy::adcenable10g}, - {"transceiverenable", &CmdProxy::transceiverenable}, - {"dsamples", &CmdProxy::dsamples}, - {"tsamples", &CmdProxy::tsamples}, - {"romode", &CmdProxy::romode}, - {"dbitclk", &CmdProxy::dbitclk}, - {"adcvpp", &CmdProxy::AdcVpp}, - {"v_a", &CmdProxy::v_a}, - {"v_b", &CmdProxy::v_b}, - {"v_c", &CmdProxy::v_c}, - {"v_d", &CmdProxy::v_d}, - {"v_io", &CmdProxy::v_io}, - {"v_chip", &CmdProxy::v_chip}, - {"vm_a", &CmdProxy::vm_a}, - {"vm_b", &CmdProxy::vm_b}, - {"vm_c", &CmdProxy::vm_c}, - {"vm_d", &CmdProxy::vm_d}, - {"vm_io", &CmdProxy::vm_io}, - {"im_a", &CmdProxy::im_a}, - {"im_b", &CmdProxy::im_b}, - {"im_c", &CmdProxy::im_c}, - {"im_d", &CmdProxy::im_d}, - {"im_io", &CmdProxy::im_io}, - {"slowadc", &CmdProxy::SlowADC}, - {"extsampling", &CmdProxy::extsampling}, - {"extsamplingsrc", &CmdProxy::extsamplingsrc}, - {"rx_dbitlist", &CmdProxy::ReceiverDbitList}, - {"rx_dbitoffset", &CmdProxy::rx_dbitoffset}, - {"diodelay", &CmdProxy::DigitalIODelay}, - {"led", &CmdProxy::led}, - - /* Pattern */ - {"pattern", &CmdProxy::Pattern}, - {"patfname", &CmdProxy::patfname}, - {"savepattern", &CmdProxy::savepattern}, - {"defaultpattern", &CmdProxy::defaultpattern}, - {"patioctrl", &CmdProxy::patioctrl}, - {"patword", &CmdProxy::PatternWord}, - {"patlimits", &CmdProxy::PatternLoopAddresses}, - {"patloop", &CmdProxy::PatternLoopAddresses}, - {"patloop0", &CmdProxy::PatternLoopAddresses}, - {"patloop1", &CmdProxy::PatternLoopAddresses}, - {"patloop2", &CmdProxy::PatternLoopAddresses}, - {"patnloop", &CmdProxy::PatternLoopCycles}, - {"patnloop0", &CmdProxy::PatternLoopCycles}, - {"patnloop1", &CmdProxy::PatternLoopCycles}, - {"patnloop2", &CmdProxy::PatternLoopCycles}, - {"patwait", &CmdProxy::PatternWaitAddress}, - {"patwait0", &CmdProxy::PatternWaitAddress}, - {"patwait1", &CmdProxy::PatternWaitAddress}, - {"patwait2", &CmdProxy::PatternWaitAddress}, - {"patwaittime", &CmdProxy::PatternWaitTime}, - {"patwaittime0", &CmdProxy::PatternWaitTime}, - {"patwaittime1", &CmdProxy::PatternWaitTime}, - {"patwaittime2", &CmdProxy::PatternWaitTime}, - {"patmask", &CmdProxy::patmask}, - {"patsetbit", &CmdProxy::patsetbit}, - {"patternstart", &CmdProxy::patternstart}, - - /* Moench */ - - /* Advanced */ - {"adcpipeline", &CmdProxy::adcpipeline}, - {"rx_jsonaddheader", &CmdProxy::AdditionalJsonHeader}, - {"rx_jsonpara", &CmdProxy::JsonParameter}, - {"programfpga", &CmdProxy::ProgramFpga}, - {"resetfpga", &CmdProxy::resetfpga}, - {"updatedetectorserver", &CmdProxy::UpdateDetectorServer}, - {"updatekernel", &CmdProxy::UpdateKernel}, - {"rebootcontroller", &CmdProxy::rebootcontroller}, - {"update", &CmdProxy::UpdateFirmwareAndDetectorServer}, - {"updatemode", &CmdProxy::updatemode}, - {"reg", &CmdProxy::Register}, - {"adcreg", &CmdProxy::AdcRegister}, - {"setbit", &CmdProxy::BitOperations}, - {"clearbit", &CmdProxy::BitOperations}, - {"getbit", &CmdProxy::BitOperations}, - {"firmwaretest", &CmdProxy::firmwaretest}, - {"bustest", &CmdProxy::bustest}, - {"initialchecks", &CmdProxy::InitialChecks}, - {"adcinvert", &CmdProxy::adcinvert}, - - /* Insignificant */ - {"port", &CmdProxy::port}, - {"stopport", &CmdProxy::stopport}, - {"lock", &CmdProxy::lock}, - {"lastclient", &CmdProxy::lastclient}, - {"execcommand", &CmdProxy::ExecuteCommand}, - {"framecounter", &CmdProxy::framecounter}, - {"runtime", &CmdProxy::runtime}, - {"frametime", &CmdProxy::frametime}, - {"user", &CmdProxy::UserDetails} - - }; - - void WrongNumberOfParameters(size_t expected); - - /* Commands */ - std::string ListCommands(int action); - /* configuration */ - std::string Free(int action); - // std::string config2(int action); - std::string Hostname(int action); - std::string VirtualServer(int action); - std::string FirmwareVersion(int action); - std::string Versions(int action); - std::string PackageVersion(int action); - std::string ClientVersion(int action); - std::string DetectorSize(int action); - std::string Threshold(int action); - std::string Trimbits(int action); - std::string TrimEnergies(int action); - std::string GapPixels(int action); - std::string BadChannels(int action); - /* acquisition parameters */ - std::string Acquire(int action); - std::string Exptime(int action); - std::string ReadoutSpeed(int action); - std::string Adcphase(int action); - std::string Dbitphase(int action); - std::string ClockFrequency(int action); - std::string ClockPhase(int action); - std::string MaxClockPhaseShift(int action); - std::string ClockDivider(int action); - std::string ExternalSignal(int action); - std::string CurrentSource(int action); - /** temperature */ - std::string TemperatureValues(int action); - /* list */ - /* dacs */ - std::string Dac(int action); - std::string DacValues(int action); - std::string ResetDacs(int action); - std::string DefaultDac(int action); - /* acquisition */ - std::string ReceiverStatus(int action); - std::string DetectorStatus(int action); - std::string RxMissingPackets(int action); - std::string Scan(int action); - std::string Trigger(int action); - /* Network Configuration (Detector<->Receiver) */ - IpAddr getDstIpFromAuto(); - IpAddr getSrcIpFromAuto(); - UdpDestination getUdpEntry(); - std::string UDPDestinationList(int action); - std::string UDPSourceIP(int action); - std::string UDPSourceIP2(int action); - std::string UDPDestinationIP(int action); - std::string UDPDestinationIP2(int action); - std::string TransmissionDelay(int action); - /* Receiver Config */ - std::string ReceiverHostname(int action); - std::string Rx_ROI(int action); - /* File */ - /* ZMQ Streaming Parameters (Receiver<->Client) */ - std::string ZMQHWM(int action); - /* Eiger Specific */ - std::string RateCorrection(int action); - std::string PulsePixel(int action); - std::string PulsePixelAndMove(int action); - std::string PulseChip(int action); - std::string Quad(int action); - std::string DataStream(int action); - /* Jungfrau Specific */ - std::string TemperatureEvent(int action); - std::string PedestalMode(int action); - /* Gotthard Specific */ - std::string ROI(int action); - /* Gotthard2 Specific */ - std::string InjectChannel(int action); - std::string VetoPhoton(int action); - std::string VetoReference(int action); - std::string VetoFile(int action); - std::string BurstMode(int action); - std::string VetoStreaming(int action); - std::string VetoAlgorithm(int action); - std::string ConfigureADC(int action); - /* Mythen3 Specific */ - std::string Counters(int action); - std::string GateDelay(int action); - std::string GainCaps(int action); - /* CTB/ Moench Specific */ - std::string Samples(int action); - /* CTB Specific */ - std::string AdcVpp(int action); - std::string SlowADC(int action); - std::string ReceiverDbitList(int action); - std::string DigitalIODelay(int action); - /* Pattern */ - std::string Pattern(int action); - std::string PatternWord(int action); - void GetLevelAndUpdateArgIndex(int action, - std::string levelSeparatedCommand, - int &level, int &iArg, size_t nGetArgs, - size_t nPutArgs); - std::string PatternLoopAddresses(int action); - std::string PatternLoopCycles(int action); - std::string PatternWaitAddress(int action); - std::string PatternWaitTime(int action); - /* Moench */ - std::string AdditionalJsonHeader(int action); - std::string JsonParameter(int action); - /* Advanced */ - std::string ProgramFpga(int action); - std::string UpdateDetectorServer(int action); - std::string UpdateKernel(int action); - std::string UpdateFirmwareAndDetectorServer(int action); - std::string Register(int action); - std::string AdcRegister(int action); - std::string BitOperations(int action); - std::string InitialChecks(int action); - /* Insignificant */ - std::string ExecuteCommand(int action); - std::string UserDetails(int action); - - /* configuration */ - EXECUTE_SET_COMMAND_NOID_1ARG( - config, loadConfig, - "[fname]\n\tFrees shared memory before loading configuration file. " - "Set up once."); - - EXECUTE_SET_COMMAND_NOID_1ARG(parameters, loadParameters, - "[fname]\n\tSets detector measurement " - "parameters to those contained in " - "fname. Set up per measurement."); - - GET_COMMAND(detectorserverversion, getDetectorServerVersion, - "\n\tOn-board detector server software version"); - - GET_COMMAND(hardwareversion, getHardwareVersion, - "\n\t[Jungfrau][Gotthard2][Myhten3][Gotthard][Ctb][Moench] " - "Hardware version of detector. \n\t[Eiger] Hardware version of " - "front FPGA on detector."); - - GET_COMMAND( - kernelversion, getKernelVersion, - "\n\tGet kernel version on the detector including time and date."); - - GET_COMMAND(rx_version, getReceiverVersion, "\n\tReceiver version"); - - GET_COMMAND_HEX(serialnumber, getSerialNumber, - "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][CTB]" - "Serial number of detector."); - - GET_COMMAND( - moduleid, getModuleId, - "\n\t[Gotthard2][Eiger][Mythen3][Jungfrau][Moench] 16 bit value " - "(ideally unique) that is streamed out in the UDP header of " - "the detector. Picked up from a file on the module."); - - GET_COMMAND(type, getDetectorType, - "\n\tReturns detector type. Can be Eiger, Jungfrau, Gotthard, " - "Moench, Mythen3, Gotthard2, ChipTestBoard"); - - GET_COMMAND_NOID(nmod, size, "\n\tNumber of modules in shared memory."); - - GET_COMMAND_NOID(settingslist, getSettingsList, - "\n\tList of settings implemented for this detector."); - - INTEGER_COMMAND_VEC_ID( - settings, getSettings, setSettings, - StringTo, - "[standard, fast, highgain, dynamicgain, lowgain, " - "mediumgain, veryhighgain, highgain0, " - "fixgain1, fixgain2, forceswitchg1, forceswitchg2, " - "verylowgain, g1_hg, g1_lg, g2_hc_hg, g2_hc_lg, " - "g2_lc_hg, g2_lc_lg, g4_hg, g4_lg, gain0]" - "\n\t Detector Settings" - "\n\t[Jungfrau] - [ gain0 | highgain0]" - "\n\t[Gotthard] - [dynamicgain | highgain | lowgain | " - "mediumgain | veryhighgain]" - "\n\t[Gotthard] Also loads default dacs on to the detector." - "\n\t[Gotthard2] - [dynamicgain | fixgain1 | fixgain2]" - "\n\t[Mythen3] - [standard | fast | highgain] Also changes vrshaper " - "and vrpreamp. \n\t[Eiger] Use threshold or thresholdnotb. \n\t[Eiger] " - "threshold and settings loaded from file found in settingspath. " - "\n\t[Moench] - [g1_hg | g1_lg | g2_hc_hg | g2_hc_lg | " - "g2_lc_hg | g2_lc_lg | g4_hg | g4_lg]"); - - STRING_COMMAND(settingspath, getSettingsPath, setSettingsPath, - "[path]\n\t[Eiger][Mythen3] Directory where settings files " - "are loaded from/to."); - - INTEGER_COMMAND_VEC_ID( - trimval, getAllTrimbits, setAllTrimbits, StringTo, - "[n_trimval]\n\t[Eiger][Mythen3] All trimbits set to this " - "value. Returns -1 if all trimbits are different values."); - - INTEGER_COMMAND_VEC_ID( - fliprows, getFlipRows, setFlipRows, StringTo, - "[0, 1]\n\t[Eiger] flips rows paramater sent to slsreceiver " - "to stream as json parameter to flip rows in gui " - "\n\t[Jungfrau][Moench] flips " - "rows in the detector itself. For bottom module and number of " - "interfaces must be set to 2. slsReceiver and slsDetectorGui " - "does not handle."); - - INTEGER_COMMAND_VEC_ID_GET(master, getMaster, setMaster, StringTo, - "[0, 1]\n\t[Eiger][Gotthard2][Jungfrau][Moench] " - "Sets (half) module to master " - "and other(s) to " - "slaves.\n\t[Gotthard][Gotthard2][Mythen3][" - "Eiger][Jungfrau][Moench] Gets if " - "the current (half) module is master."); - - INTEGER_COMMAND_SET_NOID_GET_ID( - sync, getSynchronization, setSynchronization, StringTo, - "[0, 1]\n\t[Jungfrau][Moench] Enables or disables " - "synchronization between modules."); - - INTEGER_COMMAND_VEC_ID(row, getRow, setRow, StringTo, - "[value]\n\tSet Detector row (udp header) to value. " - "\n\tGui uses it to rearrange for complete image"); - - INTEGER_COMMAND_VEC_ID( - column, getColumn, setColumn, StringTo, - "[value]\n\tSet Detector column (udp header) to value. \n\tGui uses it " - "to rearrange for complete image"); - - /* acquisition parameters */ - - INTEGER_COMMAND_SET_NOID_GET_ID( - frames, getNumberOfFrames, setNumberOfFrames, StringTo, - "[n_frames]\n\tNumber of frames per acquisition. In " - "trigger mode, number of frames per trigger. \n\tCannot be set in " - "modular level. \n\tIn scan mode, number of frames is set to " - "number of steps.\n\t[Gotthard2] Burst mode has a maximum of 2720 " - "frames."); - - INTEGER_COMMAND_SET_NOID_GET_ID( - triggers, getNumberOfTriggers, setNumberOfTriggers, StringTo, - "[n_triggers]\n\tNumber of triggers per aquire. Set " - "timing mode to use triggers."); - - TIME_COMMAND( - period, getPeriod, setPeriod, - "[duration] [(optional unit) ns|us|ms|s]\n\tPeriod between frames"); - - TIME_COMMAND(delay, getDelayAfterTrigger, setDelayAfterTrigger, - "[duration] [(optional unit) " - "ns|us|ms|s]\n\t[Jungfrau][Moench][Gotthard][Mythen3][" - "Gotthard2][Ctb][Moench] Delay after trigger"); - - GET_COMMAND(framesl, getNumberOfFramesLeft, - "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB] " - "Number of frames left in acquisition." - "\n\t[Gotthard2] only in continuous auto mode."); - - GET_COMMAND(triggersl, getNumberOfTriggersLeft, - "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB] " - "Number of triggers left in acquisition. Only when external " - "trigger used."); - - TIME_GET_COMMAND(delayl, getDelayAfterTriggerLeft, - "\n\t[Gotthard][Jungfrau][Moench][Mythen3][Gotthard2][CTB]" - " DelayLeft Delay Left in Acquisition." - "\n\t[Gotthard2] only in continuous mode."); - - TIME_GET_COMMAND(periodl, getPeriodLeft, - "\n\t[Gotthard][Jungfrau][Moench][CTB][Mythen3][Gotthard2]" - " Period left for current frame." - "\n\t[Gotthard2] only in continuous mode."); - - INTEGER_COMMAND_SET_NOID_GET_ID( - dr, getDynamicRange, setDynamicRange, StringTo, - "[value]\n\tDynamic Range or number of bits per " - "pixel in detector.\n\t" - "[Eiger] Options: 4, 8, 12, 16, 32. If set to 32, also sets " - "clkdivider to 2, else to 0.\n\t" - "[Mythen3] Options: 8, 16, 32\n\t" - "[Jungfrau][Moench][Gotthard][Ctb][Mythen3][Gotthard2] 16"); - - GET_COMMAND_NOID(drlist, getDynamicRangeList, - "\n\tGets the list of dynamic ranges for this detector."); - - INTEGER_COMMAND_VEC_ID( - timing, getTimingMode, setTimingMode, - StringTo, - "[auto|trigger|gating|burst_trigger]\n\tTiming Mode of " - "detector.\n\t[Jungfrau][Moench][Gotthard][Ctb][Gotthard2] " - "[auto|trigger]\n\t[Mythen3] " - "[auto|trigger|gating|trigger_gating]\n\t[Eiger] " - "[auto|trigger|gating|burst_trigger]"); - - GET_COMMAND_NOID(timinglist, getTimingModeList, - "\n\tGets the list of timing modes for this detector."); - - GET_COMMAND_NOID( - readoutspeedlist, getReadoutSpeedList, - "\n\tList of readout speed levels implemented for this detector."); - - GET_COMMAND(maxadcphaseshift, getMaxADCPhaseShift, - "\n\t[Jungfrau][Moench][CTB] Absolute maximum Phase shift of " - "ADC clock."); - - GET_COMMAND(maxdbitphaseshift, getMaxDBITPhaseShift, - "\n\t[CTB][Jungfrau] Absolute maximum Phase shift of of the " - "clock to latch digital bits."); - - INTEGER_COMMAND_VEC_ID(highvoltage, getHighVoltage, setHighVoltage, - StringTo, - "[n_value]\n\tHigh voltage to the sensor in Voltage." - "\n\t[Gotthard] [0|90|110|120|150|180|200]" - "\n\t[Eiger][Mythen3][Gotthard2] 0-200" - "\n\t[Jungfrau][Moench][Ctb] [0|60-200]"); - - INTEGER_COMMAND_VEC_ID( - powerchip, getPowerChip, setPowerChip, StringTo, - "[0, 1]\n\t[Jungfrau][Moench][Mythen3][Gotthard2] Power " - "the chip. \n\t[Jungfrau][Moench] Default is 0. Get " - "will return power status. Can be off if temperature event occured " - "(temperature over temp_threshold with temp_control " - "enabled. Will configure chip (only chip v1.1)\n\t[Mythen3][Gotthard2] " - "Default is 1. If module not connected or wrong module, powerchip will " - "fail."); - - INTEGER_COMMAND_VEC_ID( - imagetest, getImageTestMode, setImageTestMode, StringTo, - "[0, 1]\n\t[Gotthard] 1 adds channel intensity with precalculated " - "values when taking an acquisition. Default is 0." - "\n\t[Eiger][Jungfrau][Moench] Only for Virtual servers. If 0, each " - "pixel intensity incremented by 1. If 1, all pixels almost saturated."); - - INTEGER_COMMAND_VEC_ID( - parallel, getParallelMode, setParallelMode, StringTo, - "[0, 1]\n\t[Eiger][Mythen3][Gotthard2][Moench] Enable or disable " - "parallel " - "mode.\n\t[Mythen3] If exptime is too short, the " - "acquisition will return ERROR status and take fewer " - "frames than expected.\n\t[Mythen3][Eiger][Moench] Default: Non " - "parallel.\n\t[Gotthard2] Default: Parallel. Non parallel mode works " - "only in continuous mode."); - - INTEGER_COMMAND_VEC_ID( - filterresistor, getFilterResistor, setFilterResistor, StringTo, - "[value] [Gotthard2][Jungfrau] Set filter resistor. Increasing " - "values for increasing resistance.\n\t[Gotthard2] Options: " - "[0|1|2|3]. Default is 0.\n\t[Jungfrau] Options: [0|1]. Default is 1."); - - INTEGER_COMMAND_VEC_ID(dbitpipeline, getDBITPipeline, setDBITPipeline, - StringTo, - "[n_value]\n\t[Ctb][Gotthard2] Pipeline of the " - "clock for latching digital bits.\n\t[Gotthard2] " - "Options: 0-7\n\t[CTB] Options: 0-255"); - - INTEGER_COMMAND_VEC_ID( - readnrows, getReadNRows, setReadNRows, StringTo, - "\n\t[1-256]\n\t\t[Eiger] Number of rows to readout per half " - "module starting from the centre. Options: 0 - 256. 256 is default. " - "The permissible values depend on dynamic range and 10Gbe " - "enabled.\n\t[8-512 (multiple of 8)]\n\t\t[Jungfrau] Number of rows " - "per module starting from the centre. Options: 8 - 512, must be " - "multiples of 8. Default is 512.\n\t\t[Moench] Number of rows per " - "module starting from the centre. Options:16 - 400, must be multiples " - "of 16. Default is 400."); - - /** temperature */ - GET_COMMAND_NOID( - templist, getTemperatureList, - "\n\tList of temperature commands implemented for this detector."); - - GET_IND_COMMAND( - temp_adc, getTemperature, slsDetectorDefs::TEMPERATURE_ADC, " °C", - "[n_value]\n\t[Jungfrau][Moench][Gotthard] ADC Temperature"); - - GET_IND_COMMAND(temp_fpga, getTemperature, - slsDetectorDefs::TEMPERATURE_FPGA, " °C", - "[n_value]\n\t[Eiger][Jungfrau][Moench][Gotthard][Mythen3][" - "Gotthard2] FPGA Temperature"); - - GET_IND_COMMAND(temp_fpgaext, getTemperature, - slsDetectorDefs::TEMPERATURE_FPGAEXT, " °C", - "[n_value]\n\t[Eiger]Temperature close to the FPGA"); - - GET_IND_COMMAND(temp_10ge, getTemperature, - slsDetectorDefs::TEMPERATURE_10GE, " °C", - "[n_value]\n\t[Eiger]Temperature close to the 10GbE"); - - GET_IND_COMMAND( - temp_dcdc, getTemperature, slsDetectorDefs::TEMPERATURE_DCDC, " °C", - "[n_value]\n\t[Eiger]Temperature close to the dc dc converter"); - - GET_IND_COMMAND( - temp_sodl, getTemperature, slsDetectorDefs::TEMPERATURE_SODL, " °C", - "[n_value]\n\t[Eiger]Temperature close to the left so-dimm memory"); - - GET_IND_COMMAND(temp_sodr, getTemperature, - slsDetectorDefs::TEMPERATURE_SODR, " °C", - "[n_value]\n\t[Eiger]Temperature close to the right " - "so-dimm memory"); - - GET_IND_COMMAND(temp_fpgafl, getTemperature, - slsDetectorDefs::TEMPERATURE_FPGA2, " °C", - "[n_value]\n\t[Eiger]Temperature of the left front end " - "board fpga."); - - GET_IND_COMMAND(temp_fpgafr, getTemperature, - slsDetectorDefs::TEMPERATURE_FPGA3, " °C", - "[n_value]\n\t[Eiger]Temperature of the left front end " - "board fpga."); - - GET_IND_COMMAND(temp_slowadc, getTemperature, - slsDetectorDefs::SLOW_ADC_TEMP, " °C", - "[n_value]\n\t[Ctb]Temperature of the slow adc"); - - /* lists */ - CTB_NAMED_LIST(daclist, getDacNames, setDacNames, - "[dacname1 dacname2 .. dacname18] \n\t\t[ChipTestBoard] Set " - "the list of dac names for this detector.\n\t\t[All] Gets " - "the list of dac names for every dac for this detector."); - - CTB_SINGLE_DACNAME(dacname, getDacName, setDacName, defs::DAC_0, - "\n\t[0-17][name] \n\t\t[ChipTestBoard] Set " - "the dac at the given position to the given name."); - - CTB_GET_DACINDEX(dacindex, getDacIndex, defs::DAC_0, - "\n\t[name] \n\t\t[ChipTestBoard] Get " - "the dac index for the given name."); - - CTB_NAMED_LIST(adclist, getAdcNames, setAdcNames, - "[adcname1 adcname2 .. adcname32] \n\t\t[ChipTestBoard] Set " - "the list of adc names for this board."); - - CTB_SINGLE_NAME(adcname, getAdcName, setAdcName, - "[0-31][name] \n\t\t[ChipTestBoard] Set " - "the adc at the given position to the given name."); - - CTB_GET_INDEX(adcindex, getAdcIndex, - "[name] \n\t\t[ChipTestBoard] Get " - "the adc index for the given name."); - - CTB_NAMED_LIST(signallist, getSignalNames, setSignalNames, - "[signalname1 signalname2 .. signalname63] " - "\n\t\t[ChipTestBoard] Set " - "the list of signal names for this board."); - - CTB_SINGLE_NAME(signalname, getSignalName, setSignalName, - "[0-63][name] \n\t\t[ChipTestBoard] Set " - "the signal at the given position to the given name."); - - CTB_GET_INDEX(signalindex, getSignalIndex, - "[name] \n\t\t[ChipTestBoard] Get " - "the signal index for the given name."); - - CTB_NAMED_LIST(powerlist, getPowerNames, setPowerNames, - "[powername1 powername2 .. powername4] " - "\n\t\t[ChipTestBoard] Set " - "the list of power names for this board."); - - CTB_SINGLE_DACNAME(powername, getPowerName, setPowerName, defs::V_POWER_A, - "[0-4][name] \n\t\t[ChipTestBoard] Set " - "the power at the given position to the given name."); - - CTB_GET_DACINDEX(powerindex, getPowerIndex, defs::V_POWER_A, - "[name] \n\t\t[ChipTestBoard] Get " - "the power index for the given name."); - - CTB_VALUES(powervalues, getPower, getPowerList, getPowerNames, - "[name] \n\t\t[ChipTestBoard] Get values of all powers."); - - CTB_VALUES(slowadcvalues, getSlowADC, getSlowADCList, getSlowADCNames, - "[name] \n\t\t[ChipTestBoard] Get values of all slow adcs."); - - CTB_NAMED_LIST( - slowadclist, getSlowADCNames, setSlowADCNames, - "[slowadcname1 slowadcname2 .. slowadcname7] " - "\n\t\t[ChipTestBoard] Set the list of slowadc names for this board."); - - CTB_SINGLE_DACNAME(slowadcname, getSlowADCName, setSlowADCName, - defs::SLOW_ADC0, - "[0-7][name] \n\t\t[ChipTestBoard] Set " - "the slowadc at the given position to the given name."); - - CTB_GET_DACINDEX(slowadcindex, getSlowADCIndex, defs::SLOW_ADC0, - "[name] \n\t\t[ChipTestBoard] Get " - "the slowadc index for the given name."); - - /* dacs */ - - /* on chip dacs */ - INTEGER_USER_IND_COMMAND( - vchip_comp_fe, getOnChipDAC, setOnChipDAC, StringTo, - defs::VB_COMP_FE, - "[chip index 0-10, -1 for all][10 bit hex value] \n\t[Gotthard2] " - "On chip Dac for comparator current of analogue front end."); - - INTEGER_USER_IND_COMMAND( - vchip_opa_1st, getOnChipDAC, setOnChipDAC, StringTo, - defs::VB_OPA_1ST, - "[chip index 0-10, -1 for all][10 bit hex value] \n\t[Gotthard2] " - "On " - "chip Dac for opa current for driving the other DACs in chip."); - - INTEGER_USER_IND_COMMAND(vchip_opa_fd, getOnChipDAC, setOnChipDAC, - StringTo, defs::VB_OPA_FD, - "[chip index 0-10, -1 for all][10 bit hex " - "value] \n\t[Gotthard2] On " - "chip Dac current for CDS opa stage."); - - INTEGER_USER_IND_COMMAND(vchip_comp_adc, getOnChipDAC, setOnChipDAC, - StringTo, defs::VB_COMP_ADC, - "[chip index 0-10, -1 for all][10 bit hex " - "value] \n\t[Gotthard2] On " - "chip Dac for comparator current of ADC."); - - INTEGER_USER_IND_COMMAND(vchip_ref_comp_fe, getOnChipDAC, setOnChipDAC, - StringTo, defs::VREF_COMP_FE, - "[chip index 0-10, -1 for all][10 bit hex " - "value] \n\t[Gotthard2] On " - "chip Dac for reference voltage of the " - "comparator of analogue front " - "end."); - - INTEGER_USER_IND_COMMAND( - vchip_cs, getOnChipDAC, setOnChipDAC, StringTo, defs::VB_CS, - "[chip index 0-10, -1 for all][10 bit hex value] \n\t[Gotthard2] " - "On chip Dac for current injection into preamplifier."); - - /* acquisition */ - - EXECUTE_SET_COMMAND_NOID( - clearbusy, clearAcquiringFlag, - "\n\tIf acquisition aborted during acquire command, use this to " - "clear acquiring flag in shared memory before starting next " - "acquisition"); - - EXECUTE_SET_COMMAND_NOID(rx_start, startReceiver, - "\n\tStarts receiver listener for detector " - "data packets and create a " - "data file (if file write enabled)."); - - EXECUTE_SET_COMMAND_NOID( - rx_stop, stopReceiver, - "\n\tStops receiver listener for detector data packets and closes " - "current data file (if file write enabled)."); - - EXECUTE_SET_COMMAND( - start, startDetector, - "\n\tStarts detector acquisition. Status changes to RUNNING or " - "WAITING and automatically returns to idle at the end of acquisition. " - "If the acquisition was abruptly stopped, some detectors come back to " - "STOPPED."); - - EXECUTE_SET_COMMAND_NOID( - readout, startDetectorReadout, - "\n\t[Mythen3] Starts detector readout. Status changes to " - "TRANSMITTING and automatically returns to idle at the end of " - "readout."); - - EXECUTE_SET_COMMAND(stop, stopDetector, - "\n\tAbort detector acquisition. Status changes " - "to IDLE or STOPPED. Goes to stop server."); - - GET_COMMAND(rx_framescaught, getFramesCaught, - "\n\tNumber of frames caught by each port in receiver."); - - GET_COMMAND(rx_missingpackets, getNumMissingPackets, - "\n\tNumber of missing packets for each port in receiver. If " - "negative, they are packets in excess. "); - - GET_COMMAND(rx_frameindex, getRxCurrentFrameIndex, - "\n\tCurrent frame index received for each port in receiver " - "during acquisition."); - - INTEGER_COMMAND_VEC_ID( - nextframenumber, getNextFrameNumber, setNextFrameNumber, - StringTo, - "[n_value]\n\t[Eiger][Jungfrau][Moench][CTB] Next frame number. " - "Stopping acquisition might result in different frame numbers for " - "different modules."); - - GET_COMMAND(scanerrmsg, getScanErrorMessage, - "\n\tGets Scan error message if scan ended in error for non " - "blocking acquisitions."); - - /* Network Configuration (Detector<->Receiver) */ - - INTEGER_COMMAND_VEC_ID( - numinterfaces, getNumberofUDPInterfaces, setNumberofUDPInterfaces, - StringTo, - "[1, 2]\n\t[Jungfrau][Moench] Number of udp interfaces to stream " - "data from detector. Default: 1.\n\tAlso enables second interface " - "in receiver for listening (Writes a file per interface if writing " - "enabled).\n\tAlso restarts client and receiver zmq sockets if zmq " - "streaming enabled.\n\t[Eiger] Only gets with result 2."); - - INTEGER_COMMAND_VEC_ID(selinterface, getSelectedUDPInterface, - selectUDPInterface, StringTo, - "[0, 1]\n\t[Jungfrau][Moench] The udp interface " - "to stream data from detector. Effective only when " - "number of interfaces is 1. Default: 0 (outer)"); - - GET_COMMAND( - udp_numdst, getNumberofUDPDestinations, - "\n\t[Jungfrau][Moench][Eiger][Mythen3][Gotthard2] One can enter " - "upto 32 (64 for Mythen3) destinations that the detector will stream " - "images out in a round robin fashion. This is get only command. " - "Default: 1"); - - EXECUTE_SET_COMMAND(udp_cleardst, clearUDPDestinations, - "\n\tClears udp destination details on the detector."); - - INTEGER_COMMAND_VEC_ID( - udp_firstdst, getFirstUDPDestination, setFirstUDPDestination, - StringTo, - "\n[0 - 31 (or number of udp " - "destinations)]\n\t[Jungfrau][Moench][Gotthard2]\n[0-63]\n\t[" - "Mythen3]\n\n\t One can set which is the first destination that the " - "detector will stream images out from in a round robin fashion. The " - "entry must not have been empty. Default: 0"); - - INTEGER_COMMAND_VEC_ID( - udp_srcmac, getSourceUDPMAC, setSourceUDPMAC, MacAddr, - "[x:x:x:x:x:x]\n\tMac address of the detector (source) udp " - "interface. \n\t[Eiger] Do not set as detector will replace with " - "its own DHCP Mac (1G) or DHCP Mac + 1 (10G)."); - - INTEGER_COMMAND_VEC_ID( - udp_srcmac2, getSourceUDPMAC2, setSourceUDPMAC2, MacAddr, - "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the top " - "half or inner (source) udp interface. "); - - INTEGER_COMMAND_VEC_ID( - udp_dstmac, getDestinationUDPMAC, setDestinationUDPMAC, MacAddr, - "[x:x:x:x:x:x]\n\tMac address of the receiver (destination) udp " - "interface. Not mandatory to set as udp_dstip retrieves it from " - "slsReceiver process, but must be set if you use a custom receiver " - "(not slsReceiver). Use router mac if router between detector and " - "receiver."); - - INTEGER_COMMAND_VEC_ID( - udp_dstmac2, getDestinationUDPMAC2, setDestinationUDPMAC2, MacAddr, - "[x:x:x:x:x:x]\n\t[Jungfrau][Moench] Mac address of the receiver " - "(destination) udp interface 2. Not mandatory to set as udp_dstip2 " - "retrieves it from slsReceiver process but must be set if you use a " - "custom receiver (not slsReceiver). \n\t [Jungfrau][Moench] top half " - "or inner interface \n\t [Gotthard2] veto debugging. Use router mac if " - "router between detector and receiver."); - - INTEGER_COMMAND_VEC_ID_GET( - udp_dstport, getDestinationUDPPort, setDestinationUDPPort, - StringTo, - "[n]\n\tPort number of the receiver (destination) udp " - "interface. Default is 50001. \n\tIf multi command, ports for each " - "module is calculated (incremented by 1 if no 2nd interface)"); - - INTEGER_COMMAND_VEC_ID_GET( - udp_dstport2, getDestinationUDPPort2, setDestinationUDPPort2, - StringTo, - "[n]\n\t[Jungfrau][Moench][Eiger][Gotthard2] Port number of the " - "receiver (destination) udp interface 2. Default is 50002. " - "\n\tIf multi command, ports for each module is calculated " - "(incremented by 2) \n\t[Jungfrau][Moench] top half or inner " - "interface \n\t[Eiger] right half \n\t[Gotthard2] veto debugging"); - - EXECUTE_SET_COMMAND( - udp_reconfigure, reconfigureUDPDestination, - "\n\tReconfigures Detector with UDP destination. More for " - "debugging as the configuration is done automatically when the " - "detector has sufficient UDP details."); - - EXECUTE_SET_COMMAND( - udp_validate, validateUDPConfiguration, - "\n\tValidates that UDP configuration in the detector is " - "valid. If not configured, it will throw with error message " - "requesting missing udp information."); - - GET_COMMAND(rx_printconfig, printRxConfiguration, - "\n\tPrints the receiver configuration."); - - INTEGER_COMMAND_VEC_ID(tengiga, getTenGiga, setTenGiga, StringTo, - "[0, 1]\n\t[Eiger][Ctb][Mythen3] 10GbE Enable."); - - INTEGER_COMMAND_VEC_ID( - flowcontrol10g, getTenGigaFlowControl, setTenGigaFlowControl, - StringTo, - "[0, 1]\n\t[Eiger][Jungfrau][Moench] 10GbE Flow Control."); - - INTEGER_COMMAND_VEC_ID( - txdelay_frame, getTransmissionDelayFrame, setTransmissionDelayFrame, - StringTo, - "[n_delay]\n\t[Eiger][Jungfrau][Moench][Mythen3] Transmission " - "delay of first udp packet being streamed out of the " - "module.\n\t[Jungfrau][Moench] [0-31] Each value represents 1 " - "ms\n\t[Eiger] Additional delay to txdelay_left and txdelay_right. " - "Each value represents 10ns. Typical value is 50000.\n\t[Mythen3] " - "[0-16777215] Each value represents 8 ns (125 MHz clock), max is 134 " - "ms."); - - INTEGER_COMMAND_VEC_ID( - txdelay_left, getTransmissionDelayLeft, setTransmissionDelayLeft, - StringTo, - "[n_delay]\n\t[Eiger] Transmission delay of first packet in an " - "image being streamed out of the module's left UDP port. Each value " - "represents 10ns. Typical value is 50000."); - - INTEGER_COMMAND_VEC_ID( - txdelay_right, getTransmissionDelayRight, setTransmissionDelayRight, - StringTo, - "[n_delay]\n\t[Eiger] Transmission delay of first packet in an " - "image being streamed out of the module's right UDP port. Each value " - "represents 10ns. Typical value is 50000."); - - /* Receiver Config */ - - INTEGER_COMMAND_VEC_ID_GET( - rx_tcpport, getRxPort, setRxPort, StringTo, - "[port]\n\tTCP port for client-receiver communication. Default is " - "1954. Must be different if multiple receivers on same pc. Must be " - "first command to set a receiver parameter. Multi command will " - "automatically increment for individual modules."); - - INTEGER_COMMAND_VEC_ID( - rx_fifodepth, getRxFifoDepth, setRxFifoDepth, StringTo, - "[n_frames]\n\tSet the number of frames in the receiver " - "fifo depth (buffer between listener and writer threads)."); - - INTEGER_COMMAND_VEC_ID(rx_silent, getRxSilentMode, setRxSilentMode, - StringTo, - "[0, 1]\n\tSwitch on or off receiver text " - "output during acquisition."); - - INTEGER_COMMAND_VEC_ID( - rx_discardpolicy, getRxFrameDiscardPolicy, setRxFrameDiscardPolicy, - StringTo, - "[nodiscard (default)|discardempty|discardpartial(fastest)]\n\tFrame " - "discard policy of receiver. nodiscard does not discard frames, " - "discardempty discards empty frames, discardpartial discards partial " - "frames."); - - INTEGER_COMMAND_VEC_ID(rx_padding, getPartialFramesPadding, - setPartialFramesPadding, StringTo, - "[0, 1]\n\tPartial frames padding enable in the " - "receiver. Default: enabled. Disabling is fastest."); - - INTEGER_COMMAND_VEC_ID(rx_udpsocksize, getRxUDPSocketBufferSize, - setRxUDPSocketBufferSize, StringTo, - "[n_size]\n\tUDP socket buffer size in " - "receiver. Tune rmem_default and rmem_max " - "accordingly. Max value is INT_MAX/2."); - - GET_COMMAND(rx_realudpsocksize, getRxRealUDPSocketBufferSize, - "\n\tActual udp socket buffer size. Double the size of " - "rx_udpsocksize due to kernel bookkeeping."); - - INTEGER_COMMAND_VEC_ID(rx_lock, getRxLock, setRxLock, StringTo, - "[0, 1]\n\tLock receiver to one client IP, 1 locks, " - "0 unlocks. Default is unlocked."); - - GET_COMMAND( - rx_lastclient, getRxLastClientIP, - "\n\tClient IP Address that last communicated with the receiver."); - - GET_COMMAND( - rx_threads, getRxThreadIds, - "\n\tGet kernel thread ids from the receiver in order of [parent, " - "tcp, listener 0, processor 0, streamer 0, listener 1, processor 1, " - "streamer 1, arping]. If no streamer yet or there is no second " - "interface, it gives 0 in its place."); - - INTEGER_COMMAND_VEC_ID( - rx_arping, getRxArping, setRxArping, StringTo, - "[0, 1]\n\tStarts a thread in slsReceiver to arping " - "the interface it is listening to every minute. Useful in 10G mode."); - - EXECUTE_SET_COMMAND_NOID(rx_clearroi, clearRxROI, - "Resets Region of interest in receiver. Default " - "is all channels/pixels enabled."); - - /* File */ - - INTEGER_COMMAND_VEC_ID( - fformat, getFileFormat, setFileFormat, - StringTo, - "[binary|hdf5]\n\tFile format of data file. For " - "HDF5, package must be compiled with HDF5 flags. Default is binary."); - - STRING_COMMAND(fpath, getFilePath, setFilePath, - "[path]\n\tDirectory where output data files are written in " - "receiver. Default is '/'. \n\tIf path does not exist, it " - "will try to create it."); - - STRING_COMMAND(fname, getFileNamePrefix, setFileNamePrefix, - "[name]\n\tFile name prefix for output data file. Default " - "is run. File name: [file name prefix]_d[detector " - "index]_f[sub file index]_[acquisition/file index].raw."); - - INTEGER_COMMAND_VEC_ID(findex, getAcquisitionIndex, setAcquisitionIndex, - StringTo, - "[n_value]\n\tFile or Acquisition index."); - - INTEGER_COMMAND_VEC_ID( - fwrite, getFileWrite, setFileWrite, StringTo, - "[0, 1]\n\tEnable or disable receiver file write. Default is 1."); - - INTEGER_COMMAND_NOID( - fmaster, getMasterFileWrite, setMasterFileWrite, StringTo, - "[0, 1]\n\tEnable or disable receiver master file. Default is 1."); - - INTEGER_COMMAND_VEC_ID( - foverwrite, getFileOverWrite, setFileOverWrite, StringTo, - "[0, 1]\n\tEnable or disable file overwriting. Default is 1."); - - INTEGER_COMMAND_VEC_ID( - rx_framesperfile, getFramesPerFile, setFramesPerFile, StringTo, - "[n_frames]\n\tNumber of frames per file in receiver in an " - "acquisition. Default depends on detector type. 0 is infinite or " - "all " - "frames in single file."); - - /* ZMQ Streaming Parameters (Receiver<->Client) */ - - INTEGER_COMMAND_VEC_ID( - rx_zmqstream, getRxZmqDataStream, setRxZmqDataStream, StringTo, - "[0, 1]\n\tEnable/ disable data streaming from receiver via zmq " - "(eg. to GUI or to another process for further processing). This " - "creates/ destroys zmq streamer threads in receiver. \n\tSwitching to " - "Gui automatically enables data streaming in receiver. \n\tSwitching " - "back to command line acquire will require disabling data streaming in " - "receiver for fast applications. "); - - INTEGER_COMMAND_VEC_ID( - rx_zmqfreq, getRxZmqFrequency, setRxZmqFrequency, StringTo, - "[nth frame]\n\tFrequency of frames streamed out from receiver via " - "zmq\n\tDefault: 1, Means every frame is streamed out. \n\tIf 2, " - "every second frame is streamed out. \n\tIf 0, streaming timer is the " - "timeout, after which current frame is sent out. (default timeout is " - "500 ms). Usually used for gui purposes."); - - INTEGER_COMMAND_VEC_ID( - rx_zmqstartfnum, getRxZmqStartingFrame, setRxZmqStartingFrame, - StringTo, - "[fnum]\n\tThe starting frame index to stream out. 0 by " - "default, which streams the first frame in an acquisition, " - "and then depending on the rx zmq frequency/ timer"); - - INTEGER_COMMAND_VEC_ID_GET( - rx_zmqport, getRxZmqPort, setRxZmqPort, StringTo, - "[port]\n\tZmq port for data to be streamed out of the receiver. " - "Also restarts receiver zmq streaming if enabled. Default is 30001. " - "Modified only when using an intermediate process between receiver and " - "client(gui). Must be different for every detector (and udp port). " - "Multi command will automatically increment for individual modules."); - - INTEGER_COMMAND_VEC_ID_GET( - zmqport, getClientZmqPort, setClientZmqPort, StringTo, - "[port]\n\tZmq port in client(gui) or intermediate process for " - "data to be streamed to from receiver. Default connects to receiver " - "zmq streaming out port (30001). Modified only when using an " - "intermediate process between receiver and client(gui). Also restarts " - "client zmq streaming if enabled. Must be different for every detector " - "(and udp port). Multi command will automatically increment for " - "individual modules."); - - INTEGER_COMMAND_VEC_ID( - rx_zmqip, getRxZmqIP, setRxZmqIP, IpAddr, - "[x.x.x.x]\n\tZmq Ip Address from which data is to be streamed out " - "of the receiver. Also restarts receiver zmq streaming if enabled. " - "Default is from rx_hostname. Modified only when using an intermediate " - "process between receiver."); - - INTEGER_COMMAND_VEC_ID( - zmqip, getClientZmqIp, setClientZmqIp, IpAddr, - "[x.x.x.x]\n\tIp Address to listen to zmq data streamed out from " - "receiver or intermediate process. Default connects to receiver zmq Ip " - "Address (from rx_hostname). Modified only when using an intermediate " - "process between receiver and client(gui). Also restarts client zmq " - "streaming if enabled."); - - INTEGER_COMMAND_SET_NOID_GET_ID( - rx_zmqhwm, getRxZmqHwm, setRxZmqHwm, StringTo, - "[n_value]\n\tReceiver's zmq send high water mark. Default is the " - "zmq library's default (1000). This is a high number and can be set to " - "2 for gui purposes. One must also set the client's receive high water " - "mark to similar value. Final effect is sum of them. Also restarts " - "receiver zmq streaming if enabled. Can set to -1 to set default " - "value."); - - /* Eiger Specific */ - - TIME_COMMAND(subexptime, getSubExptime, setSubExptime, - "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Exposure " - "time of EIGER subframes in 32 bit mode."); - - TIME_COMMAND(subdeadtime, getSubDeadTime, setSubDeadTime, - "[duration] [(optional unit) ns|us|ms|s]\n\t[Eiger] Dead time " - "of EIGER subframes in 32 bit mode. Subperiod = subexptime + " - "subdeadtime."); - - INTEGER_COMMAND_VEC_ID( - overflow, getOverFlowMode, setOverFlowMode, StringTo, - "[0, 1]\n\t[Eiger] Enable or disable show overflow flag in " - "32 bit mode. Default is disabled."); - - INTEGER_COMMAND_VEC_ID( - interruptsubframe, getInterruptSubframe, setInterruptSubframe, - StringTo, - "[0, 1]\n\t[Eiger] 1 interrupts last subframe at required " - "exposure time. 0 will wait for last sub frame to finish " - "exposing. 0 is default."); - - TIME_GET_COMMAND(measuredperiod, getMeasuredPeriod, - "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured frame " - "period between last frame and previous one. Can be " - "measured with minimum 2 frames in an acquisition."); - - TIME_GET_COMMAND(measuredsubperiod, getMeasuredSubFramePeriod, - "[(optional unit) ns|us|ms|s]\n\t[Eiger] Measured sub " - "frame period between last sub frame and previous one."); - - INTEGER_COMMAND_VEC_ID(activate, getActive, setActive, StringTo, - "[0, 1] \n\t[Eiger] 1 is default. 0 deactivates " - "readout and does not send data."); - - INTEGER_COMMAND_VEC_ID( - partialreset, getPartialReset, setPartialReset, StringTo, - "[0, 1]\n\t[Eiger] Sets up detector to do " - "partial or complete reset at start of acquisition. 0 complete reset, " - "1 partial reset. Default is complete reset. Advanced function!"); - - INTEGER_COMMAND_VEC_ID( - top, getTop, setTop, StringTo, - "[0, 1]\n\t[Eiger] Sets half module to top (1), else bottom."); - - /* Jungfrau Specific */ - - GET_COMMAND(chipversion, getChipVersion, - "\n\t[Jungfrau] Returns chip version. Can be 1.0 or 1.1"); - - INTEGER_COMMAND_VEC_ID( - temp_threshold, getThresholdTemperature, setThresholdTemperature, - StringTo, - "[n_temp (in degrees)]\n\t[Jungfrau][Moench] Threshold temperature " - "in degrees. If temperature crosses threshold temperature and " - "temperature control is enabled, power to chip will be switched off " - "and temperature event occurs. To power on chip again, temperature has " - "to be less than threshold temperature and temperature event has to be " - "cleared."); - - INTEGER_COMMAND_VEC_ID( - temp_control, getTemperatureControl, setTemperatureControl, - StringTo, - "[0, 1]\n\t[Jungfrau][Moench] Temperature control enable. Default " - "is 0 (disabled). If temperature crosses threshold temperature and " - "temperature control is enabled, power to chip will be switched off " - "and temperature event occurs. To power on chip again, temperature has " - "to be less than threshold temperature and temperature event has to be " - "cleared."); - - INTEGER_COMMAND_VEC_ID( - autocompdisable, getAutoComparatorDisable, setAutoComparatorDisable, - StringTo, - "[0, 1]\n\t[Jungfrau] Auto comparator disable mode. By " - "default, the on-chip gain switching is active during the entire " - "exposure.This mode disables the on - chip gain switching " - "comparator automatically after 93.75% (only for chipv1.0) of exposure " - "time (only for longer than 100us). It is possible to set the duration " - "for chipv1.1 using compdisabletime command.\n\tDefault is 0 or this " - "mode disabled(comparator enabled throughout). 1 enables mode. 0 " - "disables mode. "); - - TIME_COMMAND(compdisabletime, getComparatorDisableTime, - setComparatorDisableTime, - "[duration] [(optional unit) ns|us|ms|s]\n\t[Jungfrau] Time " - "before end of exposure when comparator is disabled. It is " - "only possible for chipv1.1."); - - INTEGER_COMMAND_SET_NOID_GET_ID( - extrastoragecells, getNumberOfAdditionalStorageCells, - setNumberOfAdditionalStorageCells, StringTo, - "[0-15]\n\t[Jungfrau] Only for chipv1.0. Number of additional " - "storage cells. Default is 0. For advanced users only. \n\tThe #images " - "= #frames x #triggers x (#extrastoragecells + 1)."); - - INTEGER_COMMAND_VEC_ID( - storagecell_start, getStorageCellStart, setStorageCellStart, - StringTo, - "[0-max]\n\t[Jungfrau] Storage cell that stores " - "the first acquisition of the series. max is 15 (default) for chipv1.0 " - "and 3 (default) for chipv1.1. For advanced users only."); - - TIME_COMMAND(storagecell_delay, getStorageCellDelay, setStorageCellDelay, - "[duration (0-1638375 ns)] [(optional unit) " - "ns|us|ms|s]\n\t[Jungfrau] Additional time delay between 2 " - "consecutive exposures in burst mode (resolution of 25ns). " - "Only applicable for chipv1.0. For advanced users only."); - - INTEGER_COMMAND_VEC_ID( - gainmode, getGainMode, setGainMode, StringTo, - "[dynamicgain|forceswitchg1|forceswitchg2|fixg1|fixg2|fixg0]\n\t[" - "Jungfrau] Gain mode.\n\tCAUTION: Do not use fixg0 without " - "caution, you can damage the detector!!!"); - - INTEGER_COMMAND_VEC_ID(filtercells, getNumberOfFilterCells, - setNumberOfFilterCells, StringTo, - "[0-12]\n\t[Jungfrau] Set Filter Cell. Only for " - "chipv1.1. Advanced user Command"); - - /* Gotthard Specific */ - TIME_GET_COMMAND(exptimel, getExptimeLeft, - "[(optional unit) ns|us|ms|s]\n\t[Gotthard] Exposure time " - "left for current frame. "); - - EXECUTE_SET_COMMAND(clearroi, clearROI, - "[Gotthard] Resets Region of interest in detector. All " - "channels enabled. Default is all channels enabled."); - - /* Gotthard2 Specific */ - INTEGER_COMMAND_SET_NOID_GET_ID( - bursts, getNumberOfBursts, setNumberOfBursts, StringTo, - "[n_bursts]\n\t[Gotthard2] Number of bursts per aquire. Only in auto " - "timing mode and burst mode. Use timing command to set timing mode and " - "burstmode command to set burst mode."); - - TIME_COMMAND(burstperiod, getBurstPeriod, setBurstPeriod, - "[duration] [(optional unit) ns|us|ms|s]\n\t[Gotthard2] " - "Period between 2 bursts. Only in burst mode and auto " - "timing mode."); - - GET_COMMAND(burstsl, getNumberOfBurstsLeft, - "\n\t[Gotthard2] Number of bursts left in acquisition. Only in " - "burst auto mode."); - - INTEGER_COMMAND_VEC_ID( - cdsgain, getCDSGain, setCDSGain, StringTo, - "[0, 1]\n\t[Gotthard2] Enable or disable CDS gain. Default " - "is disabled."); - - INTEGER_COMMAND_VEC_ID( - timingsource, getTimingSource, setTimingSource, - StringTo, - "[internal|external]\n\t[Gotthard2] Timing source. Internal is " - "crystal and external is system timing. Default is internal."); - - INTEGER_COMMAND_VEC_ID(veto, getVeto, setVeto, StringTo, - "[0, 1]\n\t[Gotthard2] Enable or disable veto data " - "data from chip. Default is 0."); - - /* Mythen3 Specific */ - - INTEGER_COMMAND_VEC_ID( - gates, getNumberOfGates, setNumberOfGates, StringTo, - "[n_gates]\n\t[Mythen3] Number of external gates in gating " - "or trigger_gating mode (external gating)."); - - INTEGER_COMMAND_VEC_ID(polarity, getPolarity, setPolarity, - StringTo, - "[pos|neg]\n\t[Mythen3] Sets negative or positive " - "polarity. Default is positive"); - - INTEGER_COMMAND_VEC_ID(interpolation, getInterpolation, setInterpolation, - StringTo, - "[0, 1]\n\t[Mythen3] Enables or disables " - "interpolation. Default is disabled. Interpolation " - "mode enables all counters and disables vth3. " - "Disabling sets back counter mask and vth3."); - - INTEGER_COMMAND_VEC_ID( - pumpprobe, getPumpProbe, setPumpProbe, StringTo, - "[0, 1]\n\t[Mythen3] Enables or disables pump probe " - "mode. Default is disabled. Pump probe mode only enables vth2. " - "Disabling sets back to previous value."); - - INTEGER_COMMAND_VEC_ID(apulse, getAnalogPulsing, setAnalogPulsing, - StringTo, - "[0, 1]\n\t[Mythen3] Enables or disables analog " - "pulsing. Default is disabled"); - - INTEGER_COMMAND_VEC_ID(dpulse, getDigitalPulsing, setDigitalPulsing, - StringTo, - "[0, 1]\n\t[Mythen3] Enables or disables digital " - "pulsing. Default is disabled"); - - /* CTB/ Moench Specific */ - - INTEGER_COMMAND_VEC_ID( - asamples, getNumberOfAnalogSamples, setNumberOfAnalogSamples, - StringTo, - "[n_samples]\n\t[CTB] Number of analog samples expected."); - - INTEGER_COMMAND_VEC_ID( - adcclk, getADCClock, setADCClock, StringTo, - "[n_clk in MHz]\n\t[Ctb] ADC clock frequency in MHz."); - - INTEGER_COMMAND_VEC_ID(runclk, getRUNClock, setRUNClock, StringTo, - "[n_clk in MHz]\n\t[Ctb] Run clock in MHz."); - - GET_COMMAND(syncclk, getSYNCClock, - "[n_clk in MHz]\n\t[Ctb] Sync clock in MHz."); - - INTEGER_IND_COMMAND(v_limit, getPower, setPower, StringTo, - defs::V_LIMIT, - "[n_value]\n\t[Ctb] Soft limit for power " - "supplies (ctb only) and DACS in mV."); - - INTEGER_COMMAND_HEX(adcenable, getADCEnableMask, setADCEnableMask, - StringTo, - "[bitmask]\n\t[Ctb] ADC Enable Mask for 1Gb " - "Enable for each 32 ADC channel."); - - INTEGER_COMMAND_HEX( - adcenable10g, getTenGigaADCEnableMask, setTenGigaADCEnableMask, - StringTo, - "[bitmask]\n\t[Ctb] ADC Enable Mask for 10Gb mode for each 32 " - "ADC channel. However, if any of a consecutive 4 bits are enabled, " - "the complete 4 bits are enabled."); - - INTEGER_COMMAND_HEX(transceiverenable, getTransceiverEnableMask, - setTransceiverEnableMask, StringTo, - "[bitmask]\n\t[Ctb] Transceiver Enable Mask. Enable " - "for each 4 Transceiver channel."); - - INTEGER_COMMAND_VEC_ID( - dsamples, getNumberOfDigitalSamples, setNumberOfDigitalSamples, - StringTo, - "[n_value]\n\t[CTB] Number of digital samples expected."); - - INTEGER_COMMAND_VEC_ID( - tsamples, getNumberOfTransceiverSamples, setNumberOfTransceiverSamples, - StringTo, - "[n_value]\n\t[CTB] Number of transceiver samples expected."); - - INTEGER_COMMAND_VEC_ID( - romode, getReadoutMode, setReadoutMode, - StringTo, - "[analog|digital|analog_digital|transceiver|digital_transceiver]\n\t[" - "CTB] Readout mode. Default is analog."); - - INTEGER_COMMAND_VEC_ID(dbitclk, getDBITClock, setDBITClock, StringTo, - "[n_clk in MHz]\n\t[Ctb] Clock for latching the " - "digital bits in MHz."); - - INTEGER_IND_COMMAND(v_a, getPower, setPower, StringTo, defs::V_POWER_A, - "[n_value]\n\t[Ctb] Power supply a in mV."); - - INTEGER_IND_COMMAND(v_b, getPower, setPower, StringTo, defs::V_POWER_B, - "[n_value]\n\t[Ctb] Power supply b in mV."); - - INTEGER_IND_COMMAND(v_c, getPower, setPower, StringTo, defs::V_POWER_C, - "[n_value]\n\t[Ctb] Power supply c in mV."); - - INTEGER_IND_COMMAND(v_d, getPower, setPower, StringTo, defs::V_POWER_D, - "[n_value]\n\t[Ctb] Power supply d in mV."); - - INTEGER_IND_COMMAND( - v_io, getPower, setPower, StringTo, defs::V_POWER_IO, - "[n_value]\n\t[Ctb] Power supply io in mV. Minimum 1200 mV. Must " - "be the first power regulator to be set after fpga reset (on-board " - "detector server start up)."); - - INTEGER_IND_COMMAND( - v_chip, getPower, setPower, StringTo, defs::V_POWER_CHIP, - "[n_value]\n\t[Ctb] Power supply chip in mV. Do not use it " - "unless " - "you are completely sure you will not fry the board."); - - GET_IND_COMMAND(vm_a, getMeasuredPower, defs::V_POWER_A, "", - "\n\t[Ctb] Measured voltage of power supply a in mV."); - - GET_IND_COMMAND(vm_b, getMeasuredPower, defs::V_POWER_B, "", - "\n\t[Ctb] Measured voltage of power supply b in mV."); - - GET_IND_COMMAND(vm_c, getMeasuredPower, defs::V_POWER_C, "", - "\n\t[Ctb] Measured voltage of power supply c in mV."); - - GET_IND_COMMAND(vm_d, getMeasuredPower, defs::V_POWER_D, "", - "\n\t[Ctb] Measured voltage of power supply d in mV."); - - GET_IND_COMMAND(vm_io, getMeasuredPower, defs::V_POWER_IO, "", - "\n\t[Ctb] Measured voltage of power supply io in mV."); - - GET_IND_COMMAND(im_a, getMeasuredCurrent, defs::I_POWER_A, "", - "\n\t[Ctb] Measured current of power supply a in mA."); - - GET_IND_COMMAND(im_b, getMeasuredCurrent, defs::I_POWER_B, "", - "\n\t[Ctb] Measured current of power supply b in mA."); - - GET_IND_COMMAND(im_c, getMeasuredCurrent, defs::I_POWER_C, "", - "\n\t[Ctb] Measured current of power supply c in mA."); - - GET_IND_COMMAND(im_d, getMeasuredCurrent, defs::I_POWER_D, "", - "\n\t[Ctb] Measured current of power supply d in mA."); - - GET_IND_COMMAND(im_io, getMeasuredCurrent, defs::I_POWER_IO, "", - "\n\t[Ctb] Measured current of power supply io in mA."); - - INTEGER_COMMAND_VEC_ID( - extsampling, getExternalSampling, setExternalSampling, StringTo, - "[0, 1]\n\t[Ctb] Enable for external sampling signal for digital " - "data to signal by extsampling src command. For advanced users only."); - - INTEGER_COMMAND_VEC_ID( - extsamplingsrc, getExternalSamplingSource, setExternalSamplingSource, - StringTo, - "[0-63]\n\t[Ctb] Sampling source signal for digital data. " - "For advanced users only."); - - INTEGER_COMMAND_VEC_ID( - rx_dbitoffset, getRxDbitOffset, setRxDbitOffset, StringTo, - "[n_bytes]\n\t[Ctb] Offset in bytes in digital data to " - "skip in receiver."); - - INTEGER_COMMAND_VEC_ID(led, getLEDEnable, setLEDEnable, StringTo, - "[0, 1]\n\t[Ctb] Switches on/off all LEDs."); - - /* Pattern */ - - GET_COMMAND(patfname, getPatterFileName, - "\n\t[Ctb][Mythen3] Gets the pattern file name including " - "path of the last pattern uploaded. Returns an empty if " - "nothing was uploaded or via a server default file"); - - EXECUTE_SET_COMMAND_NOID_1ARG( - savepattern, savePattern, - "[fname]\n\t[Ctb][Mythen3] Saves pattern to file (ascii). " - "\n\t[Ctb] Also executes pattern."); - - EXECUTE_SET_COMMAND( - defaultpattern, loadDefaultPattern, - "\n\t[Mythen3] Loads and runs default pattern in pattern " - "generator. It is to go back to initial settings."); - - INTEGER_COMMAND_HEX_WIDTH16(patioctrl, getPatternIOControl, - setPatternIOControl, StringTo, - "[64 bit mask]\n\t[Ctb] 64 bit mask " - "defining input (0) and output (1) signals."); - - INTEGER_COMMAND_HEX_WIDTH16( - patmask, getPatternMask, setPatternMask, StringTo, - "[64 bit mask]\n\t[Ctb][Mythen3] Selects the bits that will " - "have a pattern mask applied to the selected patmask for every " - "pattern."); - - INTEGER_COMMAND_HEX_WIDTH16( - patsetbit, getPatternBitMask, setPatternBitMask, StringTo, - "[64 bit mask]\n\t[Ctb][Mythen3] Sets the mask applied to " - "every pattern to the selected bits."); - - EXECUTE_SET_COMMAND(patternstart, startPattern, - "\n\t[Mythen3] Starts Pattern"); - - /* Moench */ - /* Advanced */ - - INTEGER_COMMAND_VEC_ID( - adcpipeline, getADCPipeline, setADCPipeline, StringTo, - "[n_value]\n\t[Ctb][Moench] Pipeline for ADC clock."); - - EXECUTE_SET_COMMAND(resetfpga, resetFPGA, - "\n\t[Jungfrau][Moench][Ctb] Reset FPGA."); - - EXECUTE_SET_COMMAND(rebootcontroller, rebootController, - "\n\t[Jungfrau][Moench][Ctb][Gotthard][Mythen3][" - "Gotthard2] Reboot controller of detector."); - - INTEGER_COMMAND_VEC_ID( - updatemode, getUpdateMode, setUpdateMode, StringTo, - "[0|1]\n\tRestart the detector server in update " - "mode or not. This is useful when server-firmware compatibility is at " - "its worst and server cannot start up normally"); - - EXECUTE_SET_COMMAND( - firmwaretest, executeFirmwareTest, - "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] " - "Firmware test, ie. reads a read fixed pattern from a register."); - - EXECUTE_SET_COMMAND( - bustest, executeBusTest, - "\n\t[Jungfrau][Moench][Gotthard][Mythen3][Gotthard2][Ctb] Bus " - "test, ie. Writes different values in a R/W register and confirms the " - "writes to check bus.\n\tAdvanced User function!"); - - INTEGER_COMMAND_HEX( - adcinvert, getADCInvert, setADCInvert, StringTo, - "[bitmask]\n\t[Ctb][Jungfrau][Moench] ADC Inversion " - "Mask.\n\t[Jungfrau][Moench] Inversions on top of the default mask."); - - /* Insignificant */ - - INTEGER_COMMAND_VEC_ID( - port, getControlPort, setControlPort, StringTo, - "[n]\n\tPort number of the control server on detector for " - "detector-client tcp interface. Default is 1952. Normally unchanged. " - "Set different ports for virtual servers on same pc."); - - INTEGER_COMMAND_VEC_ID( - stopport, getStopPort, setStopPort, StringTo, - "[n]\n\tPort number of the stop server on detector for detector-client " - "tcp interface. Default is 1953. Normally unchanged."); - - INTEGER_COMMAND_VEC_ID( - lock, getDetectorLock, setDetectorLock, StringTo, - "[0, 1]\n\tLock detector to one IP, 1: locks. Default is unlocked"); - - GET_COMMAND( - lastclient, getLastClientIP, - "\n\tClient IP Address that last communicated with the detector."); - - GET_COMMAND( - framecounter, getNumberOfFramesFromStart, - "\n\t[Jungfrau][Moench][Mythen3][Gotthard2][CTB] Number of frames from " - "start run control.\n\t[Gotthard2] only in continuous mode."); - - TIME_GET_COMMAND(runtime, getActualTime, - "[(optional unit) " - "ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][" - "CTB] Time from detector start up.\n\t[Gotthard2] not in " - "burst and auto mode."); - - TIME_GET_COMMAND(frametime, getMeasurementTime, - "[(optional unit) " - "ns|us|ms|s]\n\t[Jungfrau][Moench][Mythen3][Gotthard2][" - "CTB] Timestamp at a frame start.\n\t[Gotthard2] not in " - "burst and auto mode."); -}; - -} // namespace sls diff --git a/slsDetectorSoftware/src/Detector.cpp b/slsDetectorSoftware/src/Detector.cpp index 344bde73c..0473c3c9a 100644 --- a/slsDetectorSoftware/src/Detector.cpp +++ b/slsDetectorSoftware/src/Detector.cpp @@ -3,8 +3,8 @@ #include "sls/Detector.h" #include "sls/detectorData.h" +#include "Caller.h" #include "CmdParser.h" -#include "CmdProxy.h" #include "CtbConfig.h" #include "DetectorImpl.h" #include "Module.h" @@ -18,6 +18,7 @@ #include #include +#include #include namespace sls { @@ -90,12 +91,12 @@ void Detector::loadParameters(const std::string &fname) { } void Detector::loadParameters(const std::vector ¶meters) { - CmdProxy proxy(this); + Caller caller(this); CmdParser parser; for (const auto ¤t_line : parameters) { parser.Parse(current_line); - proxy.Call(parser.command(), parser.arguments(), parser.detector_id(), - defs::PUT_ACTION, std::cout, parser.receiver_id()); + caller.call(parser.command(), parser.arguments(), parser.detector_id(), + defs::PUT_ACTION, std::cout, parser.receiver_id()); } } @@ -207,6 +208,7 @@ std::vector Detector::getSettingsList() const { defs::G2_LOWCAP_HIGHGAIN, defs::G2_LOWCAP_LOWGAIN, defs::G4_HIGHGAIN, defs::G4_LOWGAIN}; case defs::CHIPTESTBOARD: + case defs::XILINX_CHIPTESTBOARD: throw RuntimeError("Settings not implemented for this detector"); default: throw RuntimeError("Unknown detector type"); @@ -742,6 +744,7 @@ std::vector Detector::getDacList() const { defs::VBP_COLBUF, defs::VIPRE, defs::VIN_CM, defs::VB_SDA, defs::VCASC_SFP, defs::VOUT_CM, defs::VIPRE_CDS, defs::IBIAS_SFP}; case defs::CHIPTESTBOARD: + case defs::XILINX_CHIPTESTBOARD: for (int i = 0; i != 18; ++i) { retval.push_back(static_cast(i)); } @@ -873,18 +876,26 @@ void Detector::startDetectorReadout() { void Detector::stopDetector(Positions pos) { - // stop and check status X times int retries{0}; - // avoid default construction of runStatus::IDLE on squash - auto status = getDetectorStatus().squash(defs::runStatus::RUNNING); - while (status != defs::runStatus::IDLE && - status != defs::runStatus::STOPPED) { - if (status == defs::runStatus::ERROR) { - throw RuntimeError( - "Could not stop detector. Returned error status."); + auto status = getDetectorStatus(pos); + + // jf sync fix: status [stopped or idle] = [stopped] + // sync issue: (master idle sometimes, slaves stopped) + + // eiger fix: stop multiple times from multi client till all modules stopped + // issue: asynchronous start and stop scripts with a module being started + // (stop before) and waiting for the other to be done. So a module that was + // idle before stopping will return running (after async start script) when + // getting status after, which will then be stopped again. + + while (!status.contains_only(defs::runStatus::IDLE, + defs::runStatus::STOPPED)) { + if (status.any(defs::runStatus::ERROR)) { + throw RuntimeError("Could not stop detector. At least one module " + "returned error status."); } pimpl->stopDetector(pos); - status = getDetectorStatus().squash(defs::runStatus::RUNNING); + status = getDetectorStatus(pos); ++retries; if (retries == 10) @@ -896,14 +907,15 @@ void Detector::stopDetector(Positions pos) { case defs::EIGER: case defs::JUNGFRAU: case defs::MOENCH: - case defs::CHIPTESTBOARD: { + case defs::CHIPTESTBOARD: + case defs::XILINX_CHIPTESTBOARD: { auto res = getNextFrameNumber(pos); if (!res.equal()) { uint64_t maxVal = 0; for (auto it : res) { maxVal = std::max(maxVal, it); } - setNextFrameNumber(maxVal + 1); + setNextFrameNumber(maxVal + 1, pos); } } break; default: @@ -2070,7 +2082,9 @@ Result Detector::getSYNCClock(Positions pos) const { } std::vector Detector::getPowerList() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) { + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && + dettype != defs::XILINX_CHIPTESTBOARD) { throw RuntimeError("Power list not implemented for this detector"); } return std::vector{defs::V_POWER_A, defs::V_POWER_B, @@ -2079,7 +2093,9 @@ std::vector Detector::getPowerList() const { } std::vector Detector::getSlowADCList() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) { + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && + dettype != defs::XILINX_CHIPTESTBOARD) { throw RuntimeError("Slow ADC list not implemented for this detector"); } return std::vector{ @@ -2268,7 +2284,8 @@ void Detector::setLEDEnable(bool enable, Positions pos) { } void Detector::setDacNames(const std::vector names) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named dacs only for CTB"); pimpl->setCtbDacNames(names); } @@ -2276,7 +2293,7 @@ void Detector::setDacNames(const std::vector names) { std::vector Detector::getDacNames() const { std::vector names; auto type = getDetectorType().squash(); - if (type == defs::CHIPTESTBOARD) + if (type == defs::CHIPTESTBOARD || type == defs::XILINX_CHIPTESTBOARD) return pimpl->getCtbDacNames(); for (const auto &index : getDacList()) @@ -2286,7 +2303,7 @@ std::vector Detector::getDacNames() const { defs::dacIndex Detector::getDacIndex(const std::string &name) const { auto type = getDetectorType().squash(); - if (type == defs::CHIPTESTBOARD) { + if (type == defs::CHIPTESTBOARD || type == defs::XILINX_CHIPTESTBOARD) { auto names = getDacNames(); auto it = std::find(names.begin(), names.end(), name); if (it == names.end()) @@ -2297,32 +2314,36 @@ defs::dacIndex Detector::getDacIndex(const std::string &name) const { } void Detector::setDacName(const defs::dacIndex i, const std::string &name) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named dacs only for CTB"); pimpl->setCtbDacName(i, name); } std::string Detector::getDacName(const defs::dacIndex i) const { - auto type = getDetectorType().squash(); - if (type == defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype == defs::CHIPTESTBOARD || dettype == defs::XILINX_CHIPTESTBOARD) return pimpl->getCtbDacName(i); return ToString(i); } void Detector::setAdcNames(const std::vector names) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named adcs only for CTB"); pimpl->setCtbAdcNames(names); } std::vector Detector::getAdcNames() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named adcs only for CTB"); return pimpl->getCtbAdcNames(); } int Detector::getAdcIndex(const std::string &name) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named adcs only for CTB"); auto names = getAdcNames(); auto it = std::find(names.begin(), names.end(), name); @@ -2332,31 +2353,36 @@ int Detector::getAdcIndex(const std::string &name) const { } void Detector::setAdcName(const int index, const std::string &name) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named adcs only for CTB"); pimpl->setCtbAdcName(index, name); } std::string Detector::getAdcName(const int i) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named adcs only for CTB"); return pimpl->getCtbAdcName(i); } void Detector::setSignalNames(const std::vector names) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named signals only for CTB"); pimpl->setCtbSignalNames(names); } std::vector Detector::getSignalNames() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named signals only for CTB"); return pimpl->getCtbSignalNames(); } int Detector::getSignalIndex(const std::string &name) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named signals only for CTB"); auto names = getSignalNames(); auto it = std::find(names.begin(), names.end(), name); @@ -2366,31 +2392,37 @@ int Detector::getSignalIndex(const std::string &name) const { } void Detector::setSignalName(const int index, const std::string &name) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named signals only for CTB"); pimpl->setCtbSignalName(index, name); } std::string Detector::getSignalName(const int i) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named signals only for CTB"); return pimpl->getCtbSignalName(i); } void Detector::setPowerNames(const std::vector names) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (getDetectorType().squash() != defs::CHIPTESTBOARD && + dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named powers only for CTB"); pimpl->setCtbPowerNames(names); } std::vector Detector::getPowerNames() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named powers only for CTB"); return pimpl->getCtbPowerNames(); } defs::dacIndex Detector::getPowerIndex(const std::string &name) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named powers only for CTB"); auto names = getPowerNames(); auto it = std::find(names.begin(), names.end(), name); @@ -2401,31 +2433,36 @@ defs::dacIndex Detector::getPowerIndex(const std::string &name) const { void Detector::setPowerName(const defs::dacIndex index, const std::string &name) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named powers only for CTB"); pimpl->setCtbPowerName(index, name); } std::string Detector::getPowerName(const defs::dacIndex i) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named powers only for CTB"); return pimpl->getCtbPowerName(i); } void Detector::setSlowADCNames(const std::vector names) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named SlowADCs only for CTB"); pimpl->setCtbSlowADCNames(names); } std::vector Detector::getSlowADCNames() const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named SlowADCs only for CTB"); return pimpl->getCtbSlowADCNames(); } defs::dacIndex Detector::getSlowADCIndex(const std::string &name) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named SlowADCs only for CTB"); auto names = getSlowADCNames(); auto it = std::find(names.begin(), names.end(), name); @@ -2436,13 +2473,15 @@ defs::dacIndex Detector::getSlowADCIndex(const std::string &name) const { void Detector::setSlowADCName(const defs::dacIndex index, const std::string &name) { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named SlowADCs only for CTB"); pimpl->setCtbSlowADCName(index, name); } std::string Detector::getSlowADCName(const defs::dacIndex i) const { - if (getDetectorType().squash() != defs::CHIPTESTBOARD) + auto dettype = getDetectorType().squash(); + if (dettype != defs::CHIPTESTBOARD && dettype != defs::XILINX_CHIPTESTBOARD) throw RuntimeError("Named SlowADCs only for CTB"); return pimpl->getCtbSlowADCName(i); } diff --git a/slsDetectorSoftware/src/DetectorImpl.cpp b/slsDetectorSoftware/src/DetectorImpl.cpp index 9bf392e5a..a44bbadec 100644 --- a/slsDetectorSoftware/src/DetectorImpl.cpp +++ b/slsDetectorSoftware/src/DetectorImpl.cpp @@ -272,7 +272,8 @@ void DetectorImpl::setHostname(const std::vector &name) { // Here we know the detector type and can add ctb shared memory // if needed, CTB dac names are only on detector level - if (shm()->detType == defs::CHIPTESTBOARD) { + if (shm()->detType == defs::CHIPTESTBOARD || + shm()->detType == defs::XILINX_CHIPTESTBOARD) { if (ctb_shm.exists()) ctb_shm.openSharedMemory(true); else @@ -711,7 +712,8 @@ void DetectorImpl::readFrameFromReceiver() { uint32_t yoffset = coordY * nPixelsY; uint32_t singledetrowoffset = nPixelsX * bytesPerPixel; uint32_t rowoffset = nX * singledetrowoffset; - if (shm()->detType == CHIPTESTBOARD) { + if (shm()->detType == CHIPTESTBOARD || + shm()->detType == defs::XILINX_CHIPTESTBOARD) { singledetrowoffset = size; } LOG(logDEBUG1) @@ -1220,10 +1222,26 @@ int DetectorImpl::acquire() { dataProcessingThread.join(); if (acquisition_finished != nullptr) { - int status = Parallel(&Module::getRunStatus, {}).squash(ERROR); + // status + runStatus status = IDLE; + auto statusList = Parallel(&Module::getRunStatus, {}); + status = statusList.squash(ERROR); + // difference, but none error + if (status == ERROR && (!statusList.any(ERROR))) { + // handle jf sync issue (master idle, slaves stopped) + if (statusList.contains_only(IDLE, STOPPED)) { + status = STOPPED; + } else + status = statusList.squash(RUNNING); + } + + // progress auto a = Parallel(&Module::getReceiverProgress, {}); double progress = (*std::max_element(a.begin(), a.end())); - acquisition_finished(progress, status, acqFinished_p); + + // callback + acquisition_finished(progress, static_cast(status), + acqFinished_p); } clock_gettime(CLOCK_REALTIME, &end); @@ -1293,13 +1311,24 @@ void DetectorImpl::startAcquisition(const bool blocking, Positions pos) { std::vector masters; std::vector slaves; getMasterSlaveList(pos, masters, slaves); + if (masters.empty()) { + throw RuntimeError("Cannot start acquisition in sync mode. No " + "master module found"); + } if (!slaves.empty()) { Parallel(&Module::startAcquisition, slaves); } - if (!masters.empty()) { - Parallel((blocking ? &Module::startAndReadAll - : &Module::startAcquisition), - masters); + if (blocking) { + Parallel(&Module::startAndReadAll, masters); + // ensure all status normal (slaves not blocking) + // to catch those slaves that are still 'waiting' + auto status = Parallel(&Module::getRunStatus, pos); + if (!status.contains_only(IDLE, STOPPED, RUN_FINISHED)) { + throw RuntimeError("Acquisition not successful. " + "Unexpected detector status"); + } + } else { + Parallel(&Module::startAcquisition, masters); } } // all in parallel @@ -1708,7 +1737,8 @@ void DetectorImpl::verifyUniqueHost( } defs::ROI DetectorImpl::getRxROI() const { - if (shm()->detType == CHIPTESTBOARD) { + if (shm()->detType == CHIPTESTBOARD || + shm()->detType == defs::XILINX_CHIPTESTBOARD) { throw RuntimeError("RxRoi not implemented for this Detector"); } if (modules.size() == 0) { @@ -1783,7 +1813,8 @@ defs::ROI DetectorImpl::getRxROI() const { } void DetectorImpl::setRxROI(const defs::ROI arg) { - if (shm()->detType == CHIPTESTBOARD) { + if (shm()->detType == CHIPTESTBOARD || + shm()->detType == defs::XILINX_CHIPTESTBOARD) { throw RuntimeError("RxRoi not implemented for this Detector"); } if (modules.size() == 0) { diff --git a/slsDetectorSoftware/src/DetectorImpl.h b/slsDetectorSoftware/src/DetectorImpl.h index 9baefe8b3..a4484c243 100644 --- a/slsDetectorSoftware/src/DetectorImpl.h +++ b/slsDetectorSoftware/src/DetectorImpl.h @@ -84,9 +84,7 @@ class DetectorImpl : public virtual slsDetectorDefs { */ virtual ~DetectorImpl(); - template struct NonDeduced { - using type = CT; - }; + template struct NonDeduced { using type = CT; }; template Result Parallel(RT (Module::*somefunc)(CT...), std::vector positions, diff --git a/slsDetectorSoftware/src/HelpDacs.cpp b/slsDetectorSoftware/src/HelpDacs.cpp new file mode 100644 index 000000000..3a2c0504c --- /dev/null +++ b/slsDetectorSoftware/src/HelpDacs.cpp @@ -0,0 +1,319 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "sls/sls_detector_defs.h" +#include "sls/string_utils.h" +#include + +namespace sls { + +std::string GetHelpDac(std::string dac) { + if (sls::is_int(dac)) { + return std::string("[dac name] [dac or mV value] [(optional unit) mV] " + "\n\t[Ctb] Use dac index for dac name."); + } + if (dac == "vthreshold") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger][Mythen3] " + "Detector threshold voltage for single photon counters.\n\t[Eiger] " + "Sets vcmp_ll, vcmp_lr, vcmp_rl, vcmp_rr and vcp to the same " + "value. \n\t[Mythen3] Sets vth1, vth2 and vth3 to the same value " + "for enabled counters."); + } + if (dac == "vsvp") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? "); + } + if (dac == "vsvn") { + return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " + "Dac for ?? \n\t[Mythen3] voltage to define " + "feedback resistance of the first shaper"); + } + if (dac == "vtrim") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? " + "\n\t[Mythen3] Dac for the voltage defining the trim bit size."); + } + if (dac == "vrpreamp") { + return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " + "Dac for ?? \n\t[Mythen3] voltage to define the " + "preamplifier feedback resistance."); + } + if (dac == "vrshaper") { + return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " + "Dac for ?? \n\t[Mythen3] voltage to define " + "feedback resistance of the first shaper"); + } + if (dac == "vtgstv") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcmp_ll") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcmp_lr") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcal") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcmp_rl") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcmp_rr") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "rxb_rb") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "rxb_lb") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcp") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vcn") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vishaper") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "iodelay") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); + } + if (dac == "vref_ds") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard][Jungfrau] Dac for ??"); + } + if (dac == "vcascn_pb") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); + } + if (dac == "vcascp_pb") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); + } + if (dac == "vout_cm") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 5"); + } + if (dac == "vcasc_out") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); + } + if (dac == "vin_cm") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 2"); + } + if (dac == "vref_comp") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard][Jungfrau] Dac for ??"); + } + if (dac == "ib_test_c") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); + } + if (dac == "vrshaper_n") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] voltage to " + "define feedback resistance of the second shaper."); + } + if (dac == "vipre") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "preamplifier's input transistor current.\n\t[Moench] Dac for 1"); + } + if (dac == "vdcsh") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "reference (DC) voltage for the shaper."); + } + if (dac == "vth1") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for first " + "detector threshold voltage. Overwrites even if counter disabled."); + } + if (dac == "vth2") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for " + "second detector threshold voltage. Overwrites even if counter " + "disabled."); + } + if (dac == "vth3") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for third " + "detector threshold voltage. Overwrites even if counter disabled."); + } + if (dac == "vcal_n") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "low voltage for analog pulsing."); + } + if (dac == "vcal_p") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "high voltage for analog pulsing."); + } + if (dac == "vcassh") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "shaper's cascode voltage."); + } + if (dac == "vcas") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "preamplifier's cascode voltage."); + } + if (dac == "vicin") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " + "bias current for the comparator."); + } + if (dac == "vipre_out") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for " + "preamplifier's output transistor current."); + } + if (dac == "vref_h_adc") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "reference voltage high of ADC."); + } + if (dac == "vb_comp_fe") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "comparator current of analogue front end."); + } + if (dac == "vb_comp_adc") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "comparator current of ADC."); + } + if (dac == "vcom_cds") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "common mode voltage of CDS stage."); + } + if (dac == "vref_rstore") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard2] Dac for reference charging voltage " + "of temparory storage cell in high gain."); + } + if (dac == "vb_opa_1st") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] dac dac for " + "opa current for driving the other DACs in chip."); + } + if (dac == "vref_comp_fe") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "reference voltage of the comparator of analogue front end."); + } + if (dac == "vcom_adc1") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "common mode voltage of ADC DAC bank 1."); + } + if (dac == "vref_prech") { + return std::string( + "[dac or mV value][(optional unit) mV] " + "\n\t[Gotthard2][Jungfrau] " + "Dac for reference votlage for precharing the preamplifier."); + } + if (dac == "vref_l_adc") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "reference voltage low for ADC."); + } + if (dac == "vref_cds") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "reference voltage of CDS applied to the temporary storage cell in " + "medium and low gain."); + } + if (dac == "vb_cs") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "current injection into preamplifier."); + } + if (dac == "vb_opa_fd") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "current for CDS opa stage."); + } + if (dac == "vcom_adc2") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " + "common mode voltage of ADC DAC bank 2."); + } + if (dac == "vb_ds") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Jungfrau] Dac for ??"); + } + if (dac == "vb_comp") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Jungfrau] Dac for ??"); + } + if (dac == "vb_pixbuf") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Jungfrau] Dac for ??"); + } + if (dac == "vin_com") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Jungfrau] Dac for ??"); + } + if (dac == "vdd_prot") { + return std::string("[dac or mV value][(optional unit) mV] " + "\n\t[Jungfrau] Dac for ??"); + } + if (dac == "vbp_colbuf") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 0"); + } + if (dac == "vb_sda") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 3"); + } + if (dac == "vcasc_sfp") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 4"); + } + if (dac == "vipre_cds") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 6"); + } + if (dac == "ibias_sfp") { + return std::string( + "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 7"); + } + + // clang-format off + if (dac == "vtgstv") { return std::string(""); } + // clang-format on + + throw sls::RuntimeError("Unknown dac command"); +} + +std::string GetHelpDacWrapper(const std::string &cmd, + const std::vector &args) { + std::ostringstream os; + os << cmd << ' '; + if (args.size() == 0) { + os << GetHelpDac(std::to_string(0)) << '\n'; + } else { + os << args[0] << ' ' << GetHelpDac(args[0]) << '\n'; + } + return os.str(); +} + +} // namespace sls diff --git a/slsDetectorSoftware/src/HelpDacs.h b/slsDetectorSoftware/src/HelpDacs.h index 75c87710e..4c2c8cd9e 100644 --- a/slsDetectorSoftware/src/HelpDacs.h +++ b/slsDetectorSoftware/src/HelpDacs.h @@ -1,305 +1,13 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "sls/string_utils.h" +#include +#include namespace sls { -std::string GetHelpDac(std::string dac) { - if (sls::is_int(dac)) { - return std::string("[dac name] [dac or mV value] [(optional unit) mV] " - "\n\t[Ctb] Use dac index for dac name."); - } - if (dac == "vthreshold") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger][Mythen3] " - "Detector threshold voltage for single photon counters.\n\t[Eiger] " - "Sets vcmp_ll, vcmp_lr, vcmp_rl, vcmp_rr and vcp to the same " - "value. \n\t[Mythen3] Sets vth1, vth2 and vth3 to the same value " - "for enabled counters."); - } - if (dac == "vsvp") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? "); - } - if (dac == "vsvn") { - return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " - "Dac for ?? \n\t[Mythen3] voltage to define " - "feedback resistance of the first shaper"); - } - if (dac == "vtrim") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? " - "\n\t[Mythen3] Dac for the voltage defining the trim bit size."); - } - if (dac == "vrpreamp") { - return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " - "Dac for ?? \n\t[Mythen3] voltage to define the " - "preamplifier feedback resistance."); - } - if (dac == "vrshaper") { - return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] " - "Dac for ?? \n\t[Mythen3] voltage to define " - "feedback resistance of the first shaper"); - } - if (dac == "vtgstv") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcmp_ll") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcmp_lr") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcal") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcmp_rl") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcmp_rr") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "rxb_rb") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "rxb_lb") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcp") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vcn") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vishaper") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "iodelay") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??"); - } - if (dac == "vref_ds") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard][Jungfrau] Dac for ??"); - } - if (dac == "vcascn_pb") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); - } - if (dac == "vcascp_pb") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); - } - if (dac == "vout_cm") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 5"); - } - if (dac == "vcasc_out") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); - } - if (dac == "vin_cm") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 2"); - } - if (dac == "vref_comp") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard][Jungfrau] Dac for ??"); - } - if (dac == "ib_test_c") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??"); - } - if (dac == "vrshaper_n") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] voltage to " - "define feedback resistance of the second shaper."); - } - if (dac == "vipre") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "preamplifier's input transistor current.\n\t[Moench] Dac for 1"); - } - if (dac == "vdcsh") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "reference (DC) voltage for the shaper."); - } - if (dac == "vth1") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for first " - "detector threshold voltage. Overwrites even if counter disabled."); - } - if (dac == "vth2") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for " - "second detector threshold voltage. Overwrites even if counter " - "disabled."); - } - if (dac == "vth3") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for third " - "detector threshold voltage. Overwrites even if counter disabled."); - } - if (dac == "vcal_n") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "low voltage for analog pulsing."); - } - if (dac == "vcal_p") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "high voltage for analog pulsing."); - } - if (dac == "vcassh") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "shaper's cascode voltage."); - } - if (dac == "vcas") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "preamplifier's cascode voltage."); - } - if (dac == "vicin") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the " - "bias current for the comparator."); - } - if (dac == "vipre_out") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for " - "preamplifier's output transistor current."); - } - if (dac == "vref_h_adc") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "reference voltage high of ADC."); - } - if (dac == "vb_comp_fe") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "comparator current of analogue front end."); - } - if (dac == "vb_comp_adc") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "comparator current of ADC."); - } - if (dac == "vcom_cds") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "common mode voltage of CDS stage."); - } - if (dac == "vref_rstore") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard2] Dac for reference charging voltage " - "of temparory storage cell in high gain."); - } - if (dac == "vb_opa_1st") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] dac dac for " - "opa current for driving the other DACs in chip."); - } - if (dac == "vref_comp_fe") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "reference voltage of the comparator of analogue front end."); - } - if (dac == "vcom_adc1") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "common mode voltage of ADC DAC bank 1."); - } - if (dac == "vref_prech") { - return std::string( - "[dac or mV value][(optional unit) mV] " - "\n\t[Gotthard2][Jungfrau] " - "Dac for reference votlage for precharing the preamplifier."); - } - if (dac == "vref_l_adc") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "reference voltage low for ADC."); - } - if (dac == "vref_cds") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "reference voltage of CDS applied to the temporary storage cell in " - "medium and low gain."); - } - if (dac == "vb_cs") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "current injection into preamplifier."); - } - if (dac == "vb_opa_fd") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "current for CDS opa stage."); - } - if (dac == "vcom_adc2") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for " - "common mode voltage of ADC DAC bank 2."); - } - if (dac == "vb_ds") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Jungfrau] Dac for ??"); - } - if (dac == "vb_comp") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Jungfrau] Dac for ??"); - } - if (dac == "vb_pixbuf") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Jungfrau] Dac for ??"); - } - if (dac == "vin_com") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Jungfrau] Dac for ??"); - } - if (dac == "vdd_prot") { - return std::string("[dac or mV value][(optional unit) mV] " - "\n\t[Jungfrau] Dac for ??"); - } - if (dac == "vbp_colbuf") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 0"); - } - if (dac == "vb_sda") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 3"); - } - if (dac == "vcasc_sfp") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 4"); - } - if (dac == "vipre_cds") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 6"); - } - if (dac == "ibias_sfp") { - return std::string( - "[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 7"); - } +std::string GetHelpDac(std::string dac); - // clang-format off - if (dac == "vtgstv") { return std::string(""); } - // clang-format on - - throw sls::RuntimeError("Unknown dac command"); -} +std::string GetHelpDacWrapper(const std::string &cmd, + const std::vector &args); } // namespace sls diff --git a/slsDetectorSoftware/src/Module.cpp b/slsDetectorSoftware/src/Module.cpp index 33603c6ea..0f8596036 100644 --- a/slsDetectorSoftware/src/Module.cpp +++ b/slsDetectorSoftware/src/Module.cpp @@ -184,7 +184,8 @@ slsDetectorDefs::detectorType Module::getDetectorType() const { } void Module::updateNumberOfChannels() { - if (shm()->detType == CHIPTESTBOARD) { + if (shm()->detType == CHIPTESTBOARD || + shm()->detType == XILINX_CHIPTESTBOARD) { std::array retvals{}; sendToDetector(F_GET_NUM_CHANNELS, nullptr, retvals); shm()->nChan.x = retvals[0]; @@ -2461,7 +2462,8 @@ void Module::setReadoutMode(const slsDetectorDefs::readoutMode mode) { sendToDetector(F_SET_READOUT_MODE, arg, nullptr); sendToDetectorStop(F_SET_READOUT_MODE, arg, nullptr); // update #nchan, as it depends on #samples, adcmask, - if (shm()->detType == CHIPTESTBOARD) { + if (shm()->detType == CHIPTESTBOARD || + shm()->detType == XILINX_CHIPTESTBOARD) { updateNumberOfChannels(); } if (shm()->useReceiverFlag) { @@ -3407,6 +3409,8 @@ const std::string Module::getDetectorAPI() const { return APIMYTHEN3; case GOTTHARD2: return APIGOTTHARD2; + case XILINX_CHIPTESTBOARD: + return APIXILINXCTB; default: throw NotImplementedError( "Detector type not implemented to get Detector API"); diff --git a/slsDetectorSoftware/src/inferAction.cpp b/slsDetectorSoftware/src/inferAction.cpp new file mode 100644 index 000000000..31ae6919d --- /dev/null +++ b/slsDetectorSoftware/src/inferAction.cpp @@ -0,0 +1,4622 @@ +#include "inferAction.h" + +#include "sls/sls_detector_defs.h" + +namespace sls { + +int InferAction::infer(sls::CmdParser &parser, std::ostream &os) { + + args = parser.arguments(); + + cmd = parser.command(); + + auto it = functions.find(parser.command()); + + if (it != functions.end()) { + + return ((*this).*(it->second))(); + + } else { + + throw RuntimeError( + + "sls_detector not implemented for command: " + parser.command() + + + ". Use sls_detector_get or sls_detector_put."); + } +} + +int InferAction::acquire() { + + if (args.size() == 0) { + throw RuntimeError( + "sls_detector is disabled for command: acquire with number of " + "arguments 0. Use sls_detector_get or sls_detector_put"); + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::activate() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcclk() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcenable() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcenable10g() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcindex() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcinvert() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adclist() { + + throw RuntimeError("sls_detector is disabled for command: adclist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::adcname() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcphase() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: adcphase with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcpipeline() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcreg() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::adcvpp() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: adcvpp with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::apulse() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::asamples() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::autocompdisable() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::badchannels() { + + throw RuntimeError("sls_detector is disabled for command: badchannels. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::blockingtrigger() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::burstmode() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::burstperiod() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: burstperiod with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::bursts() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::burstsl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::bustest() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::cdsgain() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::chipversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clearbit() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clearbusy() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clearroi() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clientversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clkdiv() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clkfreq() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::clkphase() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + throw RuntimeError( + "sls_detector is disabled for command: clkphase with number of " + "arguments 2. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::column() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::compdisabletime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: compdisabletime with number " + "of arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::confadc() { + + if (args.size() == 2) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::config() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::counters() { + + throw RuntimeError("sls_detector is disabled for command: counters. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::currentsource() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 4) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dac() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + throw RuntimeError( + "sls_detector is disabled for command: dac with number of " + "arguments 2. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dacindex() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::daclist() { + + throw RuntimeError("sls_detector is disabled for command: daclist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::dacname() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dacvalues() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::datastream() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dbitclk() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dbitphase() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: dbitphase with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dbitpipeline() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::defaultdac() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + throw RuntimeError( + "sls_detector is disabled for command: defaultdac with number of " + "arguments 2. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::defaultpattern() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::delay() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: delay with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::delayl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::detectorserverversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::detsize() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::diodelay() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dpulse() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dr() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::drlist() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::dsamples() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::execcommand() { + + throw RuntimeError("sls_detector is disabled for command: execcommand. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::exptime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: exptime with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::exptime1() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: exptime1 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::exptime2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: exptime2 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::exptime3() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: exptime3 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::exptimel() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::extrastoragecells() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::extsampling() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::extsamplingsrc() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::extsig() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fformat() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::filtercells() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::filterresistor() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::findex() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::firmwaretest() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::firmwareversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fliprows() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::flowcontrol10g() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fmaster() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fname() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::foverwrite() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fpath() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::framecounter() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::frames() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::framesl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::frametime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::free() { + + if (args.size() == 0) { + throw RuntimeError( + "sls_detector is disabled for command: free with number of " + "arguments 0. Use sls_detector_get or sls_detector_put"); + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::fwrite() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gaincaps() { + + throw RuntimeError("sls_detector is disabled for command: gaincaps. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::gainmode() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gappixels() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gatedelay() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: gatedelay with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gatedelay1() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: gatedelay1 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gatedelay2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: gatedelay2 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gatedelay3() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: gatedelay3 with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::gates() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::getbit() { + + if (args.size() == 2) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::hardwareversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::highvoltage() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::hostname() { + + throw RuntimeError("sls_detector is disabled for command: hostname. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::im_a() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::im_b() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::im_c() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::im_d() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::im_io() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::imagetest() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::initialchecks() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::inj_ch() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::interpolation() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::interruptsubframe() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::kernelversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::lastclient() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::led() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::lock() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::master() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::maxadcphaseshift() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::maxclkphaseshift() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::maxdbitphaseshift() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::measuredperiod() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::measuredsubperiod() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::moduleid() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::nextframenumber() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::nmod() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::numinterfaces() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::overflow() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::packageversion() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::parallel() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::parameters() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::partialreset() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patfname() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patioctrl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patlimits() { + + throw RuntimeError("sls_detector is disabled for command: patlimits. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patloop() { + + throw RuntimeError("sls_detector is disabled for command: patloop. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patloop0() { + + throw RuntimeError("sls_detector is disabled for command: patloop0. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patloop1() { + + throw RuntimeError("sls_detector is disabled for command: patloop1. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patloop2() { + + throw RuntimeError("sls_detector is disabled for command: patloop2. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patmask() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patnloop() { + + throw RuntimeError("sls_detector is disabled for command: patnloop. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patnloop0() { + + throw RuntimeError("sls_detector is disabled for command: patnloop0. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patnloop1() { + + throw RuntimeError("sls_detector is disabled for command: patnloop1. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patnloop2() { + + throw RuntimeError("sls_detector is disabled for command: patnloop2. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patsetbit() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pattern() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patternstart() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::patwait() { + + throw RuntimeError("sls_detector is disabled for command: patwait. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patwait0() { + + throw RuntimeError("sls_detector is disabled for command: patwait0. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patwait1() { + + throw RuntimeError("sls_detector is disabled for command: patwait1. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patwait2() { + + throw RuntimeError("sls_detector is disabled for command: patwait2. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patwaittime() { + + throw RuntimeError("sls_detector is disabled for command: patwaittime. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::patwaittime0() { + + throw RuntimeError("sls_detector is disabled for command: patwaittime0. " + "Use sls_detector_get or sls_detector_put"); +} + +int InferAction::patwaittime1() { + + throw RuntimeError("sls_detector is disabled for command: patwaittime1. " + "Use sls_detector_get or sls_detector_put"); +} + +int InferAction::patwaittime2() { + + throw RuntimeError("sls_detector is disabled for command: patwaittime2. " + "Use sls_detector_get or sls_detector_put"); +} + +int InferAction::patword() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pedestalmode() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::period() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: period with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::periodl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::polarity() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::port() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::powerchip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::powerindex() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::powerlist() { + + throw RuntimeError("sls_detector is disabled for command: powerlist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::powername() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::powervalues() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::programfpga() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pulse() { + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pulsechip() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pulsenmove() { + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::pumpprobe() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::quad() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::ratecorr() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::readnrows() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::readout() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::readoutspeed() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::readoutspeedlist() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rebootcontroller() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::reg() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::resetdacs() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::resetfpga() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::roi() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::romode() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::row() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::runclk() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::runtime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_arping() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_clearroi() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_dbitlist() { + + throw RuntimeError("sls_detector is disabled for command: rx_dbitlist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::rx_dbitoffset() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_discardpolicy() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_fifodepth() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_frameindex() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_framescaught() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_framesperfile() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_hostname() { + + throw RuntimeError("sls_detector is disabled for command: rx_hostname. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::rx_jsonaddheader() { + + throw RuntimeError( + "sls_detector is disabled for command: rx_jsonaddheader. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::rx_jsonpara() { + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: rx_jsonpara with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_lastclient() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_lock() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_missingpackets() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_padding() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_printconfig() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_realudpsocksize() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_roi() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 4) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_silent() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_start() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_status() { + + throw RuntimeError("sls_detector is disabled for command: rx_status. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::rx_stop() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_tcpport() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_threads() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_udpsocksize() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_version() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqfreq() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqhwm() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqport() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqstartfnum() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::rx_zmqstream() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::samples() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::savepattern() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::scan() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 4) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 5) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::scanerrmsg() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::selinterface() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::serialnumber() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::setbit() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::settings() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::settingslist() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::settingspath() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::signalindex() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::signallist() { + + throw RuntimeError("sls_detector is disabled for command: signallist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::signalname() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::slowadc() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::slowadcindex() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::slowadclist() { + + throw RuntimeError("sls_detector is disabled for command: slowadclist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::slowadcname() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::slowadcvalues() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::start() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::status() { + + throw RuntimeError("sls_detector is disabled for command: status. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::stop() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::stopport() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::storagecell_delay() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: storagecell_delay with " + "number of arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::storagecell_start() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::subdeadtime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: subdeadtime with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::subexptime() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: subexptime with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::sync() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::syncclk() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_10ge() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_adc() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_control() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_dcdc() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_event() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_fpga() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_fpgaext() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_fpgafl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_fpgafr() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_slowadc() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_sodl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_sodr() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::temp_threshold() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::templist() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::tempvalues() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::tengiga() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::threshold() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 3) { + return slsDetectorDefs::PUT_ACTION; + } + + if (args.size() == 4) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::timing() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::timinglist() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::timingsource() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::top() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::transceiverenable() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::trigger() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::triggers() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::triggersl() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::trimbits() { + + if (args.size() == 1) { + throw RuntimeError( + "sls_detector is disabled for command: trimbits with number of " + "arguments 1. Use sls_detector_get or sls_detector_put"); + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::trimen() { + + throw RuntimeError("sls_detector is disabled for command: trimen. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::trimval() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::tsamples() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::txdelay() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::txdelay_frame() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::txdelay_left() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::txdelay_right() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::type() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_cleardst() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstip2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstlist() { + + throw RuntimeError("sls_detector is disabled for command: udp_dstlist. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::udp_dstmac() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstmac2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstport() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_dstport2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_firstdst() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_numdst() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_reconfigure() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_srcip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_srcip2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_srcmac() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_srcmac2() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::udp_validate() { + + if (args.size() == 0) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::update() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::updatedetectorserver() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::updatekernel() { + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::updatemode() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::user() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_a() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_b() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_c() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_chip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_d() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_io() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::v_limit() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_comp_adc() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_comp_fe() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_cs() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_opa_1st() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_opa_fd() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vchip_ref_comp_fe() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::versions() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::veto() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vetoalg() { + + if (args.size() == 1) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vetofile() { + + throw RuntimeError("sls_detector is disabled for command: vetofile. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::vetophoton() { + + if (args.size() == 2) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 4) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vetoref() { + + throw RuntimeError("sls_detector is disabled for command: vetoref. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::vetostream() { + + throw RuntimeError("sls_detector is disabled for command: vetostream. Use " + "sls_detector_get or sls_detector_put"); +} + +int InferAction::virtualFunction() { + + if (args.size() == 2) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vm_a() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vm_b() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vm_c() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vm_d() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::vm_io() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::zmqhwm() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::zmqip() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +int InferAction::zmqport() { + + if (args.size() == 0) { + return slsDetectorDefs::GET_ACTION; + } + + if (args.size() == 1) { + return slsDetectorDefs::PUT_ACTION; + } + + else { + + throw RuntimeError("Could not infer action: Wrong number of arguments"); + } +} + +} // namespace sls diff --git a/slsDetectorSoftware/src/inferAction.h b/slsDetectorSoftware/src/inferAction.h new file mode 100644 index 000000000..84de19490 --- /dev/null +++ b/slsDetectorSoftware/src/inferAction.h @@ -0,0 +1,681 @@ +#include "CmdParser.h" +#include +#include +#include + +namespace sls { +class InferAction { + public: + InferAction() {} + int infer(sls::CmdParser &parser, std::ostream &os = std::cout); + std::vector args; + std::string cmd; + + // generated functions + int acquire(); + int activate(); + int adcclk(); + int adcenable(); + int adcenable10g(); + int adcindex(); + int adcinvert(); + int adclist(); + int adcname(); + int adcphase(); + int adcpipeline(); + int adcreg(); + int adcvpp(); + int apulse(); + int asamples(); + int autocompdisable(); + int badchannels(); + int blockingtrigger(); + int burstmode(); + int burstperiod(); + int bursts(); + int burstsl(); + int bustest(); + int cdsgain(); + int chipversion(); + int clearbit(); + int clearbusy(); + int clearroi(); + int clientversion(); + int clkdiv(); + int clkfreq(); + int clkphase(); + int column(); + int compdisabletime(); + int confadc(); + int config(); + int counters(); + int currentsource(); + int dac(); + int dacindex(); + int daclist(); + int dacname(); + int dacvalues(); + int datastream(); + int dbitclk(); + int dbitphase(); + int dbitpipeline(); + int defaultdac(); + int defaultpattern(); + int delay(); + int delayl(); + int detectorserverversion(); + int detsize(); + int diodelay(); + int dpulse(); + int dr(); + int drlist(); + int dsamples(); + int execcommand(); + int exptime(); + int exptime1(); + int exptime2(); + int exptime3(); + int exptimel(); + int extrastoragecells(); + int extsampling(); + int extsamplingsrc(); + int extsig(); + int fformat(); + int filtercells(); + int filterresistor(); + int findex(); + int firmwaretest(); + int firmwareversion(); + int fliprows(); + int flowcontrol10g(); + int fmaster(); + int fname(); + int foverwrite(); + int fpath(); + int framecounter(); + int frames(); + int framesl(); + int frametime(); + int free(); + int fwrite(); + int gaincaps(); + int gainmode(); + int gappixels(); + int gatedelay(); + int gatedelay1(); + int gatedelay2(); + int gatedelay3(); + int gates(); + int getbit(); + int hardwareversion(); + int highvoltage(); + int hostname(); + int im_a(); + int im_b(); + int im_c(); + int im_d(); + int im_io(); + int imagetest(); + int initialchecks(); + int inj_ch(); + int interpolation(); + int interruptsubframe(); + int kernelversion(); + int lastclient(); + int led(); + int lock(); + int master(); + int maxadcphaseshift(); + int maxclkphaseshift(); + int maxdbitphaseshift(); + int measuredperiod(); + int measuredsubperiod(); + int moduleid(); + int nextframenumber(); + int nmod(); + int numinterfaces(); + int overflow(); + int packageversion(); + int parallel(); + int parameters(); + int partialreset(); + int patfname(); + int patioctrl(); + int patlimits(); + int patloop(); + int patloop0(); + int patloop1(); + int patloop2(); + int patmask(); + int patnloop(); + int patnloop0(); + int patnloop1(); + int patnloop2(); + int patsetbit(); + int pattern(); + int patternstart(); + int patwait(); + int patwait0(); + int patwait1(); + int patwait2(); + int patwaittime(); + int patwaittime0(); + int patwaittime1(); + int patwaittime2(); + int patword(); + int pedestalmode(); + int period(); + int periodl(); + int polarity(); + int port(); + int powerchip(); + int powerindex(); + int powerlist(); + int powername(); + int powervalues(); + int programfpga(); + int pulse(); + int pulsechip(); + int pulsenmove(); + int pumpprobe(); + int quad(); + int ratecorr(); + int readnrows(); + int readout(); + int readoutspeed(); + int readoutspeedlist(); + int rebootcontroller(); + int reg(); + int resetdacs(); + int resetfpga(); + int roi(); + int romode(); + int row(); + int runclk(); + int runtime(); + int rx_arping(); + int rx_clearroi(); + int rx_dbitlist(); + int rx_dbitoffset(); + int rx_discardpolicy(); + int rx_fifodepth(); + int rx_frameindex(); + int rx_framescaught(); + int rx_framesperfile(); + int rx_hostname(); + int rx_jsonaddheader(); + int rx_jsonpara(); + int rx_lastclient(); + int rx_lock(); + int rx_missingpackets(); + int rx_padding(); + int rx_printconfig(); + int rx_realudpsocksize(); + int rx_roi(); + int rx_silent(); + int rx_start(); + int rx_status(); + int rx_stop(); + int rx_tcpport(); + int rx_threads(); + int rx_udpsocksize(); + int rx_version(); + int rx_zmqfreq(); + int rx_zmqhwm(); + int rx_zmqip(); + int rx_zmqport(); + int rx_zmqstartfnum(); + int rx_zmqstream(); + int samples(); + int savepattern(); + int scan(); + int scanerrmsg(); + int selinterface(); + int serialnumber(); + int setbit(); + int settings(); + int settingslist(); + int settingspath(); + int signalindex(); + int signallist(); + int signalname(); + int slowadc(); + int slowadcindex(); + int slowadclist(); + int slowadcname(); + int slowadcvalues(); + int start(); + int status(); + int stop(); + int stopport(); + int storagecell_delay(); + int storagecell_start(); + int subdeadtime(); + int subexptime(); + int sync(); + int syncclk(); + int temp_10ge(); + int temp_adc(); + int temp_control(); + int temp_dcdc(); + int temp_event(); + int temp_fpga(); + int temp_fpgaext(); + int temp_fpgafl(); + int temp_fpgafr(); + int temp_slowadc(); + int temp_sodl(); + int temp_sodr(); + int temp_threshold(); + int templist(); + int tempvalues(); + int tengiga(); + int threshold(); + int timing(); + int timinglist(); + int timingsource(); + int top(); + int transceiverenable(); + int trigger(); + int triggers(); + int triggersl(); + int trimbits(); + int trimen(); + int trimval(); + int tsamples(); + int txdelay(); + int txdelay_frame(); + int txdelay_left(); + int txdelay_right(); + int type(); + int udp_cleardst(); + int udp_dstip(); + int udp_dstip2(); + int udp_dstlist(); + int udp_dstmac(); + int udp_dstmac2(); + int udp_dstport(); + int udp_dstport2(); + int udp_firstdst(); + int udp_numdst(); + int udp_reconfigure(); + int udp_srcip(); + int udp_srcip2(); + int udp_srcmac(); + int udp_srcmac2(); + int udp_validate(); + int update(); + int updatedetectorserver(); + int updatekernel(); + int updatemode(); + int user(); + int v_a(); + int v_b(); + int v_c(); + int v_chip(); + int v_d(); + int v_io(); + int v_limit(); + int vchip_comp_adc(); + int vchip_comp_fe(); + int vchip_cs(); + int vchip_opa_1st(); + int vchip_opa_fd(); + int vchip_ref_comp_fe(); + int versions(); + int veto(); + int vetoalg(); + int vetofile(); + int vetophoton(); + int vetoref(); + int vetostream(); + int virtualFunction(); + int vm_a(); + int vm_b(); + int vm_c(); + int vm_d(); + int vm_io(); + int zmqhwm(); + int zmqip(); + int zmqport(); + // int frames(); + + private: + using FunctionMap = std::map; + FunctionMap functions{ + // generated functions + + {"acquire", &InferAction::acquire}, + {"activate", &InferAction::activate}, + {"adcclk", &InferAction::adcclk}, + {"adcenable", &InferAction::adcenable}, + {"adcenable10g", &InferAction::adcenable10g}, + {"adcindex", &InferAction::adcindex}, + {"adcinvert", &InferAction::adcinvert}, + {"adclist", &InferAction::adclist}, + {"adcname", &InferAction::adcname}, + {"adcphase", &InferAction::adcphase}, + {"adcpipeline", &InferAction::adcpipeline}, + {"adcreg", &InferAction::adcreg}, + {"adcvpp", &InferAction::adcvpp}, + {"apulse", &InferAction::apulse}, + {"asamples", &InferAction::asamples}, + {"autocompdisable", &InferAction::autocompdisable}, + {"badchannels", &InferAction::badchannels}, + {"blockingtrigger", &InferAction::blockingtrigger}, + {"burstmode", &InferAction::burstmode}, + {"burstperiod", &InferAction::burstperiod}, + {"bursts", &InferAction::bursts}, + {"burstsl", &InferAction::burstsl}, + {"bustest", &InferAction::bustest}, + {"cdsgain", &InferAction::cdsgain}, + {"chipversion", &InferAction::chipversion}, + {"clearbit", &InferAction::clearbit}, + {"clearbusy", &InferAction::clearbusy}, + {"clearroi", &InferAction::clearroi}, + {"clientversion", &InferAction::clientversion}, + {"clkdiv", &InferAction::clkdiv}, + {"clkfreq", &InferAction::clkfreq}, + {"clkphase", &InferAction::clkphase}, + {"column", &InferAction::column}, + {"compdisabletime", &InferAction::compdisabletime}, + {"confadc", &InferAction::confadc}, + {"config", &InferAction::config}, + {"counters", &InferAction::counters}, + {"currentsource", &InferAction::currentsource}, + {"dac", &InferAction::dac}, + {"dacindex", &InferAction::dacindex}, + {"daclist", &InferAction::daclist}, + {"dacname", &InferAction::dacname}, + {"dacvalues", &InferAction::dacvalues}, + {"datastream", &InferAction::datastream}, + {"dbitclk", &InferAction::dbitclk}, + {"dbitphase", &InferAction::dbitphase}, + {"dbitpipeline", &InferAction::dbitpipeline}, + {"defaultdac", &InferAction::defaultdac}, + {"defaultpattern", &InferAction::defaultpattern}, + {"delay", &InferAction::delay}, + {"delayl", &InferAction::delayl}, + {"detectorserverversion", &InferAction::detectorserverversion}, + {"detsize", &InferAction::detsize}, + {"diodelay", &InferAction::diodelay}, + {"dpulse", &InferAction::dpulse}, + {"dr", &InferAction::dr}, + {"drlist", &InferAction::drlist}, + {"dsamples", &InferAction::dsamples}, + {"execcommand", &InferAction::execcommand}, + {"exptime", &InferAction::exptime}, + {"exptime1", &InferAction::exptime1}, + {"exptime2", &InferAction::exptime2}, + {"exptime3", &InferAction::exptime3}, + {"exptimel", &InferAction::exptimel}, + {"extrastoragecells", &InferAction::extrastoragecells}, + {"extsampling", &InferAction::extsampling}, + {"extsamplingsrc", &InferAction::extsamplingsrc}, + {"extsig", &InferAction::extsig}, + {"fformat", &InferAction::fformat}, + {"filtercells", &InferAction::filtercells}, + {"filterresistor", &InferAction::filterresistor}, + {"findex", &InferAction::findex}, + {"firmwaretest", &InferAction::firmwaretest}, + {"firmwareversion", &InferAction::firmwareversion}, + {"fliprows", &InferAction::fliprows}, + {"flowcontrol10g", &InferAction::flowcontrol10g}, + {"fmaster", &InferAction::fmaster}, + {"fname", &InferAction::fname}, + {"foverwrite", &InferAction::foverwrite}, + {"fpath", &InferAction::fpath}, + {"framecounter", &InferAction::framecounter}, + {"frames", &InferAction::frames}, + {"framesl", &InferAction::framesl}, + {"frametime", &InferAction::frametime}, + {"free", &InferAction::free}, + {"fwrite", &InferAction::fwrite}, + {"gaincaps", &InferAction::gaincaps}, + {"gainmode", &InferAction::gainmode}, + {"gappixels", &InferAction::gappixels}, + {"gatedelay", &InferAction::gatedelay}, + {"gatedelay1", &InferAction::gatedelay1}, + {"gatedelay2", &InferAction::gatedelay2}, + {"gatedelay3", &InferAction::gatedelay3}, + {"gates", &InferAction::gates}, + {"getbit", &InferAction::getbit}, + {"hardwareversion", &InferAction::hardwareversion}, + {"highvoltage", &InferAction::highvoltage}, + {"hostname", &InferAction::hostname}, + {"im_a", &InferAction::im_a}, + {"im_b", &InferAction::im_b}, + {"im_c", &InferAction::im_c}, + {"im_d", &InferAction::im_d}, + {"im_io", &InferAction::im_io}, + {"imagetest", &InferAction::imagetest}, + {"initialchecks", &InferAction::initialchecks}, + {"inj_ch", &InferAction::inj_ch}, + {"interpolation", &InferAction::interpolation}, + {"interruptsubframe", &InferAction::interruptsubframe}, + {"kernelversion", &InferAction::kernelversion}, + {"lastclient", &InferAction::lastclient}, + {"led", &InferAction::led}, + {"lock", &InferAction::lock}, + {"master", &InferAction::master}, + {"maxadcphaseshift", &InferAction::maxadcphaseshift}, + {"maxclkphaseshift", &InferAction::maxclkphaseshift}, + {"maxdbitphaseshift", &InferAction::maxdbitphaseshift}, + {"measuredperiod", &InferAction::measuredperiod}, + {"measuredsubperiod", &InferAction::measuredsubperiod}, + {"moduleid", &InferAction::moduleid}, + {"nextframenumber", &InferAction::nextframenumber}, + {"nmod", &InferAction::nmod}, + {"numinterfaces", &InferAction::numinterfaces}, + {"overflow", &InferAction::overflow}, + {"packageversion", &InferAction::packageversion}, + {"parallel", &InferAction::parallel}, + {"parameters", &InferAction::parameters}, + {"partialreset", &InferAction::partialreset}, + {"patfname", &InferAction::patfname}, + {"patioctrl", &InferAction::patioctrl}, + {"patlimits", &InferAction::patlimits}, + {"patloop", &InferAction::patloop}, + {"patloop0", &InferAction::patloop0}, + {"patloop1", &InferAction::patloop1}, + {"patloop2", &InferAction::patloop2}, + {"patmask", &InferAction::patmask}, + {"patnloop", &InferAction::patnloop}, + {"patnloop0", &InferAction::patnloop0}, + {"patnloop1", &InferAction::patnloop1}, + {"patnloop2", &InferAction::patnloop2}, + {"patsetbit", &InferAction::patsetbit}, + {"patternX", &InferAction::pattern}, + {"patternstart", &InferAction::patternstart}, + {"patwait", &InferAction::patwait}, + {"patwait0", &InferAction::patwait0}, + {"patwait1", &InferAction::patwait1}, + {"patwait2", &InferAction::patwait2}, + {"patwaittime", &InferAction::patwaittime}, + {"patwaittime0", &InferAction::patwaittime0}, + {"patwaittime1", &InferAction::patwaittime1}, + {"patwaittime2", &InferAction::patwaittime2}, + {"patword", &InferAction::patword}, + {"pedestalmode", &InferAction::pedestalmode}, + {"period", &InferAction::period}, + {"periodl", &InferAction::periodl}, + {"polarity", &InferAction::polarity}, + {"port", &InferAction::port}, + {"powerchip", &InferAction::powerchip}, + {"powerindex", &InferAction::powerindex}, + {"powerlist", &InferAction::powerlist}, + {"powername", &InferAction::powername}, + {"powervalues", &InferAction::powervalues}, + {"programfpga", &InferAction::programfpga}, + {"pulse", &InferAction::pulse}, + {"pulsechip", &InferAction::pulsechip}, + {"pulsenmove", &InferAction::pulsenmove}, + {"pumpprobe", &InferAction::pumpprobe}, + {"quad", &InferAction::quad}, + {"ratecorr", &InferAction::ratecorr}, + {"readnrows", &InferAction::readnrows}, + {"readout", &InferAction::readout}, + {"readoutspeed", &InferAction::readoutspeed}, + {"readoutspeedlist", &InferAction::readoutspeedlist}, + {"rebootcontroller", &InferAction::rebootcontroller}, + {"reg", &InferAction::reg}, + {"resetdacs", &InferAction::resetdacs}, + {"resetfpga", &InferAction::resetfpga}, + {"roi", &InferAction::roi}, + {"romode", &InferAction::romode}, + {"row", &InferAction::row}, + {"runclk", &InferAction::runclk}, + {"runtime", &InferAction::runtime}, + {"rx_arping", &InferAction::rx_arping}, + {"rx_clearroi", &InferAction::rx_clearroi}, + {"rx_dbitlist", &InferAction::rx_dbitlist}, + {"rx_dbitoffset", &InferAction::rx_dbitoffset}, + {"rx_discardpolicy", &InferAction::rx_discardpolicy}, + {"rx_fifodepth", &InferAction::rx_fifodepth}, + {"rx_frameindex", &InferAction::rx_frameindex}, + {"rx_framescaught", &InferAction::rx_framescaught}, + {"rx_framesperfile", &InferAction::rx_framesperfile}, + {"rx_hostname", &InferAction::rx_hostname}, + {"rx_jsonaddheader", &InferAction::rx_jsonaddheader}, + {"rx_jsonpara", &InferAction::rx_jsonpara}, + {"rx_lastclient", &InferAction::rx_lastclient}, + {"rx_lock", &InferAction::rx_lock}, + {"rx_missingpackets", &InferAction::rx_missingpackets}, + {"rx_padding", &InferAction::rx_padding}, + {"rx_printconfig", &InferAction::rx_printconfig}, + {"rx_realudpsocksize", &InferAction::rx_realudpsocksize}, + {"rx_roi", &InferAction::rx_roi}, + {"rx_silent", &InferAction::rx_silent}, + {"rx_start", &InferAction::rx_start}, + {"rx_status", &InferAction::rx_status}, + {"rx_stop", &InferAction::rx_stop}, + {"rx_tcpport", &InferAction::rx_tcpport}, + {"rx_threads", &InferAction::rx_threads}, + {"rx_udpsocksize", &InferAction::rx_udpsocksize}, + {"rx_version", &InferAction::rx_version}, + {"rx_zmqfreq", &InferAction::rx_zmqfreq}, + {"rx_zmqhwm", &InferAction::rx_zmqhwm}, + {"rx_zmqip", &InferAction::rx_zmqip}, + {"rx_zmqport", &InferAction::rx_zmqport}, + {"rx_zmqstartfnum", &InferAction::rx_zmqstartfnum}, + {"rx_zmqstream", &InferAction::rx_zmqstream}, + {"samples", &InferAction::samples}, + {"savepattern", &InferAction::savepattern}, + {"scan", &InferAction::scan}, + {"scanerrmsg", &InferAction::scanerrmsg}, + {"selinterface", &InferAction::selinterface}, + {"serialnumber", &InferAction::serialnumber}, + {"setbit", &InferAction::setbit}, + {"settings", &InferAction::settings}, + {"settingslist", &InferAction::settingslist}, + {"settingspath", &InferAction::settingspath}, + {"signalindex", &InferAction::signalindex}, + {"signallist", &InferAction::signallist}, + {"signalname", &InferAction::signalname}, + {"slowadc", &InferAction::slowadc}, + {"slowadcindex", &InferAction::slowadcindex}, + {"slowadclist", &InferAction::slowadclist}, + {"slowadcname", &InferAction::slowadcname}, + {"slowadcvalues", &InferAction::slowadcvalues}, + {"start", &InferAction::start}, + {"status", &InferAction::status}, + {"stop", &InferAction::stop}, + {"stopport", &InferAction::stopport}, + {"storagecell_delay", &InferAction::storagecell_delay}, + {"storagecell_start", &InferAction::storagecell_start}, + {"subdeadtime", &InferAction::subdeadtime}, + {"subexptime", &InferAction::subexptime}, + {"sync", &InferAction::sync}, + {"syncclk", &InferAction::syncclk}, + {"temp_10ge", &InferAction::temp_10ge}, + {"temp_adc", &InferAction::temp_adc}, + {"temp_control", &InferAction::temp_control}, + {"temp_dcdc", &InferAction::temp_dcdc}, + {"temp_event", &InferAction::temp_event}, + {"temp_fpga", &InferAction::temp_fpga}, + {"temp_fpgaext", &InferAction::temp_fpgaext}, + {"temp_fpgafl", &InferAction::temp_fpgafl}, + {"temp_fpgafr", &InferAction::temp_fpgafr}, + {"temp_slowadc", &InferAction::temp_slowadc}, + {"temp_sodl", &InferAction::temp_sodl}, + {"temp_sodr", &InferAction::temp_sodr}, + {"temp_threshold", &InferAction::temp_threshold}, + {"templist", &InferAction::templist}, + {"tempvalues", &InferAction::tempvalues}, + {"tengiga", &InferAction::tengiga}, + {"threshold", &InferAction::threshold}, + {"thresholdnotb", &InferAction::threshold}, + {"timing", &InferAction::timing}, + {"timinglist", &InferAction::timinglist}, + {"timingsource", &InferAction::timingsource}, + {"top", &InferAction::top}, + {"transceiverenable", &InferAction::transceiverenable}, + {"trigger", &InferAction::trigger}, + {"triggers", &InferAction::triggers}, + {"triggersl", &InferAction::triggersl}, + {"trimbits", &InferAction::trimbits}, + {"trimen", &InferAction::trimen}, + {"trimval", &InferAction::trimval}, + {"tsamples", &InferAction::tsamples}, + {"txdelay", &InferAction::txdelay}, + {"txdelay_frame", &InferAction::txdelay_frame}, + {"txdelay_left", &InferAction::txdelay_left}, + {"txdelay_right", &InferAction::txdelay_right}, + {"type", &InferAction::type}, + {"udp_cleardst", &InferAction::udp_cleardst}, + {"udp_dstip", &InferAction::udp_dstip}, + {"udp_dstip2", &InferAction::udp_dstip2}, + {"udp_dstlist", &InferAction::udp_dstlist}, + {"udp_dstmac", &InferAction::udp_dstmac}, + {"udp_dstmac2", &InferAction::udp_dstmac2}, + {"udp_dstport", &InferAction::udp_dstport}, + {"udp_dstport2", &InferAction::udp_dstport2}, + {"udp_firstdst", &InferAction::udp_firstdst}, + {"udp_numdst", &InferAction::udp_numdst}, + {"udp_reconfigure", &InferAction::udp_reconfigure}, + {"udp_srcip", &InferAction::udp_srcip}, + {"udp_srcip2", &InferAction::udp_srcip2}, + {"udp_srcmac", &InferAction::udp_srcmac}, + {"udp_srcmac2", &InferAction::udp_srcmac2}, + {"udp_validate", &InferAction::udp_validate}, + {"update", &InferAction::update}, + {"updatedetectorserver", &InferAction::updatedetectorserver}, + {"updatekernel", &InferAction::updatekernel}, + {"updatemode", &InferAction::updatemode}, + {"user", &InferAction::user}, + {"v_a", &InferAction::v_a}, + {"v_b", &InferAction::v_b}, + {"v_c", &InferAction::v_c}, + {"v_chip", &InferAction::v_chip}, + {"v_d", &InferAction::v_d}, + {"v_io", &InferAction::v_io}, + {"v_limit", &InferAction::v_limit}, + {"vchip_comp_adc", &InferAction::vchip_comp_adc}, + {"vchip_comp_fe", &InferAction::vchip_comp_fe}, + {"vchip_cs", &InferAction::vchip_cs}, + {"vchip_opa_1st", &InferAction::vchip_opa_1st}, + {"vchip_opa_fd", &InferAction::vchip_opa_fd}, + {"vchip_ref_comp_fe", &InferAction::vchip_ref_comp_fe}, + {"versions", &InferAction::versions}, + {"veto", &InferAction::veto}, + {"vetoalg", &InferAction::vetoalg}, + {"vetofile", &InferAction::vetofile}, + {"vetophoton", &InferAction::vetophoton}, + {"vetoref", &InferAction::vetoref}, + {"vetostream", &InferAction::vetostream}, + {"virtual", &InferAction::virtualFunction}, + {"vm_a", &InferAction::vm_a}, + {"vm_b", &InferAction::vm_b}, + {"vm_c", &InferAction::vm_c}, + {"vm_d", &InferAction::vm_d}, + {"vm_io", &InferAction::vm_io}, + {"zmqhwm", &InferAction::zmqhwm}, + {"zmqip", &InferAction::zmqip}, + {"zmqport", &InferAction::zmqport} + + // {"frames",&InferAction::frames} + + }; +}; + +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/tests/CMakeLists.txt b/slsDetectorSoftware/tests/CMakeLists.txt index 14a522639..ddd9abbb3 100755 --- a/slsDetectorSoftware/tests/CMakeLists.txt +++ b/slsDetectorSoftware/tests/CMakeLists.txt @@ -1,24 +1,32 @@ # SPDX-License-Identifier: LGPL-3.0-or-other # Copyright (C) 2021 Contributors to the SLS Detector Package + + target_sources(tests PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/test-SharedMemory.cpp ${CMAKE_CURRENT_SOURCE_DIR}/test-slsDetector.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-rx.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-pattern.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-eiger.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-jungfrau.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-mythen3.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-gotthard2.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-gotthard.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-chiptestboard.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-moench.cpp - ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdProxy-global.cpp + + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-rx.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-pattern.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-eiger.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-jungfrau.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-mythen3.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-gotthard2.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-gotthard.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-chiptestboard.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-moench.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/Caller/test-Caller-global.cpp + + ${CMAKE_CURRENT_SOURCE_DIR}/test-Result.cpp ${CMAKE_CURRENT_SOURCE_DIR}/test-CmdParser.cpp ${CMAKE_CURRENT_SOURCE_DIR}/test-Module.cpp ${CMAKE_CURRENT_SOURCE_DIR}/test-Pattern.cpp ${CMAKE_CURRENT_SOURCE_DIR}/test-CtbConfig.cpp + + + ) target_include_directories(tests diff --git a/slsDetectorSoftware/tests/test-CmdProxy-chiptestboard.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-chiptestboard.cpp similarity index 53% rename from slsDetectorSoftware/tests/test-CmdProxy-chiptestboard.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-chiptestboard.cpp index ad3211888..510f0ea8b 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-chiptestboard.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-chiptestboard.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" @@ -9,7 +9,7 @@ #include "sls/Result.h" #include "sls/ToString.h" #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -19,74 +19,77 @@ using test::PUT; /* dacs */ -TEST_CASE("dacname", "[.cmd]") { +TEST_CASE("CALLER::dacname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2); std::string str_dac_index = "2"; auto prev = det.getDacName(ind); // 1 arg throw - REQUIRE_THROWS(proxy.Call("dacname", {"2", "3", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dacname", {"2", "3", "bname"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("dacname", {"18", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dacname", {"18", "bname"}, -1, PUT)); { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("dacname", {str_dac_index, "bname"}, -1, PUT, oss)); + caller.call("dacname", {str_dac_index, "bname"}, -1, PUT, oss)); } { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("dacname", {str_dac_index}, -1, GET, oss)); + caller.call("dacname", {str_dac_index}, -1, GET, oss)); REQUIRE(oss.str() == std::string("dacname ") + str_dac_index + " bname\n"); } det.setDacName(ind, prev); } else { - REQUIRE_THROWS(proxy.Call("dacname", {"2", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("dacname", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dacname", {"2", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dacname", {"2"}, -1, GET)); } } -TEST_CASE("dacindex", "[.cmd]") { +TEST_CASE("CALLER::dacindex", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2); std::string str_dac_index = "2"; // 1 arg throw - REQUIRE_THROWS(proxy.Call("dacindex", {"2", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dacindex", {"2", "2"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("dacindex", {"18"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dacindex", {"18"}, -1, PUT)); auto dacname = det.getDacName(ind); { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("dacindex", {dacname}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("dacindex", {dacname}, -1, GET, oss)); REQUIRE(oss.str() == std::string("dacindex ") + str_dac_index + '\n'); } } else { - REQUIRE_THROWS(proxy.Call("dacindex", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dacindex", {"2"}, -1, GET)); } } -TEST_CASE("adclist", "[.cmd]") { +TEST_CASE("CALLER::adclist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { auto prev = det.getAdcNames(); - REQUIRE_THROWS(proxy.Call("adclist", {"a", "s", "d"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adclist", {"a", "s", "d"}, -1, PUT)); std::vector names; for (int iarg = 0; iarg != 32; ++iarg) { @@ -94,90 +97,93 @@ TEST_CASE("adclist", "[.cmd]") { } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("adclist", names, -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("adclist", names, -1, PUT, oss)); } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("adclist", {}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("adclist", {}, -1, GET, oss)); REQUIRE(oss.str() == std::string("adclist ") + ToString(names) + '\n'); } det.setAdcNames(prev); } else { - REQUIRE_THROWS(proxy.Call("adclist", {"a", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("adclist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adclist", {"a", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adclist", {}, -1, GET)); } } -TEST_CASE("adcname", "[.cmd]") { +TEST_CASE("CALLER::adcname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { int ind = 2; std::string str_adc_index = "2"; auto prev = det.getAdcName(ind); // 1 arg throw - REQUIRE_THROWS(proxy.Call("adcname", {"2", "3", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcname", {"2", "3", "bname"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("adcname", {"32", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcname", {"32", "bname"}, -1, PUT)); { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("adcname", {str_adc_index, "bname"}, -1, PUT, oss)); + caller.call("adcname", {str_adc_index, "bname"}, -1, PUT, oss)); } { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("adcname", {str_adc_index}, -1, GET, oss)); + caller.call("adcname", {str_adc_index}, -1, GET, oss)); REQUIRE(oss.str() == std::string("adcname ") + str_adc_index + " bname\n"); } det.setAdcName(ind, prev); } else { - REQUIRE_THROWS(proxy.Call("adcname", {"2", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("adcname", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("adcname", {"2", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcname", {"2"}, -1, GET)); } } -TEST_CASE("adcindex", "[.cmd]") { +TEST_CASE("CALLER::adcindex", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { int ind = 2; std::string str_adc_index = "2"; // 1 arg throw - REQUIRE_THROWS(proxy.Call("adcindex", {"2", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcindex", {"2", "2"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("adcindex", {"32"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcindex", {"32"}, -1, PUT)); auto adcname = det.getAdcName(ind); { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("adcindex", {adcname}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("adcindex", {adcname}, -1, GET, oss)); REQUIRE(oss.str() == std::string("adcindex ") + str_adc_index + '\n'); } } else { - REQUIRE_THROWS(proxy.Call("adcindex", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("adcindex", {"2"}, -1, GET)); } } -TEST_CASE("signallist", "[.cmd]") { +TEST_CASE("CALLER::signallist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { auto prev = det.getSignalNames(); - REQUIRE_THROWS(proxy.Call("signallist", {"a", "s", "d"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signallist", {"a", "s", "d"}, -1, PUT)); std::vector names; for (int iarg = 0; iarg != 64; ++iarg) { @@ -185,91 +191,94 @@ TEST_CASE("signallist", "[.cmd]") { } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("signallist", names, -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("signallist", names, -1, PUT, oss)); } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("signallist", {}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("signallist", {}, -1, GET, oss)); REQUIRE(oss.str() == std::string("signallist ") + ToString(names) + '\n'); } det.setSignalNames(prev); } else { - REQUIRE_THROWS(proxy.Call("signallist", {"a", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("signallist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("signallist", {"a", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signallist", {}, -1, GET)); } } -TEST_CASE("signalname", "[.cmd]") { +TEST_CASE("CALLER::signalname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { int ind = 2; std::string str_signal_index = "2"; auto prev = det.getSignalName(ind); // 1 arg throw - REQUIRE_THROWS(proxy.Call("signalname", {"2", "3", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signalname", {"2", "3", "bname"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("signalname", {"64", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signalname", {"64", "bname"}, -1, PUT)); { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "signalname", {str_signal_index, "bname"}, -1, PUT, oss)); } { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("signalname", {str_signal_index}, -1, GET, oss)); + caller.call("signalname", {str_signal_index}, -1, GET, oss)); REQUIRE(oss.str() == std::string("signalname ") + str_signal_index + " bname\n"); } det.setSignalName(ind, prev); } else { - REQUIRE_THROWS(proxy.Call("signalname", {"2", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("signalname", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("signalname", {"2", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signalname", {"2"}, -1, GET)); } } -TEST_CASE("signalindex", "[.cmd]") { +TEST_CASE("CALLER::signalindex", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { int ind = 2; std::string str_signal_index = "2"; // 1 arg throw - REQUIRE_THROWS(proxy.Call("signalindex", {"2", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signalindex", {"2", "2"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("signalindex", {"64"}, -1, PUT)); + REQUIRE_THROWS(caller.call("signalindex", {"64"}, -1, PUT)); auto signalname = det.getSignalName(ind); { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("signalindex", {signalname}, -1, GET, oss)); + caller.call("signalindex", {signalname}, -1, GET, oss)); REQUIRE(oss.str() == std::string("signalindex ") + str_signal_index + '\n'); } } else { - REQUIRE_THROWS(proxy.Call("signalindex", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("signalindex", {"2"}, -1, GET)); } } -TEST_CASE("powerlist", "[.cmd]") { +TEST_CASE("CALLER::powerlist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { auto prev = det.getPowerNames(); - REQUIRE_THROWS(proxy.Call("powerlist", {"a", "s", "d"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powerlist", {"a", "s", "d"}, -1, PUT)); std::vector names; for (int iarg = 0; iarg != 5; ++iarg) { @@ -277,105 +286,118 @@ TEST_CASE("powerlist", "[.cmd]") { } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("powerlist", names, -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("powerlist", names, -1, PUT, oss)); } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("powerlist", {}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("powerlist", {}, -1, GET, oss)); REQUIRE(oss.str() == std::string("powerlist ") + ToString(names) + '\n'); } det.setPowerNames(prev); } else { - REQUIRE_THROWS(proxy.Call("powerlist", {"a", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("powerlist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("powerlist", {"a", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powerlist", {}, -1, GET)); } } -TEST_CASE("powername", "[.cmd]") { +TEST_CASE("CALLER::powername", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2 + defs::V_POWER_A); std::string str_power_index = "2"; auto prev = det.getPowerName(ind); // 1 arg throw - REQUIRE_THROWS(proxy.Call("powername", {"2", "3", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powername", {"2", "3", "bname"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("powername", {"5", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powername", {"5", "bname"}, -1, PUT)); { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("powername", {str_power_index, "bname"}, - -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("powername", {str_power_index, "bname"}, + -1, PUT, oss)); } { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("powername", {str_power_index}, -1, GET, oss)); + caller.call("powername", {str_power_index}, -1, GET, oss)); REQUIRE(oss.str() == std::string("powername ") + str_power_index + " bname\n"); } det.setPowerName(ind, prev); } else { - REQUIRE_THROWS(proxy.Call("powername", {"2", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("powername", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("powername", {"2", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powername", {"2"}, -1, GET)); } } -TEST_CASE("powerindex", "[.cmd]") { +TEST_CASE("CALLER::powerindex", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2 + defs::V_POWER_A); std::string str_power_index = "2"; // 1 arg throw - REQUIRE_THROWS(proxy.Call("powerindex", {"2", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powerindex", {"2", "2"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("powerindex", {"5"}, -1, PUT)); + REQUIRE_THROWS(caller.call("powerindex", {"5"}, -1, PUT)); auto powername = det.getPowerName(ind); { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("powerindex", {powername}, -1, GET, oss)); + caller.call("powerindex", {powername}, -1, GET, oss)); REQUIRE(oss.str() == std::string("powerindex ") + str_power_index + '\n'); } } else { - REQUIRE_THROWS(proxy.Call("powerindex", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("powerindex", {"2"}, -1, GET)); } } -TEST_CASE("powervalues", "[.cmd]") { +TEST_CASE("CALLER::powervalues", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("powervalues", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("powervalues", {}, -1, PUT)); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::CHIPTESTBOARD) { + REQUIRE_NOTHROW(caller.call("powervalues", {}, -1, GET)); + REQUIRE_THROWS(caller.call("powervalues", {}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("powervalues", {}, -1, GET)); + } } -TEST_CASE("slowadcvalues", "[.cmd]") { +TEST_CASE("CALLER::slowadcvalues", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("slowadcvalues", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("slowadcvalues", {}, -1, PUT)); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::CHIPTESTBOARD) { + REQUIRE_NOTHROW(caller.call("slowadcvalues", {}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadcvalues", {}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("slowadcvalues", {}, -1, GET)); + } } -TEST_CASE("slowadclist", "[.cmd]") { +TEST_CASE("CALLER::slowadclist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { auto prev = det.getSlowADCNames(); - REQUIRE_THROWS(proxy.Call("slowadclist", {"a", "s", "d"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadclist", {"a", "s", "d"}, -1, PUT)); std::vector names; for (int iarg = 0; iarg != 8; ++iarg) { @@ -383,202 +405,212 @@ TEST_CASE("slowadclist", "[.cmd]") { } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("slowadclist", names, -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("slowadclist", names, -1, PUT, oss)); } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("slowadclist", {}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("slowadclist", {}, -1, GET, oss)); REQUIRE(oss.str() == std::string("slowadclist ") + ToString(names) + '\n'); } det.setSlowADCNames(prev); } else { - REQUIRE_THROWS(proxy.Call("slowadclist", {"a", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("slowadclist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadclist", {"a", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadclist", {}, -1, GET)); } } -TEST_CASE("slowadcname", "[.cmd]") { +TEST_CASE("CALLER::slowadcname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2 + defs::SLOW_ADC0); std::string str_slowadc_index = "2"; auto prev = det.getSlowADCName(ind); // 1 arg throw - REQUIRE_THROWS(proxy.Call("slowadcname", {"2", "3", "bname"}, -1, PUT)); + REQUIRE_THROWS( + caller.call("slowadcname", {"2", "3", "bname"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("slowadcname", {"8", "bname"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadcname", {"8", "bname"}, -1, PUT)); { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "slowadcname", {str_slowadc_index, "bname"}, -1, PUT, oss)); } { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("slowadcname", {str_slowadc_index}, -1, GET, oss)); + caller.call("slowadcname", {str_slowadc_index}, -1, GET, oss)); REQUIRE(oss.str() == std::string("slowadcname ") + str_slowadc_index + " bname\n"); } det.setSlowADCName(ind, prev); } else { - REQUIRE_THROWS(proxy.Call("slowadcname", {"2", "b"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("slowadcname", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadcname", {"2", "b"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadcname", {"2"}, -1, GET)); } } -TEST_CASE("slowadcindex", "[.cmd]") { +TEST_CASE("CALLER::slowadcindex", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { defs::dacIndex ind = static_cast(2 + defs::SLOW_ADC0); std::string str_slowadc_index = "2"; // 1 arg throw - REQUIRE_THROWS(proxy.Call("slowadcindex", {"2", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadcindex", {"2", "2"}, -1, PUT)); // invalid index - REQUIRE_THROWS(proxy.Call("slowadcindex", {"8"}, -1, PUT)); + REQUIRE_THROWS(caller.call("slowadcindex", {"8"}, -1, PUT)); auto slowadcname = det.getSlowADCName(ind); { std::ostringstream oss; REQUIRE_NOTHROW( - proxy.Call("slowadcindex", {slowadcname}, -1, GET, oss)); + caller.call("slowadcindex", {slowadcname}, -1, GET, oss)); REQUIRE(oss.str() == std::string("slowadcindex ") + str_slowadc_index + '\n'); } } else { - REQUIRE_THROWS(proxy.Call("slowadcindex", {"2"}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadcindex", {"2"}, -1, GET)); } } /* dacs */ -TEST_CASE("dac", "[.cmd][.dacs]") { +TEST_CASE("CALLER::dac", "[.cmdcall][.dacs]") { // dac 0 to dac 17 Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { for (int i = 0; i < 18; ++i) { SECTION("dac " + std::to_string(i)) { - test_dac(static_cast(i), "dac", 0); + if (det_type == defs::CHIPTESTBOARD) { + test_dac_caller(static_cast(i), "dac", 0); + } else { + REQUIRE_THROWS( + caller.call("dac", {std::to_string(i)}, -1, GET)); + } } } + // eiger - // REQUIRE_THROWS(proxy.Call("dac", {"vthreshold"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vsvp"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vsvn"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vtgstv"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcmp_ll"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcmp_lr"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcal"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rl"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rr"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"rxb_rb"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"rxb_lb"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcp"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vcn"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"iodelay"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vthreshold"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vsvp"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vsvn"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vtgstv"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcmp_ll"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcmp_lr"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcal"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcmp_rl"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcmp_rr"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"rxb_rb"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"rxb_lb"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcp"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vcn"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"iodelay"}, -1, GET)); // jungfrau - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdd_prot"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_com"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_prech"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_pixbuf"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdd_prot"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_com"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_prech"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_pixbuf"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); // gotthard - REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascn_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascp_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vout_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcasc_out"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"ib_test_c"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascn_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascp_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vout_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcasc_out"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"ib_test_c"}, -1, GET)); // mythen3 - REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdcsh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth2"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth3"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_p"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcassh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcas"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vicin"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre_out"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdcsh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth3"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_p"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcassh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcas"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vicin"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre_out"}, -1, GET)); // gotthard2 - REQUIRE_THROWS(proxy.Call("dac", {"vref_h_Signal"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_rstore"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_1st"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_l_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_cs"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_fd"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_h_Signal"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_rstore"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_1st"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_l_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_cs"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_fd"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc2"}, -1, GET)); } } -TEST_CASE("adcvpp", "[.cmd]") { +TEST_CASE("CALLER::adcvpp", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getADCVpp(false); { std::ostringstream oss; - proxy.Call("adcvpp", {"1"}, -1, PUT, oss); + caller.call("adcvpp", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "adcvpp 1\n"); } { std::ostringstream oss; - proxy.Call("adcvpp", {"1140", "mv"}, -1, PUT, oss); + caller.call("adcvpp", {"1140", "mv"}, -1, PUT, oss); REQUIRE(oss.str() == "adcvpp 1140 mV\n"); } { std::ostringstream oss; - proxy.Call("adcvpp", {"mv"}, -1, GET, oss); + caller.call("adcvpp", {"mv"}, -1, GET, oss); REQUIRE(oss.str() == "adcvpp 1140 mV\n"); } for (int i = 0; i != det.size(); ++i) { det.setADCVpp(prev_val[i], false, {i}); } } else { - REQUIRE_THROWS(proxy.Call("adcvpp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcvpp", {}, -1, GET)); } } /* CTB Specific */ -TEST_CASE("samples", "[.cmd]") { +TEST_CASE("CALLER::samples", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { @@ -589,27 +621,27 @@ TEST_CASE("samples", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("samples", {"25"}, -1, PUT, oss); + caller.call("samples", {"25"}, -1, PUT, oss); REQUIRE(oss.str() == "samples 25\n"); } { std::ostringstream oss; - proxy.Call("samples", {"450"}, -1, PUT, oss); + caller.call("samples", {"450"}, -1, PUT, oss); REQUIRE(oss.str() == "samples 450\n"); } { std::ostringstream oss; - proxy.Call("samples", {}, -1, GET, oss); + caller.call("samples", {}, -1, GET, oss); REQUIRE(oss.str() == "samples 450\n"); } { std::ostringstream oss; - proxy.Call("asamples", {}, -1, GET, oss); + caller.call("asamples", {}, -1, GET, oss); REQUIRE(oss.str() == "asamples 450\n"); } if (det_type == defs::CHIPTESTBOARD) { std::ostringstream oss; - proxy.Call("dsamples", {}, -1, GET, oss); + caller.call("dsamples", {}, -1, GET, oss); REQUIRE(oss.str() == "dsamples 450\n"); } for (int i = 0; i != det.size(); ++i) { @@ -619,60 +651,60 @@ TEST_CASE("samples", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("samples", {}, -1, GET)); + REQUIRE_THROWS(caller.call("samples", {}, -1, GET)); } } -TEST_CASE("asamples", "[.cmd]") { +TEST_CASE("CALLER::asamples", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getNumberOfAnalogSamples(); { std::ostringstream oss; - proxy.Call("asamples", {"25"}, -1, PUT, oss); + caller.call("asamples", {"25"}, -1, PUT, oss); REQUIRE(oss.str() == "asamples 25\n"); } { std::ostringstream oss; - proxy.Call("asamples", {"450"}, -1, PUT, oss); + caller.call("asamples", {"450"}, -1, PUT, oss); REQUIRE(oss.str() == "asamples 450\n"); } { std::ostringstream oss; - proxy.Call("asamples", {}, -1, GET, oss); + caller.call("asamples", {}, -1, GET, oss); REQUIRE(oss.str() == "asamples 450\n"); } for (int i = 0; i != det.size(); ++i) { det.setNumberOfAnalogSamples(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("asamples", {}, -1, GET)); + REQUIRE_THROWS(caller.call("asamples", {}, -1, GET)); } } -TEST_CASE("adcclk", "[.cmd]") { +TEST_CASE("CALLER::adcclk", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getADCClock(); { std::ostringstream oss; - proxy.Call("adcclk", {"20"}, -1, PUT, oss); + caller.call("adcclk", {"20"}, -1, PUT, oss); REQUIRE(oss.str() == "adcclk 20\n"); } { std::ostringstream oss; - proxy.Call("adcclk", {"10"}, -1, PUT, oss); + caller.call("adcclk", {"10"}, -1, PUT, oss); REQUIRE(oss.str() == "adcclk 10\n"); } { std::ostringstream oss; - proxy.Call("adcclk", {}, -1, GET, oss); + caller.call("adcclk", {}, -1, GET, oss); REQUIRE(oss.str() == "adcclk 10\n"); } for (int i = 0; i != det.size(); ++i) { @@ -680,30 +712,30 @@ TEST_CASE("adcclk", "[.cmd]") { } } else { // clock index might work - // REQUIRE_THROWS(proxy.Call("adcclk", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("adcclk", {}, -1, GET)); } } -TEST_CASE("runclk", "[.cmd]") { +TEST_CASE("CALLER::runclk", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getRUNClock(); { std::ostringstream oss; - proxy.Call("runclk", {"20"}, -1, PUT, oss); + caller.call("runclk", {"20"}, -1, PUT, oss); REQUIRE(oss.str() == "runclk 20\n"); } { std::ostringstream oss; - proxy.Call("runclk", {"10"}, -1, PUT, oss); + caller.call("runclk", {"10"}, -1, PUT, oss); REQUIRE(oss.str() == "runclk 10\n"); } { std::ostringstream oss; - proxy.Call("runclk", {}, -1, GET, oss); + caller.call("runclk", {}, -1, GET, oss); REQUIRE(oss.str() == "runclk 10\n"); } for (int i = 0; i != det.size(); ++i) { @@ -711,47 +743,47 @@ TEST_CASE("runclk", "[.cmd]") { } } else { // clock index might work - // REQUIRE_THROWS(proxy.Call("runclk", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("runclk", {}, -1, GET)); } } -TEST_CASE("syncclk", "[.cmd]") { +TEST_CASE("CALLER::syncclk", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("syncclk", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("syncclk", {}, -1, GET)); } else { // clock index might work - // REQUIRE_THROWS(proxy.Call("syncclk", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("syncclk", {}, -1, GET)); } } -TEST_CASE("v_limit", "[.cmd]") { +TEST_CASE("CALLER::v_limit", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPower(defs::V_LIMIT); { std::ostringstream oss; - proxy.Call("v_limit", {"1500"}, -1, PUT, oss); + caller.call("v_limit", {"1500"}, -1, PUT, oss); REQUIRE(oss.str() == "v_limit 1500\n"); } { std::ostringstream oss; - proxy.Call("v_limit", {"0"}, -1, PUT, oss); + caller.call("v_limit", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "v_limit 0\n"); } { std::ostringstream oss; - proxy.Call("v_limit", {"0"}, -1, PUT, oss); + caller.call("v_limit", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "v_limit 0\n"); } { std::ostringstream oss; - proxy.Call("v_limit", {}, -1, GET, oss); + caller.call("v_limit", {}, -1, GET, oss); REQUIRE(oss.str() == "v_limit 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -761,165 +793,165 @@ TEST_CASE("v_limit", "[.cmd]") { det.setPower(defs::V_LIMIT, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("v_limit", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_limit", {}, -1, GET)); } } -TEST_CASE("adcenable", "[.cmd]") { +TEST_CASE("CALLER::adcenable", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getADCEnableMask(); { std::ostringstream oss; - proxy.Call("adcenable", {"0x8d0aa0d8"}, -1, PUT, oss); + caller.call("adcenable", {"0x8d0aa0d8"}, -1, PUT, oss); REQUIRE(oss.str() == "adcenable 0x8d0aa0d8\n"); } { std::ostringstream oss; - proxy.Call("adcenable", {"0xffffffff"}, -1, PUT, oss); + caller.call("adcenable", {"0xffffffff"}, -1, PUT, oss); REQUIRE(oss.str() == "adcenable 0xffffffff\n"); } { std::ostringstream oss; - proxy.Call("adcenable", {}, -1, GET, oss); + caller.call("adcenable", {}, -1, GET, oss); REQUIRE(oss.str() == "adcenable 0xffffffff\n"); } for (int i = 0; i != det.size(); ++i) { det.setADCEnableMask(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("adcenable", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcenable", {}, -1, GET)); } } -TEST_CASE("adcenable10g", "[.cmd]") { +TEST_CASE("CALLER::adcenable10g", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getTenGigaADCEnableMask(); { std::ostringstream oss; - proxy.Call("adcenable10g", {"0xff0000ff"}, -1, PUT, oss); + caller.call("adcenable10g", {"0xff0000ff"}, -1, PUT, oss); REQUIRE(oss.str() == "adcenable10g 0xff0000ff\n"); } { std::ostringstream oss; - proxy.Call("adcenable10g", {"0xffffffff"}, -1, PUT, oss); + caller.call("adcenable10g", {"0xffffffff"}, -1, PUT, oss); REQUIRE(oss.str() == "adcenable10g 0xffffffff\n"); } { std::ostringstream oss; - proxy.Call("adcenable10g", {}, -1, GET, oss); + caller.call("adcenable10g", {}, -1, GET, oss); REQUIRE(oss.str() == "adcenable10g 0xffffffff\n"); } for (int i = 0; i != det.size(); ++i) { det.setTenGigaADCEnableMask(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("adcenable10g", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcenable10g", {}, -1, GET)); } } -TEST_CASE("transceiverenable", "[.cmd]") { +TEST_CASE("CALLER::transceiverenable", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getTransceiverEnableMask(); { std::ostringstream oss; - proxy.Call("transceiverenable", {"0x3"}, -1, PUT, oss); + caller.call("transceiverenable", {"0x3"}, -1, PUT, oss); REQUIRE(oss.str() == "transceiverenable 0x3\n"); } { std::ostringstream oss; - proxy.Call("transceiverenable", {"0xf"}, -1, PUT, oss); + caller.call("transceiverenable", {"0xf"}, -1, PUT, oss); REQUIRE(oss.str() == "transceiverenable 0xf\n"); } { std::ostringstream oss; - proxy.Call("transceiverenable", {}, -1, GET, oss); + caller.call("transceiverenable", {}, -1, GET, oss); REQUIRE(oss.str() == "transceiverenable 0xf\n"); } for (int i = 0; i != det.size(); ++i) { det.setTransceiverEnableMask(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("transceiverenable", {}, -1, GET)); + REQUIRE_THROWS(caller.call("transceiverenable", {}, -1, GET)); } } /* CTB Specific */ -TEST_CASE("dsamples", "[.cmd]") { +TEST_CASE("CALLER::dsamples", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getNumberOfDigitalSamples(); { std::ostringstream oss; - proxy.Call("dsamples", {"1"}, -1, PUT, oss); + caller.call("dsamples", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "dsamples 1\n"); } { std::ostringstream oss; - proxy.Call("dsamples", {"450"}, -1, PUT, oss); + caller.call("dsamples", {"450"}, -1, PUT, oss); REQUIRE(oss.str() == "dsamples 450\n"); } { std::ostringstream oss; - proxy.Call("dsamples", {}, -1, GET, oss); + caller.call("dsamples", {}, -1, GET, oss); REQUIRE(oss.str() == "dsamples 450\n"); } for (int i = 0; i != det.size(); ++i) { det.setNumberOfDigitalSamples(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("dsamples", {}, -1, GET)); + REQUIRE_THROWS(caller.call("dsamples", {}, -1, GET)); } } -TEST_CASE("tsamples", "[.cmd]") { +TEST_CASE("CALLER::tsamples", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getNumberOfTransceiverSamples(); { std::ostringstream oss; - proxy.Call("tsamples", {"1"}, -1, PUT, oss); + caller.call("tsamples", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "tsamples 1\n"); } { std::ostringstream oss; - proxy.Call("tsamples", {"450"}, -1, PUT, oss); + caller.call("tsamples", {"450"}, -1, PUT, oss); REQUIRE(oss.str() == "tsamples 450\n"); } { std::ostringstream oss; - proxy.Call("tsamples", {}, -1, GET, oss); + caller.call("tsamples", {}, -1, GET, oss); REQUIRE(oss.str() == "tsamples 450\n"); } for (int i = 0; i != det.size(); ++i) { det.setNumberOfTransceiverSamples(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("tsamples", {}, -1, GET)); + REQUIRE_THROWS(caller.call("tsamples", {}, -1, GET)); } } -TEST_CASE("romode", "[.cmd]") { +TEST_CASE("CALLER::romode", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_romode = det.getReadoutMode(); @@ -931,32 +963,32 @@ TEST_CASE("romode", "[.cmd]") { det.setNumberOfTransceiverSamples(5000); { std::ostringstream oss; - proxy.Call("romode", {"digital"}, -1, PUT, oss); + caller.call("romode", {"digital"}, -1, PUT, oss); REQUIRE(oss.str() == "romode digital\n"); } { std::ostringstream oss; - proxy.Call("romode", {"analog_digital"}, -1, PUT, oss); + caller.call("romode", {"analog_digital"}, -1, PUT, oss); REQUIRE(oss.str() == "romode analog_digital\n"); } { std::ostringstream oss; - proxy.Call("romode", {"analog"}, -1, PUT, oss); + caller.call("romode", {"analog"}, -1, PUT, oss); REQUIRE(oss.str() == "romode analog\n"); } { std::ostringstream oss; - proxy.Call("romode", {}, -1, GET, oss); + caller.call("romode", {}, -1, GET, oss); REQUIRE(oss.str() == "romode analog\n"); } { std::ostringstream oss; - proxy.Call("romode", {"transceiver"}, -1, PUT, oss); + caller.call("romode", {"transceiver"}, -1, PUT, oss); REQUIRE(oss.str() == "romode transceiver\n"); } { std::ostringstream oss; - proxy.Call("romode", {"digital_transceiver"}, -1, PUT, oss); + caller.call("romode", {"digital_transceiver"}, -1, PUT, oss); REQUIRE(oss.str() == "romode digital_transceiver\n"); } for (int i = 0; i != det.size(); ++i) { @@ -966,30 +998,30 @@ TEST_CASE("romode", "[.cmd]") { det.setNumberOfTransceiverSamples(prev_tsamples[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("romode", {}, -1, GET)); + REQUIRE_THROWS(caller.call("romode", {}, -1, GET)); } } -TEST_CASE("dbitclk", "[.cmd]") { +TEST_CASE("CALLER::dbitclk", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getRUNClock(); { std::ostringstream oss; - proxy.Call("dbitclk", {"20"}, -1, PUT, oss); + caller.call("dbitclk", {"20"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitclk 20\n"); } { std::ostringstream oss; - proxy.Call("dbitclk", {"10"}, -1, PUT, oss); + caller.call("dbitclk", {"10"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitclk 10\n"); } { std::ostringstream oss; - proxy.Call("dbitclk", {}, -1, GET, oss); + caller.call("dbitclk", {}, -1, GET, oss); REQUIRE(oss.str() == "dbitclk 10\n"); } for (int i = 0; i != det.size(); ++i) { @@ -997,353 +1029,354 @@ TEST_CASE("dbitclk", "[.cmd]") { } } else { // clock index might work - // REQUIRE_THROWS(proxy.Call("dbitclk", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("dbitclk", {}, -1, GET)); } } -TEST_CASE("v_a", "[.cmd]") { +TEST_CASE("CALLER::v_a", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPower(defs::V_POWER_A); { std::ostringstream oss1, oss2; - proxy.Call("v_a", {"700"}, -1, PUT, oss1); + caller.call("v_a", {"700"}, -1, PUT, oss1); REQUIRE(oss1.str() == "v_a 700\n"); - proxy.Call("v_a", {}, -1, GET, oss2); + caller.call("v_a", {}, -1, GET, oss2); REQUIRE(oss2.str() == "v_a 700\n"); } for (int i = 0; i != det.size(); ++i) { det.setPower(defs::V_POWER_A, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("v_a", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_a", {}, -1, GET)); } } -TEST_CASE("v_b", "[.cmd]") { +TEST_CASE("CALLER::v_b", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPower(defs::V_POWER_B); { std::ostringstream oss1, oss2; - proxy.Call("v_b", {"700"}, -1, PUT, oss1); + caller.call("v_b", {"700"}, -1, PUT, oss1); REQUIRE(oss1.str() == "v_b 700\n"); - proxy.Call("v_b", {}, -1, GET, oss2); + caller.call("v_b", {}, -1, GET, oss2); REQUIRE(oss2.str() == "v_b 700\n"); } for (int i = 0; i != det.size(); ++i) { det.setPower(defs::V_POWER_B, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("v_b", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_b", {}, -1, GET)); } } -TEST_CASE("v_c", "[.cmd]") { +TEST_CASE("CALLER::v_c", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPower(defs::V_POWER_C); { std::ostringstream oss1, oss2; - proxy.Call("v_c", {"700"}, -1, PUT, oss1); + caller.call("v_c", {"700"}, -1, PUT, oss1); REQUIRE(oss1.str() == "v_c 700\n"); - proxy.Call("v_c", {}, -1, GET, oss2); + caller.call("v_c", {}, -1, GET, oss2); REQUIRE(oss2.str() == "v_c 700\n"); } for (int i = 0; i != det.size(); ++i) { det.setPower(defs::V_POWER_C, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("v_c", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_c", {}, -1, GET)); } } -TEST_CASE("v_d", "[.cmd]") { +TEST_CASE("CALLER::v_d", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPower(defs::V_POWER_D); { std::ostringstream oss1, oss2; - proxy.Call("v_d", {"700"}, -1, PUT, oss1); + caller.call("v_d", {"700"}, -1, PUT, oss1); REQUIRE(oss1.str() == "v_d 700\n"); - proxy.Call("v_d", {}, -1, GET, oss2); + caller.call("v_d", {}, -1, GET, oss2); REQUIRE(oss2.str() == "v_d 700\n"); } for (int i = 0; i != det.size(); ++i) { det.setPower(defs::V_POWER_D, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("v_d", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_d", {}, -1, GET)); } } -TEST_CASE("v_io", "[.cmd]") { +TEST_CASE("CALLER::v_io", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { // better not to play with setting it - REQUIRE_NOTHROW(proxy.Call("v_io", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("v_io", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("v_io", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_io", {}, -1, GET)); } } -TEST_CASE("v_chip", "[.cmd]") { +TEST_CASE("CALLER::v_chip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { // better not to play with setting it - REQUIRE_NOTHROW(proxy.Call("v_chip", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("v_chip", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("v_chip", {}, -1, GET)); + REQUIRE_THROWS(caller.call("v_chip", {}, -1, GET)); } } -TEST_CASE("vm_a", "[.cmd]") { +TEST_CASE("CALLER::vm_a", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("vm_a", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("vm_a", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("vm_a", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vm_a", {}, -1, GET)); } } -TEST_CASE("vm_b", "[.cmd]") { +TEST_CASE("CALLER::vm_b", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("vm_b", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("vm_b", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("vm_b", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vm_b", {}, -1, GET)); } } -TEST_CASE("vm_c", "[.cmd]") { +TEST_CASE("CALLER::vm_c", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("vm_c", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("vm_c", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("vm_c", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vm_c", {}, -1, GET)); } } -TEST_CASE("vm_d", "[.cmd]") { +TEST_CASE("CALLER::vm_d", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("vm_d", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("vm_d", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("vm_d", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vm_d", {}, -1, GET)); } } -TEST_CASE("vm_io", "[.cmd]") { +TEST_CASE("CALLER::vm_io", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("vm_io", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("vm_io", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("vm_io", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vm_io", {}, -1, GET)); } } -TEST_CASE("im_a", "[.cmd]") { +TEST_CASE("CALLER::im_a", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("im_a", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("im_a", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("im_a", {}, -1, GET)); + REQUIRE_THROWS(caller.call("im_a", {}, -1, GET)); } } -TEST_CASE("im_b", "[.cmd]") { +TEST_CASE("CALLER::im_b", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("im_b", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("im_b", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("im_b", {}, -1, GET)); + REQUIRE_THROWS(caller.call("im_b", {}, -1, GET)); } } -TEST_CASE("im_c", "[.cmd]") { +TEST_CASE("CALLER::im_c", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("im_c", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("im_c", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("im_c", {}, -1, GET)); + REQUIRE_THROWS(caller.call("im_c", {}, -1, GET)); } } -TEST_CASE("im_d", "[.cmd]") { +TEST_CASE("CALLER::im_d", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("im_d", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("im_d", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("im_d", {}, -1, GET)); + REQUIRE_THROWS(caller.call("im_d", {}, -1, GET)); } } -TEST_CASE("im_io", "[.cmd]") { +TEST_CASE("CALLER::im_io", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("im_io", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("im_io", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("im_io", {}, -1, GET)); + REQUIRE_THROWS(caller.call("im_io", {}, -1, GET)); } } -TEST_CASE("adc", "[.cmd]") { +TEST_CASE("CALLER::adc", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { for (int i = 0; i <= 7; ++i) { - REQUIRE_NOTHROW(proxy.Call("adc", {std::to_string(i)}, -1, GET)); - REQUIRE_THROWS(proxy.Call("adc", {"0"}, -1, PUT)); + REQUIRE_NOTHROW( + caller.call("slowadc", {std::to_string(i)}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadc", {"0"}, -1, PUT)); } } else { - REQUIRE_THROWS(proxy.Call("adc", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("slowadc", {"0"}, -1, GET)); } } -TEST_CASE("extsampling", "[.cmd]") { +TEST_CASE("CALLER::extsampling", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getExternalSampling(); { std::ostringstream oss; - proxy.Call("extsampling", {"1"}, -1, PUT, oss); + caller.call("extsampling", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "extsampling 1\n"); } { std::ostringstream oss; - proxy.Call("extsampling", {"0"}, -1, PUT, oss); + caller.call("extsampling", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "extsampling 0\n"); } { std::ostringstream oss; - proxy.Call("extsampling", {}, -1, GET, oss); + caller.call("extsampling", {}, -1, GET, oss); REQUIRE(oss.str() == "extsampling 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setExternalSampling(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("extsampling", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extsampling", {}, -1, GET)); } } -TEST_CASE("extsamplingsrc", "[.cmd]") { +TEST_CASE("CALLER::extsamplingsrc", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getExternalSamplingSource(); { std::ostringstream oss; - proxy.Call("extsamplingsrc", {"63"}, -1, PUT, oss); + caller.call("extsamplingsrc", {"63"}, -1, PUT, oss); REQUIRE(oss.str() == "extsamplingsrc 63\n"); } { std::ostringstream oss; - proxy.Call("extsamplingsrc", {"0"}, -1, PUT, oss); + caller.call("extsamplingsrc", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "extsamplingsrc 0\n"); } { std::ostringstream oss; - proxy.Call("extsamplingsrc", {}, -1, GET, oss); + caller.call("extsamplingsrc", {}, -1, GET, oss); REQUIRE(oss.str() == "extsamplingsrc 0\n"); } - REQUIRE_THROWS(proxy.Call("extsamplingsrc", {"64"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extsamplingsrc", {"64"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setExternalSamplingSource(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("extsamplingsrc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extsamplingsrc", {}, -1, GET)); } } -TEST_CASE("diodelay", "[.cmd]") { +TEST_CASE("CALLER::diodelay", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { { std::ostringstream oss; - proxy.Call("diodelay", {"0x01010", "0"}, -1, PUT, oss); + caller.call("diodelay", {"0x01010", "0"}, -1, PUT, oss); REQUIRE(oss.str() == "diodelay [0x01010, 0]\n"); } { std::ostringstream oss; - proxy.Call("diodelay", {"0x01010", "775"}, -1, PUT, oss); + caller.call("diodelay", {"0x01010", "775"}, -1, PUT, oss); REQUIRE(oss.str() == "diodelay [0x01010, 775]\n"); } - REQUIRE_THROWS(proxy.Call("diodelay", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("diodelay", {"0x01010", "776"}, -1, GET)); + REQUIRE_THROWS(caller.call("diodelay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("diodelay", {"0x01010", "776"}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("diodelay", {"0x01010", "775"}, -1, PUT)); + REQUIRE_THROWS(caller.call("diodelay", {"0x01010", "775"}, -1, PUT)); } } -TEST_CASE("led", "[.cmd]") { +TEST_CASE("CALLER::led", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getLEDEnable(); { std::ostringstream oss; - proxy.Call("led", {"1"}, -1, PUT, oss); + caller.call("led", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "led 1\n"); } { std::ostringstream oss; - proxy.Call("led", {"0"}, -1, PUT, oss); + caller.call("led", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "led 0\n"); } { std::ostringstream oss; - proxy.Call("led", {}, -1, GET, oss); + caller.call("led", {}, -1, GET, oss); REQUIRE(oss.str() == "led 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setLEDEnable(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("led", {}, -1, GET)); + REQUIRE_THROWS(caller.call("led", {}, -1, GET)); } } diff --git a/slsDetectorSoftware/tests/test-CmdProxy-eiger.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-eiger.cpp similarity index 52% rename from slsDetectorSoftware/tests/test-CmdProxy-eiger.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-eiger.cpp index ebab79135..1df82c68f 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-eiger.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-eiger.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" @@ -9,7 +9,7 @@ #include #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -19,137 +19,143 @@ using test::PUT; /** temperature */ -TEST_CASE("temp_fpgaext", "[.cmd]") { +TEST_CASE("CALLER::temp_fpgaext", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_fpgaext", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_fpgaext", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_fpgaext", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_fpgaext", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_fpgaext ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_fpgaext", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_fpgaext", {}, -1, GET)); } } -TEST_CASE("temp_10ge", "[.cmd]") { +TEST_CASE("CALLER::temp_10ge", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_10ge", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_10ge", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_10ge", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_10ge", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_10ge ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_10ge", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_10ge", {}, -1, GET)); } } -TEST_CASE("temp_dcdc", "[.cmd]") { +TEST_CASE("CALLER::temp_dcdc", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_dcdc", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_dcdc", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_dcdc", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_dcdc", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_dcdc ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_dcdc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_dcdc", {}, -1, GET)); } } -TEST_CASE("temp_sodl", "[.cmd]") { +TEST_CASE("CALLER::temp_sodl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_sodl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_sodl", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_sodl", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_sodl", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_sodl ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_sodl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_sodl", {}, -1, GET)); } } -TEST_CASE("temp_sodr", "[.cmd]") { +TEST_CASE("CALLER::temp_sodr", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_sodr", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_sodr", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_sodr", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_sodr", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_sodr ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_sodr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_sodr", {}, -1, GET)); } } -TEST_CASE("temp_fpgafl", "[.cmd]") { +TEST_CASE("CALLER::temp_fpgafl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_fpgafl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_fpgafl", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_fpgafl", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_fpgafl", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_fpgafl ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_fpgafl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_fpgafl", {}, -1, GET)); } } -TEST_CASE("temp_fpgafr", "[.cmd]") { +TEST_CASE("CALLER::temp_fpgafr", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("temp_fpgafr", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_fpgafr", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_fpgafr", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_fpgafr", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_fpgafr ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_fpgafr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_fpgafr", {}, -1, GET)); } } /* dacs */ -TEST_CASE("Setting and reading back EIGER dacs", "[.cmd][.dacs]") { +TEST_CASE("CALLER::Setting and reading back EIGER dacs", "[.cmdcall][.dacs]") { // vsvp, vtr, vrf, vrs, vsvn, vtgstv, vcmp_ll, vcmp_lr, vcal, vcmp_rl, // rxb_rb, rxb_lb, vcmp_rr, vcp, vcn, vis, vthreshold Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - SECTION("vsvp") { test_dac(defs::VSVP, "vsvp", 5); } - SECTION("vtrim") { test_dac(defs::VTRIM, "vtrim", 1200); } - SECTION("vrpreamp") { test_dac(defs::VRPREAMP, "vrpreamp", 1500); } - SECTION("vrshaper") { test_dac(defs::VRSHAPER, "vrshaper", 1510); } - SECTION("vsvn") { test_dac(defs::VSVN, "vsvn", 3800); } - SECTION("vtgstv") { test_dac(defs::VTGSTV, "vtgstv", 2550); } - SECTION("vcmp_ll") { test_dac(defs::VCMP_LL, "vcmp_ll", 1400); } - SECTION("vcmp_lr") { test_dac(defs::VCMP_LR, "vcmp_lr", 1400); } - SECTION("vcal") { test_dac(defs::VCAL, "vcal", 1400); } - SECTION("vcmp_rl") { test_dac(defs::VCMP_RL, "vcmp_rl", 1400); } - SECTION("rxb_rb") { test_dac(defs::RXB_RB, "rxb_rb", 1400); } - SECTION("rxb_lb") { test_dac(defs::RXB_LB, "rxb_lb", 1400); } - SECTION("vcmp_rr") { test_dac(defs::VCMP_RR, "vcmp_rr", 1400); } - SECTION("vcp") { test_dac(defs::VCP, "vcp", 1400); } - SECTION("vcn") { test_dac(defs::VCN, "vcn", 1400); } - SECTION("vishaper") { test_dac(defs::VISHAPER, "vishaper", 1400); } - SECTION("iodelay") { test_dac(defs::IO_DELAY, "iodelay", 1400); } + SECTION("vsvp") { test_dac_caller(defs::VSVP, "vsvp", 5); } + SECTION("vtrim") { test_dac_caller(defs::VTRIM, "vtrim", 1200); } + SECTION("vrpreamp") { + test_dac_caller(defs::VRPREAMP, "vrpreamp", 1500); + } + SECTION("vrshaper") { + test_dac_caller(defs::VRSHAPER, "vrshaper", 1510); + } + SECTION("vsvn") { test_dac_caller(defs::VSVN, "vsvn", 3800); } + SECTION("vtgstv") { test_dac_caller(defs::VTGSTV, "vtgstv", 2550); } + SECTION("vcmp_ll") { test_dac_caller(defs::VCMP_LL, "vcmp_ll", 1400); } + SECTION("vcmp_lr") { test_dac_caller(defs::VCMP_LR, "vcmp_lr", 1400); } + SECTION("vcal") { test_dac_caller(defs::VCAL, "vcal", 1400); } + SECTION("vcmp_rl") { test_dac_caller(defs::VCMP_RL, "vcmp_rl", 1400); } + SECTION("rxb_rb") { test_dac_caller(defs::RXB_RB, "rxb_rb", 1400); } + SECTION("rxb_lb") { test_dac_caller(defs::RXB_LB, "rxb_lb", 1400); } + SECTION("vcmp_rr") { test_dac_caller(defs::VCMP_RR, "vcmp_rr", 1400); } + SECTION("vcp") { test_dac_caller(defs::VCP, "vcp", 1400); } + SECTION("vcn") { test_dac_caller(defs::VCN, "vcn", 1400); } + SECTION("vishaper") { + test_dac_caller(defs::VISHAPER, "vishaper", 1400); + } + SECTION("iodelay") { test_dac_caller(defs::IO_DELAY, "iodelay", 1400); } SECTION("vthreshold") { // Read out individual vcmp to be able to reset after // the test is done @@ -161,12 +167,12 @@ TEST_CASE("Setting and reading back EIGER dacs", "[.cmd][.dacs]") { { std::ostringstream oss; - proxy.Call("vthreshold", {"1234"}, -1, PUT, oss); + caller.call("dac", {"vthreshold", "1234"}, -1, PUT, oss); REQUIRE(oss.str() == "dac vthreshold 1234\n"); } { std::ostringstream oss; - proxy.Call("vthreshold", {}, -1, GET, oss); + caller.call("dac", {"vthreshold"}, -1, GET, oss); REQUIRE(oss.str() == "dac vthreshold 1234\n"); } @@ -180,54 +186,54 @@ TEST_CASE("Setting and reading back EIGER dacs", "[.cmd][.dacs]") { } } // gotthard - REQUIRE_THROWS(proxy.Call("vref_ds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcascn_pb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcascp_pb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vout_cm", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcasc_out", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vin_cm", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_comp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("ib_test_c", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascn_pb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascp_pb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vout_cm", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcasc_out", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vin_cm", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("ib_test_c", {}, -1, GET)); // mythen3 - // REQUIRE_THROWS(proxy.Call("vrpreamp", {}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("vrshaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vrshaper_n", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vipre", {}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("vishaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vdcsh", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth1", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth2", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth3", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcal_n", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcal_p", {}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("vtrim", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcassh", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcas", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vicin", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vipre_out", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vrpreamp", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vrshaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper_n", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vipre", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vishaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vdcsh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth3", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_n", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_p", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vtrim", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcassh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcas", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vicin", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vipre_out", {}, -1, GET)); // gotthard2 - REQUIRE_THROWS(proxy.Call("vref_h_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_comp_fe", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_comp_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_cds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_rstore", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_opa_1st", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_comp_fe", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_adc1", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_l_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_cds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_cs", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_opa_fd", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_adc2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_h_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_rstore", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_1st", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_l_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_cs", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_fd", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc2", {}, -1, GET)); // jungfrau - REQUIRE_THROWS(proxy.Call("vb_comp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vdd_prot", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vin_com", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_prech", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_pixbuf", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_ds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_ds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vdd_prot", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vin_com", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_prech", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_pixbuf", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp", {}, -1, GET)); } } @@ -235,116 +241,116 @@ TEST_CASE("Setting and reading back EIGER dacs", "[.cmd][.dacs]") { /* Network Configuration (Detector<->Receiver) */ -TEST_CASE("txdelay_left", "[.cmd]") { +TEST_CASE("CALLER::txdelay_left", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getTransmissionDelayLeft(); { std::ostringstream oss1, oss2; - proxy.Call("txdelay_left", {"5000"}, -1, PUT, oss1); + caller.call("txdelay_left", {"5000"}, -1, PUT, oss1); REQUIRE(oss1.str() == "txdelay_left 5000\n"); - proxy.Call("txdelay_left", {}, -1, GET, oss2); + caller.call("txdelay_left", {}, -1, GET, oss2); REQUIRE(oss2.str() == "txdelay_left 5000\n"); } for (int i = 0; i != det.size(); ++i) { det.setTransmissionDelayLeft(prev_val[i]); } } else { - REQUIRE_THROWS(proxy.Call("txdelay_left", {}, -1, GET)); + REQUIRE_THROWS(caller.call("txdelay_left", {}, -1, GET)); } } -TEST_CASE("txdelay_right", "[.cmd]") { +TEST_CASE("CALLER::txdelay_right", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getTransmissionDelayRight(); { std::ostringstream oss1, oss2; - proxy.Call("txdelay_right", {"5000"}, -1, PUT, oss1); + caller.call("txdelay_right", {"5000"}, -1, PUT, oss1); REQUIRE(oss1.str() == "txdelay_right 5000\n"); - proxy.Call("txdelay_right", {}, -1, GET, oss2); + caller.call("txdelay_right", {}, -1, GET, oss2); REQUIRE(oss2.str() == "txdelay_right 5000\n"); } for (int i = 0; i != det.size(); ++i) { det.setTransmissionDelayRight(prev_val[i]); } } else { - REQUIRE_THROWS(proxy.Call("txdelay_right", {}, -1, GET)); + REQUIRE_THROWS(caller.call("txdelay_right", {}, -1, GET)); } } /* Eiger Specific */ -TEST_CASE("subexptime", "[.cmd]") { +TEST_CASE("CALLER::subexptime", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto time = det.getSubExptime(); std::ostringstream oss1, oss2; - proxy.Call("subexptime", {"2.5us"}, -1, PUT, oss1); + caller.call("subexptime", {"2.5us"}, -1, PUT, oss1); REQUIRE(oss1.str() == "subexptime 2.5us\n"); - proxy.Call("subexptime", {}, -1, GET, oss2); + caller.call("subexptime", {}, -1, GET, oss2); REQUIRE(oss2.str() == "subexptime 2.5us\n"); for (int i = 0; i != det.size(); ++i) { det.setSubExptime(time[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("subexptime", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("subexptime", {"2.13"}, -1, PUT)); + REQUIRE_THROWS(caller.call("subexptime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("subexptime", {"2.13"}, -1, PUT)); } } -TEST_CASE("subdeadtime", "[.cmd]") { +TEST_CASE("CALLER::subdeadtime", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto time = det.getSubDeadTime(); std::ostringstream oss1, oss2; - proxy.Call("subdeadtime", {"500us"}, -1, PUT, oss1); + caller.call("subdeadtime", {"500us"}, -1, PUT, oss1); REQUIRE(oss1.str() == "subdeadtime 500us\n"); - proxy.Call("subdeadtime", {}, -1, GET, oss2); + caller.call("subdeadtime", {}, -1, GET, oss2); REQUIRE(oss2.str() == "subdeadtime 500us\n"); for (int i = 0; i != det.size(); ++i) { det.setSubDeadTime(time[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("subdeadtime", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("subdeadtime", {"2.13"}, -1, PUT)); + REQUIRE_THROWS(caller.call("subdeadtime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("subdeadtime", {"2.13"}, -1, PUT)); } } -TEST_CASE("overflow", "[.cmd]") { +TEST_CASE("CALLER::overflow", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto previous = det.getOverFlowMode(); std::ostringstream oss1, oss2, oss3; - proxy.Call("overflow", {"1"}, -1, PUT, oss1); + caller.call("overflow", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "overflow 1\n"); - proxy.Call("overflow", {}, -1, GET, oss2); + caller.call("overflow", {}, -1, GET, oss2); REQUIRE(oss2.str() == "overflow 1\n"); - proxy.Call("overflow", {"0"}, -1, PUT, oss3); + caller.call("overflow", {"0"}, -1, PUT, oss3); REQUIRE(oss3.str() == "overflow 0\n"); for (int i = 0; i != det.size(); ++i) { det.setOverFlowMode(previous[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("overflow", {}, -1, GET)); + REQUIRE_THROWS(caller.call("overflow", {}, -1, GET)); } } -TEST_CASE("ratecorr", "[.cmd]") { +TEST_CASE("CALLER::ratecorr", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_dr = det.getDynamicRange().tsquash("inconsistent dr to test"); @@ -352,19 +358,19 @@ TEST_CASE("ratecorr", "[.cmd]") { det.setDynamicRange(16); { std::ostringstream oss; - proxy.Call("ratecorr", {"120"}, -1, PUT, oss); + caller.call("ratecorr", {"120"}, -1, PUT, oss); REQUIRE(oss.str() == "ratecorr 120ns\n"); } { std::ostringstream oss; - proxy.Call("ratecorr", {}, -1, GET, oss); + caller.call("ratecorr", {}, -1, GET, oss); REQUIRE(oss.str() == "ratecorr 120ns\n"); } // may fail if default settings not loaded - // REQUIRE_NOTHROW(proxy.Call("ratecorr", {"-1"}, -1, PUT)); + // REQUIRE_NOTHROW(caller.call("ratecorr", {"-1"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("ratecorr", {"0"}, -1, PUT, oss); + caller.call("ratecorr", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "ratecorr 0ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -372,37 +378,37 @@ TEST_CASE("ratecorr", "[.cmd]") { } det.setDynamicRange(prev_dr); } else { - REQUIRE_THROWS(proxy.Call("ratecorr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("ratecorr", {}, -1, GET)); } } -TEST_CASE("interruptsubframe", "[.cmd]") { +TEST_CASE("CALLER::interruptsubframe", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getInterruptSubframe(); std::ostringstream oss1, oss2, oss3; - proxy.Call("interruptsubframe", {"1"}, -1, PUT, oss1); + caller.call("interruptsubframe", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "interruptsubframe 1\n"); - proxy.Call("interruptsubframe", {}, -1, GET, oss2); + caller.call("interruptsubframe", {}, -1, GET, oss2); REQUIRE(oss2.str() == "interruptsubframe 1\n"); - proxy.Call("interruptsubframe", {"0"}, -1, PUT, oss3); + caller.call("interruptsubframe", {"0"}, -1, PUT, oss3); REQUIRE(oss3.str() == "interruptsubframe 0\n"); for (int i = 0; i != det.size(); ++i) { det.setInterruptSubframe(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("interruptsubframe", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("interruptsubframe", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("interruptsubframe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("interruptsubframe", {"1"}, -1, PUT)); } } -TEST_CASE("measuredperiod", "[.cmd]") { +TEST_CASE("CALLER::measuredperiod", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_frames = det.getNumberOfFrames().tsquash( @@ -416,7 +422,7 @@ TEST_CASE("measuredperiod", "[.cmd]") { det.startDetector(); std::this_thread::sleep_for(std::chrono::seconds(3)); std::ostringstream oss; - proxy.Call("measuredperiod", {}, -1, GET, oss); + caller.call("measuredperiod", {}, -1, GET, oss); std::string st = oss.str(); std::string s; if (st.find('[') != std::string::npos) { @@ -433,13 +439,13 @@ TEST_CASE("measuredperiod", "[.cmd]") { det.setNumberOfFrames(prev_frames); det.setTimingMode(prev_timing); } else { - REQUIRE_THROWS(proxy.Call("measuredperiod", {}, -1, GET)); + REQUIRE_THROWS(caller.call("measuredperiod", {}, -1, GET)); } } -TEST_CASE("measuredsubperiod", "[.cmd]") { +TEST_CASE("CALLER::measuredsubperiod", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_frames = det.getNumberOfFrames().tsquash( @@ -455,7 +461,7 @@ TEST_CASE("measuredsubperiod", "[.cmd]") { det.startDetector(); std::this_thread::sleep_for(std::chrono::seconds(3)); std::ostringstream oss; - proxy.Call("measuredsubperiod", {}, -1, GET, oss); + caller.call("measuredsubperiod", {}, -1, GET, oss); std::string st = oss.str(); std::string s; if (st.find('[') != std::string::npos) { @@ -473,29 +479,29 @@ TEST_CASE("measuredsubperiod", "[.cmd]") { det.setTimingMode(prev_timing); det.setDynamicRange(prev_dr); } else { - REQUIRE_THROWS(proxy.Call("measuredsubperiod", {}, -1, GET)); + REQUIRE_THROWS(caller.call("measuredsubperiod", {}, -1, GET)); } } -TEST_CASE("activate", "[.cmd]") { +TEST_CASE("CALLER::activate", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getActive(); { std::ostringstream oss; - proxy.Call("activate", {"1"}, -1, PUT, oss); + caller.call("activate", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "activate 1\n"); } { std::ostringstream oss; - proxy.Call("activate", {}, -1, GET, oss); + caller.call("activate", {}, -1, GET, oss); REQUIRE(oss.str() == "activate 1\n"); } { std::ostringstream oss; - proxy.Call("activate", {"0"}, -1, PUT, oss); + caller.call("activate", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "activate 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -503,137 +509,137 @@ TEST_CASE("activate", "[.cmd]") { } } else { - REQUIRE_THROWS(proxy.Call("activate", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("activate", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("activate", {}, -1, GET)); + REQUIRE_THROWS(caller.call("activate", {"1"}, -1, PUT)); } } -TEST_CASE("partialreset", "[.cmd]") { +TEST_CASE("CALLER::partialreset", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getPartialReset(); std::ostringstream oss1, oss2, oss3; - proxy.Call("partialreset", {"1"}, -1, PUT, oss1); + caller.call("partialreset", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "partialreset 1\n"); - proxy.Call("partialreset", {}, -1, GET, oss2); + caller.call("partialreset", {}, -1, GET, oss2); REQUIRE(oss2.str() == "partialreset 1\n"); - proxy.Call("partialreset", {"0"}, -1, PUT, oss3); + caller.call("partialreset", {"0"}, -1, PUT, oss3); REQUIRE(oss3.str() == "partialreset 0\n"); for (int i = 0; i != det.size(); ++i) { det.setPartialReset(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("partialreset", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("partialreset", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("partialreset", {}, -1, GET)); + REQUIRE_THROWS(caller.call("partialreset", {"1"}, -1, PUT)); } } -TEST_CASE("pulse", "[.cmd]") { +TEST_CASE("CALLER::pulse", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("pulse", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulse", {}, -1, GET)); std::ostringstream oss; - proxy.Call("pulse", {"1", "1", "5"}, -1, PUT, oss); + caller.call("pulse", {"1", "1", "5"}, -1, PUT, oss); REQUIRE(oss.str() == "pulse [1, 1, 5]\n"); } else { - REQUIRE_THROWS(proxy.Call("pulse", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pulse", {"1", "1", "5"}, -1, PUT)); + REQUIRE_THROWS(caller.call("pulse", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulse", {"1", "1", "5"}, -1, PUT)); } } -TEST_CASE("pulsenmove", "[.cmd]") { +TEST_CASE("CALLER::pulsenmove", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("pulsenmove", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulsenmove", {}, -1, GET)); std::ostringstream oss; - proxy.Call("pulsenmove", {"1", "1", "5"}, -1, PUT, oss); + caller.call("pulsenmove", {"1", "1", "5"}, -1, PUT, oss); REQUIRE(oss.str() == "pulsenmove [1, 1, 5]\n"); } else { - REQUIRE_THROWS(proxy.Call("pulsenmove", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pulsenmove", {"1", "1", "5"}, -1, PUT)); + REQUIRE_THROWS(caller.call("pulsenmove", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulsenmove", {"1", "1", "5"}, -1, PUT)); } } -TEST_CASE("pulsechip", "[.cmd]") { +TEST_CASE("CALLER::pulsechip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("pulsechip", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulsechip", {}, -1, GET)); std::ostringstream oss; - proxy.Call("pulsechip", {"1"}, -1, PUT, oss); + caller.call("pulsechip", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "pulsechip 1\n"); } else { - REQUIRE_THROWS(proxy.Call("pulsechip", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pulsechip", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("pulsechip", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pulsechip", {"1"}, -1, PUT)); } } -TEST_CASE("quad", "[.cmd]") { +TEST_CASE("CALLER::quad", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getQuad().tsquash("inconsistent quad to test"); // Quad only works with a single half module EIGER std::ostringstream oss; - proxy.Call("quad", {}, -1, GET, oss); + caller.call("quad", {}, -1, GET, oss); REQUIRE(oss.str() == "quad 0\n"); det.setQuad(prev_val); } else { - REQUIRE_THROWS(proxy.Call("quad", {}, -1, GET)); + REQUIRE_THROWS(caller.call("quad", {}, -1, GET)); } } -TEST_CASE("datastream", "[.cmd]") { +TEST_CASE("CALLER::datastream", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val_left = det.getDataStream(defs::LEFT); auto prev_val_right = det.getDataStream(defs::RIGHT); // no "left" or "right" - REQUIRE_THROWS(proxy.Call("datastream", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("datastream", {"1"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("datastream", {"left", "0"}, -1, PUT, oss); - REQUIRE(oss.str() == "datastream left 0\n"); + caller.call("datastream", {"left", "0"}, -1, PUT, oss); + REQUIRE(oss.str() == "datastream [left, 0]\n"); } { std::ostringstream oss; - proxy.Call("datastream", {"right", "0"}, -1, PUT, oss); - REQUIRE(oss.str() == "datastream right 0\n"); + caller.call("datastream", {"right", "0"}, -1, PUT, oss); + REQUIRE(oss.str() == "datastream [right, 0]\n"); } { std::ostringstream oss; - proxy.Call("datastream", {"left", "1"}, -1, PUT, oss); - REQUIRE(oss.str() == "datastream left 1\n"); + caller.call("datastream", {"left", "1"}, -1, PUT, oss); + REQUIRE(oss.str() == "datastream [left, 1]\n"); } { std::ostringstream oss; - proxy.Call("datastream", {"right", "1"}, -1, PUT, oss); - REQUIRE(oss.str() == "datastream right 1\n"); + caller.call("datastream", {"right", "1"}, -1, PUT, oss); + REQUIRE(oss.str() == "datastream [right, 1]\n"); } for (int i = 0; i != det.size(); ++i) { det.setDataStream(defs::LEFT, prev_val_left[i], {i}); det.setDataStream(defs::RIGHT, prev_val_right[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("datastream", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("datastream", {"1"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("datastream", {"left", "1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("datastream", {}, -1, GET)); + REQUIRE_THROWS(caller.call("datastream", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("datastream", {"left", "1"}, -1, PUT)); } } -TEST_CASE("top", "[.cmd]") { +TEST_CASE("CALLER::top", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto prev_val = det.getTop(); @@ -643,19 +649,19 @@ TEST_CASE("top", "[.cmd]") { } for (int i = 0; i != numModulesTested; ++i) { std::ostringstream oss1, oss2, oss3; - proxy.Call("top", {"1"}, i, PUT, oss1); + caller.call("top", {"1"}, i, PUT, oss1); REQUIRE(oss1.str() == "top 1\n"); - proxy.Call("top", {}, i, GET, oss2); + caller.call("top", {}, i, GET, oss2); REQUIRE(oss2.str() == "top 1\n"); - proxy.Call("top", {"0"}, i, PUT, oss3); + caller.call("top", {"0"}, i, PUT, oss3); REQUIRE(oss3.str() == "top 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setTop(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("top", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("top", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("top", {}, -1, GET)); + REQUIRE_THROWS(caller.call("top", {"1"}, -1, PUT)); } } diff --git a/slsDetectorSoftware/tests/test-CmdProxy-global.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-global.cpp similarity index 65% rename from slsDetectorSoftware/tests/test-CmdProxy-global.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-global.cpp index fd92bc162..7900f3340 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-global.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-global.cpp @@ -1,7 +1,7 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "test-CmdProxy-global.h" -#include "CmdProxy.h" +#include "test-Caller-global.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "tests/globals.h" @@ -10,12 +10,11 @@ namespace sls { using test::GET; using test::PUT; - -void test_valid_port(const std::string &command, - const std::vector &arguments, int detector_id, - int action) { +void test_valid_port_caller(const std::string &command, + const std::vector &arguments, + int detector_id, int action) { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); std::vector arg(arguments); if (arg.empty()) @@ -25,33 +24,34 @@ void test_valid_port(const std::string &command, for (int i = 0; i != 3; ++i) { int port_number = test_values[i]; arg[arg.size() - 1] = std::to_string(port_number); - REQUIRE_THROWS(proxy.Call(command, arg, detector_id, action)); + REQUIRE_THROWS(caller.call(command, arg, detector_id, action)); /*REQUIRE_THROWS_WITH(proxy.Call(command, arguments, detector_id, action), "Invalid port range. Must be between 1 - 65535.");*/ } } -void test_dac(defs::dacIndex index, const std::string &dacname, int dacvalue) { +void test_dac_caller(defs::dacIndex index, const std::string &dacname, + int dacvalue) { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); std::ostringstream oss_set, oss_get; auto dacstr = std::to_string(dacvalue); auto previous = det.getDAC(index, false); // chip test board if (dacname == "dac") { auto dacIndexstr = std::to_string(static_cast(index)); - proxy.Call(dacname, {dacIndexstr, dacstr}, -1, PUT, oss_set); + caller.call(dacname, {dacIndexstr, dacstr}, -1, PUT, oss_set); REQUIRE(oss_set.str() == dacname + " " + dacIndexstr + " " + dacstr + "\n"); - proxy.Call(dacname, {dacIndexstr}, -1, GET, oss_get); + caller.call(dacname, {dacIndexstr}, -1, GET, oss_get); REQUIRE(oss_get.str() == dacname + " " + dacIndexstr + " " + dacstr + "\n"); } // other detectors else { - proxy.Call("dac", {dacname, dacstr}, -1, PUT, oss_set); + caller.call("dac", {dacname, dacstr}, -1, PUT, oss_set); REQUIRE(oss_set.str() == "dac " + dacname + " " + dacstr + "\n"); - proxy.Call("dac", {dacname}, -1, GET, oss_get); + caller.call("dac", {dacname}, -1, GET, oss_get); REQUIRE(oss_get.str() == "dac " + dacname + " " + dacstr + "\n"); } // Reset all dacs to previous value @@ -60,25 +60,25 @@ void test_dac(defs::dacIndex index, const std::string &dacname, int dacvalue) { } } -void test_onchip_dac(defs::dacIndex index, const std::string &dacname, - int dacvalue) { +void test_onchip_dac_caller(defs::dacIndex index, const std::string &dacname, + int dacvalue) { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call(dacname, {}, -1, GET)); + Caller caller(&det); + REQUIRE_THROWS(caller.call(dacname, {}, -1, GET)); REQUIRE_THROWS( - proxy.Call(dacname, {"10", "0x0"}, -1, PUT)); // chip index (-1 to 9) + caller.call(dacname, {"10", "0x0"}, -1, PUT)); // chip index (-1 to 9) REQUIRE_THROWS( - proxy.Call(dacname, {"-1", "0x400"}, -1, PUT)); // max val is 0x3ff + caller.call(dacname, {"-1", "0x400"}, -1, PUT)); // max val is 0x3ff int chipIndex = -1; // for now, it is -1 only auto prev_val = det.getOnChipDAC(index, chipIndex); auto dacValueStr = ToStringHex(dacvalue); auto chipIndexStr = std::to_string(chipIndex); std::ostringstream oss_set, oss_get; - proxy.Call(dacname, {chipIndexStr, dacValueStr}, -1, PUT, oss_set); + caller.call(dacname, {chipIndexStr, dacValueStr}, -1, PUT, oss_set); REQUIRE(oss_set.str() == dacname + " " + chipIndexStr + " " + dacValueStr + "\n"); - proxy.Call(dacname, {chipIndexStr}, -1, GET, oss_get); + caller.call(dacname, {chipIndexStr}, -1, GET, oss_get); REQUIRE(oss_get.str() == dacname + " " + chipIndexStr + " " + dacValueStr + "\n"); diff --git a/slsDetectorSoftware/tests/Caller/test-Caller-global.h b/slsDetectorSoftware/tests/Caller/test-Caller-global.h new file mode 100644 index 000000000..98fa46860 --- /dev/null +++ b/slsDetectorSoftware/tests/Caller/test-Caller-global.h @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#pragma once +#include "sls/sls_detector_defs.h" + +namespace sls { +void test_valid_port_caller(const std::string &command, + const std::vector &arguments, + int detector_id, int action); + +void test_dac_caller(slsDetectorDefs::dacIndex index, + const std::string &dacname, int dacvalue); +void test_onchip_dac_caller(slsDetectorDefs::dacIndex index, + const std::string &dacname, int dacvalue); + +} // namespace sls diff --git a/slsDetectorSoftware/tests/Caller/test-Caller-gotthard.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-gotthard.cpp new file mode 100644 index 000000000..67d2db2d8 --- /dev/null +++ b/slsDetectorSoftware/tests/Caller/test-Caller-gotthard.cpp @@ -0,0 +1,175 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "Caller.h" +#include "catch.hpp" +#include "sls/Detector.h" +#include "sls/sls_detector_defs.h" +#include + +#include "sls/Result.h" +#include "sls/ToString.h" +#include "sls/versionAPI.h" +#include "test-Caller-global.h" +#include "tests/globals.h" + +namespace sls { + +using test::GET; +using test::PUT; + +/* dacs */ + +TEST_CASE("Caller::Setting and reading back GOTTHARD dacs", + "[.cmdcall][.dacs]") { + // vref_ds, vcascn_pb, vcascp_pb, vout_cm, vcasc_out, vin_cm, vref_comp, + // ib_test_c + + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::GOTTHARD) { + SECTION("vref_ds") { test_dac_caller(defs::VREF_DS, "vref_ds", 660); } + SECTION("vcascn_pb") { + test_dac_caller(defs::VCASCN_PB, "vcascn_pb", 650); + } + SECTION("vcascp_pb") { + test_dac_caller(defs::VCASCP_PB, "vcascp_pb", 1480); + } + SECTION("vout_cm") { test_dac_caller(defs::VOUT_CM, "vout_cm", 1520); } + SECTION("vcasc_out") { + test_dac_caller(defs::VCASC_OUT, "vcasc_out", 1320); + } + SECTION("vin_cm") { test_dac_caller(defs::VIN_CM, "vin_cm", 1350); } + SECTION("vref_comp") { + test_dac_caller(defs::VREF_COMP, "vref_comp", 350); + } + SECTION("ib_test_c") { + test_dac_caller(defs::IB_TESTC, "ib_test_c", 2001); + } + // eiger + REQUIRE_THROWS(caller.call("dac", {"vthreshold"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvn"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtgstv"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_ll"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_lr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rl"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_rb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_lb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcn"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"iodelay"}, -1, GET)); + // jungfrau + REQUIRE_THROWS(caller.call("dac", {"vb_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdd_prot"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_com"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_prech"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_pixbuf"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_ds"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); + // mythen3 + REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdcsh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth3"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_p"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcassh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcas"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vicin"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre_out"}, -1, GET)); + // gotthard2 + REQUIRE_THROWS(caller.call("dac", {"vref_h_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_rstore"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_1st"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_l_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_cs"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_fd"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc2"}, -1, GET)); + } +} + +/* Gotthard Specific */ + +TEST_CASE("Caller::roi", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + + if (det_type == defs::GOTTHARD) { + if (det.size() > 1) { + REQUIRE_THROWS(caller.call("roi", {"0", "255"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("roi", {}, -1, GET)); + } else { + auto prev_val = det.getROI(); + { + std::ostringstream oss; + caller.call("roi", {"0", "255"}, -1, PUT, oss); + REQUIRE(oss.str() == "roi [0, 255]\n"); + } + { + std::ostringstream oss; + caller.call("roi", {"256", "511"}, -1, PUT, oss); + REQUIRE(oss.str() == "roi [256, 511]\n"); + } + REQUIRE_THROWS(caller.call("roi", {"0", "256"}, -1, PUT)); + for (int i = 0; i != det.size(); ++i) { + det.setROI(prev_val[i], i); + } + } + } else { + REQUIRE_THROWS(caller.call("roi", {}, -1, GET)); + } +} + +TEST_CASE("Caller::clearroi", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + + if (det_type == defs::GOTTHARD) { + auto prev_val = det.getROI(); + { + std::ostringstream oss; + caller.call("clearroi", {}, -1, PUT, oss); + REQUIRE(oss.str() == "clearroi successful\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setROI(prev_val[i], i); + } + } else { + REQUIRE_THROWS(caller.call("clearroi", {}, -1, PUT)); + } +} + +TEST_CASE("Caller::exptimel", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::GOTTHARD) { + REQUIRE_NOTHROW(caller.call("exptimel", {}, -1, GET)); + } else { + REQUIRE_THROWS(caller.call("exptimel", {}, -1, GET)); + } +} + +} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy-gotthard2.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-gotthard2.cpp similarity index 51% rename from slsDetectorSoftware/tests/test-CmdProxy-gotthard2.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-gotthard2.cpp index 1be0fb46c..518e519d7 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-gotthard2.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-gotthard2.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" @@ -9,7 +9,7 @@ #include "sls/Result.h" #include "sls/ToString.h" #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -18,21 +18,21 @@ using test::GET; using test::PUT; // time specific measurements for gotthard2 -TEST_CASE("timegotthard2", "[.cmd]") { +TEST_CASE("Caller::timegotthard2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { // exptime auto prev_val = det.getExptime(); { std::ostringstream oss; - proxy.Call("exptime", {"220ns"}, -1, PUT, oss); + caller.call("exptime", {"220ns"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime 220ns\n"); } { std::ostringstream oss; - proxy.Call("exptime", {}, -1, GET, oss); + caller.call("exptime", {}, -1, GET, oss); REQUIRE(oss.str() == "exptime 221ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -42,12 +42,12 @@ TEST_CASE("timegotthard2", "[.cmd]") { prev_val = det.getBurstPeriod(); { std::ostringstream oss; - proxy.Call("burstperiod", {"220ns"}, -1, PUT, oss); + caller.call("burstperiod", {"220ns"}, -1, PUT, oss); REQUIRE(oss.str() == "burstperiod 220ns\n"); } { std::ostringstream oss; - proxy.Call("burstperiod", {}, -1, GET, oss); + caller.call("burstperiod", {}, -1, GET, oss); REQUIRE(oss.str() == "burstperiod 221ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -57,12 +57,12 @@ TEST_CASE("timegotthard2", "[.cmd]") { prev_val = det.getDelayAfterTrigger(); { std::ostringstream oss; - proxy.Call("delay", {"220ns"}, -1, PUT, oss); + caller.call("delay", {"220ns"}, -1, PUT, oss); REQUIRE(oss.str() == "delay 220ns\n"); } { std::ostringstream oss; - proxy.Call("delay", {}, -1, GET, oss); + caller.call("delay", {}, -1, GET, oss); REQUIRE(oss.str() == "delay 221ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -74,12 +74,12 @@ TEST_CASE("timegotthard2", "[.cmd]") { prev_val = det.getPeriod(); { std::ostringstream oss; - proxy.Call("period", {"220ns"}, -1, PUT, oss); + caller.call("period", {"220ns"}, -1, PUT, oss); REQUIRE(oss.str() == "period 220ns\n"); } { std::ostringstream oss; - proxy.Call("period", {}, -1, GET, oss); + caller.call("period", {}, -1, GET, oss); REQUIRE(oss.str() == "period 221ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -90,12 +90,12 @@ TEST_CASE("timegotthard2", "[.cmd]") { prev_val = det.getPeriod(); { std::ostringstream oss; - proxy.Call("period", {"220ns"}, -1, PUT, oss); + caller.call("period", {"220ns"}, -1, PUT, oss); REQUIRE(oss.str() == "period 220ns\n"); } { std::ostringstream oss; - proxy.Call("period", {}, -1, GET, oss); + caller.call("period", {}, -1, GET, oss); REQUIRE(oss.str() == "period 221ns\n"); } for (int i = 0; i != det.size(); ++i) { @@ -106,180 +106,200 @@ TEST_CASE("timegotthard2", "[.cmd]") { } /* dacs */ -TEST_CASE("Setting and reading back GOTTHARD2 dacs", "[.cmd][.dacs]") { +TEST_CASE("Caller::Setting and reading back GOTTHARD2 dacs", + "[.cmdcall][.dacs]") { // vref_h_adc, vb_comp_fe, vb_comp_adc, vcom_cds, // vref_restore, vb_opa_1st, vref_comp_fe, vcom_adc1, // vref_prech, vref_l_adc, vref_cds, vb_cs, // vb_opa_fd, vcom_adc2 Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vref_h_adc") { - test_dac(defs::VREF_H_ADC, "vref_h_adc", 2099); + test_dac_caller(defs::VREF_H_ADC, "vref_h_adc", 2099); + } + SECTION("vb_comp_fe") { + test_dac_caller(defs::VB_COMP_FE, "vb_comp_fe", 0); } - SECTION("vb_comp_fe") { test_dac(defs::VB_COMP_FE, "vb_comp_fe", 0); } SECTION("vb_comp_adc") { - test_dac(defs::VB_COMP_ADC, "vb_comp_adc", 0); + test_dac_caller(defs::VB_COMP_ADC, "vb_comp_adc", 0); + } + SECTION("vcom_cds") { + test_dac_caller(defs::VCOM_CDS, "vcom_cds", 1400); } - SECTION("vcom_cds") { test_dac(defs::VCOM_CDS, "vcom_cds", 1400); } SECTION("vref_rstore") { - test_dac(defs::VREF_RSTORE, "vref_rstore", 640); + test_dac_caller(defs::VREF_RSTORE, "vref_rstore", 640); + } + SECTION("vb_opa_1st") { + test_dac_caller(defs::VB_OPA_1ST, "vb_opa_1st", 0); } - SECTION("vb_opa_1st") { test_dac(defs::VB_OPA_1ST, "vb_opa_1st", 0); } SECTION("vref_comp_fe") { - test_dac(defs::VREF_COMP_FE, "vref_comp_fe", 0); + test_dac_caller(defs::VREF_COMP_FE, "vref_comp_fe", 0); + } + SECTION("vcom_adc1") { + test_dac_caller(defs::VCOM_ADC1, "vcom_adc1", 1400); } - SECTION("vcom_adc1") { test_dac(defs::VCOM_ADC1, "vcom_adc1", 1400); } SECTION("vref_prech") { - test_dac(defs::VREF_PRECH, "vref_prech", 1720); + test_dac_caller(defs::VREF_PRECH, "vref_prech", 1720); + } + SECTION("vref_l_adc") { + test_dac_caller(defs::VREF_L_ADC, "vref_l_adc", 700); + } + SECTION("vref_cds") { + test_dac_caller(defs::VREF_CDS, "vref_cds", 1200); + } + SECTION("vb_cs") { test_dac_caller(defs::VB_CS, "vb_cs", 2799); } + SECTION("vb_opa_fd") { + test_dac_caller(defs::VB_OPA_FD, "vb_opa_fd", 0); + } + SECTION("vcom_adc2") { + test_dac_caller(defs::VCOM_ADC2, "vcom_adc2", 1400); } - SECTION("vref_l_adc") { test_dac(defs::VREF_L_ADC, "vref_l_adc", 700); } - SECTION("vref_cds") { test_dac(defs::VREF_CDS, "vref_cds", 1200); } - SECTION("vb_cs") { test_dac(defs::VB_CS, "vb_cs", 2799); } - SECTION("vb_opa_fd") { test_dac(defs::VB_OPA_FD, "vb_opa_fd", 0); } - SECTION("vcom_adc2") { test_dac(defs::VCOM_ADC2, "vcom_adc2", 1400); } // eiger - REQUIRE_THROWS(proxy.Call("dac", {"vthreshold"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vsvp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vsvn"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtgstv"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_ll"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_lr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rl"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_rb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_lb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcn"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"iodelay"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vthreshold"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvn"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtgstv"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_ll"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_lr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rl"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_rb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_lb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcn"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"iodelay"}, -1, GET)); // gotthard - REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascn_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascp_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vout_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcasc_out"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"ib_test_c"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascn_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascp_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vout_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcasc_out"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"ib_test_c"}, -1, GET)); // jungfrau - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdd_prot"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_com"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vref_prech"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_pixbuf"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdd_prot"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_com"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vref_prech"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_pixbuf"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); // mythen3 - REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdcsh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth2"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth3"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_p"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcassh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcas"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vicin"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre_out"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vrshaper_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdcsh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vth3"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_n"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal_p"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcassh"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcas"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vicin"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vipre_out"}, -1, GET)); } } /* on chip dacs */ -TEST_CASE("vchip_comp_fe", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_comp_fe", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vchip_comp_fe") { - test_onchip_dac(defs::VB_COMP_FE, "vchip_comp_fe", 0x137); + test_onchip_dac_caller(defs::VB_COMP_FE, "vchip_comp_fe", 0x137); } } else { - REQUIRE_THROWS(proxy.Call("vchip_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_comp_fe", {}, -1, GET)); } } -TEST_CASE("vchip_opa_1st", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_opa_1st", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vchip_opa_1st") { - test_onchip_dac(defs::VB_OPA_1ST, "vchip_opa_1st", 0x000); + test_onchip_dac_caller(defs::VB_OPA_1ST, "vchip_opa_1st", 0x000); } } else { - REQUIRE_THROWS(proxy.Call("vchip_opa_1st", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_opa_1st", {}, -1, GET)); } } -TEST_CASE("vchip_opa_fd", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_opa_fd", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vchip_opa_fd") { - test_onchip_dac(defs::VB_OPA_FD, "vchip_opa_fd", 0x134); + test_onchip_dac_caller(defs::VB_OPA_FD, "vchip_opa_fd", 0x134); } } else { - REQUIRE_THROWS(proxy.Call("vchip_opa_fd", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_opa_fd", {}, -1, GET)); } } -TEST_CASE("vchip_comp_adc", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_comp_adc", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vchip_comp_adc") { - test_onchip_dac(defs::VB_COMP_ADC, "vchip_comp_adc", 0x3FF); + test_onchip_dac_caller(defs::VB_COMP_ADC, "vchip_comp_adc", 0x3FF); } } else { - REQUIRE_THROWS(proxy.Call("vchip_comp_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_comp_adc", {}, -1, GET)); } } -TEST_CASE("vchip_ref_comp_fe", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_ref_comp_fe", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { SECTION("vchip_ref_comp_fe") { - test_onchip_dac(defs::VREF_COMP_FE, "vchip_ref_comp_fe", 0x100); + test_onchip_dac_caller(defs::VREF_COMP_FE, "vchip_ref_comp_fe", + 0x100); } } else { - REQUIRE_THROWS(proxy.Call("vchip_ref_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_ref_comp_fe", {}, -1, GET)); } } -TEST_CASE("vchip_cs", "[.cmd][.onchipdacs]") { +TEST_CASE("Caller::vchip_cs", "[.cmdcall][.onchipdacs]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - SECTION("vchip_cs") { test_onchip_dac(defs::VB_CS, "vchip_cs", 0x0D0); } + SECTION("vchip_cs") { + test_onchip_dac_caller(defs::VB_CS, "vchip_cs", 0x0D0); + } } else { - REQUIRE_THROWS(proxy.Call("vchip_cs", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vchip_cs", {}, -1, GET)); } } /* Gotthard2 Specific */ -TEST_CASE("bursts", "[.cmd]") { +TEST_CASE("Caller::bursts", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_burst = @@ -295,26 +315,26 @@ TEST_CASE("bursts", "[.cmd]") { det.setTimingMode(defs::AUTO_TIMING); { std::ostringstream oss; - proxy.Call("bursts", {"3"}, -1, PUT, oss); + caller.call("bursts", {"3"}, -1, PUT, oss); REQUIRE(oss.str() == "bursts 3\n"); } { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } - REQUIRE_THROWS(proxy.Call("bursts", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("bursts", {"0"}, -1, PUT)); // trigger mode: reg set to 1, but bursts must be same det.setTimingMode(defs::TRIGGER_EXPOSURE); { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } det.setTimingMode(defs::AUTO_TIMING); { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } // continuous mode: reg set to #frames, @@ -323,19 +343,19 @@ TEST_CASE("bursts", "[.cmd]") { det.setNumberOfFrames(2); { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } det.setTimingMode(defs::TRIGGER_EXPOSURE); { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } det.setBurstMode(defs::BURST_INTERNAL); { std::ostringstream oss; - proxy.Call("bursts", {}, -1, GET, oss); + caller.call("bursts", {}, -1, GET, oss); REQUIRE(oss.str() == "bursts 3\n"); } // set to previous values @@ -347,122 +367,122 @@ TEST_CASE("bursts", "[.cmd]") { det.setBurstMode(prev_burstMode[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("bursts", {}, -1, GET)); + REQUIRE_THROWS(caller.call("bursts", {}, -1, GET)); } } -TEST_CASE("burstperiod", "[.cmd]") { +TEST_CASE("Caller::burstperiod", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto previous = det.getBurstPeriod(); std::ostringstream oss_set, oss_get; - proxy.Call("burstperiod", {"30ms"}, -1, PUT, oss_set); + caller.call("burstperiod", {"30ms"}, -1, PUT, oss_set); REQUIRE(oss_set.str() == "burstperiod 30ms\n"); - proxy.Call("burstperiod", {}, -1, GET, oss_get); + caller.call("burstperiod", {}, -1, GET, oss_get); REQUIRE(oss_get.str() == "burstperiod 30ms\n"); // Reset to previous value for (int i = 0; i != det.size(); ++i) { det.setBurstPeriod(previous[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("burstperiod", {}, -1, GET)); + REQUIRE_THROWS(caller.call("burstperiod", {}, -1, GET)); } } -TEST_CASE("burstsl", "[.cmd]") { +TEST_CASE("Caller::burstsl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - REQUIRE_NOTHROW(proxy.Call("burstsl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("burstsl", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("burstsl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("burstsl", {}, -1, GET)); } } -TEST_CASE("inj_ch", "[.cmd]") { +TEST_CASE("Caller::inj_ch", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { REQUIRE_THROWS( - proxy.Call("inj_ch", {"-1", "1"}, -1, PUT)); // invalid offset + caller.call("inj_ch", {"-1", "1"}, -1, PUT)); // invalid offset REQUIRE_THROWS( - proxy.Call("inj_ch", {"0", "0"}, -1, PUT)); // invalid increment + caller.call("inj_ch", {"0", "0"}, -1, PUT)); // invalid increment { std::ostringstream oss; - proxy.Call("inj_ch", {"0", "1"}, -1, PUT, oss); + caller.call("inj_ch", {"0", "1"}, -1, PUT, oss); REQUIRE(oss.str() == "inj_ch [0, 1]\n"); } { std::ostringstream oss; - proxy.Call("inj_ch", {}, -1, GET, oss); + caller.call("inj_ch", {}, -1, GET, oss); REQUIRE(oss.str() == "inj_ch [0, 1]\n"); } } else { - REQUIRE_THROWS(proxy.Call("inj_ch", {}, -1, GET)); + REQUIRE_THROWS(caller.call("inj_ch", {}, -1, GET)); } } -TEST_CASE("vetophoton", "[.cmd]") { +TEST_CASE("Caller::vetophoton", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("vetophoton", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetophoton", {"-1"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetophoton", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vetophoton", {"-1"}, -1, GET)); REQUIRE_NOTHROW( - proxy.Call("vetophoton", {"-1", "/tmp/bla.txt"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetophoton", {"12", "1", "39950"}, -1, - PUT)); // invalid chip index - REQUIRE_THROWS(proxy.Call("vetophoton", {"-1", "0"}, -1, - PUT)); // invalid photon number - REQUIRE_THROWS(proxy.Call("vetophoton", {"-1", "1", "39950"}, -1, - PUT)); // invald file + caller.call("vetophoton", {"-1", "/tmp/bla.txt"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetophoton", {"12", "1", "39950"}, -1, + PUT)); // invalid chip index + REQUIRE_THROWS(caller.call("vetophoton", {"-1", "0"}, -1, + PUT)); // invalid photon number + REQUIRE_THROWS(caller.call("vetophoton", {"-1", "1", "39950"}, -1, + PUT)); // invald file } else { REQUIRE_THROWS( - proxy.Call("vetophoton", {"-1", "/tmp/bla.txt"}, -1, GET)); + caller.call("vetophoton", {"-1", "/tmp/bla.txt"}, -1, GET)); } } -TEST_CASE("vetoref", "[.cmd]") { +TEST_CASE("Caller::vetoref", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("vetoref", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetoref", {"3", "0x3ff"}, -1, - PUT)); // invalid chip index - REQUIRE_NOTHROW(proxy.Call("vetoref", {"1", "0x010"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetoref", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vetoref", {"3", "0x3ff"}, -1, + PUT)); // invalid chip index + REQUIRE_NOTHROW(caller.call("vetoref", {"1", "0x010"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("vetoref", {"3", "0x0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetoref", {"3", "0x0"}, -1, PUT)); } } -TEST_CASE("vetofile", "[.cmd]") { +TEST_CASE("Caller::vetofile", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("vetofile", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetofile", {"12", "/tmp/bla.txt"}, -1, - PUT)); // invalid chip index + REQUIRE_THROWS(caller.call("vetofile", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vetofile", {"12", "/tmp/bla.txt"}, -1, + PUT)); // invalid chip index } else { - REQUIRE_THROWS(proxy.Call("vetofile", {"-1"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetofile", {"-1"}, -1, GET)); } } -TEST_CASE("burstmode", "[.cmd]") { +TEST_CASE("Caller::burstmode", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { @@ -470,166 +490,166 @@ TEST_CASE("burstmode", "[.cmd]") { auto burststr = ToString(burst); { std::ostringstream oss; - proxy.Call("burstmode", {"burst_internal"}, -1, PUT, oss); + caller.call("burstmode", {"burst_internal"}, -1, PUT, oss); REQUIRE(oss.str() == "burstmode burst_internal\n"); } { std::ostringstream oss; - proxy.Call("burstmode", {"cw_internal"}, -1, PUT, oss); + caller.call("burstmode", {"cw_internal"}, -1, PUT, oss); REQUIRE(oss.str() == "burstmode cw_internal\n"); } { std::ostringstream oss; - proxy.Call("burstmode", {}, -1, GET, oss); + caller.call("burstmode", {}, -1, GET, oss); REQUIRE(oss.str() == "burstmode cw_internal\n"); } for (int i = 0; i != det.size(); ++i) { det.setBurstMode(burst[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("burstmode", {}, -1, GET)); + REQUIRE_THROWS(caller.call("burstmode", {}, -1, GET)); } } -TEST_CASE("cdsgain", "[.cmd]") { +TEST_CASE("Caller::cdsgain", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_val = det.getCDSGain(); { std::ostringstream oss; - proxy.Call("cdsgain", {"1"}, -1, PUT, oss); + caller.call("cdsgain", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "cdsgain 1\n"); } { std::ostringstream oss; - proxy.Call("cdsgain", {"0"}, -1, PUT, oss); + caller.call("cdsgain", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "cdsgain 0\n"); } { std::ostringstream oss; - proxy.Call("cdsgain", {}, -1, GET, oss); + caller.call("cdsgain", {}, -1, GET, oss); REQUIRE(oss.str() == "cdsgain 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setCDSGain(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("cdsgain", {}, -1, GET)); + REQUIRE_THROWS(caller.call("cdsgain", {}, -1, GET)); } } -TEST_CASE("timingsource", "[.cmd]") { +TEST_CASE("Caller::timingsource", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_val = det.getTimingSource(); /* { until its activated in fpga std::ostringstream oss; - proxy.Call("timingsource", {"external"}, -1, PUT, oss); + caller.call("timingsource", {"external"}, -1, PUT, oss); REQUIRE(oss.str() == "timingsource external\n"); }*/ { std::ostringstream oss; - proxy.Call("timingsource", {"internal"}, -1, PUT, oss); + caller.call("timingsource", {"internal"}, -1, PUT, oss); REQUIRE(oss.str() == "timingsource internal\n"); } { std::ostringstream oss; - proxy.Call("timingsource", {}, -1, GET, oss); + caller.call("timingsource", {}, -1, GET, oss); REQUIRE(oss.str() == "timingsource internal\n"); } for (int i = 0; i != det.size(); ++i) { det.setTimingSource(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("timingsource", {}, -1, GET)); + REQUIRE_THROWS(caller.call("timingsource", {}, -1, GET)); } } -TEST_CASE("veto", "[.cmd]") { +TEST_CASE("Caller::veto", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_val = det.getVeto(); { std::ostringstream oss; - proxy.Call("veto", {"1"}, -1, PUT, oss); + caller.call("veto", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "veto 1\n"); } { std::ostringstream oss; - proxy.Call("veto", {"0"}, -1, PUT, oss); + caller.call("veto", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "veto 0\n"); } { std::ostringstream oss; - proxy.Call("veto", {}, -1, GET, oss); + caller.call("veto", {}, -1, GET, oss); REQUIRE(oss.str() == "veto 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setVeto(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("veto", {}, -1, GET)); + REQUIRE_THROWS(caller.call("veto", {}, -1, GET)); } } -TEST_CASE("vetostream", "[.cmd]") { +TEST_CASE("Caller::vetostream", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_val = det.getVetoStream().tsquash("inconsistent veto stream to test"); { std::ostringstream oss; - proxy.Call("vetostream", {"none"}, -1, PUT, oss); + caller.call("vetostream", {"none"}, -1, PUT, oss); REQUIRE(oss.str() == "vetostream none\n"); } { std::ostringstream oss; - proxy.Call("vetostream", {}, -1, GET, oss); + caller.call("vetostream", {}, -1, GET, oss); REQUIRE(oss.str() == "vetostream none\n"); } { std::ostringstream oss; - proxy.Call("vetostream", {"lll"}, -1, PUT, oss); + caller.call("vetostream", {"lll"}, -1, PUT, oss); REQUIRE(oss.str() == "vetostream lll\n"); } { std::ostringstream oss; - proxy.Call("vetostream", {}, -1, GET, oss); + caller.call("vetostream", {}, -1, GET, oss); REQUIRE(oss.str() == "vetostream lll\n"); } { std::ostringstream oss; - proxy.Call("vetostream", {"lll", "10gbe"}, -1, PUT, oss); + caller.call("vetostream", {"lll", "10gbe"}, -1, PUT, oss); REQUIRE(oss.str() == "vetostream lll, 10gbe\n"); } { std::ostringstream oss; - proxy.Call("vetostream", {}, -1, GET, oss); + caller.call("vetostream", {}, -1, GET, oss); REQUIRE(oss.str() == "vetostream lll, 10gbe\n"); } - REQUIRE_THROWS(proxy.Call("vetostream", {"lll", "none"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetostream", {"lll", "none"}, -1, PUT)); det.setVetoStream(prev_val); } else { - REQUIRE_THROWS(proxy.Call("vetostream", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetostream", {"none"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetostream", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vetostream", {"none"}, -1, PUT)); } - REQUIRE_THROWS(proxy.Call("vetostream", {"dfgd"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetostream", {"dfgd"}, -1, GET)); } -TEST_CASE("vetoalg", "[.cmd]") { +TEST_CASE("Caller::vetoalg", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { auto prev_val_lll = @@ -638,37 +658,37 @@ TEST_CASE("vetoalg", "[.cmd]") { det.getVetoAlgorithm(defs::streamingInterface::ETHERNET_10GB); { std::ostringstream oss; - proxy.Call("vetoalg", {"hits", "lll"}, -1, PUT, oss); + caller.call("vetoalg", {"hits", "lll"}, -1, PUT, oss); REQUIRE(oss.str() == "vetoalg hits lll\n"); } { std::ostringstream oss; - proxy.Call("vetoalg", {"lll"}, -1, GET, oss); + caller.call("vetoalg", {"lll"}, -1, GET, oss); REQUIRE(oss.str() == "vetoalg hits lll\n"); } { std::ostringstream oss; - proxy.Call("vetoalg", {"hits", "10gbe"}, -1, PUT, oss); + caller.call("vetoalg", {"hits", "10gbe"}, -1, PUT, oss); REQUIRE(oss.str() == "vetoalg hits 10gbe\n"); } { std::ostringstream oss; - proxy.Call("vetoalg", {"10gbe"}, -1, GET, oss); + caller.call("vetoalg", {"10gbe"}, -1, GET, oss); REQUIRE(oss.str() == "vetoalg hits 10gbe\n"); } { std::ostringstream oss; - proxy.Call("vetoalg", {"raw", "lll"}, -1, PUT, oss); + caller.call("vetoalg", {"raw", "lll"}, -1, PUT, oss); REQUIRE(oss.str() == "vetoalg raw lll\n"); } { std::ostringstream oss; - proxy.Call("vetoalg", {"raw", "10gbe"}, -1, PUT, oss); + caller.call("vetoalg", {"raw", "10gbe"}, -1, PUT, oss); REQUIRE(oss.str() == "vetoalg raw 10gbe\n"); } REQUIRE_THROWS( - proxy.Call("vetoalg", {"default", "lll", "10gbe"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("vetoalg", {"hits", "none"}, -1, PUT)); + caller.call("vetoalg", {"default", "lll", "10gbe"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetoalg", {"hits", "none"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setVetoAlgorithm(prev_val_lll[i], defs::streamingInterface::LOW_LATENCY_LINK, @@ -677,22 +697,23 @@ TEST_CASE("vetoalg", "[.cmd]") { defs::streamingInterface::ETHERNET_10GB, {i}); } } else { - REQUIRE_THROWS(proxy.Call("vetoalg", {"lll"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vetoalg", {"none"}, -1, PUT)); + REQUIRE_THROWS(caller.call("vetoalg", {"lll"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetoalg", {"none"}, -1, PUT)); } - REQUIRE_THROWS(proxy.Call("vetoalg", {"dfgd"}, -1, GET)); + REQUIRE_THROWS(caller.call("vetoalg", {"dfgd"}, -1, GET)); } -TEST_CASE("confadc", "[.cmd]") { +TEST_CASE("Caller::confadc", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2) { - int ndet = det.size(); - int nchip = 10; - int nadc = 32; - int prev_val[ndet][nchip][nadc]; + const int ndet = det.size(); + const int nchip = 10; + const int nadc = 32; + std::vector>> prev_val( + ndet, std::vector>(nchip, std::vector(nadc))); for (int i = 0; i != ndet; ++i) { for (int j = 0; j != nchip; ++j) { for (int k = 0; k != nadc; ++k) { @@ -702,20 +723,20 @@ TEST_CASE("confadc", "[.cmd]") { } } - REQUIRE_THROWS(proxy.Call("confadc", {"11", "2", "0x7f"}, -1, - PUT)); // invalid chip index - REQUIRE_THROWS(proxy.Call("confadc", {"-1", "32", "0x7f"}, -1, - PUT)); // invalid adc index - REQUIRE_THROWS(proxy.Call("confadc", {"-1", "10", "0x80"}, -1, - PUT)); // invalid value + REQUIRE_THROWS(caller.call("confadc", {"11", "2", "0x7f"}, -1, + PUT)); // invalid chip index + REQUIRE_THROWS(caller.call("confadc", {"-1", "32", "0x7f"}, -1, + PUT)); // invalid adc index + REQUIRE_THROWS(caller.call("confadc", {"-1", "10", "0x80"}, -1, + PUT)); // invalid value { std::ostringstream oss; - proxy.Call("confadc", {"-1", "-1", "0x11"}, -1, PUT, oss); + caller.call("confadc", {"-1", "-1", "0x11"}, -1, PUT, oss); REQUIRE(oss.str() == "confadc [-1, -1, 0x11]\n"); } { std::ostringstream oss; - proxy.Call("confadc", {"2", "3"}, -1, GET, oss); + caller.call("confadc", {"2", "3"}, -1, GET, oss); REQUIRE(oss.str() == "confadc 0x11\n"); } @@ -727,7 +748,7 @@ TEST_CASE("confadc", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("confadc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("confadc", {}, -1, GET)); } } diff --git a/slsDetectorSoftware/tests/test-CmdProxy-jungfrau.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-jungfrau.cpp similarity index 53% rename from slsDetectorSoftware/tests/test-CmdProxy-jungfrau.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-jungfrau.cpp index f069a6f5d..767d3d270 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-jungfrau.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-jungfrau.cpp @@ -1,13 +1,13 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" #include #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -17,275 +17,282 @@ using test::PUT; /* dacs */ -TEST_CASE("Setting and reading back Jungfrau dacs", "[.cmd][.dacs]") { +TEST_CASE("Caller::Setting and reading back Jungfrau dacs", + "[.cmdcall][.dacs]") { // vb_comp, vdd_prot, vin_com, vref_prech, vb_pixbuf, vb_ds, vref_ds, // vref_comp Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - SECTION("vb_comp") { test_dac(defs::VB_COMP, "vb_comp", 1220); } - SECTION("vdd_prot") { test_dac(defs::VDD_PROT, "vdd_prot", 3000); } - SECTION("vin_com") { test_dac(defs::VIN_COM, "vin_com", 1053); } - SECTION("vref_prech") { - test_dac(defs::VREF_PRECH, "vref_prech", 1450); + if (det_type == defs::JUNGFRAU) { + SECTION("vb_comp") { test_dac_caller(defs::VB_COMP, "vb_comp", 1220); } + SECTION("vdd_prot") { + test_dac_caller(defs::VDD_PROT, "vdd_prot", 3000); + } + SECTION("vin_com") { test_dac_caller(defs::VIN_COM, "vin_com", 1053); } + SECTION("vref_prech") { + test_dac_caller(defs::VREF_PRECH, "vref_prech", 1450); + } + SECTION("vb_pixbuf") { + test_dac_caller(defs::VB_PIXBUF, "vb_pixbuf", 750); + } + SECTION("vb_ds") { test_dac_caller(defs::VB_DS, "vb_ds", 1000); } + SECTION("vref_ds") { test_dac_caller(defs::VREF_DS, "vref_ds", 480); } + SECTION("vref_comp") { + test_dac_caller(defs::VREF_COMP, "vref_comp", 420); } - SECTION("vb_pixbuf") { test_dac(defs::VB_PIXBUF, "vb_pixbuf", 750); } - SECTION("vb_ds") { test_dac(defs::VB_DS, "vb_ds", 1000); } - SECTION("vref_ds") { test_dac(defs::VREF_DS, "vref_ds", 480); } - SECTION("vref_comp") { test_dac(defs::VREF_COMP, "vref_comp", 420); } // eiger - REQUIRE_THROWS(proxy.Call("vthreshold", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vsvp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vsvn", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vtrim", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vrpreamp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vrshaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vtgstv", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcmp_ll", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcmp_lr", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcal", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcmp_rl", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcmp_rr", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("rxb_rb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("rxb_lb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcn", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vishaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("iodelay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vthreshold", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vsvp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vsvn", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtrim", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrpreamp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtgstv", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_ll", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_lr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_rl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_rr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("rxb_rb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("rxb_lb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcn", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vishaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("iodelay", {}, -1, GET)); // gotthard - // REQUIRE_THROWS(proxy.Call("vref_ds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcascn_pb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcascp_pb", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vout_cm", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcasc_out", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vin_cm", {}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("vref_comp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("ib_test_c", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vref_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascn_pb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascp_pb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vout_cm", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcasc_out", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vin_cm", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vref_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("ib_test_c", {}, -1, GET)); // mythen3 - REQUIRE_THROWS(proxy.Call("vrpreamp", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vrshaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vrshaper_n", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vipre", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vishaper", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vdcsh", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth1", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth2", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vth3", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcal_n", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcal_p", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vtrim", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcassh", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcas", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vicin", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vipre_out", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrpreamp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper_n", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vipre", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vishaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vdcsh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth3", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_n", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_p", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtrim", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcassh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcas", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vicin", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vipre_out", {}, -1, GET)); // gotthard2 - REQUIRE_THROWS(proxy.Call("vref_h_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_comp_fe", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_comp_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_cds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_rstore", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_opa_1st", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_comp_fe", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_adc1", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_l_adc", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vref_cds", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_cs", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vb_opa_fd", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("vcom_adc2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_h_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_rstore", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_1st", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_l_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_cs", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_fd", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc2", {}, -1, GET)); } } /* Network Configuration (Detector<->Receiver) */ -TEST_CASE("selinterface", "[.cmd]") { +TEST_CASE("Caller::selinterface", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_val = det.getSelectedUDPInterface().tsquash( "inconsistent selected interface to test"); { std::ostringstream oss; - proxy.Call("selinterface", {"1"}, -1, PUT, oss); + caller.call("selinterface", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "selinterface 1\n"); } { std::ostringstream oss; - proxy.Call("selinterface", {"0"}, -1, PUT, oss); + caller.call("selinterface", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "selinterface 0\n"); } { std::ostringstream oss; - proxy.Call("selinterface", {}, -1, GET, oss); + caller.call("selinterface", {}, -1, GET, oss); REQUIRE(oss.str() == "selinterface 0\n"); } det.selectUDPInterface(prev_val); - REQUIRE_THROWS(proxy.Call("selinterface", {"2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("selinterface", {"2"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("selinterface", {}, -1, GET)); + REQUIRE_THROWS(caller.call("selinterface", {}, -1, GET)); } } /* Jungfrau/moench Specific */ -TEST_CASE("temp_threshold", "[.cmd]") { +TEST_CASE("Caller::temp_threshold", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_val = det.getThresholdTemperature(); { std::ostringstream oss; - proxy.Call("temp_threshold", {"65"}, -1, PUT, oss); + caller.call("temp_threshold", {"65"}, -1, PUT, oss); REQUIRE(oss.str() == "temp_threshold 65\n"); } { std::ostringstream oss; - proxy.Call("temp_threshold", {"70"}, -1, PUT, oss); + caller.call("temp_threshold", {"70"}, -1, PUT, oss); REQUIRE(oss.str() == "temp_threshold 70\n"); } { std::ostringstream oss; - proxy.Call("temp_threshold", {}, -1, GET, oss); + caller.call("temp_threshold", {}, -1, GET, oss); REQUIRE(oss.str() == "temp_threshold 70\n"); } for (int i = 0; i != det.size(); ++i) { det.setThresholdTemperature(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("temp_threshold", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("temp_threshold", {"70"}, -1, PUT)); + REQUIRE_THROWS(caller.call("temp_threshold", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_threshold", {"70"}, -1, PUT)); } } -TEST_CASE("chipversion", "[.cmd]") { +TEST_CASE("Caller::chipversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - REQUIRE_NOTHROW(proxy.Call("chipversion", {}, -1, GET)); + if (det_type == defs::JUNGFRAU) { + REQUIRE_NOTHROW(caller.call("chipversion", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("chipversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("chipversion", {}, -1, GET)); } - REQUIRE_THROWS(proxy.Call("chipversion", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("chipversion", {"0"}, -1, PUT)); } -TEST_CASE("temp_control", "[.cmd]") { +TEST_CASE("Caller::temp_control", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_val = det.getTemperatureControl(); { std::ostringstream oss; - proxy.Call("temp_control", {"0"}, -1, PUT, oss); + caller.call("temp_control", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "temp_control 0\n"); } { std::ostringstream oss; - proxy.Call("temp_control", {"1"}, -1, PUT, oss); + caller.call("temp_control", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "temp_control 1\n"); } { std::ostringstream oss; - proxy.Call("temp_control", {}, -1, GET, oss); + caller.call("temp_control", {}, -1, GET, oss); REQUIRE(oss.str() == "temp_control 1\n"); } for (int i = 0; i != det.size(); ++i) { det.setTemperatureControl(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("temp_control", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("temp_control", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("temp_control", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_control", {"0"}, -1, PUT)); } } -TEST_CASE("temp_event", "[.cmd]") { +TEST_CASE("Caller::temp_event", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { { std::ostringstream oss; - proxy.Call("temp_event", {"0"}, -1, PUT, oss); + caller.call("temp_event", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "temp_event cleared\n"); } { std::ostringstream oss; - proxy.Call("temp_event", {}, -1, GET, oss); + caller.call("temp_event", {}, -1, GET, oss); REQUIRE(oss.str() == "temp_event 0\n"); } } else { - REQUIRE_THROWS(proxy.Call("temp_event", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("temp_event", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("temp_event", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_event", {"0"}, -1, PUT)); } } -TEST_CASE("autocompdisable", "[.cmd]") { +TEST_CASE("Caller::autocompdisable", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { auto prev_val = det.getAutoComparatorDisable(); { std::ostringstream oss; - proxy.Call("autocompdisable", {"0"}, -1, PUT, oss); + caller.call("autocompdisable", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "autocompdisable 0\n"); } { std::ostringstream oss; - proxy.Call("autocompdisable", {"1"}, -1, PUT, oss); + caller.call("autocompdisable", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "autocompdisable 1\n"); } { std::ostringstream oss; - proxy.Call("autocompdisable", {}, -1, GET, oss); + caller.call("autocompdisable", {}, -1, GET, oss); REQUIRE(oss.str() == "autocompdisable 1\n"); } for (int i = 0; i != det.size(); ++i) { det.setAutoComparatorDisable(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("autocompdisable", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("autocompdisable", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("autocompdisable", {}, -1, GET)); + REQUIRE_THROWS(caller.call("autocompdisable", {"0"}, -1, PUT)); } } -TEST_CASE("compdisabletime", "[.cmd]") { +TEST_CASE("Caller::compdisabletime", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU && det.getChipVersion().squash() * 10 == 11) { auto prev_val = det.getComparatorDisableTime(); { std::ostringstream oss; - proxy.Call("compdisabletime", {"125ns"}, -1, PUT, oss); + caller.call("compdisabletime", {"125ns"}, -1, PUT, oss); REQUIRE(oss.str() == "compdisabletime 125ns\n"); } { std::ostringstream oss; - proxy.Call("compdisabletime", {}, -1, GET, oss); + caller.call("compdisabletime", {}, -1, GET, oss); REQUIRE(oss.str() == "compdisabletime 125ns\n"); } { std::ostringstream oss; - proxy.Call("compdisabletime", {"0"}, -1, PUT, oss); + caller.call("compdisabletime", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "compdisabletime 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setComparatorDisableTime(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("compdisabletime", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("compdisabletime", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("compdisabletime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("compdisabletime", {"0"}, -1, PUT)); } } -TEST_CASE("extrastoragecells", "[.cmd]") { +TEST_CASE("Caller::extrastoragecells", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { // chip version 1.0 @@ -294,86 +301,86 @@ TEST_CASE("extrastoragecells", "[.cmd]") { "inconsistent #additional storage cells to test"); { std::ostringstream oss; - proxy.Call("extrastoragecells", {"1"}, -1, PUT, oss); + caller.call("extrastoragecells", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "extrastoragecells 1\n"); } { std::ostringstream oss; - proxy.Call("extrastoragecells", {"15"}, -1, PUT, oss); + caller.call("extrastoragecells", {"15"}, -1, PUT, oss); REQUIRE(oss.str() == "extrastoragecells 15\n"); } { std::ostringstream oss; - proxy.Call("extrastoragecells", {"0"}, -1, PUT, oss); + caller.call("extrastoragecells", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "extrastoragecells 0\n"); } { std::ostringstream oss; - proxy.Call("extrastoragecells", {}, -1, GET, oss); + caller.call("extrastoragecells", {}, -1, GET, oss); REQUIRE(oss.str() == "extrastoragecells 0\n"); } - REQUIRE_THROWS(proxy.Call("extrastoragecells", {"16"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extrastoragecells", {"16"}, -1, PUT)); det.setNumberOfAdditionalStorageCells(prev_val); } // chip version 1.1 else { // cannot set number of addl. storage cells - REQUIRE_THROWS(proxy.Call("extrastoragecells", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extrastoragecells", {"1"}, -1, PUT)); } } else { - REQUIRE_THROWS(proxy.Call("extrastoragecells", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("extrastoragecells", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extrastoragecells", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extrastoragecells", {"0"}, -1, PUT)); } } -TEST_CASE("storagecell_start", "[.cmd]") { +TEST_CASE("Caller::storagecell_start", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { auto prev_val = det.getStorageCellStart(); { std::ostringstream oss; - proxy.Call("storagecell_start", {"1"}, -1, PUT, oss); + caller.call("storagecell_start", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_start 1\n"); } // chip version 1.0 if (det.getChipVersion().squash() * 10 == 10) { std::ostringstream oss; - proxy.Call("storagecell_start", {"15"}, -1, PUT, oss); + caller.call("storagecell_start", {"15"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_start 15\n"); } // chip version 1.1 else { // max is 3 - REQUIRE_THROWS(proxy.Call("storagecell_start", {"15"}, -1, PUT)); + REQUIRE_THROWS(caller.call("storagecell_start", {"15"}, -1, PUT)); std::ostringstream oss; - proxy.Call("storagecell_start", {"3"}, -1, PUT, oss); + caller.call("storagecell_start", {"3"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_start 3\n"); } { std::ostringstream oss; - proxy.Call("storagecell_start", {"0"}, -1, PUT, oss); + caller.call("storagecell_start", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_start 0\n"); } { std::ostringstream oss; - proxy.Call("storagecell_start", {}, -1, GET, oss); + caller.call("storagecell_start", {}, -1, GET, oss); REQUIRE(oss.str() == "storagecell_start 0\n"); } - REQUIRE_THROWS(proxy.Call("storagecell_start", {"16"}, -1, PUT)); + REQUIRE_THROWS(caller.call("storagecell_start", {"16"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setStorageCellStart(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("storagecell_start", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("storagecell_start", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("storagecell_start", {}, -1, GET)); + REQUIRE_THROWS(caller.call("storagecell_start", {"0"}, -1, PUT)); } } -TEST_CASE("storagecell_delay", "[.cmd]") { +TEST_CASE("Caller::storagecell_delay", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { // chip version 1.0 @@ -381,21 +388,21 @@ TEST_CASE("storagecell_delay", "[.cmd]") { auto prev_val = det.getStorageCellDelay(); { std::ostringstream oss; - proxy.Call("storagecell_delay", {"1.62ms"}, -1, PUT, oss); + caller.call("storagecell_delay", {"1.62ms"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_delay 1.62ms\n"); } { std::ostringstream oss; - proxy.Call("storagecell_delay", {}, -1, GET, oss); + caller.call("storagecell_delay", {}, -1, GET, oss); REQUIRE(oss.str() == "storagecell_delay 1.62ms\n"); } { std::ostringstream oss; - proxy.Call("storagecell_delay", {"0"}, -1, PUT, oss); + caller.call("storagecell_delay", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "storagecell_delay 0\n"); } REQUIRE_THROWS( - proxy.Call("storagecell_delay", {"1638376ns"}, -1, PUT)); + caller.call("storagecell_delay", {"1638376ns"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setStorageCellDelay(prev_val[i], {i}); } @@ -404,66 +411,66 @@ TEST_CASE("storagecell_delay", "[.cmd]") { else { // cannot set storage cell delay REQUIRE_THROWS( - proxy.Call("storagecell_delay", {"1.62ms"}, -1, PUT)); + caller.call("storagecell_delay", {"1.62ms"}, -1, PUT)); } } else { - REQUIRE_THROWS(proxy.Call("storagecell_delay", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("storagecell_delay", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("storagecell_delay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("storagecell_delay", {"0"}, -1, PUT)); } } -TEST_CASE("gainmode", "[.cmd]") { +TEST_CASE("Caller::gainmode", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { auto prev_val = det.getGainMode(); { std::ostringstream oss; - proxy.Call("gainmode", {"forceswitchg1"}, -1, PUT, oss); + caller.call("gainmode", {"forceswitchg1"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode forceswitchg1\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {}, -1, GET, oss); + caller.call("gainmode", {}, -1, GET, oss); REQUIRE(oss.str() == "gainmode forceswitchg1\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {"dynamic"}, -1, PUT, oss); + caller.call("gainmode", {"dynamic"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode dynamic\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {"forceswitchg2"}, -1, PUT, oss); + caller.call("gainmode", {"forceswitchg2"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode forceswitchg2\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {"fixg1"}, -1, PUT, oss); + caller.call("gainmode", {"fixg1"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode fixg1\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {"fixg2"}, -1, PUT, oss); + caller.call("gainmode", {"fixg2"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode fixg2\n"); } { std::ostringstream oss; - proxy.Call("gainmode", {"fixg0"}, -1, PUT, oss); + caller.call("gainmode", {"fixg0"}, -1, PUT, oss); REQUIRE(oss.str() == "gainmode fixg0\n"); } for (int i = 0; i != det.size(); ++i) { det.setGainMode(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("gainmode", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gainmode", {}, -1, GET)); } } -TEST_CASE("filtercells", "[.cmd]") { +TEST_CASE("Caller::filtercells", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { // chip version 1.1 @@ -471,25 +478,25 @@ TEST_CASE("filtercells", "[.cmd]") { auto prev_val = det.getNumberOfFilterCells(); { std::ostringstream oss; - proxy.Call("filtercells", {"1"}, -1, PUT, oss); + caller.call("filtercells", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "filtercells 1\n"); } { std::ostringstream oss; - proxy.Call("filtercells", {"12"}, -1, PUT, oss); + caller.call("filtercells", {"12"}, -1, PUT, oss); REQUIRE(oss.str() == "filtercells 12\n"); } { std::ostringstream oss; - proxy.Call("filtercells", {"0"}, -1, PUT, oss); + caller.call("filtercells", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "filtercells 0\n"); } { std::ostringstream oss; - proxy.Call("filtercells", {}, -1, GET, oss); + caller.call("filtercells", {}, -1, GET, oss); REQUIRE(oss.str() == "filtercells 0\n"); } - REQUIRE_THROWS(proxy.Call("filtercells", {"13"}, -1, PUT)); + REQUIRE_THROWS(caller.call("filtercells", {"13"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setNumberOfFilterCells(prev_val[i], {i}); } @@ -497,18 +504,17 @@ TEST_CASE("filtercells", "[.cmd]") { // chip version 1.0 else { // cannot set/get filter cell - REQUIRE_THROWS(proxy.Call("filtercells", {"1"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("filtercells", {}, -1, GET)); + REQUIRE_THROWS(caller.call("filtercells", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("filtercells", {}, -1, GET)); } } else { - REQUIRE_THROWS(proxy.Call("filtercells", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("filtercells", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("filtercells", {}, -1, GET)); + REQUIRE_THROWS(caller.call("filtercells", {"0"}, -1, PUT)); } } - -TEST_CASE("pedestalmode", "[.cmd]") { +TEST_CASE("Caller::pedestalmode", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU) { auto prev_val = det.getPedestalMode(); @@ -519,51 +525,51 @@ TEST_CASE("pedestalmode", "[.cmd]") { auto prev_timingmode = det.getTimingMode().tsquash("Inconsistent timing mode to test"); - REQUIRE_NOTHROW(proxy.Call("pedestalmode", {}, 0, GET)); - REQUIRE_NOTHROW(proxy.Call("pedestalmode", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"0"}, -1, GET)); + REQUIRE_NOTHROW(caller.call("pedestalmode", {}, 0, GET)); + REQUIRE_NOTHROW(caller.call("pedestalmode", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pedestalmode", {"0"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"256", "10"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"-1", "10"}, 0, PUT)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"20", "65536"}, 0, PUT)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"20", "-1"}, 0, PUT)); + REQUIRE_THROWS(caller.call("pedestalmode", {"256", "10"}, -1, PUT)); + REQUIRE_THROWS(caller.call("pedestalmode", {"-1", "10"}, 0, PUT)); + REQUIRE_THROWS(caller.call("pedestalmode", {"20", "65536"}, 0, PUT)); + REQUIRE_THROWS(caller.call("pedestalmode", {"20", "-1"}, 0, PUT)); { std::ostringstream oss; - proxy.Call("pedestalmode", {"30", "1000"}, -1, PUT, oss); + caller.call("pedestalmode", {"30", "1000"}, -1, PUT, oss); REQUIRE(oss.str() == "pedestalmode [30, 1000]\n"); } // cannot change any of these in pedestal mode - REQUIRE_THROWS_WITH(proxy.Call("frames", {"200"}, -1, PUT), + REQUIRE_THROWS_WITH(caller.call("frames", {"200"}, -1, PUT), "Detector returned: Cannot set frames in pedestal " "mode. It is overwritten anyway.\n"); - REQUIRE_THROWS_WITH(proxy.Call("triggers", {"200"}, -1, PUT), + REQUIRE_THROWS_WITH(caller.call("triggers", {"200"}, -1, PUT), "Detector returned: Cannot set triggers in " "pedestal mode. It is overwritten anyway.\n"); REQUIRE_THROWS_WITH( - proxy.Call("timing", {"auto"}, -1, PUT), + caller.call("timing", {"auto"}, -1, PUT), "Detector returned: Cannot set timing mode in pedestal mode. " "Switch off pedestal mode to change timing mode.\n"); REQUIRE_THROWS_WITH( - proxy.Call("scan", {"vb_comp", "500", "1500", "10"}, -1, PUT), + caller.call("scan", {"vb_comp", "500", "1500", "10"}, -1, PUT), "Detector returned: Cannot set scan when in pedestal mode.\n"); REQUIRE_THROWS_WITH( - proxy.Call("scan", {"0"}, -1, PUT), + caller.call("scan", {"0"}, -1, PUT), "Detector returned: Cannot set scan when in pedestal mode.\n"); // should not throw to get these values though - REQUIRE_NOTHROW(proxy.Call("frames", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("triggers", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("timing", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("scan", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("frames", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("triggers", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("timing", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("scan", {}, -1, GET)); { std::ostringstream oss; - proxy.Call("pedestalmode", {"50", "500"}, -1, PUT, oss); + caller.call("pedestalmode", {"50", "500"}, -1, PUT, oss); REQUIRE(oss.str() == "pedestalmode [50, 500]\n"); } { std::ostringstream oss; - proxy.Call("pedestalmode", {}, -1, GET, oss); + caller.call("pedestalmode", {}, -1, GET, oss); REQUIRE(oss.str() == "pedestalmode [enabled, 50, 500]\n"); } { @@ -575,12 +581,12 @@ TEST_CASE("pedestalmode", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("pedestalmode", {"0"}, -1, PUT, oss); + caller.call("pedestalmode", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "pedestalmode [0]\n"); } { std::ostringstream oss; - proxy.Call("pedestalmode", {}, -1, GET, oss); + caller.call("pedestalmode", {}, -1, GET, oss); REQUIRE(oss.str() == "pedestalmode [disabled]\n"); } @@ -592,7 +598,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { // auto mode det.setTimingMode(defs::AUTO_TIMING); - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "pedestalmode", {std::to_string(pedestalFrames), std::to_string(pedestalLoops)}, -1, PUT)); @@ -602,7 +608,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { REQUIRE(numTriggers == 1); // pedestal mode off - REQUIRE_NOTHROW(proxy.Call("pedestalmode", {"0"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("pedestalmode", {"0"}, -1, PUT)); numTriggers = det.getNumberOfTriggers().squash(-1); numFrames = det.getNumberOfFrames().squash(-1); REQUIRE(numFrames == origFrames); @@ -612,7 +618,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { REQUIRE_NOTHROW(det.setTimingMode(defs::TRIGGER_EXPOSURE)); origFrames = 5; REQUIRE_NOTHROW(det.setNumberOfFrames(origFrames)); - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "pedestalmode", {std::to_string(pedestalFrames), std::to_string(pedestalLoops)}, -1, PUT)); @@ -622,7 +628,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { REQUIRE(numTriggers == 1); // pedestal mode off - REQUIRE_NOTHROW(proxy.Call("pedestalmode", {"0"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("pedestalmode", {"0"}, -1, PUT)); numTriggers = det.getNumberOfTriggers().squash(-1); numFrames = det.getNumberOfFrames().squash(-1); REQUIRE(numFrames == origFrames); @@ -633,7 +639,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { REQUIRE_NOTHROW(det.setNumberOfFrames(origFrames)); origTriggers = 10; REQUIRE_NOTHROW(det.setNumberOfTriggers(origTriggers)); - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "pedestalmode", {std::to_string(pedestalFrames), std::to_string(pedestalLoops)}, -1, PUT)); @@ -643,7 +649,7 @@ TEST_CASE("pedestalmode", "[.cmd]") { REQUIRE(numTriggers == expNumFrames); // pedestal mode off - REQUIRE_NOTHROW(proxy.Call("pedestalmode", {"0"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("pedestalmode", {"0"}, -1, PUT)); numTriggers = det.getNumberOfTriggers().squash(-1); numFrames = det.getNumberOfFrames().squash(-1); REQUIRE(numFrames == origFrames); @@ -656,26 +662,26 @@ TEST_CASE("pedestalmode", "[.cmd]") { det.setPedestalMode(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("pedestalmode", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("pedestalmode", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("pedestalmode", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pedestalmode", {"0"}, -1, PUT)); } } -TEST_CASE("sync", "[.cmd]") { +TEST_CASE("Caller::sync", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_val = det.getSynchronization().tsquash( "inconsistent synchronization to test"); { std::ostringstream oss; - proxy.Call("sync", {"0"}, -1, PUT, oss); + caller.call("sync", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "sync 0\n"); } { std::ostringstream oss; - proxy.Call("sync", {"1"}, -1, PUT, oss); + caller.call("sync", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "sync 1\n"); } // setting to master or slave when synced @@ -689,10 +695,10 @@ TEST_CASE("sync", "[.cmd]") { break; } } - proxy.Call("master", {"1"}, 0, PUT); - proxy.Call("master", {"0"}, 0, PUT); + caller.call("master", {"1"}, 0, PUT); + caller.call("master", {"0"}, 0, PUT); std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); + caller.call("status", {}, -1, GET, oss); REQUIRE(oss.str() != "status running\n"); // set all to slaves, and then master for (int i = 0; i != det.size(); ++i) { @@ -702,13 +708,41 @@ TEST_CASE("sync", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("sync", {}, -1, GET, oss); + caller.call("sync", {}, -1, GET, oss); REQUIRE(oss.str() == "sync 1\n"); } + // setting sync when running + { + auto prev_timing = + det.getTimingMode().tsquash("inconsistent timing mode in test"); + auto prev_frames = + det.getNumberOfFrames().tsquash("inconsistent #frames in test"); + auto prev_exptime = + det.getExptime().tsquash("inconsistent exptime in test"); + auto prev_period = + det.getPeriod().tsquash("inconsistent period in test"); + det.setTimingMode(defs::AUTO_TIMING); + det.setNumberOfFrames(10000); + det.setExptime(std::chrono::microseconds(200)); + det.setPeriod(std::chrono::milliseconds(1000)); + det.setSynchronization(1); + det.startDetector(); + REQUIRE_THROWS(caller.call("sync", {"0"}, -1, PUT)); + { + std::ostringstream oss; + caller.call("sync", {}, -1, GET, oss); + REQUIRE(oss.str() == "sync 1\n"); + } + det.stopDetector(); + det.setTimingMode(prev_timing); + det.setNumberOfFrames(prev_frames); + det.setExptime(prev_exptime); + det.setPeriod(prev_period); + } det.setSynchronization(prev_val); } else { - REQUIRE_THROWS(proxy.Call("sync", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("sync", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("sync", {}, -1, GET)); + REQUIRE_THROWS(caller.call("sync", {"0"}, -1, PUT)); } } diff --git a/slsDetectorSoftware/tests/Caller/test-Caller-moench.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-moench.cpp new file mode 100644 index 000000000..19ebaa435 --- /dev/null +++ b/slsDetectorSoftware/tests/Caller/test-Caller-moench.cpp @@ -0,0 +1,114 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "Caller.h" +#include "catch.hpp" +#include "sls/Detector.h" +#include "sls/sls_detector_defs.h" +#include + +#include "sls/versionAPI.h" +#include "test-Caller-global.h" +#include "tests/globals.h" + +namespace sls { + +using test::GET; +using test::PUT; + +/* dacs */ + +TEST_CASE("Caller::Setting and reading back moench dacs", "[.cmdcall][.dacs]") { + // vbp_colbuf, vipre, vin_cm, vb_sda, vcasc_sfp, vout_cm, vipre_cds, + // ibias_sfp + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::MOENCH) { + SECTION("vbp_colbuf") { + test_dac_caller(defs::VBP_COLBUF, "vbp_colbuf", 1300); + } + SECTION("vipre") { test_dac_caller(defs::VIPRE, "vipre", 1000); } + SECTION("vin_cm") { test_dac_caller(defs::VIN_CM, "vin_cm", 1400); } + SECTION("vb_sda") { test_dac_caller(defs::VB_SDA, "vb_sda", 680); } + SECTION("vcasc_sfp") { + test_dac_caller(defs::VCASC_SFP, "vcasc_sfp", 1428); + } + SECTION("vout_cm") { test_dac_caller(defs::VOUT_CM, "vout_cm", 1200); } + SECTION("vipre_cds") { + test_dac_caller(defs::VIPRE_CDS, "vipre_cds", 800); + } + SECTION("ibias_sfp") { + test_dac_caller(defs::IBIAS_SFP, "ibias_sfp", 900); + } + // eiger + REQUIRE_THROWS(caller.call("vthreshold", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vsvp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vsvn", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtrim", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrpreamp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtgstv", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_ll", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_lr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_rl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcmp_rr", {}, -1, GET)); + REQUIRE_THROWS(caller.call("rxb_rb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("rxb_lb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcn", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vishaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("iodelay", {}, -1, GET)); + // gotthard + REQUIRE_THROWS(caller.call("vref_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascn_pb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcascp_pb", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vout_cm", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcasc_out", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vin_cm", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("ib_test_c", {}, -1, GET)); + // mythen3 + REQUIRE_THROWS(caller.call("vrpreamp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vrshaper_n", {}, -1, GET)); + // REQUIRE_THROWS(caller.call("vipre", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vishaper", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vdcsh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vth3", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_n", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcal_p", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vtrim", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcassh", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcas", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vicin", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vipre_out", {}, -1, GET)); + // gotthard2 + REQUIRE_THROWS(caller.call("vref_h_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_comp_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_rstore", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_1st", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp_fe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_l_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_cds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_cs", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_opa_fd", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vcom_adc2", {}, -1, GET)); + // jungfrau + REQUIRE_THROWS(caller.call("vb_comp", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vdd_prot", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vin_com", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_prech", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_pixbuf", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vb_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_ds", {}, -1, GET)); + REQUIRE_THROWS(caller.call("vref_comp", {}, -1, GET)); + } +} + +} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy-mythen3.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-mythen3.cpp similarity index 60% rename from slsDetectorSoftware/tests/test-CmdProxy-mythen3.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-mythen3.cpp index f08612096..13a678ec3 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-mythen3.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-mythen3.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" @@ -9,7 +9,7 @@ #include "sls/Result.h" #include "sls/ToString.h" #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -19,32 +19,41 @@ using test::PUT; /* dacs */ -TEST_CASE("Setting and reading back MYTHEN3 dacs", "[.cmd][.dacs]") { +TEST_CASE("Caller::Setting and reading back MYTHEN3 dacs", + "[.cmdcall][.dacs]") { // vcassh, vth2, vshaper, vshaperneg, vipre_out, vth3, vth1, // vicin, vcas, vpreamp, vpl, vipre, viinsh, vph, vtrim, vdcsh, Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { - SECTION("vcassh") { test_dac(defs::VCASSH, "vcassh", 1200); } - SECTION("vth2") { test_dac(defs::VTH2, "vth2", 2800); } - SECTION("vrshaper") { test_dac(defs::VRSHAPER, "vrshaper", 1280); } - SECTION("vrshaper_n") { - test_dac(defs::VRSHAPER_N, "vrshaper_n", 2800); + SECTION("vcassh") { test_dac_caller(defs::VCASSH, "vcassh", 1200); } + SECTION("vth2") { test_dac_caller(defs::VTH2, "vth2", 2800); } + SECTION("vrshaper") { + test_dac_caller(defs::VRSHAPER, "vrshaper", 1280); } - SECTION("vipre_out") { test_dac(defs::VIPRE_OUT, "vipre_out", 1220); } - SECTION("vth3") { test_dac(defs::VTH3, "vth3", 2800); } - SECTION("vth1") { test_dac(defs::VTH1, "vth1", 2880); } - SECTION("vicin") { test_dac(defs::VICIN, "vicin", 1708); } - SECTION("vcas") { test_dac(defs::VCAS, "vcas", 1800); } - SECTION("vrpreamp") { test_dac(defs::VRPREAMP, "vrpreamp", 1100); } - SECTION("vcal_n") { test_dac(defs::VCAL_N, "vcal_n", 1100); } - SECTION("vipre") { test_dac(defs::VIPRE, "vipre", 2624); } - SECTION("vishaper") { test_dac(defs::VISHAPER, "vishaper", 1708); } - SECTION("vcal_p") { test_dac(defs::VCAL_P, "vcal_p", 1712); } - SECTION("vtrim") { test_dac(defs::VTRIM, "vtrim", 2800); } - SECTION("vdcsh") { test_dac(defs::VDCSH, "vdcsh", 800); } + SECTION("vrshaper_n") { + test_dac_caller(defs::VRSHAPER_N, "vrshaper_n", 2800); + } + SECTION("vipre_out") { + test_dac_caller(defs::VIPRE_OUT, "vipre_out", 1220); + } + SECTION("vth3") { test_dac_caller(defs::VTH3, "vth3", 2800); } + SECTION("vth1") { test_dac_caller(defs::VTH1, "vth1", 2880); } + SECTION("vicin") { test_dac_caller(defs::VICIN, "vicin", 1708); } + SECTION("vcas") { test_dac_caller(defs::VCAS, "vcas", 1800); } + SECTION("vrpreamp") { + test_dac_caller(defs::VRPREAMP, "vrpreamp", 1100); + } + SECTION("vcal_n") { test_dac_caller(defs::VCAL_N, "vcal_n", 1100); } + SECTION("vipre") { test_dac_caller(defs::VIPRE, "vipre", 2624); } + SECTION("vishaper") { + test_dac_caller(defs::VISHAPER, "vishaper", 1708); + } + SECTION("vcal_p") { test_dac_caller(defs::VCAL_P, "vcal_p", 1712); } + SECTION("vtrim") { test_dac_caller(defs::VTRIM, "vtrim", 2800); } + SECTION("vdcsh") { test_dac_caller(defs::VDCSH, "vdcsh", 800); } SECTION("vthreshold") { // Read out individual vcmp to be able to reset after // the test is done @@ -55,67 +64,68 @@ TEST_CASE("Setting and reading back MYTHEN3 dacs", "[.cmd][.dacs]") { { std::ostringstream oss; - proxy.Call("dac", {"vthreshold", "1234"}, -1, PUT, oss); + caller.call("dac", {"vthreshold", "1234"}, -1, PUT, oss); REQUIRE(oss.str() == "dac vthreshold 1234\n"); } { std::ostringstream oss; - proxy.Call("dac", {"vthreshold"}, -1, GET, oss); + caller.call("dac", {"vthreshold"}, -1, GET, oss); REQUIRE(oss.str() == "dac vthreshold 1234\n"); } // disabling counters change vth values - proxy.Call("counters", {"0"}, -1, PUT); + caller.call("counters", {"0"}, -1, PUT); { std::ostringstream oss1, oss2, oss3; - proxy.Call("dac", {"vth1"}, -1, GET, oss1); + caller.call("dac", {"vth1"}, -1, GET, oss1); REQUIRE(oss1.str() == "dac vth1 1234\n"); - proxy.Call("dac", {"vth2"}, -1, GET, oss2); + caller.call("dac", {"vth2"}, -1, GET, oss2); REQUIRE(oss2.str() == "dac vth2 2800\n"); - proxy.Call("dac", {"vth3"}, -1, GET, oss3); + caller.call("dac", {"vth3"}, -1, GET, oss3); REQUIRE(oss3.str() == "dac vth3 2800\n"); } // vthreshold changes vth for only enabled counters - REQUIRE_NOTHROW(proxy.Call("dac", {"vthreshold", "2100"}, -1, PUT)); + REQUIRE_NOTHROW( + caller.call("dac", {"vthreshold", "2100"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("dac", {"vthreshold"}, -1, GET, oss); + caller.call("dac", {"vthreshold"}, -1, GET, oss); REQUIRE(oss.str() == "dac vthreshold 2100\n"); std::ostringstream oss1, oss2, oss3; - proxy.Call("dac", {"vth1"}, -1, GET, oss1); + caller.call("dac", {"vth1"}, -1, GET, oss1); REQUIRE(oss1.str() == "dac vth1 2100\n"); - proxy.Call("dac", {"vth2"}, -1, GET, oss2); + caller.call("dac", {"vth2"}, -1, GET, oss2); REQUIRE(oss2.str() == "dac vth2 2800\n"); - proxy.Call("dac", {"vth3"}, -1, GET, oss3); + caller.call("dac", {"vth3"}, -1, GET, oss3); REQUIRE(oss3.str() == "dac vth3 2800\n"); } // vth overwrite vth even if counter disabled { std::ostringstream oss; - proxy.Call("dac", {"vth2", "2200"}, -1, PUT); - proxy.Call("dac", {"vth2"}, -1, GET, oss); + caller.call("dac", {"vth2", "2200"}, -1, PUT); + caller.call("dac", {"vth2"}, -1, GET, oss); REQUIRE(oss.str() == "dac vth2 2200\n"); } // counters enabled, sets remembered values - proxy.Call("counters", {"0", "1", "2"}, -1, PUT); + caller.call("counters", {"0", "1", "2"}, -1, PUT); { std::ostringstream oss1, oss2, oss3; - proxy.Call("dac", {"vth1"}, -1, GET, oss1); + caller.call("dac", {"vth1"}, -1, GET, oss1); REQUIRE(oss1.str() == "dac vth1 2100\n"); - proxy.Call("dac", {"vth2"}, -1, GET, oss2); + caller.call("dac", {"vth2"}, -1, GET, oss2); REQUIRE(oss2.str() == "dac vth2 2200\n"); - proxy.Call("dac", {"vth3"}, -1, GET, oss3); + caller.call("dac", {"vth3"}, -1, GET, oss3); REQUIRE(oss3.str() == "dac vth3 2100\n"); } // counters enabled, sets remembered values - proxy.Call("counters", {"0", "1"}, -1, PUT); + caller.call("counters", {"0", "1"}, -1, PUT); { std::ostringstream oss1, oss2, oss3; - proxy.Call("dac", {"vth1"}, -1, GET, oss1); + caller.call("dac", {"vth1"}, -1, GET, oss1); REQUIRE(oss1.str() == "dac vth1 2100\n"); - proxy.Call("dac", {"vth2"}, -1, GET, oss2); + caller.call("dac", {"vth2"}, -1, GET, oss2); REQUIRE(oss2.str() == "dac vth2 2200\n"); - proxy.Call("dac", {"vth3"}, -1, GET, oss3); + caller.call("dac", {"vth3"}, -1, GET, oss3); REQUIRE(oss3.str() == "dac vth3 2800\n"); } // Reset dacs after test @@ -126,81 +136,81 @@ TEST_CASE("Setting and reading back MYTHEN3 dacs", "[.cmd][.dacs]") { det.setDAC(defs::VTH3, vth3[i], false, {i}); } } - REQUIRE_THROWS(proxy.Call("dac", {"vsvp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vsvn"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtgstv"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_ll"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_lr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rl"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_rb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_lb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcn"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"iodelay"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascn_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcascp_pb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vout_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcasc_out"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_cm"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"ib_test_c"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_h_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_rstore"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_1st"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_prech"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_l_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_cs"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_fd"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc2"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_ds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_pixbuf"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_com"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdd_prot"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vsvn"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vtrim"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vrpreamp"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vrshaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vtgstv"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_ll"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_lr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcal"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rl"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcmp_rr"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_rb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"rxb_lb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcn"}, -1, GET)); + // REQUIRE_THROWS(caller.call("dac", {"vishaper"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"iodelay"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascn_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcascp_pb"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vout_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcasc_out"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_cm"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"ib_test_c"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_h_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_rstore"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_1st"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_comp_fe"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc1"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_prech"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_l_adc"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vref_cds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_cs"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_opa_fd"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vcom_adc2"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_ds"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_comp"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vb_pixbuf"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vin_com"}, -1, GET)); + REQUIRE_THROWS(caller.call("dac", {"vdd_prot"}, -1, GET)); } } /* acquisition */ -TEST_CASE("readout", "[.cmd]") { +TEST_CASE("Caller::readout", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); // PUT only command - REQUIRE_THROWS(proxy.Call("readout", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readout", {}, -1, GET)); auto det_type = det.getDetectorType().squash(); if (det_type != defs::MYTHEN3) { - REQUIRE_THROWS(proxy.Call("readout", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readout", {}, -1, GET)); } else { std::ostringstream oss; - proxy.Call("readout", {}, -1, PUT, oss); + caller.call("readout", {}, -1, PUT, oss); REQUIRE(oss.str() == "readout successful\n"); } } /* Mythen3 Specific */ -TEST_CASE("counters", "[.cmd]") { +TEST_CASE("Caller::counters", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { - REQUIRE_THROWS(proxy.Call("counters", {}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("counters", {"3"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("counters", {"0", "-1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("counters", {"0", "1", "1"}, -1, GET)); + REQUIRE_THROWS(caller.call("counters", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("counters", {"3"}, -1, GET)); + REQUIRE_THROWS(caller.call("counters", {"0", "-1"}, -1, GET)); + REQUIRE_THROWS(caller.call("counters", {"0", "1", "1"}, -1, GET)); auto mask = det.getCounterMask({0}).squash(-1); std::vector list_str; @@ -210,140 +220,140 @@ TEST_CASE("counters", "[.cmd]") { } } std::ostringstream oss_set, oss_set2, oss_set3, oss_get; - proxy.Call("counters", {"0", "2", "1"}, -1, PUT, oss_set); + caller.call("counters", {"0", "2", "1"}, -1, PUT, oss_set); REQUIRE(oss_set.str() == "counters [0, 2, 1]\n"); - proxy.Call("counters", {"0", "2"}, -1, PUT, oss_set2); + caller.call("counters", {"0", "2"}, -1, PUT, oss_set2); REQUIRE(oss_set2.str() == "counters [0, 2]\n"); // put back old value - proxy.Call("counters", list_str, -1, PUT, oss_set3); + caller.call("counters", list_str, -1, PUT, oss_set3); REQUIRE(oss_set3.str() == "counters " + ToString(list_str) + "\n"); - proxy.Call("counters", {}, -1, GET, oss_get); + caller.call("counters", {}, -1, GET, oss_get); REQUIRE(oss_get.str() == "counters " + ToString(list_str) + "\n"); } else { - REQUIRE_THROWS(proxy.Call("counters", {}, -1, GET)); + REQUIRE_THROWS(caller.call("counters", {}, -1, GET)); } } -TEST_CASE("gates", "[.cmd]") { +TEST_CASE("Caller::gates", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getNumberOfGates(); { std::ostringstream oss; - proxy.Call("gates", {"1000"}, -1, PUT, oss); + caller.call("gates", {"1000"}, -1, PUT, oss); REQUIRE(oss.str() == "gates 1000\n"); } { std::ostringstream oss; - proxy.Call("gates", {}, -1, GET, oss); + caller.call("gates", {}, -1, GET, oss); REQUIRE(oss.str() == "gates 1000\n"); } { std::ostringstream oss; - proxy.Call("gates", {"1"}, -1, PUT, oss); + caller.call("gates", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "gates 1\n"); } - REQUIRE_THROWS(proxy.Call("gates", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("gates", {"0"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setNumberOfGates(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("gates", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gates", {}, -1, GET)); } } -TEST_CASE("exptime1", "[.cmd]") { +TEST_CASE("Caller::exptime1", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getExptime(0); { std::ostringstream oss; - proxy.Call("exptime1", {"1.25s"}, -1, PUT, oss); + caller.call("exptime1", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime1 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime1", {}, -1, GET, oss); + caller.call("exptime1", {}, -1, GET, oss); REQUIRE(oss.str() == "exptime1 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime1", {"0"}, -1, PUT, oss); + caller.call("exptime1", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime1 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setExptime(0, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("exptime1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("exptime1", {}, -1, GET)); } } -TEST_CASE("exptime2", "[.cmd]") { +TEST_CASE("Caller::exptime2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getExptime(1); { std::ostringstream oss; - proxy.Call("exptime2", {"1.25s"}, -1, PUT, oss); + caller.call("exptime2", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime2 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime2", {}, -1, GET, oss); + caller.call("exptime2", {}, -1, GET, oss); REQUIRE(oss.str() == "exptime2 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime2", {"0"}, -1, PUT, oss); + caller.call("exptime2", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime2 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setExptime(1, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("exptime2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("exptime2", {}, -1, GET)); } } -TEST_CASE("exptime3", "[.cmd]") { +TEST_CASE("Caller::exptime3", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getExptime(2); { std::ostringstream oss; - proxy.Call("exptime3", {"1.25s"}, -1, PUT, oss); + caller.call("exptime3", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime3 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime3", {}, -1, GET, oss); + caller.call("exptime3", {}, -1, GET, oss); REQUIRE(oss.str() == "exptime3 1.25s\n"); } { std::ostringstream oss; - proxy.Call("exptime3", {"0"}, -1, PUT, oss); + caller.call("exptime3", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "exptime3 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setExptime(2, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("exptime3", {}, -1, GET)); + REQUIRE_THROWS(caller.call("exptime3", {}, -1, GET)); } } -TEST_CASE("gatedelay", "[.cmd]") { +TEST_CASE("Caller::gatedelay", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getExptimeForAllGates().tsquash( @@ -353,148 +363,148 @@ TEST_CASE("gatedelay", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("gatedelay", {"0.05"}, -1, PUT, oss); + caller.call("gatedelay", {"0.05"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay 0.05\n"); } if (det_type != defs::MYTHEN3) { std::ostringstream oss; - proxy.Call("gatedelay", {}, -1, GET, oss); + caller.call("gatedelay", {}, -1, GET, oss); REQUIRE(oss.str() == "gatedelay 50ms\n"); } { std::ostringstream oss; - proxy.Call("gatedelay", {"1s"}, -1, PUT, oss); + caller.call("gatedelay", {"1s"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay 1s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay", {"0"}, -1, PUT, oss); + caller.call("gatedelay", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay 0\n"); } det.setGateDelay(-1, prev_val[0]); } else { - REQUIRE_THROWS(proxy.Call("gatedelay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gatedelay", {}, -1, GET)); } } -TEST_CASE("gatedelay1", "[.cmd]") { +TEST_CASE("Caller::gatedelay1", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getGateDelay(0); { std::ostringstream oss; - proxy.Call("gatedelay1", {"1.25s"}, -1, PUT, oss); + caller.call("gatedelay1", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay1 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay1", {}, -1, GET, oss); + caller.call("gatedelay1", {}, -1, GET, oss); REQUIRE(oss.str() == "gatedelay1 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay1", {"0"}, -1, PUT, oss); + caller.call("gatedelay1", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay1 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setGateDelay(0, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("gatedelay1", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gatedelay1", {}, -1, GET)); } } -TEST_CASE("gatedelay2", "[.cmd]") { +TEST_CASE("Caller::gatedelay2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getGateDelay(1); { std::ostringstream oss; - proxy.Call("gatedelay2", {"1.25s"}, -1, PUT, oss); + caller.call("gatedelay2", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay2 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay2", {}, -1, GET, oss); + caller.call("gatedelay2", {}, -1, GET, oss); REQUIRE(oss.str() == "gatedelay2 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay2", {"0"}, -1, PUT, oss); + caller.call("gatedelay2", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay2 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setGateDelay(1, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("gatedelay2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gatedelay2", {}, -1, GET)); } } -TEST_CASE("gatedelay3", "[.cmd]") { +TEST_CASE("Caller::gatedelay3", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { auto prev_val = det.getGateDelay(2); { std::ostringstream oss; - proxy.Call("gatedelay3", {"1.25s"}, -1, PUT, oss); + caller.call("gatedelay3", {"1.25s"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay3 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay3", {}, -1, GET, oss); + caller.call("gatedelay3", {}, -1, GET, oss); REQUIRE(oss.str() == "gatedelay3 1.25s\n"); } { std::ostringstream oss; - proxy.Call("gatedelay3", {"0"}, -1, PUT, oss); + caller.call("gatedelay3", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gatedelay3 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setGateDelay(2, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("gatedelay3", {}, -1, GET)); + REQUIRE_THROWS(caller.call("gatedelay3", {}, -1, GET)); } } -TEST_CASE("polarity", "[.cmd]") { +TEST_CASE("Caller::polarity", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); if (det.getDetectorType().squash() == defs::MYTHEN3) { auto prev_val = det.getPolarity(); { std::ostringstream oss; - proxy.Call("polarity", {"pos"}, -1, PUT, oss); + caller.call("polarity", {"pos"}, -1, PUT, oss); REQUIRE(oss.str() == "polarity pos\n"); } { std::ostringstream oss; - proxy.Call("polarity", {"neg"}, -1, PUT, oss); + caller.call("polarity", {"neg"}, -1, PUT, oss); REQUIRE(oss.str() == "polarity neg\n"); } { std::ostringstream oss; - proxy.Call("polarity", {}, -1, GET, oss); + caller.call("polarity", {}, -1, GET, oss); REQUIRE(oss.str() == "polarity neg\n"); } for (int i = 0; i != det.size(); ++i) { det.setPolarity(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("polarity", {}, -1, GET)); + REQUIRE_THROWS(caller.call("polarity", {}, -1, GET)); } } -TEST_CASE("interpolation", "[.cmd]") { +TEST_CASE("Caller::interpolation", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); if (det.getDetectorType().squash() == defs::MYTHEN3) { auto prev_interpolation = det.getInterpolation(); auto prev_mask = det.getCounterMask(); @@ -509,7 +519,7 @@ TEST_CASE("interpolation", "[.cmd]") { det.setCounterMask(fixedMask[i]); { std::ostringstream oss; - proxy.Call("interpolation", {"1"}, -1, PUT, oss); + caller.call("interpolation", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "interpolation 1\n"); REQUIRE(det.getCounterMask().tsquash( "inconsistent counter mask") == 7); @@ -519,7 +529,7 @@ TEST_CASE("interpolation", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("interpolation", {"0"}, -1, PUT, oss); + caller.call("interpolation", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "interpolation 0\n"); REQUIRE(det.getCounterMask().tsquash( "inconsistent counter mask") == fixedMask[i]); @@ -533,7 +543,7 @@ TEST_CASE("interpolation", "[.cmd]") { { std::ostringstream oss; - proxy.Call("interpolation", {}, -1, GET, oss); + caller.call("interpolation", {}, -1, GET, oss); REQUIRE(oss.str() == "interpolation 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -542,13 +552,13 @@ TEST_CASE("interpolation", "[.cmd]") { det.setDAC(defs::VTH3, prev_vth3DacVal[i], 0, {i}); } } else { - REQUIRE_THROWS(proxy.Call("interpolation", {}, -1, GET)); + REQUIRE_THROWS(caller.call("interpolation", {}, -1, GET)); } } -TEST_CASE("pumpprobe", "[.cmd]") { +TEST_CASE("Caller::pumpprobe", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); if (det.getDetectorType().squash() == defs::MYTHEN3) { auto prev_val = det.getPumpProbe(); auto prev_interpolation = det.getInterpolation(); @@ -570,7 +580,7 @@ TEST_CASE("pumpprobe", "[.cmd]") { { // pump probe std::ostringstream oss; - proxy.Call("pumpprobe", {"1"}, -1, PUT, oss); + caller.call("pumpprobe", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "pumpprobe 1\n"); REQUIRE(det.getDAC(defs::VTH1, 0, {0}) .tsquash("inconsistent vth2 dac value") == @@ -583,11 +593,11 @@ TEST_CASE("pumpprobe", "[.cmd]") { disabledDacValue); } // interpolation and pump probe - REQUIRE_THROWS(proxy.Call("interpolation", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("interpolation", {"1"}, -1, PUT)); { // none std::ostringstream oss; - proxy.Call("pumpprobe", {"0"}, -1, PUT, oss); + caller.call("pumpprobe", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "pumpprobe 0\n"); REQUIRE(det.getCounterMask().tsquash( "inconsistent counter mask") == fixedMask[i]); @@ -607,7 +617,7 @@ TEST_CASE("pumpprobe", "[.cmd]") { } { std::ostringstream oss; - proxy.Call("pumpprobe", {}, -1, GET, oss); + caller.call("pumpprobe", {}, -1, GET, oss); REQUIRE(oss.str() == "pumpprobe 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -619,63 +629,63 @@ TEST_CASE("pumpprobe", "[.cmd]") { det.setDAC(defs::VTH3, prev_vth3DacVal[i], 0, {i}); } } else { - REQUIRE_THROWS(proxy.Call("pumpprobe", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pumpprobe", {}, -1, GET)); } } -TEST_CASE("apulse", "[.cmd]") { +TEST_CASE("Caller::apulse", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); if (det.getDetectorType().squash() == defs::MYTHEN3) { auto prev_val = det.getAnalogPulsing(); { std::ostringstream oss; - proxy.Call("apulse", {"1"}, -1, PUT, oss); + caller.call("apulse", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "apulse 1\n"); } { std::ostringstream oss; - proxy.Call("apulse", {"0"}, -1, PUT, oss); + caller.call("apulse", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "apulse 0\n"); } { std::ostringstream oss; - proxy.Call("apulse", {}, -1, GET, oss); + caller.call("apulse", {}, -1, GET, oss); REQUIRE(oss.str() == "apulse 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setAnalogPulsing(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("apulse", {}, -1, GET)); + REQUIRE_THROWS(caller.call("apulse", {}, -1, GET)); } } -TEST_CASE("dpulse", "[.cmd]") { +TEST_CASE("Caller::dpulse", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); if (det.getDetectorType().squash() == defs::MYTHEN3) { auto prev_val = det.getDigitalPulsing(); { std::ostringstream oss; - proxy.Call("dpulse", {"1"}, -1, PUT, oss); + caller.call("dpulse", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "dpulse 1\n"); } { std::ostringstream oss; - proxy.Call("dpulse", {"0"}, -1, PUT, oss); + caller.call("dpulse", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "dpulse 0\n"); } { std::ostringstream oss; - proxy.Call("dpulse", {}, -1, GET, oss); + caller.call("dpulse", {}, -1, GET, oss); REQUIRE(oss.str() == "dpulse 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setDigitalPulsing(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("dpulse", {}, -1, GET)); + REQUIRE_THROWS(caller.call("dpulse", {}, -1, GET)); } } diff --git a/slsDetectorSoftware/tests/test-CmdProxy-pattern.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-pattern.cpp similarity index 61% rename from slsDetectorSoftware/tests/test-CmdProxy-pattern.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller-pattern.cpp index 08fad83bc..275612d89 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy-pattern.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller-pattern.cpp @@ -1,6 +1,6 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/sls_detector_defs.h" @@ -9,7 +9,7 @@ #include "sls/Result.h" #include "sls/ToString.h" #include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include "tests/globals.h" namespace sls { @@ -19,114 +19,124 @@ using test::PUT; /* Pattern */ -TEST_CASE("patfname", "[.cmd]") { +TEST_CASE("Caller::patfname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { - REQUIRE_THROWS(proxy.Call("patfname", {}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("patfname", {}, -1, GET)); + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { + REQUIRE_THROWS(caller.call("patfname", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("patfname", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("patfname", {}, -1, GET)); + REQUIRE_THROWS(caller.call("patfname", {}, -1, GET)); } } -TEST_CASE("pattern", "[.cmd]") { +TEST_CASE("Caller::pattern", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { // no proper test for put - REQUIRE_THROWS(proxy.Call("pattern", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pattern", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("pattern", {}, -1, GET)); + REQUIRE_THROWS(caller.call("pattern", {}, -1, GET)); } } -TEST_CASE("savepattern", "[.cmd]") { +TEST_CASE("Caller::savepattern", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { REQUIRE_THROWS( - proxy.Call("savepattern", {"/tmp/pattern.txt"}, -1, GET)); + caller.call("savepattern", {"/tmp/pattern.txt"}, -1, GET)); if (det.size() == 1) { REQUIRE_NOTHROW( - proxy.Call("savepattern", {"/tmp/pattern.txt"}, -1, PUT)); + caller.call("savepattern", {"/tmp/pattern.txt"}, -1, PUT)); } } else { REQUIRE_THROWS( - proxy.Call("savepattern", {"/tmp/pattern.txt"}, -1, PUT)); + caller.call("savepattern", {"/tmp/pattern.txt"}, -1, PUT)); } } -TEST_CASE("defaultpattern", "[.cmd]") { +TEST_CASE("Caller::defaultpattern", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { - REQUIRE_THROWS(proxy.Call("defaultpattern", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("defaultpattern", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("defaultpattern", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("defaultpattern", {}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("defaultpattern", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("defaultpattern", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("defaultpattern", {}, -1, GET)); + REQUIRE_THROWS(caller.call("defaultpattern", {}, -1, PUT)); } } -TEST_CASE("patioctrl", "[.cmd]") { +TEST_CASE("Caller::patioctrl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getPatternIOControl(); { std::ostringstream oss; - proxy.Call("patioctrl", {"0xc15004808d0a21a4"}, -1, PUT, oss); + caller.call("patioctrl", {"0xc15004808d0a21a4"}, -1, PUT, oss); REQUIRE(oss.str() == "patioctrl 0xc15004808d0a21a4\n"); } { std::ostringstream oss; - proxy.Call("patioctrl", {"0xaadf0"}, -1, PUT, oss); + caller.call("patioctrl", {"0xaadf0"}, -1, PUT, oss); REQUIRE(oss.str() == "patioctrl 0x00000000000aadf0\n"); } { std::ostringstream oss; - proxy.Call("patioctrl", {}, -1, GET, oss); + caller.call("patioctrl", {}, -1, GET, oss); REQUIRE(oss.str() == "patioctrl 0x00000000000aadf0\n"); } for (int i = 0; i != det.size(); ++i) { det.setPatternIOControl(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("patioctrl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("patioctrl", {}, -1, GET)); } } -TEST_CASE("patword", "[.cmd]") { +TEST_CASE("Caller::patword", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { int addr = 0x23; std::string saddr = ToStringHex(addr, 4); auto prev_val = det.getPatternWord(addr); { std::ostringstream oss; - proxy.Call("patword", {saddr, "0xc15004808d0a21a4"}, -1, PUT, oss); + caller.call("patword", {saddr, "0xc15004808d0a21a4"}, -1, PUT, oss); REQUIRE(oss.str() == "patword [" + saddr + ", 0xc15004808d0a21a4]\n"); } { std::ostringstream oss; - proxy.Call("patword", {saddr, "0xaadf0"}, -1, PUT, oss); + caller.call("patword", {saddr, "0x815004808d0a21a4"}, -1, PUT, oss); + REQUIRE(oss.str() == + "patword [" + saddr + ", 0x815004808d0a21a4]\n"); + } + { + std::ostringstream oss; + caller.call("patword", {saddr, "0xaadf0"}, -1, PUT, oss); REQUIRE(oss.str() == "patword [" + saddr + ", 0x00000000000aadf0]\n"); } { std::ostringstream oss; - proxy.Call("patword", {saddr}, -1, GET, oss); + caller.call("patword", {saddr}, -1, GET, oss); REQUIRE(oss.str() == "patword [" + saddr + ", 0x00000000000aadf0]\n"); } @@ -134,25 +144,26 @@ TEST_CASE("patword", "[.cmd]") { det.setPatternWord(addr, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("patword", {"0x23"}, -1, GET)); + REQUIRE_THROWS(caller.call("patword", {"0x23"}, -1, GET)); } } -TEST_CASE("patlimits", "[.cmd]") { +TEST_CASE("Caller::patlimits", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { auto prev_val = det.getPatternLoopAddresses(-1); { std::ostringstream oss; - proxy.Call("patlimits", {"0x20", "0x5c"}, -1, PUT, oss); + caller.call("patlimits", {"0x20", "0x5c"}, -1, PUT, oss); REQUIRE(oss.str() == "patlimits [0x0020, 0x005c]\n"); } { std::ostringstream oss; - proxy.Call("patlimits", {}, -1, GET, oss); + caller.call("patlimits", {}, -1, GET, oss); REQUIRE(oss.str() == "patlimits [0x0020, 0x005c]\n"); } for (int i = 0; i != det.size(); ++i) { @@ -160,16 +171,17 @@ TEST_CASE("patlimits", "[.cmd]") { {i}); } } else { - REQUIRE_THROWS(proxy.Call("patlimits", {}, -1, GET)); + REQUIRE_THROWS(caller.call("patlimits", {}, -1, GET)); } } -TEST_CASE("patloop", "[.cmd]") { +TEST_CASE("Caller::patloop", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { for (int iLoop = 0; iLoop != MAX_PATTERN_LEVELS; ++iLoop) { // m3 only has 3 levels if (det_type == defs::MYTHEN3 && iLoop >= 3) { @@ -181,24 +193,24 @@ TEST_CASE("patloop", "[.cmd]") { std::string deprecatedCmd = "patloop" + sLoop; { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {"0x20", "0x5c"}, -1, PUT, oss); + caller.call(deprecatedCmd, {"0x20", "0x5c"}, -1, PUT, oss); REQUIRE(oss.str() == deprecatedCmd + " [0x0020, 0x005c]\n"); } { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {}, -1, GET, oss); + caller.call(deprecatedCmd, {}, -1, GET, oss); REQUIRE(oss.str() == deprecatedCmd + " [0x0020, 0x005c]\n"); } } { std::ostringstream oss; - proxy.Call("patloop", {sLoop, "0x20", "0x5c"}, -1, PUT, oss); + caller.call("patloop", {sLoop, "0x20", "0x5c"}, -1, PUT, oss); REQUIRE(oss.str() == "patloop " + sLoop + " [0x0020, 0x005c]\n"); } { std::ostringstream oss; - proxy.Call("patloop", {sLoop}, -1, GET, oss); + caller.call("patloop", {sLoop}, -1, GET, oss); REQUIRE(oss.str() == "patloop " + sLoop + " [0x0020, 0x005c]\n"); } @@ -208,16 +220,17 @@ TEST_CASE("patloop", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("patloop", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("patloop", {"0"}, -1, GET)); } } -TEST_CASE("patnloop", "[.cmd]") { +TEST_CASE("Caller::patnloop", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { for (int iLoop = 0; iLoop != MAX_PATTERN_LEVELS; ++iLoop) { // m3 only has 3 levels if (det_type == defs::MYTHEN3 && iLoop >= 3) { @@ -229,23 +242,23 @@ TEST_CASE("patnloop", "[.cmd]") { std::string deprecatedCmd = "patnloop" + sLoop; { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {"5"}, -1, PUT, oss); + caller.call(deprecatedCmd, {"5"}, -1, PUT, oss); REQUIRE(oss.str() == deprecatedCmd + " 5\n"); } { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {}, -1, GET, oss); + caller.call(deprecatedCmd, {}, -1, GET, oss); REQUIRE(oss.str() == deprecatedCmd + " 5\n"); } } { std::ostringstream oss; - proxy.Call("patnloop", {sLoop, "5"}, -1, PUT, oss); + caller.call("patnloop", {sLoop, "5"}, -1, PUT, oss); REQUIRE(oss.str() == "patnloop " + sLoop + " 5\n"); } { std::ostringstream oss; - proxy.Call("patnloop", {sLoop}, -1, GET, oss); + caller.call("patnloop", {sLoop}, -1, GET, oss); REQUIRE(oss.str() == "patnloop " + sLoop + " 5\n"); } for (int iDet = 0; iDet != det.size(); ++iDet) { @@ -253,16 +266,17 @@ TEST_CASE("patnloop", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("patnloop", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("patnloop", {"0"}, -1, GET)); } } -TEST_CASE("patwait", "[.cmd]") { +TEST_CASE("Caller::patwait", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { for (int iLoop = 0; iLoop != MAX_PATTERN_LEVELS; ++iLoop) { // m3 only has 3 levels if (det_type == defs::MYTHEN3 && iLoop >= 3) { @@ -274,23 +288,23 @@ TEST_CASE("patwait", "[.cmd]") { std::string deprecatedCmd = "patwait" + sLoop; { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {"0x5c"}, -1, PUT, oss); + caller.call(deprecatedCmd, {"0x5c"}, -1, PUT, oss); REQUIRE(oss.str() == deprecatedCmd + " 0x005c\n"); } { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {}, -1, GET, oss); + caller.call(deprecatedCmd, {}, -1, GET, oss); REQUIRE(oss.str() == deprecatedCmd + " 0x005c\n"); } } { std::ostringstream oss; - proxy.Call("patwait", {sLoop, "0x5c"}, -1, PUT, oss); + caller.call("patwait", {sLoop, "0x5c"}, -1, PUT, oss); REQUIRE(oss.str() == "patwait " + sLoop + " 0x005c\n"); } { std::ostringstream oss; - proxy.Call("patwait", {sLoop}, -1, GET, oss); + caller.call("patwait", {sLoop}, -1, GET, oss); REQUIRE(oss.str() == "patwait " + sLoop + " 0x005c\n"); } for (int iDet = 0; iDet != det.size(); ++iDet) { @@ -298,16 +312,17 @@ TEST_CASE("patwait", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("patwait", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("patwait", {"0"}, -1, GET)); } } -TEST_CASE("patwaittime", "[.cmd]") { +TEST_CASE("Caller::patwaittime", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { for (int iLoop = 0; iLoop != MAX_PATTERN_LEVELS; ++iLoop) { // m3 only has 3 levels if (det_type == defs::MYTHEN3 && iLoop >= 3) { @@ -319,23 +334,23 @@ TEST_CASE("patwaittime", "[.cmd]") { std::string deprecatedCmd = "patwaittime" + sLoop; { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {"8589936640"}, -1, PUT, oss); + caller.call(deprecatedCmd, {"8589936640"}, -1, PUT, oss); REQUIRE(oss.str() == deprecatedCmd + " 8589936640\n"); } { // depreciated std::ostringstream oss; - proxy.Call(deprecatedCmd, {}, -1, GET, oss); + caller.call(deprecatedCmd, {}, -1, GET, oss); REQUIRE(oss.str() == deprecatedCmd + " 8589936640\n"); } } { std::ostringstream oss; - proxy.Call("patwaittime", {sLoop, "8589936640"}, -1, PUT, oss); + caller.call("patwaittime", {sLoop, "8589936640"}, -1, PUT, oss); REQUIRE(oss.str() == "patwaittime " + sLoop + " 8589936640\n"); } { std::ostringstream oss; - proxy.Call("patwaittime", {sLoop}, -1, GET, oss); + caller.call("patwaittime", {sLoop}, -1, GET, oss); REQUIRE(oss.str() == "patwaittime " + sLoop + " 8589936640\n"); } for (int iDet = 0; iDet != det.size(); ++iDet) { @@ -343,69 +358,71 @@ TEST_CASE("patwaittime", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("patwaittime", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("patwaittime", {"0"}, -1, GET)); } } -TEST_CASE("patmask", "[.cmd]") { +TEST_CASE("Caller::patmask", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { auto prev_val = det.getPatternMask(); { std::ostringstream oss; - proxy.Call("patmask", {"0x842f020204200dc0"}, -1, PUT, oss); + caller.call("patmask", {"0x842f020204200dc0"}, -1, PUT, oss); REQUIRE(oss.str() == "patmask 0x842f020204200dc0\n"); } { std::ostringstream oss; - proxy.Call("patmask", {}, -1, GET, oss); + caller.call("patmask", {}, -1, GET, oss); REQUIRE(oss.str() == "patmask 0x842f020204200dc0\n"); } for (int i = 0; i != det.size(); ++i) { det.setPatternMask(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("patmask", {}, -1, GET)); + REQUIRE_THROWS(caller.call("patmask", {}, -1, GET)); } } -TEST_CASE("patsetbit", "[.cmd]") { +TEST_CASE("Caller::patsetbit", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3) { + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD || det_type == defs::MYTHEN3) { auto prev_val = det.getPatternBitMask(); { std::ostringstream oss; - proxy.Call("patsetbit", {"0x842f020204200dc0"}, -1, PUT, oss); + caller.call("patsetbit", {"0x842f020204200dc0"}, -1, PUT, oss); REQUIRE(oss.str() == "patsetbit 0x842f020204200dc0\n"); } { std::ostringstream oss; - proxy.Call("patsetbit", {}, -1, GET, oss); + caller.call("patsetbit", {}, -1, GET, oss); REQUIRE(oss.str() == "patsetbit 0x842f020204200dc0\n"); } for (int i = 0; i != det.size(); ++i) { det.setPatternBitMask(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("patsetbit", {}, -1, GET)); + REQUIRE_THROWS(caller.call("patsetbit", {}, -1, GET)); } } -TEST_CASE("patternstart", "[.cmd]") { +TEST_CASE("Caller::patternstart", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("patternstart", {}, -1, GET)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("patternstart", {}, -1, GET)); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { - REQUIRE_NOTHROW(proxy.Call("patternstart", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("patternstart", {}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("patternstart", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("patternstart", {}, -1, PUT)); } } diff --git a/slsDetectorSoftware/tests/Caller/test-Caller-rx.cpp b/slsDetectorSoftware/tests/Caller/test-Caller-rx.cpp new file mode 100644 index 000000000..e5f996318 --- /dev/null +++ b/slsDetectorSoftware/tests/Caller/test-Caller-rx.cpp @@ -0,0 +1,1220 @@ +// SPDX-License-Identifier: LGPL-3.0-or-other +// Copyright (C) 2021 Contributors to the SLS Detector Package +#include "Caller.h" +#include "catch.hpp" +#include "sls/Detector.h" +#include "sls/Version.h" +#include "sls/sls_detector_defs.h" +#include "test-Caller-global.h" + +#include + +#include "sls/versionAPI.h" +#include "tests/globals.h" + +namespace sls { + +using test::GET; +using test::PUT; + +/* +This file should contain receiver specific tests use +python/scripts/list_tested_cmd.py to check if all commands are covered +*/ + +/* configuration */ + +TEST_CASE("Caller::rx_version", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::ostringstream oss; + caller.call("rx_version", {}, -1, GET, oss); + sls::Version v(APIRECEIVER); + std::ostringstream vs; + vs << "rx_version " << v.concise() << '\n'; + REQUIRE(oss.str() == vs.str()); + + REQUIRE_THROWS(caller.call("rx_version", {"0"}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("rx_version", {}, -1, GET)); + } +} + +/* acquisition */ +TEST_CASE("Caller::rx_start", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + det.setFileWrite(false); // avoid writing or error on file creation + // PUT only command + REQUIRE_THROWS(caller.call("rx_start", {}, -1, GET)); + { + std::ostringstream oss; + caller.call("rx_start", {}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_start successful\n"); + } + { + std::ostringstream oss; + caller.call("rx_status", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_status running\n"); + } + } else { + REQUIRE_THROWS(caller.call("rx_start", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_stop", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + // PUT only command + REQUIRE_THROWS(caller.call("rx_stop", {}, -1, GET)); + { + std::ostringstream oss; + caller.call("rx_stop", {}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_stop successful\n"); + } + { + std::ostringstream oss; + caller.call("rx_status", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_status idle\n"); + } + } else { + REQUIRE_THROWS(caller.call("rx_stop", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_status", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + det.setFileWrite(false); // avoid writing or error on file creation + Caller caller(&det); + det.startReceiver(); + { + std::ostringstream oss; + caller.call("rx_status", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_status running\n"); + } + det.stopReceiver(); + { + std::ostringstream oss; + caller.call("rx_status", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_status idle\n"); + } + } else { + REQUIRE_THROWS(caller.call("rx_status", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_framescaught", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + // This ensures 0 caught frames + auto prev_val = det.getFileWrite(); + det.setFileWrite(false); // avoid writing or error on file creation + det.startReceiver(); + det.stopReceiver(); + { + std::ostringstream oss; + caller.call("rx_framescaught", {}, -1, GET, oss); + if (det.getNumberofUDPInterfaces().tsquash( + "inconsistent number of interfaces") == 1) { + REQUIRE(oss.str() == "rx_framescaught [0]\n"); + } else { + REQUIRE(oss.str() == "rx_framescaught [0, 0]\n"); + } + } + + // Currently disabled may activate if we have a stable env + // Now take one frame and see that we caught it + // det.setNumberOfFrames(1); + // det.acquire(); + // { + // std::ostringstream oss; + // caller.call("rx_framescaught", {}, -1, GET, oss); + // REQUIRE(oss.str() == "rx_framescaught 1\n"); + // } + + for (int i = 0; i != det.size(); ++i) { + det.setFileWrite(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_framescaught", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_missingpackets", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFileWrite(); + det.setFileWrite(false); // avoid writing or error on file creation + Caller caller(&det); + auto prev_frames = + det.getNumberOfFrames().tsquash("inconsistent #frames in test"); + det.setNumberOfFrames(100); + { + // some missing packets + det.startReceiver(); + det.stopReceiver(); + std::ostringstream oss; + caller.call("rx_missingpackets", {}, -1, GET, oss); + if (det.getNumberofUDPInterfaces().tsquash( + "inconsistent number of interfaces") == 1) { + REQUIRE(oss.str() != "rx_missingpackets [0]\n"); + } else { + REQUIRE(oss.str() != "rx_missingpackets [0, 0]\n"); + } + } + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { + // 0 missing packets (takes into account that acquisition is + // stopped) + det.startReceiver(); + det.startDetector(); + det.stopDetector(); + det.stopReceiver(); + std::ostringstream oss; + caller.call("rx_missingpackets", {}, -1, GET, oss); + if (det.getNumberofUDPInterfaces().tsquash( + "inconsistent number of interfaces") == 1) { + REQUIRE(oss.str() == "rx_missingpackets [0]\n"); + } else { + REQUIRE(oss.str() == "rx_missingpackets [0, 0]\n"); + } + } + for (int i = 0; i != det.size(); ++i) { + det.setFileWrite(prev_val[i], {i}); + } + det.setNumberOfFrames(prev_frames); + } else { + REQUIRE_THROWS(caller.call("rx_missingpackets", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_frameindex", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + caller.call("rx_frameindex", {}, -1, GET); + + // This is a get only command + REQUIRE_THROWS(caller.call("rx_frameindex", {"2"}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("rx_frameindex", {}, -1, GET)); + } +} + +/* Network Configuration (Detector<->Receiver) */ + +TEST_CASE("Caller::rx_printconfig", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_NOTHROW(caller.call("rx_printconfig", {}, -1, GET)); + } else { + REQUIRE_THROWS(caller.call("rx_printconfig", {}, -1, GET)); + } +} + +/* Receiver Config */ + +TEST_CASE("Caller::rx_hostname", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxHostname(); + + // Cannot set rx_hostname (will reset parameters in rxr and no shm + // variables to update) + // { + // // disable receiver + // std::ostringstream oss; + // caller.call("rx_hostname", {"none"}, -1, PUT, oss); + // REQUIRE(oss.str() == "rx_hostname [none]\n"); + // } + // { + // std::ostringstream oss; + // caller.call("rx_hostname", {}, -1, GET, oss); + // REQUIRE(oss.str() == "rx_hostname none\n"); + // // receiver should be disabled + // REQUIRE(det.getUseReceiverFlag().tsquash( + // "different values of flag in test") == false); + // } + // put back old values (not necessary when we dont set it to none) + // for (int i = 0; i != det.size(); ++i) { + // det.setRxHostname(prev_val[i], {i}); + // } + { + std::ostringstream oss; + caller.call("rx_hostname", {}, 0, GET, oss); + REQUIRE(oss.str() == "rx_hostname " + prev_val[0] + "\n"); + } + } else { + REQUIRE_THROWS(caller.call("rx_hostname", {"localhost"}, -1, PUT)); + } +} + +TEST_CASE("Caller::rx_tcpport", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto prev_val = det.getRxPort(); + + uint16_t port = 3500; + caller.call("rx_tcpport", {std::to_string(port)}, -1, PUT); + for (int i = 0; i != det.size(); ++i) { + std::ostringstream oss; + caller.call("rx_tcpport", {}, i, GET, oss); + REQUIRE(oss.str() == "rx_tcpport " + std::to_string(port + i) + '\n'); + } + port = 5754; + caller.call("rx_tcpport", {std::to_string(port)}, -1, PUT); + for (int i = 0; i != det.size(); ++i) { + std::ostringstream oss; + caller.call("rx_tcpport", {}, i, GET, oss); + REQUIRE(oss.str() == "rx_tcpport " + std::to_string(port + i) + '\n'); + } + test_valid_port_caller("rx_tcpport", {}, -1, PUT); + test_valid_port_caller("rx_tcpport", {}, 0, PUT); + // should fail for the second module + if (det.size() > 1) { + REQUIRE_THROWS(caller.call("rx_tcpport", {"65535"}, -1, PUT)); + auto rxHostname = det.getRxHostname().squash("none"); + if (rxHostname != "none") { + std::ostringstream oss; + for (int i = 0; i != det.size(); ++i) { + oss << rxHostname << ":" << 65536 + i << "+"; + } + REQUIRE_THROWS(caller.call("rx_hostname", {oss.str()}, -1, PUT)); + } + } + + for (int i = 0; i != det.size(); ++i) { + det.setRxPort(prev_val[i], i); + } +} + +TEST_CASE("Caller::rx_fifodepth", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxFifoDepth(); + { + std::ostringstream oss; + caller.call("rx_fifodepth", {"10"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_fifodepth 10\n"); + } + { + std::ostringstream oss; + caller.call("rx_fifodepth", {"100"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_fifodepth 100\n"); + } + { + std::ostringstream oss; + caller.call("rx_fifodepth", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_fifodepth 100\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxFifoDepth(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_fifodepth", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_silent", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxSilentMode(); + { + std::ostringstream oss; + caller.call("rx_silent", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_silent 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_silent", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_silent 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_silent", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_silent 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxSilentMode(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_silent", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_discardpolicy", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxFrameDiscardPolicy(); + { + std::ostringstream oss; + caller.call("rx_discardpolicy", {"discardempty"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_discardpolicy discardempty\n"); + } + { + std::ostringstream oss; + caller.call("rx_discardpolicy", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_discardpolicy discardempty\n"); + } + { + std::ostringstream oss; + caller.call("rx_discardpolicy", {"discardpartial"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_discardpolicy discardpartial\n"); + } + { + std::ostringstream oss; + caller.call("rx_discardpolicy", {"nodiscard"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_discardpolicy nodiscard\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxFrameDiscardPolicy(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_discardpolicy", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_padding", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getPartialFramesPadding(); + { + std::ostringstream oss; + caller.call("rx_padding", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_padding 0\n"); + } + { + std::ostringstream oss; + caller.call("rx_padding", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_padding 0\n"); + } + { + std::ostringstream oss; + caller.call("rx_padding", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_padding 1\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setPartialFramesPadding(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_padding", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_udpsocksize", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + int64_t prev_val = det.getRxUDPSocketBufferSize().tsquash( + "Need same udp socket buffer size to test"); + std::string s_new_val = std::to_string(prev_val); + /*std::string s_new_val = std::to_string(prev_val - 1000); + { Need permissions + std::ostringstream oss; + caller.call("rx_udpsocksize", {s_new_val}, -1, PUT, oss); + REQUIRE(oss.str() >= "rx_udpsocksize " + s_new_val + "\n"); + }*/ + { + std::ostringstream oss; + caller.call("rx_udpsocksize", {}, -1, GET, oss); + REQUIRE(oss.str() >= "rx_udpsocksize " + s_new_val + "\n"); + } + det.setRxUDPSocketBufferSize(prev_val); + } else { + REQUIRE_THROWS(caller.call("rx_udpsocksize", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_realudpsocksize", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + uint64_t val = 0; + { + std::ostringstream oss; + caller.call("rx_udpsocksize", {}, -1, GET, oss); + std::string s = (oss.str()).erase(0, strlen("rx_udpsocksize ")); + val = std::stol(s); + } + { + std::ostringstream oss; + caller.call("rx_realudpsocksize", {}, -1, GET, oss); + std::string s = (oss.str()).erase(0, strlen("rx_realudpsocksize ")); + uint64_t rval = std::stol(s); + REQUIRE(rval >= val * 2); + } + } else { + REQUIRE_THROWS(caller.call("rx_realudpsocksize", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_lock", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxLock(); + { + std::ostringstream oss; + caller.call("rx_lock", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_lock 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_lock", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_lock 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_lock", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_lock 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxLock(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_lock", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_lastclient", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::ostringstream oss; + REQUIRE_NOTHROW(caller.call("rx_lastclient", {}, -1, GET, oss)); + if (test::my_ip != "undefined") { + REQUIRE(oss.str() == "rx_lastclient " + test::my_ip + "\n"); + } + } else { + REQUIRE_THROWS(caller.call("rx_lastclient", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_threads", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::ostringstream oss; + REQUIRE_NOTHROW(caller.call("rx_threads", {}, -1, GET, oss)); + } else { + REQUIRE_THROWS(caller.call("rx_threads", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_arping", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxArping(); + { + std::ostringstream oss; + caller.call("rx_arping", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_arping 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_arping", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_arping 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_arping", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_arping 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxArping(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_arping", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_roi", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("rx_roi", {"5", "10"}, -1, PUT)); + } else { + auto prev_val = det.getRxROI(); + defs::xy detsize = det.getDetectorSize(); + + // 1d + if (det_type == defs::GOTTHARD || det_type == defs::GOTTHARD2 || + det_type == defs::MYTHEN3) { + { + std::ostringstream oss; + caller.call("rx_roi", {"5", "10"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_roi [5, 10]\n"); + } + { + std::ostringstream oss; + caller.call("rx_roi", {"10", "15"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_roi [10, 15]\n"); + } + REQUIRE_THROWS(caller.call("rx_roi", {"-1", "-1"}, -1, PUT)); + REQUIRE_THROWS( + caller.call("rx_roi", {"10", "15", "25", "30"}, -1, PUT)); + } + // 2d + else { + { + std::ostringstream oss; + caller.call("rx_roi", {"10", "15", "1", "5"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_roi [10, 15, 1, 5]\n"); + } + { + std::ostringstream oss; + caller.call("rx_roi", {"10", "22", "18", "19"}, -1, PUT, + oss); + REQUIRE(oss.str() == "rx_roi [10, 22, 18, 19]\n"); + } + { + std::ostringstream oss; + caller.call("rx_roi", + {"1", std::to_string(detsize.x - 5), "1", + std::to_string(detsize.y - 5)}, + -1, PUT, oss); + REQUIRE(oss.str() == std::string("rx_roi [1, ") + + std::to_string(detsize.x - 5) + + std::string(", 1, ") + + std::to_string(detsize.y - 5) + + std::string("]\n")); + } + REQUIRE_THROWS( + caller.call("rx_roi", {"-1", "-1", "-1", "-1"}, -1, PUT)); + } + + for (int i = 0; i != det.size(); ++i) { + det.setRxROI(prev_val); + } + } + } else { + REQUIRE_THROWS(caller.call("rx_roi", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_clearroi", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + if (det_type == defs::CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("rx_clearroi", {}, -1, PUT)); + } else { + auto prev_val = det.getRxROI(); + { + std::ostringstream oss; + caller.call("rx_clearroi", {}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_clearroi successful\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxROI(prev_val); + } + } + } else { + REQUIRE_THROWS(caller.call("rx_clearroi", {}, -1, PUT)); + } +} + +/* File */ + +TEST_CASE("Caller::fformat", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFileFormat(); + { + std::ostringstream oss; + caller.call("fformat", {"binary"}, -1, PUT, oss); + REQUIRE(oss.str() == "fformat binary\n"); + } + { + std::ostringstream oss; + caller.call("fformat", {}, -1, GET, oss); + REQUIRE(oss.str() == "fformat binary\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setFileFormat(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("fformat", {}, -1, GET)); + } +} + +TEST_CASE("Caller::fpath", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFilePath(); + { + std::ostringstream oss; + caller.call("fpath", {"/tmp"}, -1, PUT, oss); + REQUIRE(oss.str() == "fpath /tmp\n"); + } + { + std::ostringstream oss; + caller.call("fpath", {}, -1, GET, oss); + REQUIRE(oss.str() == "fpath /tmp\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setFilePath(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("fpath", {}, -1, GET)); + } +} + +TEST_CASE("Caller::fname", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFileNamePrefix(); + { + std::ostringstream oss; + caller.call("fname", {"somename"}, -1, PUT, oss); + REQUIRE(oss.str() == "fname somename\n"); + } + { + std::ostringstream oss; + caller.call("fname", {}, -1, GET, oss); + REQUIRE(oss.str() == "fname somename\n"); + } + { + std::ostringstream oss; + caller.call("fname", {"run"}, -1, PUT, oss); + REQUIRE(oss.str() == "fname run\n"); + } + REQUIRE_THROWS(caller.call("fname", {"fdf/dfd"}, -1, PUT)); + REQUIRE_THROWS(caller.call("fname", {"fdf dfd"}, -1, PUT)); + + for (int i = 0; i != det.size(); ++i) { + det.setFileNamePrefix(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("fname", {}, -1, GET)); + } +} + +TEST_CASE("Caller::findex", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getAcquisitionIndex(); + { + std::ostringstream oss; + caller.call("findex", {"57"}, -1, PUT, oss); + REQUIRE(oss.str() == "findex 57\n"); + } + { + std::ostringstream oss; + caller.call("findex", {}, -1, GET, oss); + REQUIRE(oss.str() == "findex 57\n"); + } + { + std::ostringstream oss; + caller.call("findex", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "findex 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setAcquisitionIndex(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("findex", {}, -1, GET)); + } +} + +TEST_CASE("Caller::fwrite", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFileWrite(); + { + std::ostringstream oss; + caller.call("fwrite", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "fwrite 1\n"); + } + { + std::ostringstream oss; + caller.call("fwrite", {}, -1, GET, oss); + REQUIRE(oss.str() == "fwrite 1\n"); + } + { + std::ostringstream oss; + caller.call("fwrite", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "fwrite 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setFileWrite(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("fwrite", {}, -1, GET)); + } +} + +TEST_CASE("Caller::fmaster", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getMasterFileWrite(); + { + std::ostringstream oss; + caller.call("fmaster", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "fmaster 0\n"); + } + { + std::ostringstream oss; + caller.call("fmaster", {}, -1, GET, oss); + REQUIRE(oss.str() == "fmaster 0\n"); + } + { + std::ostringstream oss; + caller.call("fmaster", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "fmaster 1\n"); + } + det.setMasterFileWrite(prev_val); + } else { + REQUIRE_THROWS(caller.call("fmaster", {}, -1, GET)); + } +} + +TEST_CASE("Caller::foverwrite", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFileOverWrite(); + { + std::ostringstream oss; + caller.call("foverwrite", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "foverwrite 1\n"); + } + { + std::ostringstream oss; + caller.call("foverwrite", {}, -1, GET, oss); + REQUIRE(oss.str() == "foverwrite 1\n"); + } + { + std::ostringstream oss; + caller.call("foverwrite", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "foverwrite 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setFileOverWrite(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("foverwrite", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_framesperfile", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getFramesPerFile(); + { + std::ostringstream oss; + caller.call("rx_framesperfile", {"50"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_framesperfile 50\n"); + } + { + std::ostringstream oss; + caller.call("rx_framesperfile", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_framesperfile 50\n"); + } + { + std::ostringstream oss; + caller.call("rx_framesperfile", {"10000"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_framesperfile 10000\n"); + } + { + std::ostringstream oss; + caller.call("rx_framesperfile", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_framesperfile 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setFramesPerFile(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_framesperfile", {}, -1, GET)); + } +} + +/* ZMQ Streaming Parameters (Receiver<->Client) */ + +TEST_CASE("Caller::rx_zmqstream", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxZmqDataStream(); + { + std::ostringstream oss; + caller.call("rx_zmqstream", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqstream 1\n"); + REQUIRE(det.getRxZmqDataStream().squash() == true); + } + { + std::ostringstream oss; + caller.call("rx_zmqstream", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_zmqstream 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqstream", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqstream 0\n"); + REQUIRE(det.getRxZmqDataStream().squash() == false); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqDataStream(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_zmqstream", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_zmqfreq", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxZmqFrequency(); + { + std::ostringstream oss; + caller.call("rx_zmqfreq", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqfreq 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqfreq", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_zmqfreq 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqfreq", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqfreq 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqFrequency(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_zmqfreq", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_zmqstartfnum", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxZmqStartingFrame(); + { + std::ostringstream oss; + caller.call("rx_zmqstartfnum", {"5"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqstartfnum 5\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqstartfnum", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_zmqstartfnum 5\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqstartfnum", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqstartfnum 0\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqStartingFrame(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_zmqstartfnum", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_zmqport", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val_zmqport = det.getRxZmqPort(); + auto prev_val_numinterfaces = det.getNumberofUDPInterfaces().tsquash( + "inconsistent number of udp interfaces to test"); + + int socketsperdetector = 1; + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::EIGER) { + socketsperdetector *= 2; + } else if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { + caller.call("numinterfaces", {"2"}, -1, PUT); + socketsperdetector *= 2; + } + uint16_t port = 3500; + caller.call("rx_zmqport", {std::to_string(port)}, -1, PUT); + for (int i = 0; i != det.size(); ++i) { + std::ostringstream oss; + caller.call("rx_zmqport", {}, i, GET, oss); + REQUIRE(oss.str() == + "rx_zmqport " + + std::to_string(port + i * socketsperdetector) + '\n'); + } + port = 30001; + caller.call("rx_zmqport", {std::to_string(port)}, -1, PUT); + for (int i = 0; i != det.size(); ++i) { + std::ostringstream oss; + caller.call("rx_zmqport", {}, i, GET, oss); + REQUIRE(oss.str() == + "rx_zmqport " + + std::to_string(port + i * socketsperdetector) + '\n'); + } + test_valid_port_caller("rx_zmqport", {}, -1, PUT); + test_valid_port_caller("rx_zmqport", {}, 0, PUT); + // should fail for the second module + if (det.size() > 1) { + REQUIRE_THROWS(caller.call("rx_zmqport", {"65535"}, -1, PUT)); + } + + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqPort(prev_val_zmqport[i], i); + } + if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { + det.setNumberofUDPInterfaces(prev_val_numinterfaces); + } + } else { + REQUIRE_THROWS(caller.call("rx_zmqport", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_zmqip", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxZmqIP(); + { + std::ostringstream oss; + caller.call("rx_zmqip", {"127.0.0.1"}, 0, PUT, oss); + REQUIRE(oss.str() == "rx_zmqip 127.0.0.1\n"); + std::cout << "ZMQIP: " << det.getRxZmqIP() << '\n'; + } + { + std::ostringstream oss; + caller.call("rx_zmqip", {}, 0, GET, oss); + REQUIRE(oss.str() == "rx_zmqip 127.0.0.1\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqIP(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_zmqip", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_zmqhwm", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getRxZmqHwm().tsquash( + "Inconsistent values for rx_zmqhwm to test"); + { + std::ostringstream oss; + caller.call("rx_zmqhwm", {"50"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqhwm 50\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqhwm", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_zmqhwm 50\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqhwm", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqhwm 0\n"); + } + { + std::ostringstream oss; + caller.call("rx_zmqhwm", {"-1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_zmqhwm -1\n"); + } + det.setRxZmqHwm(prev_val); + } else { + REQUIRE_THROWS(caller.call("rx_zmqhwm", {}, -1, GET)); + } +} + +/* CTB Specific */ + +TEST_CASE("Caller::rx_dbitlist", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::CHIPTESTBOARD) { + auto prev_val = det.getRxDbitList(); + { + std::ostringstream oss; + caller.call("rx_dbitlist", + {"0", "4", "5", "8", "9", "10", "52", "63"}, -1, PUT, + oss); + REQUIRE(oss.str() == "rx_dbitlist [0, 4, 5, 8, 9, 10, 52, 63]\n"); + } + { + std::ostringstream oss; + caller.call("rx_dbitlist", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_dbitlist [0, 4, 5, 8, 9, 10, 52, 63]\n"); + } + REQUIRE_THROWS(caller.call("rx_dbitlist", {"67"}, -1, PUT)); + REQUIRE_THROWS(caller.call("rx_dbitlist", {"-1"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("rx_dbitlist", {"all"}, -1, PUT)); + for (int i = 0; i != det.size(); ++i) { + det.setRxDbitList(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_dbitlist", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_dbitoffset", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type == defs::CHIPTESTBOARD) { + auto prev_val = det.getRxDbitOffset(); + { + std::ostringstream oss; + caller.call("rx_dbitoffset", {"1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_dbitoffset 1\n"); + } + { + std::ostringstream oss; + caller.call("rx_dbitoffset", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_dbitoffset 0\n"); + } + { + std::ostringstream oss; + caller.call("rx_dbitoffset", {"15"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_dbitoffset 15\n"); + } + { + std::ostringstream oss; + caller.call("rx_dbitoffset", {}, -1, GET, oss); + REQUIRE(oss.str() == "rx_dbitoffset 15\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setRxDbitOffset(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_dbitoffset", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_jsonaddheader", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getAdditionalJsonHeader(); + + { + std::ostringstream oss; + caller.call("rx_jsonaddheader", + {"key1", "value1", "key2", "value2"}, -1, PUT, oss); + REQUIRE(oss.str() == + "rx_jsonaddheader {key1: value1, key2: value2}\n"); + } + { + std::ostringstream oss; + caller.call("rx_jsonaddheader", {}, -1, GET, oss); + REQUIRE(oss.str() == + "rx_jsonaddheader {key1: value1, key2: value2}\n"); + } + { + std::ostringstream oss; + caller.call("rx_jsonaddheader", {}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_jsonaddheader {}\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setAdditionalJsonHeader(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_jsonaddheader", {}, -1, GET)); + } +} + +TEST_CASE("Caller::rx_jsonpara", "[.cmdcall][.rx]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getAdditionalJsonHeader(); + { + std::ostringstream oss; + caller.call("rx_jsonpara", {"key1", "value1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_jsonpara {key1: value1}\n"); + } + { + std::ostringstream oss; + caller.call("rx_jsonpara", {"key1", "value2"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_jsonpara {key1: value2}\n"); + } + { + std::ostringstream oss; + caller.call("rx_jsonpara", {"key1"}, -1, GET, oss); + REQUIRE(oss.str() == "rx_jsonpara value2\n"); + } + { + std::ostringstream oss; + caller.call("rx_jsonpara", {"key1"}, -1, PUT, oss); + REQUIRE(oss.str() == "rx_jsonpara key1 deleted\n"); + } + REQUIRE_THROWS(caller.call("rx_jsonpara", {"key1"}, -1, GET)); + for (int i = 0; i != det.size(); ++i) { + det.setAdditionalJsonHeader(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("rx_jsonpara", {}, -1, GET)); + } +} + +/* Insignificant */ + +} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy.cpp b/slsDetectorSoftware/tests/Caller/test-Caller.cpp similarity index 52% rename from slsDetectorSoftware/tests/test-CmdProxy.cpp rename to slsDetectorSoftware/tests/Caller/test-Caller.cpp index 6e819ecd9..5a94f9a61 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy.cpp +++ b/slsDetectorSoftware/tests/Caller/test-Caller.cpp @@ -1,11 +1,11 @@ // SPDX-License-Identifier: LGPL-3.0-or-other // Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" +#include "Caller.h" #include "catch.hpp" #include "sls/Detector.h" #include "sls/file_utils.h" #include "sls/sls_detector_defs.h" -#include "test-CmdProxy-global.h" +#include "test-Caller-global.h" #include #include @@ -18,52 +18,51 @@ namespace sls { using test::GET; using test::PUT; -TEST_CASE("Calling help doesn't throw or cause segfault") { - // Dont add [.cmd] tag this should run with normal tests - CmdProxy proxy(nullptr); - auto commands = proxy.GetProxyCommands(); +TEST_CASE("CALLER::Caller::Calling help doesn't throw or cause segfault") { + // Dont add [.cmdcall] tag this should run with normal tests + Caller caller(nullptr); std::ostringstream os; - for (const auto &cmd : commands) + for (std::string cmd : caller.getAllCommands()) REQUIRE_NOTHROW( - proxy.Call(cmd, {}, -1, slsDetectorDefs::HELP_ACTION, os)); + caller.call(cmd, {}, -1, slsDetectorDefs::HELP_ACTION, os)); } -TEST_CASE("Unknown command", "[.cmd]") { +TEST_CASE("CALLER::Unknown command", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("vsaevrreavv", {}, -1, PUT)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("vsaevrreavv", {}, -1, PUT)); } /* configuration */ -TEST_CASE("config", "[.cmd]") { +TEST_CASE("CALLER::config", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); // put only - REQUIRE_THROWS(proxy.Call("config", {}, -1, GET)); + REQUIRE_THROWS(caller.call("config", {}, -1, GET)); } // free: not testing -TEST_CASE("parameters", "[.cmd]") { +TEST_CASE("CALLER::parameters", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); // put only - REQUIRE_THROWS(proxy.Call("parameters", {}, -1, GET)); + REQUIRE_THROWS(caller.call("parameters", {}, -1, GET)); /* auto prev_val = det.getNumberOfFrames().tsquash("Number of frames has to be same to test"); { system("echo 'frames 2' > /tmp/tempsetup.det "); std::ostringstream oss; - proxy.Call("parameters", {"/tmp/tempsetup.det"}, -1, PUT, oss); + caller.call("parameters", {"/tmp/tempsetup.det"}, -1, PUT, oss); REQUIRE(oss.str() == "parameters /tmp/tempsetup.det\n"); REQUIRE(det.getNumberOfFrames().tsquash("failed") == 2); } { system("echo '0:frames 1' > /tmp/tempsetup.det "); std::ostringstream oss; - proxy.Call("parameters", {"/tmp/tempsetup.det"}, -1, PUT, oss); + caller.call("parameters", {"/tmp/tempsetup.det"}, -1, PUT, oss); REQUIRE(oss.str() == "parameters /tmp/tempsetup.det\n"); REQUIRE(det.getNumberOfFrames({0}).tsquash("failed") == 1); } @@ -71,126 +70,127 @@ TEST_CASE("parameters", "[.cmd]") { */ } -TEST_CASE("hostname", "[.cmd]") { +TEST_CASE("CALLER::hostname", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("hostname", {}, -1, GET)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("hostname", {}, -1, GET)); } -TEST_CASE("virtual", "[.cmd]") { +TEST_CASE("CALLER::virtual", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("virtual", {}, -1, GET)); - test_valid_port("virtual", {"1"}, -1, PUT); - REQUIRE_THROWS(proxy.Call("virtual", {"3", "65534"}, -1, PUT)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("virtual", {}, -1, GET)); + test_valid_port_caller("virtual", {"1"}, -1, PUT); + REQUIRE_THROWS(caller.call("virtual", {"3", "65534"}, -1, PUT)); } -TEST_CASE("versions", "[.cmd]") { +TEST_CASE("CALLER::versions", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("versions", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("versions", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("versions", {}, -1, GET)); + REQUIRE_THROWS(caller.call("versions", {"0"}, -1, PUT)); } -TEST_CASE("packageversion", "[.cmd]") { +TEST_CASE("CALLER::packageversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("packageversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("packageversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("packageversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("packageversion", {"0"}, -1, PUT)); } -TEST_CASE("clientversion", "[.cmd]") { +TEST_CASE("CALLER::clientversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("clientversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clientversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("clientversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("clientversion", {"0"}, -1, PUT)); } -TEST_CASE("firmwareversion", "[.cmd]") { +TEST_CASE("CALLER::firmwareversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("firmwareversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("firmwareversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("firmwareversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("firmwareversion", {"0"}, -1, PUT)); } -TEST_CASE("detectorserverversion", "[.cmd]") { +TEST_CASE("CALLER::detectorserverversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("detectorserverversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("detectorserverversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("detectorserverversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("detectorserverversion", {"0"}, -1, PUT)); } -TEST_CASE("hardwareversion", "[.cmd]") { +TEST_CASE("CALLER::hardwareversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("hardwareversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("hardwareversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("hardwareversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("hardwareversion", {"0"}, -1, PUT)); } -TEST_CASE("kernelversion", "[.cmd]") { +TEST_CASE("CALLER::kernelversion", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("kernelversion", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("kernelversion", {"0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("kernelversion", {}, -1, GET)); + REQUIRE_THROWS(caller.call("kernelversion", {"0"}, -1, PUT)); } -TEST_CASE("serialnumber", "[.cmd]") { +TEST_CASE("CALLER::serialnumber", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("serialnumber", {}, -1, GET)); + if (det_type == defs::EIGER || det_type == defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("serialnumber", {}, -1, GET)); } else { - REQUIRE_NOTHROW(proxy.Call("serialnumber", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("serialnumber", {}, -1, GET)); } } -TEST_CASE("moduleid", "[.cmd]") { +TEST_CASE("CALLER::moduleid", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2 || det_type == defs::MYTHEN3 || det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - REQUIRE_NOTHROW(proxy.Call("moduleid", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("moduleid", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("moduleid", {}, -1, GET)); + REQUIRE_THROWS(caller.call("moduleid", {}, -1, GET)); } } -TEST_CASE("type", "[.cmd]") { +TEST_CASE("CALLER::type", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto dt = det.getDetectorType().squash(); std::ostringstream oss; - proxy.Call("type", {}, -1, GET, oss); + caller.call("type", {}, -1, GET, oss); auto ans = oss.str().erase(0, strlen("type ")); REQUIRE(ans == ToString(dt) + '\n'); // REQUIRE(dt == test::type); } -TEST_CASE("detsize", "[.cmd]") { +TEST_CASE("CALLER::detsize", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("detsize", {}, -1, GET)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("detsize", {}, -1, GET)); } -TEST_CASE("settingslist", "[.cmd]") { +TEST_CASE("CALLER::settingslist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_THROWS(proxy.Call("settingslist", {}, -1, GET)); + if (det_type == defs::CHIPTESTBOARD || + det_type == defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("settingslist", {}, -1, GET)); } else { - REQUIRE_NOTHROW(proxy.Call("settingslist", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("settingslist", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("settingslist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("settingslist", {}, -1, PUT)); } } -TEST_CASE("settings", "[.cmd]") { +TEST_CASE("CALLER::settings", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); std::vector allSett; allSett.push_back("standard"); @@ -252,10 +252,10 @@ TEST_CASE("settings", "[.cmd]") { default: if (det_type == defs::EIGER) { // FIXME: need to remove when settings removed - REQUIRE_NOTHROW(proxy.Call("settings", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("settings", {"standard"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("settings", {}, -1, GET)); + REQUIRE_THROWS(caller.call("settings", {"standard"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("settings", {}, -1, GET)); + REQUIRE_THROWS(caller.call("settings", {}, -1, GET)); } return; } @@ -264,18 +264,18 @@ TEST_CASE("settings", "[.cmd]") { for (auto &it : sett) { { std::ostringstream oss; - proxy.Call("settings", {it}, -1, PUT, oss); + caller.call("settings", {it}, -1, PUT, oss); REQUIRE(oss.str() == "settings " + it + "\n"); } { std::ostringstream oss; - proxy.Call("settings", {}, -1, GET, oss); + caller.call("settings", {}, -1, GET, oss); REQUIRE(oss.str() == "settings " + it + "\n"); } } for (auto &it : allSett) { if (std::find(sett.begin(), sett.end(), it) == sett.end()) { - REQUIRE_THROWS(proxy.Call("settings", {it}, -1, PUT)); + REQUIRE_THROWS(caller.call("settings", {it}, -1, PUT)); } } for (int i = 0; i != det.size(); ++i) { @@ -286,9 +286,9 @@ TEST_CASE("settings", "[.cmd]") { } } -TEST_CASE("threshold", "[.cmd]") { +TEST_CASE("CALLER::threshold", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { @@ -298,15 +298,15 @@ TEST_CASE("threshold", "[.cmd]") { if (!prev_energies.empty()) { std::string senergy = std::to_string(prev_energies[0]); std::ostringstream oss1, oss2; - proxy.Call("threshold", {senergy, "standard"}, -1, PUT, oss1); + caller.call("threshold", {senergy, "standard"}, -1, PUT, oss1); REQUIRE(oss1.str() == "threshold [" + senergy + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss2); + caller.call("threshold", {}, -1, GET, oss2); REQUIRE(oss2.str() == "threshold " + senergy + "\n"); - REQUIRE_THROWS(proxy.Call( + REQUIRE_THROWS(caller.call( "threshold", {senergy, senergy, senergy, "standard"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("threshold", {senergy, "undefined"}, -1, PUT)); + caller.call("threshold", {senergy, "undefined"}, -1, PUT)); det.setTrimEnergies(prev_energies); for (int i = 0; i != det.size(); ++i) { @@ -316,7 +316,7 @@ TEST_CASE("threshold", "[.cmd]") { } } } - REQUIRE_NOTHROW(proxy.Call("threshold", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("threshold", {}, -1, GET)); } else if (det_type == defs::MYTHEN3) { auto prev_threshold = det.getAllThresholdEnergy(); auto prev_settings = @@ -326,29 +326,29 @@ TEST_CASE("threshold", "[.cmd]") { if (!prev_energies.empty()) { std::string senergy = std::to_string(prev_energies[0]); std::ostringstream oss1, oss2; - proxy.Call("threshold", {senergy, "standard"}, -1, PUT, oss1); + caller.call("threshold", {senergy, "standard"}, -1, PUT, oss1); REQUIRE(oss1.str() == "threshold [" + senergy + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss2); + caller.call("threshold", {}, -1, GET, oss2); REQUIRE(oss2.str() == "threshold [" + senergy + ", " + senergy + ", " + senergy + "]\n"); std::string senergy2 = std::to_string(prev_energies[1]); std::string senergy3 = std::to_string(prev_energies[2]); std::ostringstream oss3, oss4; - proxy.Call("threshold", {senergy, senergy2, senergy3, "standard"}, - -1, PUT, oss3); + caller.call("threshold", {senergy, senergy2, senergy3, "standard"}, + -1, PUT, oss3); REQUIRE(oss3.str() == "threshold [" + senergy + ", " + senergy2 + ", " + senergy3 + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss4); + caller.call("threshold", {}, -1, GET, oss4); REQUIRE(oss4.str() == "threshold [" + senergy + ", " + senergy2 + ", " + senergy3 + "]\n"); - REQUIRE_THROWS(proxy.Call("threshold", - {senergy, senergy, "standard"}, -1, PUT)); + REQUIRE_THROWS(caller.call( + "threshold", {senergy, senergy, "standard"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("threshold", {senergy, "undefined"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("threshold", {senergy}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("threshold", - {senergy, senergy2, senergy3}, -1, PUT)); + caller.call("threshold", {senergy, "undefined"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("threshold", {senergy}, -1, PUT)); + REQUIRE_NOTHROW(caller.call( + "threshold", {senergy, senergy2, senergy3}, -1, PUT)); det.setTrimEnergies(prev_energies); for (int i = 0; i != det.size(); ++i) { if (prev_threshold[i][0] >= 0) { @@ -359,15 +359,15 @@ TEST_CASE("threshold", "[.cmd]") { } } } - REQUIRE_NOTHROW(proxy.Call("threshold", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("threshold", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("threshold", {}, -1, GET)); + REQUIRE_THROWS(caller.call("threshold", {}, -1, GET)); } } -TEST_CASE("thresholdnotb", "[.cmd]") { +TEST_CASE("CALLER::thresholdnotb", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { @@ -377,16 +377,16 @@ TEST_CASE("thresholdnotb", "[.cmd]") { if (!prev_energies.empty()) { std::string senergy = std::to_string(prev_energies[0]); std::ostringstream oss1, oss2; - proxy.Call("thresholdnotb", {senergy, "standard"}, -1, PUT, oss1); + caller.call("thresholdnotb", {senergy, "standard"}, -1, PUT, oss1); REQUIRE(oss1.str() == "thresholdnotb [" + senergy + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss2); + caller.call("threshold", {}, -1, GET, oss2); REQUIRE(oss2.str() == "threshold " + senergy + "\n"); - REQUIRE_THROWS(proxy.Call("thresholdnotb", - {senergy, senergy, senergy, "standard"}, - -1, PUT)); + REQUIRE_THROWS(caller.call("thresholdnotb", + {senergy, senergy, senergy, "standard"}, + -1, PUT)); REQUIRE_THROWS( - proxy.Call("thresholdnotb", {senergy, "undefined"}, -1, PUT)); + caller.call("thresholdnotb", {senergy, "undefined"}, -1, PUT)); det.setTrimEnergies(prev_energies); for (int i = 0; i != det.size(); ++i) { if (prev_threshold[i] >= 0) { @@ -395,7 +395,7 @@ TEST_CASE("thresholdnotb", "[.cmd]") { } } } - REQUIRE_NOTHROW(proxy.Call("threshold", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("threshold", {}, -1, GET)); } else if (det_type == defs::MYTHEN3) { auto prev_threshold = det.getAllThresholdEnergy(); auto prev_settings = @@ -405,32 +405,32 @@ TEST_CASE("thresholdnotb", "[.cmd]") { if (!prev_energies.empty()) { std::string senergy = std::to_string(prev_energies[0]); std::ostringstream oss1, oss2; - proxy.Call("thresholdnotb", {senergy, "standard"}, -1, PUT, oss1); + caller.call("thresholdnotb", {senergy, "standard"}, -1, PUT, oss1); REQUIRE(oss1.str() == "thresholdnotb [" + senergy + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss2); + caller.call("threshold", {}, -1, GET, oss2); REQUIRE(oss2.str() == "threshold [" + senergy + ", " + senergy + ", " + senergy + "]\n"); std::string senergy2 = std::to_string(prev_energies[1]); std::string senergy3 = std::to_string(prev_energies[2]); std::ostringstream oss3, oss4; - proxy.Call("thresholdnotb", - {senergy, senergy2, senergy3, "standard"}, -1, PUT, - oss3); + caller.call("thresholdnotb", + {senergy, senergy2, senergy3, "standard"}, -1, PUT, + oss3); REQUIRE(oss3.str() == "thresholdnotb [" + senergy + ", " + senergy2 + ", " + senergy3 + ", standard]\n"); - proxy.Call("threshold", {}, -1, GET, oss4); + caller.call("threshold", {}, -1, GET, oss4); REQUIRE(oss4.str() == "threshold [" + senergy + ", " + senergy2 + ", " + senergy3 + "]\n"); - REQUIRE_THROWS(proxy.Call("thresholdnotb", - {senergy, senergy, "standard"}, -1, PUT)); + REQUIRE_THROWS(caller.call( + "thresholdnotb", {senergy, senergy, "standard"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("thresholdnotb", {senergy, "undefined"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("thresholdnotb", {senergy}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("thresholdnotb", - {senergy, senergy2, senergy3}, -1, PUT)); + caller.call("thresholdnotb", {senergy, "undefined"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("thresholdnotb", {senergy}, -1, PUT)); + REQUIRE_NOTHROW(caller.call( + "thresholdnotb", {senergy, senergy2, senergy3}, -1, PUT)); det.setTrimEnergies(prev_energies); for (int i = 0; i != det.size(); ++i) { if (prev_threshold[i][0] >= 0) { @@ -439,21 +439,21 @@ TEST_CASE("thresholdnotb", "[.cmd]") { } } } - REQUIRE_NOTHROW(proxy.Call("threshold", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("threshold", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("thresholdnotb", {}, -1, GET)); + REQUIRE_THROWS(caller.call("thresholdnotb", {}, -1, GET)); } } -TEST_CASE("settingspath", "[.cmd]") { +TEST_CASE("CALLER::settingspath", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getSettingsPath(); { std::ostringstream oss1, oss2; - proxy.Call("settingspath", {"/tmp"}, -1, PUT, oss1); + caller.call("settingspath", {"/tmp"}, -1, PUT, oss1); REQUIRE(oss1.str() == "settingspath /tmp\n"); - proxy.Call("settingspath", {}, -1, GET, oss2); + caller.call("settingspath", {}, -1, GET, oss2); REQUIRE(oss2.str() == "settingspath /tmp\n"); } for (int i = 0; i != det.size(); ++i) { @@ -461,70 +461,71 @@ TEST_CASE("settingspath", "[.cmd]") { } } -TEST_CASE("trimbits", "[.cmd]") { +TEST_CASE("CALLER::trimbits", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("trimbits", {}, -1, GET)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("trimbits", {}, -1, GET)); } -TEST_CASE("trimval", "[.cmd]") { +TEST_CASE("CALLER::trimval", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3 || det_type == defs::EIGER) { auto prev_val = det.getAllTrimbits(); { std::ostringstream oss; - proxy.Call("trimval", {"63"}, -1, PUT, oss); + caller.call("trimval", {"63"}, -1, PUT, oss); REQUIRE(oss.str() == "trimval 63\n"); } { std::ostringstream oss; - proxy.Call("trimval", {"0"}, -1, PUT, oss); + caller.call("trimval", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "trimval 0\n"); } { std::ostringstream oss; - proxy.Call("trimval", {}, -1, GET, oss); + caller.call("trimval", {}, -1, GET, oss); REQUIRE(oss.str() == "trimval 0\n"); } - REQUIRE_THROWS(proxy.Call("trimval", {"64"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("trimval", {"-2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("trimval", {"64"}, -1, PUT)); + REQUIRE_THROWS(caller.call("trimval", {"-2"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { if (prev_val[i] != -1) { det.setAllTrimbits(prev_val[i], {i}); } } } else { - REQUIRE_THROWS(proxy.Call("trimval", {}, -1, GET)); + REQUIRE_THROWS(caller.call("trimval", {}, -1, GET)); } } -TEST_CASE("trimen", "[.cmd][.this]") { +TEST_CASE("CALLER::trimen", "[.cmdcall][.this]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::MYTHEN3) { auto previous = det.getTrimEnergies(); std::ostringstream oss1, oss2; - proxy.Call("trimen", {"4500", "5400", "6400"}, -1, PUT, oss1); + caller.call("trimen", {"4500", "5400", "6400"}, -1, PUT, oss1); REQUIRE(oss1.str() == "trimen [4500, 5400, 6400]\n"); - proxy.Call("trimen", {}, -1, GET, oss2); + caller.call("trimen", {}, -1, GET, oss2); REQUIRE(oss2.str() == "trimen [4500, 5400, 6400]\n"); for (int i = 0; i != det.size(); ++i) { det.setTrimEnergies(previous[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("trimen", {"4500", "5400", "6400"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("trimen", {}, -1, GET)); + REQUIRE_THROWS( + caller.call("trimen", {"4500", "5400", "6400"}, -1, PUT)); + REQUIRE_THROWS(caller.call("trimen", {}, -1, GET)); } } -TEST_CASE("gappixels", "[.cmd]") { +TEST_CASE("CALLER::gappixels", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); // test eiger(quad or full module only) @@ -543,38 +544,38 @@ TEST_CASE("gappixels", "[.cmd]") { auto prev_val = det.getGapPixelsinCallback(); { std::ostringstream oss; - proxy.Call("gappixels", {"1"}, -1, PUT, oss); + caller.call("gappixels", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "gappixels 1\n"); } { std::ostringstream oss; - proxy.Call("gappixels", {"0"}, -1, PUT, oss); + caller.call("gappixels", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gappixels 0\n"); } { std::ostringstream oss; - proxy.Call("gappixels", {}, -1, GET, oss); + caller.call("gappixels", {}, -1, GET, oss); REQUIRE(oss.str() == "gappixels 0\n"); } det.setGapPixelsinCallback(prev_val); } else { { std::ostringstream oss; - proxy.Call("gappixels", {}, -1, GET, oss); + caller.call("gappixels", {}, -1, GET, oss); REQUIRE(oss.str() == "gappixels 0\n"); } { std::ostringstream oss; - proxy.Call("gappixels", {"0"}, -1, PUT, oss); + caller.call("gappixels", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "gappixels 0\n"); } - REQUIRE_THROWS(proxy.Call("gappixels", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("gappixels", {"1"}, -1, PUT)); } } -TEST_CASE("fliprows", "[.cmd]") { +TEST_CASE("CALLER::fliprows", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); bool hw2 = false; if ((det_type == defs::JUNGFRAU || det_type == defs::MOENCH) && @@ -590,11 +591,11 @@ TEST_CASE("fliprows", "[.cmd]") { det.setNumberofUDPInterfaces(2); } std::ostringstream oss1, oss2, oss3; - proxy.Call("fliprows", {"1"}, -1, PUT, oss1); + caller.call("fliprows", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "fliprows 1\n"); - proxy.Call("fliprows", {}, -1, GET, oss2); + caller.call("fliprows", {}, -1, GET, oss2); REQUIRE(oss2.str() == "fliprows 1\n"); - proxy.Call("fliprows", {"0"}, -1, PUT, oss3); + caller.call("fliprows", {"0"}, -1, PUT, oss3); REQUIRE(oss3.str() == "fliprows 0\n"); for (int i = 0; i != det.size(); ++i) { det.setFlipRows(previous[i], {i}); @@ -603,18 +604,18 @@ TEST_CASE("fliprows", "[.cmd]") { det.setNumberofUDPInterfaces(previous_numudp); } } else { - REQUIRE_THROWS(proxy.Call("fliprows", {}, -1, GET)); + REQUIRE_THROWS(caller.call("fliprows", {}, -1, GET)); } } -TEST_CASE("master", "[.cmd]") { +TEST_CASE("CALLER::master", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD || det_type == defs::GOTTHARD2 || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - REQUIRE_NOTHROW(proxy.Call("master", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("master", {}, -1, GET)); if (det_type == defs::EIGER || det_type == defs::GOTTHARD2 || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { // get previous master @@ -630,16 +631,16 @@ TEST_CASE("master", "[.cmd]") { } { std::ostringstream oss1; - proxy.Call("master", {"0"}, 0, PUT, oss1); + caller.call("master", {"0"}, 0, PUT, oss1); REQUIRE(oss1.str() == "master 0\n"); } { std::ostringstream oss1; - proxy.Call("master", {"1"}, 0, PUT, oss1); + caller.call("master", {"1"}, 0, PUT, oss1); REQUIRE(oss1.str() == "master 1\n"); } if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("master", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("master", {"1"}, -1, PUT)); } // set all to slaves, and then master for (int i = 0; i != det.size(); ++i) { @@ -648,69 +649,69 @@ TEST_CASE("master", "[.cmd]") { det.setMaster(1, prevMaster); } } else { - REQUIRE_THROWS(proxy.Call("master", {}, -1, GET)); + REQUIRE_THROWS(caller.call("master", {}, -1, GET)); } } -TEST_CASE("badchannels", "[.cmd]") { +TEST_CASE("CALLER::badchannels", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2 || det_type == defs::MYTHEN3) { auto prev = det.getBadChannels(); - REQUIRE_THROWS(proxy.Call("badchannels", {}, -1, GET)); + REQUIRE_THROWS(caller.call("badchannels", {}, -1, GET)); std::string fname_put = getAbsolutePathFromCurrentProcess(TEST_FILE_NAME_BAD_CHANNELS); std::string fname_get = "/tmp/sls_test_channels.txt"; - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_put}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_put}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); auto list = getChannelsFromFile(fname_get); std::vector expected = {0, 12, 15, 40, 41, 42, 43, 44, 1279}; REQUIRE(list == expected); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"none"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"none"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); REQUIRE(list.empty()); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_put}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_put}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"0"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"0"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); REQUIRE(list.empty()); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"12"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"12"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); expected = {12}; REQUIRE(list == expected); - REQUIRE_NOTHROW(proxy.Call( + REQUIRE_NOTHROW(caller.call( "badchannels", {"0", "12,", "15", "43", "40:45", "1279"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); expected = {0, 12, 15, 40, 41, 42, 43, 44, 1279}; REQUIRE(list == expected); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"40:45"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"40:45"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); expected = {40, 41, 42, 43, 44}; REQUIRE(list == expected); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"5,6,7"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"5,6,7"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); expected = {5, 6, 7}; REQUIRE(list == expected); - REQUIRE_NOTHROW(proxy.Call("badchannels", {"1:5,6,7"}, 0, PUT)); - REQUIRE_NOTHROW(proxy.Call("badchannels", {fname_get}, 0, GET)); + REQUIRE_NOTHROW(caller.call("badchannels", {"1:5,6,7"}, 0, PUT)); + REQUIRE_NOTHROW(caller.call("badchannels", {fname_get}, 0, GET)); list = getChannelsFromFile(fname_get); expected = {1, 2, 3, 4, 6, 7}; REQUIRE(list == expected); @@ -718,53 +719,53 @@ TEST_CASE("badchannels", "[.cmd]") { det.setBadChannels(prev); } else { - REQUIRE_THROWS(proxy.Call("badchannels", {}, -1, GET)); + REQUIRE_THROWS(caller.call("badchannels", {}, -1, GET)); } } -TEST_CASE("row", "[.cmd]") { +TEST_CASE("CALLER::row", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getRow()[0]; { std::ostringstream oss; - proxy.Call("row", {"1"}, 0, PUT, oss); + caller.call("row", {"1"}, 0, PUT, oss); REQUIRE(oss.str() == "row 1\n"); } { std::ostringstream oss; - proxy.Call("row", {}, 0, GET, oss); + caller.call("row", {}, 0, GET, oss); REQUIRE(oss.str() == "row 1\n"); } { std::ostringstream oss; - proxy.Call("row", {"0"}, 0, PUT, oss); + caller.call("row", {"0"}, 0, PUT, oss); REQUIRE(oss.str() == "row 0\n"); } - REQUIRE_THROWS(proxy.Call("row", {"-5"}, -1, PUT)); + REQUIRE_THROWS(caller.call("row", {"-5"}, -1, PUT)); det.setRow(prev_val, {0}); } -TEST_CASE("column", "[.cmd]") { +TEST_CASE("CALLER::column", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getColumn()[0]; { std::ostringstream oss; - proxy.Call("column", {"1"}, 0, PUT, oss); + caller.call("column", {"1"}, 0, PUT, oss); REQUIRE(oss.str() == "column 1\n"); } { std::ostringstream oss; - proxy.Call("column", {}, 0, GET, oss); + caller.call("column", {}, 0, GET, oss); REQUIRE(oss.str() == "column 1\n"); } { std::ostringstream oss; - proxy.Call("column", {"0"}, 0, PUT, oss); + caller.call("column", {"0"}, 0, PUT, oss); REQUIRE(oss.str() == "column 0\n"); } - REQUIRE_THROWS(proxy.Call("column", {"-5"}, -1, PUT)); + REQUIRE_THROWS(caller.call("column", {"-5"}, -1, PUT)); det.setColumn(prev_val, {0}); } @@ -772,229 +773,244 @@ TEST_CASE("column", "[.cmd]") { // acquire: not testing -TEST_CASE("frames", "[.cmd]") { +TEST_CASE("CALLER::frames", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getNumberOfFrames().tsquash("#frames must be same to test"); { std::ostringstream oss; - proxy.Call("frames", {"1000"}, -1, PUT, oss); + caller.call("frames", {"1000"}, -1, PUT, oss); REQUIRE(oss.str() == "frames 1000\n"); } { std::ostringstream oss; - proxy.Call("frames", {}, -1, GET, oss); + caller.call("frames", {}, -1, GET, oss); REQUIRE(oss.str() == "frames 1000\n"); } { std::ostringstream oss; - proxy.Call("frames", {"1"}, -1, PUT, oss); + caller.call("frames", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "frames 1\n"); } - REQUIRE_THROWS(proxy.Call("frames", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("frames", {"0"}, -1, PUT)); det.setNumberOfFrames(prev_val); } -TEST_CASE("triggers", "[.cmd]") { +TEST_CASE("CALLER::triggers", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getNumberOfTriggers().tsquash("#triggers must be same to test"); { std::ostringstream oss; - proxy.Call("triggers", {"1000"}, -1, PUT, oss); + caller.call("triggers", {"1000"}, -1, PUT, oss); REQUIRE(oss.str() == "triggers 1000\n"); } { std::ostringstream oss; - proxy.Call("triggers", {}, -1, GET, oss); + caller.call("triggers", {}, -1, GET, oss); REQUIRE(oss.str() == "triggers 1000\n"); } { std::ostringstream oss; - proxy.Call("triggers", {"1"}, -1, PUT, oss); + caller.call("triggers", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "triggers 1\n"); } - REQUIRE_THROWS(proxy.Call("triggers", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("triggers", {"0"}, -1, PUT)); det.setNumberOfTriggers(prev_val); } -TEST_CASE("exptime", "[.cmd][.time]") { +TEST_CASE("CALLER::exptime", "[.cmdcall][.time]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - std::chrono::nanoseconds prev_val; - if (det_type != defs::MYTHEN3) { - prev_val = det.getExptime().tsquash("inconsistent exptime to test"); - } else { - auto t = - det.getExptimeForAllGates().tsquash("inconsistent exptime to test"); - if (t[0] != t[1] || t[1] != t[2]) { - throw RuntimeError("inconsistent exptime for all gates"); - } - prev_val = t[0]; - } - { - std::ostringstream oss; - proxy.Call("exptime", {"0.05"}, -1, PUT, oss); - REQUIRE(oss.str() == "exptime 0.05\n"); - } - if (det_type != defs::MYTHEN3) { - std::ostringstream oss; - proxy.Call("exptime", {}, -1, GET, oss); - REQUIRE(oss.str() == "exptime 50ms\n"); - } - { - std::ostringstream oss; - proxy.Call("exptime", {"1s"}, -1, PUT, oss); - REQUIRE(oss.str() == "exptime 1s\n"); - } - if (det_type != defs::JUNGFRAU && det_type != defs::MOENCH) { - { - std::ostringstream oss; - proxy.Call("exptime", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "exptime 0\n"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::chrono::nanoseconds prev_val; + if (det_type != defs::MYTHEN3) { + prev_val = det.getExptime().tsquash("inconsistent exptime to test"); + } else { + auto t = det.getExptimeForAllGates().tsquash( + "inconsistent exptime to test"); + if (t[0] != t[1] || t[1] != t[2]) { + throw RuntimeError("inconsistent exptime for all gates"); + } + prev_val = t[0]; } { - // Get exptime of single module std::ostringstream oss; - proxy.Call("exptime", {}, 0, GET, oss); - if (det_type == defs::MYTHEN3) { - REQUIRE(oss.str() == "exptime [0ns, 0ns, 0ns]\n"); - } else { - REQUIRE(oss.str() == "exptime 0ns\n"); + caller.call("exptime", {"0.05"}, -1, PUT, oss); + REQUIRE(oss.str() == "exptime 0.05\n"); + } + if (det_type != defs::MYTHEN3) { + std::ostringstream oss; + caller.call("exptime", {}, -1, GET, oss); + REQUIRE(oss.str() == "exptime 50ms\n"); + } + { + std::ostringstream oss; + caller.call("exptime", {"1s"}, -1, PUT, oss); + REQUIRE(oss.str() == "exptime 1s\n"); + } + if (det_type != defs::JUNGFRAU && det_type != defs::MOENCH) { + { + std::ostringstream oss; + caller.call("exptime", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "exptime 0\n"); + } + { + // Get exptime of single module + std::ostringstream oss; + caller.call("exptime", {}, 0, GET, oss); + if (det_type == defs::MYTHEN3) { + REQUIRE(oss.str() == "exptime [0ns, 0ns, 0ns]\n"); + } else { + REQUIRE(oss.str() == "exptime 0ns\n"); + } } } - } - det.setExptime(-1, prev_val); -} - -TEST_CASE("period", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getPeriod(); - { - std::ostringstream oss; - proxy.Call("period", {"1.25s"}, -1, PUT, oss); - REQUIRE(oss.str() == "period 1.25s\n"); - } - { - std::ostringstream oss; - proxy.Call("period", {}, -1, GET, oss); - REQUIRE(oss.str() == "period 1.25s\n"); - } - { - std::ostringstream oss; - proxy.Call("period", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "period 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setPeriod(prev_val[i], {i}); - } -} - -TEST_CASE("delay", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("delay", {"1"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("delay", {}, -1, GET)); - } else if (det_type == defs::GOTTHARD) { - // extra delays for master (can throw when setting) - REQUIRE_NOTHROW(proxy.Call("delay", {}, -1, GET)); + det.setExptime(-1, prev_val); } else { - auto prev_val = det.getDelayAfterTrigger(); + REQUIRE_THROWS(caller.call("exptime", {}, -1, GET)); + } +} + +TEST_CASE("CALLER::period", "[.cmdcall]") { + Detector det; + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getPeriod(); { std::ostringstream oss; - proxy.Call("delay", {"1.25s"}, -1, PUT, oss); - REQUIRE(oss.str() == "delay 1.25s\n"); + caller.call("period", {"1.25s"}, -1, PUT, oss); + REQUIRE(oss.str() == "period 1.25s\n"); } { std::ostringstream oss; - proxy.Call("delay", {}, -1, GET, oss); - REQUIRE(oss.str() == "delay 1.25s\n"); + caller.call("period", {}, -1, GET, oss); + REQUIRE(oss.str() == "period 1.25s\n"); } { std::ostringstream oss; - proxy.Call("delay", {"0s"}, -1, PUT, oss); - REQUIRE(oss.str() == "delay 0s\n"); + caller.call("period", {"0"}, -1, PUT, oss); + REQUIRE(oss.str() == "period 0\n"); } for (int i = 0; i != det.size(); ++i) { - det.setDelayAfterTrigger(prev_val[i], {i}); + det.setPeriod(prev_val[i], {i}); } + } else { + REQUIRE_THROWS(caller.call("period", {}, -1, GET)); } } -TEST_CASE("framesl", "[.cmd]") { +TEST_CASE("CALLER::delay", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + if (det_type == defs::EIGER) { + REQUIRE_THROWS(caller.call("delay", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("delay", {}, -1, GET)); + } else if (det_type == defs::GOTTHARD) { + // extra delays for master (can throw when setting) + REQUIRE_NOTHROW(caller.call("delay", {}, -1, GET)); + } else { + auto prev_val = det.getDelayAfterTrigger(); + { + std::ostringstream oss; + caller.call("delay", {"1.25s"}, -1, PUT, oss); + REQUIRE(oss.str() == "delay 1.25s\n"); + } + { + std::ostringstream oss; + caller.call("delay", {}, -1, GET, oss); + REQUIRE(oss.str() == "delay 1.25s\n"); + } + { + std::ostringstream oss; + caller.call("delay", {"0s"}, -1, PUT, oss); + REQUIRE(oss.str() == "delay 0s\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setDelayAfterTrigger(prev_val[i], {i}); + } + } + } else { + REQUIRE_THROWS(caller.call("delay", {}, -1, GET)); + } +} + +TEST_CASE("CALLER::framesl", "[.cmdcall]") { + Detector det; + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("framesl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("framesl", {}, -1, GET)); } else { - REQUIRE_NOTHROW(proxy.Call("framesl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("framesl", {}, -1, GET)); } } -TEST_CASE("triggersl", "[.cmd]") { +TEST_CASE("CALLER::triggersl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("triggersl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("triggersl", {}, -1, GET)); } else { - REQUIRE_NOTHROW(proxy.Call("triggersl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("triggersl", {}, -1, GET)); } } -TEST_CASE("delayl", "[.cmd]") { +TEST_CASE("CALLER::delayl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); switch (det_type) { case defs::EIGER: case defs::CHIPTESTBOARD: + case defs::XILINX_CHIPTESTBOARD: case defs::GOTTHARD2: case defs::MYTHEN3: - REQUIRE_THROWS(proxy.Call("delayl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("delayl", {}, -1, GET)); break; default: - REQUIRE_NOTHROW(proxy.Call("delayl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("delayl", {}, -1, GET)); break; } } -TEST_CASE("periodl", "[.cmd]") { +TEST_CASE("CALLER::periodl", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); switch (det_type) { case defs::EIGER: case defs::CHIPTESTBOARD: + case defs::XILINX_CHIPTESTBOARD: case defs::GOTTHARD2: case defs::MYTHEN3: - REQUIRE_THROWS(proxy.Call("periodl", {}, -1, GET)); + REQUIRE_THROWS(caller.call("periodl", {}, -1, GET)); break; default: - REQUIRE_NOTHROW(proxy.Call("periodl", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("periodl", {}, -1, GET)); break; } } -TEST_CASE("dr", "[.cmd]") { +TEST_CASE("CALLER::dr", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { auto dr = det.getDynamicRange().squash(); std::array vals{4, 8, 16, 32}; for (const auto val : vals) { std::ostringstream oss1, oss2; - proxy.Call("dr", {std::to_string(val)}, -1, PUT, oss1); + caller.call("dr", {std::to_string(val)}, -1, PUT, oss1); REQUIRE(oss1.str() == "dr " + std::to_string(val) + '\n'); - proxy.Call("dr", {}, -1, GET, oss2); + caller.call("dr", {}, -1, GET, oss2); REQUIRE(oss2.str() == "dr " + std::to_string(val) + '\n'); } det.setDynamicRange(dr); @@ -1004,106 +1020,106 @@ TEST_CASE("dr", "[.cmd]") { std::array vals{8, 16, 32}; for (const auto val : vals) { std::ostringstream oss1, oss2; - proxy.Call("dr", {std::to_string(val)}, -1, PUT, oss1); + caller.call("dr", {std::to_string(val)}, -1, PUT, oss1); REQUIRE(oss1.str() == "dr " + std::to_string(val) + '\n'); - proxy.Call("dr", {}, -1, GET, oss2); + caller.call("dr", {}, -1, GET, oss2); REQUIRE(oss2.str() == "dr " + std::to_string(val) + '\n'); } det.setDynamicRange(dr); } else { // For the other detectors we should get an error message // except for dr 16 - REQUIRE_THROWS(proxy.Call("dr", {"4"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("dr", {"8"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("dr", {"32"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dr", {"4"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dr", {"8"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dr", {"32"}, -1, PUT)); std::ostringstream oss1, oss2; - proxy.Call("dr", {"16"}, -1, PUT, oss1); + caller.call("dr", {"16"}, -1, PUT, oss1); REQUIRE(oss1.str() == "dr 16\n"); - proxy.Call("dr", {"16"}, -1, PUT, oss2); + caller.call("dr", {"16"}, -1, PUT, oss2); REQUIRE(oss2.str() == "dr 16\n"); } } -TEST_CASE("drlist", "[.cmd]") { +TEST_CASE("CALLER::drlist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("drlist", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("drlist", {}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("drlist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("drlist", {}, -1, PUT)); } -TEST_CASE("timing", "[.cmd]") { +TEST_CASE("CALLER::timing", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); auto prev_val = det.getTimingMode(); det.setTimingMode(defs::AUTO_TIMING); { std::ostringstream oss1, oss2; - proxy.Call("timing", {"auto"}, -1, PUT, oss1); + caller.call("timing", {"auto"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing auto\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing auto\n"); } { std::ostringstream oss1, oss2; - proxy.Call("timing", {"trigger"}, -1, PUT, oss1); + caller.call("timing", {"trigger"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing trigger\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing trigger\n"); } - auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER) { { std::ostringstream oss1, oss2; - proxy.Call("timing", {"gating"}, -1, PUT, oss1); + caller.call("timing", {"gating"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing gating\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing gating\n"); } { std::ostringstream oss1, oss2; - proxy.Call("timing", {"burst_trigger"}, -1, PUT, oss1); + caller.call("timing", {"burst_trigger"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing burst_trigger\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing burst_trigger\n"); } - REQUIRE_THROWS(proxy.Call("timing", {"trigger_gating"}, -1, PUT)); + REQUIRE_THROWS(caller.call("timing", {"trigger_gating"}, -1, PUT)); } else if (det_type == defs::MYTHEN3) { { std::ostringstream oss1, oss2; - proxy.Call("timing", {"gating"}, -1, PUT, oss1); + caller.call("timing", {"gating"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing gating\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing gating\n"); } { std::ostringstream oss1, oss2; - proxy.Call("timing", {"trigger_gating"}, -1, PUT, oss1); + caller.call("timing", {"trigger_gating"}, -1, PUT, oss1); REQUIRE(oss1.str() == "timing trigger_gating\n"); - proxy.Call("timing", {}, -1, GET, oss2); + caller.call("timing", {}, -1, GET, oss2); REQUIRE(oss2.str() == "timing trigger_gating\n"); } - REQUIRE_THROWS(proxy.Call("timing", {"burst_trigger"}, -1, PUT)); + REQUIRE_THROWS(caller.call("timing", {"burst_trigger"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("timing", {"gating"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("timing", {"burst_trigger"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("timing", {"trigger_gating"}, -1, PUT)); + REQUIRE_THROWS(caller.call("timing", {"gating"}, -1, PUT)); + REQUIRE_THROWS(caller.call("timing", {"burst_trigger"}, -1, PUT)); + REQUIRE_THROWS(caller.call("timing", {"trigger_gating"}, -1, PUT)); } for (int i = 0; i != det.size(); ++i) { det.setTimingMode(prev_val[i], {i}); } } -TEST_CASE("timinglist", "[.cmd]") { +TEST_CASE("CALLER::timinglist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("timinglist", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("timinglist", {}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("timinglist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("timinglist", {}, -1, PUT)); } -TEST_CASE("readoutspeed", "[.cmd]") { +TEST_CASE("CALLER::readoutspeed", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2) { @@ -1115,13 +1131,13 @@ TEST_CASE("readoutspeed", "[.cmd]") { det.getChipVersion().squash() * 10 == 11) || (det_type == defs::EIGER) || (det_type == defs::MOENCH)) { std::ostringstream oss1, oss2, oss3, oss4; - proxy.Call("readoutspeed", {"0"}, -1, PUT, oss1); + caller.call("readoutspeed", {"0"}, -1, PUT, oss1); REQUIRE(oss1.str() == "readoutspeed full_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss2); + caller.call("readoutspeed", {}, -1, GET, oss2); REQUIRE(oss2.str() == "readoutspeed full_speed\n"); - proxy.Call("readoutspeed", {"full_speed"}, -1, PUT, oss3); + caller.call("readoutspeed", {"full_speed"}, -1, PUT, oss3); REQUIRE(oss3.str() == "readoutspeed full_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss4); + caller.call("readoutspeed", {}, -1, GET, oss4); REQUIRE(oss4.str() == "readoutspeed full_speed\n"); } @@ -1129,104 +1145,106 @@ TEST_CASE("readoutspeed", "[.cmd]") { det_type == defs::MOENCH) { { std::ostringstream oss1, oss2, oss3, oss4; - proxy.Call("readoutspeed", {"1"}, -1, PUT, oss1); + caller.call("readoutspeed", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "readoutspeed half_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss2); + caller.call("readoutspeed", {}, -1, GET, oss2); REQUIRE(oss2.str() == "readoutspeed half_speed\n"); - proxy.Call("readoutspeed", {"half_speed"}, -1, PUT, oss3); + caller.call("readoutspeed", {"half_speed"}, -1, PUT, oss3); REQUIRE(oss3.str() == "readoutspeed half_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss4); + caller.call("readoutspeed", {}, -1, GET, oss4); REQUIRE(oss4.str() == "readoutspeed half_speed\n"); } { std::ostringstream oss1, oss2, oss3, oss4; - proxy.Call("readoutspeed", {"2"}, -1, PUT, oss1); + caller.call("readoutspeed", {"2"}, -1, PUT, oss1); REQUIRE(oss1.str() == "readoutspeed quarter_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss2); + caller.call("readoutspeed", {}, -1, GET, oss2); REQUIRE(oss2.str() == "readoutspeed quarter_speed\n"); - proxy.Call("readoutspeed", {"quarter_speed"}, -1, PUT, oss3); + caller.call("readoutspeed", {"quarter_speed"}, -1, PUT, oss3); REQUIRE(oss3.str() == "readoutspeed quarter_speed\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss4); + caller.call("readoutspeed", {}, -1, GET, oss4); REQUIRE(oss4.str() == "readoutspeed quarter_speed\n"); } - REQUIRE_THROWS(proxy.Call("readoutspeed", {"108"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {"144"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {"108"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {"144"}, -1, PUT)); } if (det_type == defs::GOTTHARD2) { { std::ostringstream oss1, oss2, oss3, oss4; - proxy.Call("readoutspeed", {"108"}, -1, PUT, oss1); + caller.call("readoutspeed", {"108"}, -1, PUT, oss1); REQUIRE(oss1.str() == "readoutspeed 108\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss2); + caller.call("readoutspeed", {}, -1, GET, oss2); REQUIRE(oss2.str() == "readoutspeed 108\n"); } { std::ostringstream oss1, oss2, oss3, oss4; - proxy.Call("readoutspeed", {"144"}, -1, PUT, oss1); + caller.call("readoutspeed", {"144"}, -1, PUT, oss1); REQUIRE(oss1.str() == "readoutspeed 144\n"); - proxy.Call("readoutspeed", {}, -1, GET, oss2); + caller.call("readoutspeed", {}, -1, GET, oss2); REQUIRE(oss2.str() == "readoutspeed 144\n"); } - REQUIRE_THROWS(proxy.Call("readoutspeed", {"full_speed"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {"half_speed"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("readoutspeed", {"quarter_speed"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {"0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {"1"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {"2"}, -1, PUT)); + caller.call("readoutspeed", {"full_speed"}, -1, PUT)); + REQUIRE_THROWS( + caller.call("readoutspeed", {"half_speed"}, -1, PUT)); + REQUIRE_THROWS( + caller.call("readoutspeed", {"quarter_speed"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {"2"}, -1, PUT)); } for (int i = 0; i != det.size(); ++i) { det.setReadoutSpeed(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("readoutspeed", {"0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readoutspeed", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readoutspeed", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readoutspeed", {}, -1, GET)); } } -TEST_CASE("readoutspeedlist", "[.cmd]") { +TEST_CASE("CALLER::readoutspeedlist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2 || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::EIGER) { - REQUIRE_NOTHROW(proxy.Call("readoutspeedlist", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("readoutspeedlist", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("readoutspeedlist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readoutspeedlist", {}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("readoutspeedlist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readoutspeedlist", {}, -1, GET)); } } -TEST_CASE("adcphase", "[.cmd]") { +TEST_CASE("CALLER::adcphase", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD) { if (det_type == defs::GOTTHARD) { std::ostringstream oss1; - proxy.Call("adcphase", {"20"}, -1, PUT, oss1); + caller.call("adcphase", {"20"}, -1, PUT, oss1); REQUIRE(oss1.str() == "adcphase 20\n"); // cant get, cant use deg - REQUIRE_THROWS(proxy.Call("adcphase", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("adcphase", {"20", "deg"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcphase", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcphase", {"20", "deg"}, -1, PUT)); } else { auto prev_val = det.getADCPhase(); { std::ostringstream oss1, oss2; - proxy.Call("adcphase", {"20"}, -1, PUT, oss1); + caller.call("adcphase", {"20"}, -1, PUT, oss1); REQUIRE(oss1.str() == "adcphase 20\n"); - proxy.Call("adcphase", {}, -1, GET, oss2); + caller.call("adcphase", {}, -1, GET, oss2); REQUIRE(oss2.str() == "adcphase 20\n"); } { std::ostringstream oss1, oss2; - proxy.Call("adcphase", {"20", "deg"}, -1, PUT, oss1); + caller.call("adcphase", {"20", "deg"}, -1, PUT, oss1); REQUIRE(oss1.str() == "adcphase 20 deg\n"); - proxy.Call("adcphase", {"deg"}, -1, GET, oss2); + caller.call("adcphase", {"deg"}, -1, GET, oss2); REQUIRE(oss2.str() == "adcphase 20 deg\n"); } for (int i = 0; i != det.size(); ++i) { @@ -1234,96 +1252,96 @@ TEST_CASE("adcphase", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("adcphase", {"0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("adcphase", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcphase", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcphase", {}, -1, GET)); } } -TEST_CASE("maxadcphaseshift", "[.cmd]") { +TEST_CASE("CALLER::maxadcphaseshift", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || // only because clk index of 0 exists det_type == defs::GOTTHARD2) { // only because clk index of 0 exists - REQUIRE_NOTHROW(proxy.Call("maxadcphaseshift", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("maxadcphaseshift", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("maxadcphaseshift", {}, -1, GET)); + REQUIRE_THROWS(caller.call("maxadcphaseshift", {}, -1, GET)); } } -TEST_CASE("dbitphase", "[.cmd]") { +TEST_CASE("CALLER::dbitphase", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::CHIPTESTBOARD) { auto prev_val = det.getDBITPhase(); { std::ostringstream oss1, oss2; - proxy.Call("dbitphase", {"20"}, -1, PUT, oss1); + caller.call("dbitphase", {"20"}, -1, PUT, oss1); REQUIRE(oss1.str() == "dbitphase 20\n"); - proxy.Call("dbitphase", {}, -1, GET, oss2); + caller.call("dbitphase", {}, -1, GET, oss2); REQUIRE(oss2.str() == "dbitphase 20\n"); } { std::ostringstream oss1, oss2; - proxy.Call("dbitphase", {"23", "deg"}, -1, PUT, oss1); + caller.call("dbitphase", {"23", "deg"}, -1, PUT, oss1); REQUIRE(oss1.str() == "dbitphase 23 deg\n"); - proxy.Call("dbitphase", {"deg"}, -1, GET, oss2); + caller.call("dbitphase", {"deg"}, -1, GET, oss2); REQUIRE(oss2.str() == "dbitphase 23 deg\n"); } for (int i = 0; i != det.size(); ++i) { det.setDBITPhase(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("dbitphase", {"0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("dbitphase", {}, -1, GET)); + REQUIRE_THROWS(caller.call("dbitphase", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dbitphase", {}, -1, GET)); } } -TEST_CASE("maxdbitphaseshift", "[.cmd]") { +TEST_CASE("CALLER::maxdbitphaseshift", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || // only because clk index of 0 exists det_type == defs::GOTTHARD2) { // only because clk index of 0 exists - REQUIRE_NOTHROW(proxy.Call("maxdbitphaseshift", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("maxdbitphaseshift", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("maxdbitphaseshift", {}, -1, GET)); + REQUIRE_THROWS(caller.call("maxdbitphaseshift", {}, -1, GET)); } } -TEST_CASE("clkfreq", "[.cmd]") { +TEST_CASE("CALLER::clkfreq", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("clkfreq", {"0", "2"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clkfreq", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clkfreq", {"7"}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("clkfreq", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkfreq", {"0", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkfreq", {}, -1, GET)); + REQUIRE_THROWS(caller.call("clkfreq", {"7"}, -1, GET)); + REQUIRE_NOTHROW(caller.call("clkfreq", {"0"}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("clkfreq", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkfreq", {"0"}, -1, GET)); } } -TEST_CASE("clkphase", "[.cmd]") { +TEST_CASE("CALLER::clkphase", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("clkphase", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clkphase", {"7"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clkphase", {"4"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clkphase", {"7", "4"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkphase", {}, -1, GET)); + REQUIRE_THROWS(caller.call("clkphase", {"7"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkphase", {"4"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkphase", {"7", "4"}, -1, PUT)); auto prev_val = det.getClockPhase(0); { std::ostringstream oss1, oss2; - proxy.Call("clkphase", {"0", "20"}, -1, PUT, oss1); + caller.call("clkphase", {"0", "20"}, -1, PUT, oss1); REQUIRE(oss1.str() == "clkphase 20\n"); - proxy.Call("clkphase", {"0"}, -1, GET, oss2); + caller.call("clkphase", {"0"}, -1, GET, oss2); REQUIRE(oss2.str() == "clkphase 20\n"); } std::string s_deg_val = "15"; @@ -1334,160 +1352,165 @@ TEST_CASE("clkphase", "[.cmd]") { } { std::ostringstream oss1, oss2; - proxy.Call("clkphase", {"0", s_deg_val, "deg"}, -1, PUT, oss1); + caller.call("clkphase", {"0", s_deg_val, "deg"}, -1, PUT, oss1); REQUIRE(oss1.str() == "clkphase " + s_deg_val + " deg\n"); - proxy.Call("clkphase", {"0", "deg"}, -1, GET, oss2); + caller.call("clkphase", {"0", "deg"}, -1, GET, oss2); REQUIRE(oss2.str() == "clkphase " + s_deg_val + " deg\n"); } for (int i = 0; i != det.size(); ++i) { det.setClockPhase(0, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("clkphase", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkphase", {"0"}, -1, GET)); } } -TEST_CASE("clkdiv", "[.cmd]") { +TEST_CASE("CALLER::clkdiv", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("clkdiv", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clkdiv", {"7"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("clkdiv", {"7", "4"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clkdiv", {"7", "4"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clkdiv", {"0", "1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkdiv", {}, -1, GET)); + REQUIRE_THROWS(caller.call("clkdiv", {"7"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkdiv", {"7", "4"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkdiv", {"7", "4"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clkdiv", {"0", "1"}, -1, PUT)); auto prev_val = det.getClockDivider(0); { std::ostringstream oss1, oss2; - proxy.Call("clkdiv", {"0", "3"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "clkdiv 3\n"); - proxy.Call("clkdiv", {"0"}, -1, GET, oss2); - REQUIRE(oss2.str() == "clkdiv 3\n"); + caller.call("clkdiv", {"0", "3"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "clkdiv 0 3\n"); + caller.call("clkdiv", {"0"}, -1, GET, oss2); + REQUIRE(oss2.str() == "clkdiv 0 3\n"); } for (int i = 0; i != det.size(); ++i) { det.setClockDivider(0, prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("clkdiv", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("clkdiv", {"0"}, -1, GET)); } } -TEST_CASE("maxclkphaseshift", "[.cmd]") { +TEST_CASE("CALLER::maxclkphaseshift", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("maxclkphaseshift", {"0", "2"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("maxclkphaseshift", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("maxclkphaseshift", {"7"}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("maxclkphaseshift", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("maxclkphaseshift", {"0", "2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("maxclkphaseshift", {}, -1, GET)); + REQUIRE_THROWS(caller.call("maxclkphaseshift", {"7"}, -1, GET)); + REQUIRE_NOTHROW(caller.call("maxclkphaseshift", {"0"}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("maxclkphaseshift", {"0"}, -1, GET)); + REQUIRE_THROWS(caller.call("maxclkphaseshift", {"0"}, -1, GET)); } } -TEST_CASE("highvoltage", "[.cmd]") { +TEST_CASE("CALLER::highvoltage", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - auto prev_val = det.getHighVoltage(); - // selected values - if (det_type == defs::GOTTHARD) { - REQUIRE_THROWS(proxy.Call("highvoltage", {"50"}, -1, PUT)); - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"90"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 90\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 90\n"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getHighVoltage(); + // selected values + if (det_type == defs::GOTTHARD) { + REQUIRE_THROWS(caller.call("highvoltage", {"50"}, -1, PUT)); + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"90"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 90\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 90\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"0"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 0\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 0\n"); + } } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"0"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 0\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 0\n"); + // range 0, 60 - 200 + else if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || + det_type == defs::CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("highvoltage", {"50"}, -1, PUT)); + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"90"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 90\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 90\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"0"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 0\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 0\n"); + } } - } - // range 0, 60 - 200 - else if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || - det_type == defs::CHIPTESTBOARD) { - REQUIRE_THROWS(proxy.Call("highvoltage", {"50"}, -1, PUT)); - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"90"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 90\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 90\n"); + // full range 0 - 200 (get needs to wait) + else if (det_type == defs::EIGER) { + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"50"}, 0, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 50\n"); + std::this_thread::sleep_for(std::chrono::seconds(2)); + caller.call("highvoltage", {}, 0, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 50\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"120"}, 0, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 120\n"); + std::this_thread::sleep_for(std::chrono::seconds(2)); + caller.call("highvoltage", {}, 0, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 120\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"0"}, 0, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 0\n"); + std::this_thread::sleep_for(std::chrono::seconds(2)); + caller.call("highvoltage", {}, 0, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 0\n"); + } } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"0"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 0\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 0\n"); + // full range 0 - 200 + else { + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"50"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 50\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 50\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"120"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 120\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 120\n"); + } + { + std::ostringstream oss1, oss2; + caller.call("highvoltage", {"0"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "highvoltage 0\n"); + caller.call("highvoltage", {}, -1, GET, oss2); + REQUIRE(oss2.str() == "highvoltage 0\n"); + } } - } - // full range 0 - 200 (get needs to wait) - else if (det_type == defs::EIGER) { - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"50"}, 0, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 50\n"); - std::this_thread::sleep_for(std::chrono::seconds(2)); - proxy.Call("highvoltage", {}, 0, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 50\n"); + for (int i = 0; i != det.size(); ++i) { + det.setHighVoltage(prev_val[i], {i}); } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"120"}, 0, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 120\n"); - std::this_thread::sleep_for(std::chrono::seconds(2)); - proxy.Call("highvoltage", {}, 0, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 120\n"); - } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"0"}, 0, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 0\n"); - std::this_thread::sleep_for(std::chrono::seconds(2)); - proxy.Call("highvoltage", {}, 0, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 0\n"); - } - } - // full range 0 - 200 - else { - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"50"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 50\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 50\n"); - } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"120"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 120\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 120\n"); - } - { - std::ostringstream oss1, oss2; - proxy.Call("highvoltage", {"0"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "highvoltage 0\n"); - proxy.Call("highvoltage", {}, -1, GET, oss2); - REQUIRE(oss2.str() == "highvoltage 0\n"); - } - } - for (int i = 0; i != det.size(); ++i) { - det.setHighVoltage(prev_val[i], {i}); + } else { + REQUIRE_THROWS(caller.call("highvoltage", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("highvoltage", {}, -1, GET)); } } -TEST_CASE("powerchip", "[.cmd]") { +TEST_CASE("CALLER::powerchip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || @@ -1495,46 +1518,46 @@ TEST_CASE("powerchip", "[.cmd]") { auto prev_val = det.getPowerChip(); { std::ostringstream oss; - proxy.Call("powerchip", {"1"}, -1, PUT, oss); + caller.call("powerchip", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "powerchip 1\n"); } { std::ostringstream oss; - proxy.Call("powerchip", {"0"}, -1, PUT, oss); + caller.call("powerchip", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "powerchip 0\n"); } { std::ostringstream oss; - proxy.Call("powerchip", {}, -1, GET, oss); + caller.call("powerchip", {}, -1, GET, oss); REQUIRE(oss.str() == "powerchip 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setPowerChip(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("powerchip", {}, -1, GET)); + REQUIRE_THROWS(caller.call("powerchip", {}, -1, GET)); } } -TEST_CASE("imagetest", "[.cmd]") { +TEST_CASE("CALLER::imagetest", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); // cannot test only for virtual eiger/jungfrau if (det_type == defs::GOTTHARD) { auto prev_val = det.getImageTestMode(); { std::ostringstream oss1, oss2; - proxy.Call("imagetest", {"1"}, -1, PUT, oss1); + caller.call("imagetest", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "imagetest 1\n"); - proxy.Call("imagetest", {}, -1, GET, oss2); + caller.call("imagetest", {}, -1, GET, oss2); REQUIRE(oss2.str() == "imagetest 1\n"); } { std::ostringstream oss1, oss2; - proxy.Call("imagetest", {"0"}, -1, PUT, oss1); + caller.call("imagetest", {"0"}, -1, PUT, oss1); REQUIRE(oss1.str() == "imagetest 0\n"); - proxy.Call("imagetest", {}, -1, GET, oss2); + caller.call("imagetest", {}, -1, GET, oss2); REQUIRE(oss2.str() == "imagetest 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -1543,34 +1566,34 @@ TEST_CASE("imagetest", "[.cmd]") { } else if (det_type != defs::JUNGFRAU && det_type != defs::MOENCH && det_type != defs::EIGER) { // wont fail for eiger and jungfrau/moench virtual servers - REQUIRE_THROWS(proxy.Call("imagetest", {}, -1, GET)); + REQUIRE_THROWS(caller.call("imagetest", {}, -1, GET)); } } -TEST_CASE("extsig", "[.cmd]") { +TEST_CASE("CALLER::extsig", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD) { auto prev_val = det.getExternalSignalFlags(0); - REQUIRE_THROWS(proxy.Call("extsig", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("extsig", {"1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("extsig", {"0", "inversion_on"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("extsig", {"0", "inversion_off"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extsig", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extsig", {"1"}, -1, GET)); + REQUIRE_THROWS(caller.call("extsig", {"0", "inversion_on"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extsig", {"0", "inversion_off"}, -1, PUT)); { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"0", "trigger_in_rising_edge"}, -1, PUT, - oss1); + caller.call("extsig", {"0", "trigger_in_rising_edge"}, -1, PUT, + oss1); REQUIRE(oss1.str() == "extsig 0 trigger_in_rising_edge\n"); - proxy.Call("extsig", {"0"}, -1, GET, oss2); + caller.call("extsig", {"0"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 0 trigger_in_rising_edge\n"); } { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"0", "trigger_in_falling_edge"}, -1, PUT, - oss1); + caller.call("extsig", {"0", "trigger_in_falling_edge"}, -1, PUT, + oss1); REQUIRE(oss1.str() == "extsig 0 trigger_in_falling_edge\n"); - proxy.Call("extsig", {"0"}, -1, GET, oss2); + caller.call("extsig", {"0"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 0 trigger_in_falling_edge\n"); } for (int i = 0; i != det.size(); ++i) { @@ -1579,42 +1602,42 @@ TEST_CASE("extsig", "[.cmd]") { } else if (det_type == defs::MYTHEN3) { auto prev_val_0 = det.getExternalSignalFlags(0); auto prev_val_1 = det.getExternalSignalFlags(1); - REQUIRE_THROWS(proxy.Call("extsig", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("extsig", {"8"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("extsig", {"0", "inversion_on"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("extsig", {"0", "inversion_off"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extsig", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extsig", {"8"}, -1, GET)); + REQUIRE_THROWS(caller.call("extsig", {"0", "inversion_on"}, -1, PUT)); + REQUIRE_THROWS(caller.call("extsig", {"0", "inversion_off"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("extsig", {"1", "trigger_in_rising_edge"}, -1, PUT)); + caller.call("extsig", {"1", "trigger_in_rising_edge"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("extsig", {"1", "trigger_in_falling_edge"}, -1, PUT)); + caller.call("extsig", {"1", "trigger_in_falling_edge"}, -1, PUT)); { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"0", "trigger_in_rising_edge"}, -1, PUT, - oss1); + caller.call("extsig", {"0", "trigger_in_rising_edge"}, -1, PUT, + oss1); REQUIRE(oss1.str() == "extsig 0 trigger_in_rising_edge\n"); - proxy.Call("extsig", {"0"}, -1, GET, oss2); + caller.call("extsig", {"0"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 0 trigger_in_rising_edge\n"); } { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"0", "trigger_in_falling_edge"}, -1, PUT, - oss1); + caller.call("extsig", {"0", "trigger_in_falling_edge"}, -1, PUT, + oss1); REQUIRE(oss1.str() == "extsig 0 trigger_in_falling_edge\n"); - proxy.Call("extsig", {"0"}, -1, GET, oss2); + caller.call("extsig", {"0"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 0 trigger_in_falling_edge\n"); } { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"1", "inversion_off"}, -1, PUT, oss1); + caller.call("extsig", {"1", "inversion_off"}, -1, PUT, oss1); REQUIRE(oss1.str() == "extsig 1 inversion_off\n"); - proxy.Call("extsig", {"1"}, -1, GET, oss2); + caller.call("extsig", {"1"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 1 inversion_off\n"); } { std::ostringstream oss1, oss2; - proxy.Call("extsig", {"1", "inversion_on"}, -1, PUT, oss1); + caller.call("extsig", {"1", "inversion_on"}, -1, PUT, oss1); REQUIRE(oss1.str() == "extsig 1 inversion_on\n"); - proxy.Call("extsig", {"1"}, -1, GET, oss2); + caller.call("extsig", {"1"}, -1, GET, oss2); REQUIRE(oss2.str() == "extsig 1 inversion_on\n"); } for (int i = 0; i != det.size(); ++i) { @@ -1622,13 +1645,13 @@ TEST_CASE("extsig", "[.cmd]") { det.setExternalSignalFlags(1, prev_val_1[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("extsig", {}, -1, GET)); + REQUIRE_THROWS(caller.call("extsig", {}, -1, GET)); } } -TEST_CASE("parallel", "[.cmd]") { +TEST_CASE("CALLER::parallel", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::MYTHEN3 || @@ -1636,30 +1659,30 @@ TEST_CASE("parallel", "[.cmd]") { auto prev_val = det.getParallelMode(); { std::ostringstream oss; - proxy.Call("parallel", {"1"}, -1, PUT, oss); + caller.call("parallel", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "parallel 1\n"); } { std::ostringstream oss; - proxy.Call("parallel", {"0"}, -1, PUT, oss); + caller.call("parallel", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "parallel 0\n"); } { std::ostringstream oss; - proxy.Call("parallel", {}, -1, GET, oss); + caller.call("parallel", {}, -1, GET, oss); REQUIRE(oss.str() == "parallel 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setParallelMode(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("parallel", {}, -1, GET)); + REQUIRE_THROWS(caller.call("parallel", {}, -1, GET)); } } -TEST_CASE("filterresistor", "[.cmd]") { +TEST_CASE("CALLER::filterresistor", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); // only for chipv1.1 @@ -1673,87 +1696,87 @@ TEST_CASE("filterresistor", "[.cmd]") { auto prev_val = det.getFilterResistor(); { std::ostringstream oss; - proxy.Call("filterresistor", {"1"}, -1, PUT, oss); + caller.call("filterresistor", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "filterresistor 1\n"); } { std::ostringstream oss; - proxy.Call("filterresistor", {"0"}, -1, PUT, oss); + caller.call("filterresistor", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "filterresistor 0\n"); } { std::ostringstream oss; - proxy.Call("filterresistor", {}, -1, GET, oss); + caller.call("filterresistor", {}, -1, GET, oss); REQUIRE(oss.str() == "filterresistor 0\n"); } if (det_type == defs::GOTTHARD2) { - REQUIRE_NOTHROW(proxy.Call("filterresistor", {"2"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("filterresistor", {"3"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("filterresistor", {"2"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("filterresistor", {"3"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("filterresistor", {"2"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("filterresistor", {"3"}, -1, PUT)); + REQUIRE_THROWS(caller.call("filterresistor", {"2"}, -1, PUT)); + REQUIRE_THROWS(caller.call("filterresistor", {"3"}, -1, PUT)); } for (int i = 0; i != det.size(); ++i) { det.setFilterResistor(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("filterresistor", {}, -1, GET)); + REQUIRE_THROWS(caller.call("filterresistor", {}, -1, GET)); } } -TEST_CASE("dbitpipeline", "[.cmd]") { +TEST_CASE("CALLER::dbitpipeline", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD || det_type == defs::GOTTHARD2) { auto prev_val = det.getDBITPipeline(); { std::ostringstream oss; - proxy.Call("dbitpipeline", {"1"}, -1, PUT, oss); + caller.call("dbitpipeline", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitpipeline 1\n"); } { std::ostringstream oss; - proxy.Call("dbitpipeline", {"0"}, -1, PUT, oss); + caller.call("dbitpipeline", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitpipeline 0\n"); } if (det_type == defs::CHIPTESTBOARD) { { std::ostringstream oss; - proxy.Call("dbitpipeline", {"15"}, -1, PUT, oss); + caller.call("dbitpipeline", {"15"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitpipeline 15\n"); } { std::ostringstream oss; - proxy.Call("dbitpipeline", {}, -1, GET, oss); + caller.call("dbitpipeline", {}, -1, GET, oss); REQUIRE(oss.str() == "dbitpipeline 15\n"); } - REQUIRE_THROWS(proxy.Call("dbitpipeline", {"256"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dbitpipeline", {"256"}, -1, PUT)); } else { { std::ostringstream oss; - proxy.Call("dbitpipeline", {"7"}, -1, PUT, oss); + caller.call("dbitpipeline", {"7"}, -1, PUT, oss); REQUIRE(oss.str() == "dbitpipeline 7\n"); } { std::ostringstream oss; - proxy.Call("dbitpipeline", {}, -1, GET, oss); + caller.call("dbitpipeline", {}, -1, GET, oss); REQUIRE(oss.str() == "dbitpipeline 7\n"); } - REQUIRE_THROWS(proxy.Call("dbitpipeline", {"8"}, -1, PUT)); + REQUIRE_THROWS(caller.call("dbitpipeline", {"8"}, -1, PUT)); } for (int i = 0; i != det.size(); ++i) { det.setDBITPipeline(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("dbitpipeline", {}, -1, GET)); + REQUIRE_THROWS(caller.call("dbitpipeline", {}, -1, GET)); } } -TEST_CASE("readnrows", "[.cmd]") { +TEST_CASE("CALLER::readnrows", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { @@ -1766,46 +1789,46 @@ TEST_CASE("readnrows", "[.cmd]") { if ((det_type == defs::JUNGFRAU || det_type == defs::MOENCH) && !hw2) { { std::ostringstream oss; - proxy.Call("readnrows", {}, -1, GET, oss); + caller.call("readnrows", {}, -1, GET, oss); REQUIRE(oss.str() == "readnrows 512\n"); } } else { auto prev_val = det.getReadNRows(); { std::ostringstream oss; - proxy.Call("readnrows", {"256"}, -1, PUT, oss); + caller.call("readnrows", {"256"}, -1, PUT, oss); REQUIRE(oss.str() == "readnrows 256\n"); } { std::ostringstream oss; - proxy.Call("readnrows", {}, -1, GET, oss); + caller.call("readnrows", {}, -1, GET, oss); REQUIRE(oss.str() == "readnrows 256\n"); } { std::ostringstream oss; - proxy.Call("readnrows", {"16"}, -1, PUT, oss); + caller.call("readnrows", {"16"}, -1, PUT, oss); REQUIRE(oss.str() == "readnrows 16\n"); } if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - REQUIRE_THROWS(proxy.Call("readnrows", {"7"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readnrows", {"20"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readnrows", {"44"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readnrows", {"513"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("readnrows", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"7"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"20"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"44"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"513"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"1"}, -1, PUT)); } - REQUIRE_THROWS(proxy.Call("readnrows", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("readnrows", {"0"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setReadNRows(prev_val[i], {i}); } } } else { - REQUIRE_THROWS(proxy.Call("readnrows", {}, -1, GET)); + REQUIRE_THROWS(caller.call("readnrows", {}, -1, GET)); } } -TEST_CASE("currentsource", "[.cmd]") { +TEST_CASE("CALLER::currentsource", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::GOTTHARD2 || det_type == defs::JUNGFRAU) { @@ -1814,23 +1837,23 @@ TEST_CASE("currentsource", "[.cmd]") { if (det_type == defs::GOTTHARD2) { { std::ostringstream oss; - proxy.Call("currentsource", {"1"}, -1, PUT, oss); + caller.call("currentsource", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "currentsource [1]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {"0"}, -1, PUT, oss); + caller.call("currentsource", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "currentsource [0]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {}, -1, GET, oss); + caller.call("currentsource", {}, -1, GET, oss); REQUIRE(oss.str() == "currentsource [disabled]\n"); } REQUIRE_THROWS( - proxy.Call("currentsource", {"1", "fix", "42"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("currentsource", - {"1", "fix", "42", "normal"}, -1, PUT)); + caller.call("currentsource", {"1", "fix", "42"}, -1, PUT)); + REQUIRE_THROWS(caller.call("currentsource", + {"1", "fix", "42", "normal"}, -1, PUT)); } // jungfrau else { @@ -1841,94 +1864,94 @@ TEST_CASE("currentsource", "[.cmd]") { 10; } if (chipVersion == 10) { - REQUIRE_THROWS(proxy.Call("currentsource", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("currentsource", {"1"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("currentsource", {"1", "fix"}, -1, PUT)); + caller.call("currentsource", {"1", "fix"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("currentsource", {"1", "fix", "64"}, -1, PUT)); + caller.call("currentsource", {"1", "fix", "64"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("currentsource", {"1", "dfg", "64"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call( + caller.call("currentsource", {"1", "dfg", "64"}, -1, PUT)); + REQUIRE_THROWS(caller.call( "currentsource", {"1", "fix", "63", "normal"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("currentsource", {"1", "fix", "63"}, -1, PUT, - oss); + caller.call("currentsource", {"1", "fix", "63"}, -1, PUT, + oss); REQUIRE(oss.str() == "currentsource [1, fix, 63]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {"0"}, -1, PUT, oss); + caller.call("currentsource", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "currentsource [0]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {}, -1, GET, oss); + caller.call("currentsource", {}, -1, GET, oss); REQUIRE(oss.str() == "currentsource [disabled]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {"1", "nofix", "63"}, -1, PUT, - oss); + caller.call("currentsource", {"1", "nofix", "63"}, -1, PUT, + oss); REQUIRE(oss.str() == "currentsource [1, nofix, 63]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {}, -1, GET, oss); + caller.call("currentsource", {}, -1, GET, oss); REQUIRE(oss.str() == "currentsource [enabled, nofix, 63]\n"); } } // chipv1.1 else { - REQUIRE_THROWS(proxy.Call("currentsource", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("currentsource", {"1"}, -1, PUT)); REQUIRE_THROWS( - proxy.Call("currentsource", {"1", "fix"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call( + caller.call("currentsource", {"1", "fix"}, -1, PUT)); + REQUIRE_THROWS(caller.call( "currentsource", {"1", "ffgdfgix", "0x0000000000000041"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call( + REQUIRE_THROWS(caller.call( "currentsource", {"1", "fix", "0x0000000000000041", "normaldgf"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("currentsource", - {"1", "fix", "0x0000000000000041", "normal"}, -1, - PUT, oss); + caller.call("currentsource", + {"1", "fix", "0x0000000000000041", "normal"}, + -1, PUT, oss); REQUIRE( oss.str() == "currentsource [1, fix, 0x0000000000000041, normal]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {"0"}, -1, PUT, oss); + caller.call("currentsource", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "currentsource [0]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {}, -1, GET, oss); + caller.call("currentsource", {}, -1, GET, oss); REQUIRE(oss.str() == "currentsource [disabled]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", - {"1", "nofix", "0x0000000000000041", "normal"}, - -1, PUT, oss); + caller.call("currentsource", + {"1", "nofix", "0x0000000000000041", "normal"}, + -1, PUT, oss); REQUIRE(oss.str() == "currentsource [1, nofix, " "0x0000000000000041, normal]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", {}, -1, GET, oss); + caller.call("currentsource", {}, -1, GET, oss); REQUIRE(oss.str() == "currentsource [enabled, nofix, " "0x0000000000000041, normal]\n"); } { std::ostringstream oss; - proxy.Call("currentsource", - {"1", "nofix", "0x0000000000000041", "low"}, -1, - PUT, oss); + caller.call("currentsource", + {"1", "nofix", "0x0000000000000041", "low"}, -1, + PUT, oss); REQUIRE( oss.str() == "currentsource [1, nofix, 0x0000000000000041, low]\n"); @@ -1939,69 +1962,70 @@ TEST_CASE("currentsource", "[.cmd]") { det.setCurrentSource(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("currentsource", {}, -1, GET)); + REQUIRE_THROWS(caller.call("currentsource", {}, -1, GET)); } } /** temperature */ -TEST_CASE("templist", "[.cmd]") { +TEST_CASE("CALLER::templist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("templist", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("templist", {}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("templist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("templist", {}, -1, PUT)); } -TEST_CASE("tempvalues", "[.cmd]") { +TEST_CASE("CALLER::tempvalues", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("tempvalues", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("tempvalues", {}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("tempvalues", {}, -1, GET)); + REQUIRE_THROWS(caller.call("tempvalues", {}, -1, PUT)); } -TEST_CASE("temp_adc", "[.cmd]") { +TEST_CASE("CALLER::temp_adc", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD) { - REQUIRE_NOTHROW(proxy.Call("temp_adc", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("temp_adc", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_adc", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_adc", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_adc ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_adc", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_adc", {}, -1, GET)); } } -TEST_CASE("temp_fpga", "[.cmd]") { +TEST_CASE("CALLER::temp_fpga", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("temp_fpga", {}, -1, GET)); + if (det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_NOTHROW(caller.call("temp_fpga", {}, -1, GET)); std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("temp_fpga", {}, 0, GET, oss)); + REQUIRE_NOTHROW(caller.call("temp_fpga", {}, 0, GET, oss)); std::string s = (oss.str()).erase(0, strlen("temp_fpga ")); REQUIRE(std::stoi(s) != -1); } else { - REQUIRE_THROWS(proxy.Call("temp_fpga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("temp_fpga", {}, -1, GET)); } } /* list */ -TEST_CASE("daclist", "[.cmd]") { +TEST_CASE("CALLER::daclist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_NOTHROW(proxy.Call("daclist", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("daclist", {}, -1, GET)); auto prev = det.getDacNames(); - REQUIRE_THROWS(proxy.Call("daclist", {"a", "s", "d"}, -1, PUT)); + REQUIRE_THROWS(caller.call("daclist", {"a", "s", "d"}, -1, PUT)); std::vector names; for (int iarg = 0; iarg != 18; ++iarg) { @@ -2009,38 +2033,44 @@ TEST_CASE("daclist", "[.cmd]") { } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("daclist", names, -1, PUT, oss)); + REQUIRE_NOTHROW(caller.call("daclist", names, -1, PUT, oss)); } { std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("daclist", {}, -1, GET, oss)); + REQUIRE_NOTHROW(caller.call("daclist", {}, -1, GET, oss)); REQUIRE(oss.str() == std::string("daclist ") + ToString(names) + '\n'); } det.setDacNames(prev); } else { - REQUIRE_THROWS(proxy.Call("daclist", {"a", "b"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("daclist", {}, -1, GET)); + REQUIRE_THROWS(caller.call("daclist", {"a", "b"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("daclist", {}, -1, GET)); } } /* dacs */ -TEST_CASE("dacvalues", "[.cmd]") { +TEST_CASE("CALLER::dacvalues", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("dacvalues", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dacvalues", {}, -1, PUT)); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_NOTHROW(caller.call("dacvalues", {}, -1, GET)); + REQUIRE_THROWS(caller.call("dacvalues", {}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("dacvalues", {}, -1, GET)); + } } -TEST_CASE("defaultdac", "[.cmd]") { +TEST_CASE("CALLER::defaultdac", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::CHIPTESTBOARD) { - REQUIRE_THROWS(proxy.Call("defaultdac", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("defaultdac", {"blabla"}, -1, PUT)); + if (det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("defaultdac", {}, -1, GET)); + REQUIRE_THROWS(caller.call("defaultdac", {"blabla"}, -1, PUT)); auto daclist = det.getDacList(); for (auto it : daclist) { if (it == defs::VTHRESHOLD) { @@ -2050,13 +2080,13 @@ TEST_CASE("defaultdac", "[.cmd]") { auto prev_val = det.getDefaultDac(it); { std::ostringstream oss; - proxy.Call("defaultdac", {dacname, "1000"}, -1, PUT, oss); + caller.call("defaultdac", {dacname, "1000"}, -1, PUT, oss); REQUIRE(oss.str() == std::string("defaultdac ") + dacname + std::string(" 1000\n")); } { std::ostringstream oss; - proxy.Call("defaultdac", {dacname}, -1, GET, oss); + caller.call("defaultdac", {dacname}, -1, GET, oss); REQUIRE(oss.str() == std::string("defaultdac ") + dacname + std::string(" 1000\n")); } @@ -2064,7 +2094,7 @@ TEST_CASE("defaultdac", "[.cmd]") { det.setDefaultDac(it, prev_val[i], {i}); } } - if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { + if (det_type == defs::JUNGFRAU) { std::vector daclist = { defs::VREF_PRECH, defs::VREF_DS, defs::VREF_COMP}; for (auto it : daclist) { @@ -2072,14 +2102,14 @@ TEST_CASE("defaultdac", "[.cmd]") { auto prev_val = det.getDefaultDac(it, defs::GAIN0); { std::ostringstream oss; - proxy.Call("defaultdac", {dacname, "1000", "gain0"}, -1, - PUT, oss); + caller.call("defaultdac", {dacname, "1000", "gain0"}, -1, + PUT, oss); REQUIRE(oss.str() == std::string("defaultdac ") + dacname + std::string(" gain0 1000\n")); } { std::ostringstream oss; - proxy.Call("defaultdac", {dacname, "gain0"}, -1, GET, oss); + caller.call("defaultdac", {dacname, "gain0"}, -1, GET, oss); REQUIRE(oss.str() == std::string("defaultdac ") + dacname + std::string(" gain0 1000\n")); } @@ -2089,20 +2119,21 @@ TEST_CASE("defaultdac", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("defaultdac", {}, -1, GET)); + REQUIRE_THROWS(caller.call("defaultdac", {}, -1, GET)); } } -TEST_CASE("resetdacs", "[.cmd]") { +TEST_CASE("CALLER::resetdacs", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::CHIPTESTBOARD) { + if (det_type != defs::CHIPTESTBOARD && + det_type != defs::XILINX_CHIPTESTBOARD) { auto prev_val = det.getSettings(); - REQUIRE_THROWS(proxy.Call("resetdacs", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("resetdacs", {}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("resetdacs", {"hard"}, -1, PUT)); + REQUIRE_THROWS(caller.call("resetdacs", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("resetdacs", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("resetdacs", {"hard"}, -1, PUT)); // settings should not change especially for jungfrau/moench and m3 auto next_val = det.getSettings(); @@ -2110,20 +2141,20 @@ TEST_CASE("resetdacs", "[.cmd]") { REQUIRE(prev_val[i] == next_val[i]); } } else { - REQUIRE_THROWS(proxy.Call("resetdacs", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("resetdacs", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("resetdacs", {}, -1, GET)); + REQUIRE_THROWS(caller.call("resetdacs", {}, -1, PUT)); } } /* acquisition */ -TEST_CASE("trigger", "[.cmd]") { +TEST_CASE("CALLER::trigger", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("trigger", {}, -1, GET)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("trigger", {}, -1, GET)); auto det_type = det.getDetectorType().squash(); if (det_type == defs::MYTHEN3) { - REQUIRE_NOTHROW(proxy.Call("trigger", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("trigger", {}, -1, PUT)); } else if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_timing = @@ -2143,7 +2174,7 @@ TEST_CASE("trigger", "[.cmd]") { det.startDetector(); { std::ostringstream oss; - proxy.Call("trigger", {}, -1, PUT, oss); + caller.call("trigger", {}, -1, PUT, oss); REQUIRE(oss.str() == "trigger successful\n"); } std::this_thread::sleep_for(std::chrono::seconds(2)); @@ -2156,14 +2187,14 @@ TEST_CASE("trigger", "[.cmd]") { det.setExptime(prev_exptime); det.setPeriod(prev_period); } else { - REQUIRE_THROWS(proxy.Call("trigger", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("trigger", {}, -1, PUT)); } } -TEST_CASE("blockingtrigger", "[.cmd]") { +TEST_CASE("CALLER::blockingtrigger", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("blockingtrigger", {}, -1, GET)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("blockingtrigger", {}, -1, GET)); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { @@ -2184,7 +2215,7 @@ TEST_CASE("blockingtrigger", "[.cmd]") { det.startDetector(); { std::ostringstream oss; - proxy.Call("blockingtrigger", {}, -1, PUT, oss); + caller.call("blockingtrigger", {}, -1, PUT, oss); REQUIRE(oss.str() == "blockingtrigger successful\n"); } if (det.isVirtualDetectorServer().tsquash( @@ -2200,162 +2231,179 @@ TEST_CASE("blockingtrigger", "[.cmd]") { det.setExptime(prev_exptime); det.setPeriod(prev_period); } else { - REQUIRE_THROWS(proxy.Call("blockingtrigger", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("blockingtrigger", {}, -1, PUT)); } } -TEST_CASE("clearbusy", "[.cmd]") { +TEST_CASE("CALLER::clearbusy", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("clearbusy", {}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clearbusy", {"0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("clearbusy", {}, -1, GET)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("clearbusy", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("clearbusy", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("clearbusy", {}, -1, GET)); } -TEST_CASE("start", "[.cmd]") { +TEST_CASE("CALLER::start", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - // PUT only command - REQUIRE_THROWS(proxy.Call("start", {}, -1, GET)); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - std::chrono::nanoseconds prev_val; - if (det_type != defs::MYTHEN3) { - prev_val = det.getExptime().tsquash("inconsistent exptime to test"); - } else { - auto t = - det.getExptimeForAllGates().tsquash("inconsistent exptime to test"); - if (t[0] != t[1] || t[1] != t[2]) { - throw RuntimeError("inconsistent exptime for all gates"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + // PUT only command + REQUIRE_THROWS(caller.call("start", {}, -1, GET)); + auto det_type = det.getDetectorType().squash(); + std::chrono::nanoseconds prev_val; + if (det_type != defs::MYTHEN3) { + prev_val = det.getExptime().tsquash("inconsistent exptime to test"); + } else { + auto t = det.getExptimeForAllGates().tsquash( + "inconsistent exptime to test"); + if (t[0] != t[1] || t[1] != t[2]) { + throw RuntimeError("inconsistent exptime for all gates"); + } + prev_val = t[0]; } - prev_val = t[0]; + auto prev_frames = + det.getNumberOfFrames().tsquash("inconsistent #frames in test"); + auto prev_period = + det.getPeriod().tsquash("inconsistent period in test"); + det.setExptime(-1, std::chrono::microseconds(200)); + det.setPeriod(std::chrono::milliseconds(1)); + det.setNumberOfFrames(2000); + { + std::ostringstream oss; + caller.call("start", {}, -1, PUT, oss); + REQUIRE(oss.str() == "start successful\n"); + } + if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { + std::ostringstream oss; + caller.call("status", {}, -1, GET, oss); + REQUIRE(oss.str() == "status running\n"); + } + det.stopDetector(); + det.setExptime(-1, prev_val); + det.setPeriod(prev_period); + det.setNumberOfFrames(prev_frames); + } else { + REQUIRE_THROWS(caller.call("start", {}, -1, GET)); } - auto prev_frames = - det.getNumberOfFrames().tsquash("inconsistent #frames in test"); - auto prev_period = det.getPeriod().tsquash("inconsistent period in test"); - det.setExptime(-1, std::chrono::microseconds(200)); - det.setPeriod(std::chrono::milliseconds(1)); - det.setNumberOfFrames(2000); - { - std::ostringstream oss; - proxy.Call("start", {}, -1, PUT, oss); - REQUIRE(oss.str() == "start successful\n"); - } - if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { - std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); - REQUIRE(oss.str() == "status running\n"); - } - det.stopDetector(); - det.setExptime(-1, prev_val); - det.setPeriod(prev_period); - det.setNumberOfFrames(prev_frames); } -TEST_CASE("stop", "[.cmd]") { +TEST_CASE("CALLER::stop", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - // PUT only command - REQUIRE_THROWS(proxy.Call("stop", {}, -1, GET)); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - std::chrono::nanoseconds prev_val; - if (det_type != defs::MYTHEN3) { - prev_val = det.getExptime().tsquash("inconsistent exptime to test"); - } else { - auto t = - det.getExptimeForAllGates().tsquash("inconsistent exptime to test"); - if (t[0] != t[1] || t[1] != t[2]) { - throw RuntimeError("inconsistent exptime for all gates"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + // PUT only command + REQUIRE_THROWS(caller.call("stop", {}, -1, GET)); + auto det_type = det.getDetectorType().squash(); + std::chrono::nanoseconds prev_val; + if (det_type != defs::MYTHEN3) { + prev_val = det.getExptime().tsquash("inconsistent exptime to test"); + } else { + auto t = det.getExptimeForAllGates().tsquash( + "inconsistent exptime to test"); + if (t[0] != t[1] || t[1] != t[2]) { + throw RuntimeError("inconsistent exptime for all gates"); + } + prev_val = t[0]; } - prev_val = t[0]; + auto prev_frames = + det.getNumberOfFrames().tsquash("inconsistent #frames in test"); + auto prev_period = + det.getPeriod().tsquash("inconsistent period in test"); + det.setExptime(-1, std::chrono::microseconds(200)); + det.setPeriod(std::chrono::milliseconds(1)); + det.setNumberOfFrames(2000); + det.startDetector(); + if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { + std::ostringstream oss; + caller.call("status", {}, -1, GET, oss); + REQUIRE(oss.str() == "status running\n"); + } + { + std::ostringstream oss; + caller.call("stop", {}, -1, PUT, oss); + REQUIRE(oss.str() == "stop successful\n"); + } + { + std::ostringstream oss; + caller.call("status", {}, -1, GET, oss); + REQUIRE(((oss.str() == "status stopped\n") || + (oss.str() == "status idle\n"))); + } + det.setExptime(-1, prev_val); + det.setPeriod(prev_period); + det.setNumberOfFrames(prev_frames); + } else { + REQUIRE_THROWS(caller.call("stop", {}, -1, GET)); } - auto prev_frames = - det.getNumberOfFrames().tsquash("inconsistent #frames in test"); - auto prev_period = det.getPeriod().tsquash("inconsistent period in test"); - det.setExptime(-1, std::chrono::microseconds(200)); - det.setPeriod(std::chrono::milliseconds(1)); - det.setNumberOfFrames(2000); - det.startDetector(); - if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { - std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); - REQUIRE(oss.str() == "status running\n"); - } - { - std::ostringstream oss; - proxy.Call("stop", {}, -1, PUT, oss); - REQUIRE(oss.str() == "stop successful\n"); - } - { - std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); - REQUIRE(((oss.str() == "status stopped\n") || - (oss.str() == "status idle\n"))); - } - det.setExptime(-1, prev_val); - det.setPeriod(prev_period); - det.setNumberOfFrames(prev_frames); } -TEST_CASE("status", "[.cmd]") { +TEST_CASE("CALLER::status", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - std::chrono::nanoseconds prev_val; - if (det_type != defs::MYTHEN3) { - prev_val = det.getExptime().tsquash("inconsistent exptime to test"); - } else { - auto t = - det.getExptimeForAllGates().tsquash("inconsistent exptime to test"); - if (t[0] != t[1] || t[1] != t[2]) { - throw RuntimeError("inconsistent exptime for all gates"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::chrono::nanoseconds prev_val; + if (det_type != defs::MYTHEN3) { + prev_val = det.getExptime().tsquash("inconsistent exptime to test"); + } else { + auto t = det.getExptimeForAllGates().tsquash( + "inconsistent exptime to test"); + if (t[0] != t[1] || t[1] != t[2]) { + throw RuntimeError("inconsistent exptime for all gates"); + } + prev_val = t[0]; } - prev_val = t[0]; + auto prev_frames = + det.getNumberOfFrames().tsquash("inconsistent #frames in test"); + auto prev_period = + det.getPeriod().tsquash("inconsistent period in test"); + det.setExptime(-1, std::chrono::microseconds(200)); + det.setPeriod(std::chrono::milliseconds(1)); + det.setNumberOfFrames(2000); + det.startDetector(); + if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { + std::ostringstream oss; + caller.call("status", {}, -1, GET, oss); + REQUIRE(oss.str() == "status running\n"); + } + det.stopDetector(); + { + std::ostringstream oss; + caller.call("status", {}, -1, GET, oss); + REQUIRE(((oss.str() == "status stopped\n") || + (oss.str() == "status idle\n"))); + } + det.setExptime(-1, prev_val); + det.setPeriod(prev_period); + det.setNumberOfFrames(prev_frames); + } else { + REQUIRE_THROWS(caller.call("status", {}, -1, GET)); } - auto prev_frames = - det.getNumberOfFrames().tsquash("inconsistent #frames in test"); - auto prev_period = det.getPeriod().tsquash("inconsistent period in test"); - det.setExptime(-1, std::chrono::microseconds(200)); - det.setPeriod(std::chrono::milliseconds(1)); - det.setNumberOfFrames(2000); - det.startDetector(); - if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { - std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); - REQUIRE(oss.str() == "status running\n"); - } - det.stopDetector(); - { - std::ostringstream oss; - proxy.Call("status", {}, -1, GET, oss); - REQUIRE(((oss.str() == "status stopped\n") || - (oss.str() == "status idle\n"))); - } - det.setExptime(-1, prev_val); - det.setPeriod(prev_period); - det.setNumberOfFrames(prev_frames); } -TEST_CASE("nextframenumber", "[.cmd]") { +TEST_CASE("CALLER::nextframenumber", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD) { auto prev_sfnum = det.getNextFrameNumber(); - REQUIRE_THROWS(proxy.Call("nextframenumber", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("nextframenumber", {"0"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("nextframenumber", {"3"}, -1, PUT, oss); + caller.call("nextframenumber", {"3"}, -1, PUT, oss); REQUIRE(oss.str() == "nextframenumber 3\n"); } { std::ostringstream oss; - proxy.Call("nextframenumber", {}, -1, GET, oss); + caller.call("nextframenumber", {}, -1, GET, oss); REQUIRE(oss.str() == "nextframenumber 3\n"); } { std::ostringstream oss; - proxy.Call("nextframenumber", {"1"}, -1, PUT, oss); + caller.call("nextframenumber", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "nextframenumber 1\n"); } @@ -2397,331 +2445,361 @@ TEST_CASE("nextframenumber", "[.cmd]") { det.setNextFrameNumber(prev_sfnum[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("nextframenumber", {}, -1, GET)); + REQUIRE_THROWS(caller.call("nextframenumber", {}, -1, GET)); } } -TEST_CASE("scan", "[.cmd]") { +TEST_CASE("CALLER::scan", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); defs::dacIndex ind = defs::DAC_0; defs::dacIndex notImplementedInd = defs::DAC_0; auto det_type = det.getDetectorType().squash(); - switch (det_type) { - case defs::CHIPTESTBOARD: - ind = defs::DAC_0; - notImplementedInd = defs::VSVP; - break; - case defs::EIGER: - ind = defs::VCMP_LL; - notImplementedInd = defs::VCASCP_PB; - break; - case defs::JUNGFRAU: - case defs::MOENCH: - ind = defs::VB_COMP; - notImplementedInd = defs::VSVP; - break; - case defs::GOTTHARD: - ind = defs::VREF_DS; - notImplementedInd = defs::VSVP; - break; - case defs::GOTTHARD2: - ind = defs::VB_COMP_FE; - notImplementedInd = defs::VSVP; - break; - case defs::MYTHEN3: - ind = defs::VTH2; - notImplementedInd = defs::VSVP; - break; - default: - break; - } - - // when taking acquisition - // auto previous = det.getDAC(ind, false); - // auto notImplementedPrevious = det.getDAC(notImplementedInd, false); - - if (det_type == defs::MYTHEN3 && det.size() > 1) { - ; // scan only allowed for single module due to sync - } else { - { - std::ostringstream oss; - proxy.Call("scan", {ToString(ind), "500", "1500", "500"}, -1, PUT, - oss); - CHECK(oss.str() == - "scan [" + ToString(ind) + ", 500, 1500, 500]\n"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + switch (det_type) { + case defs::CHIPTESTBOARD: + ind = defs::DAC_0; + notImplementedInd = defs::VSVP; + break; + case defs::EIGER: + ind = defs::VCMP_LL; + notImplementedInd = defs::VCASCP_PB; + break; + case defs::JUNGFRAU: + ind = defs::VB_COMP; + notImplementedInd = defs::VSVP; + break; + case defs::MOENCH: + ind = defs::VIN_CM; + notImplementedInd = defs::VSVP; + break; + case defs::GOTTHARD: + ind = defs::VREF_DS; + notImplementedInd = defs::VSVP; + break; + case defs::GOTTHARD2: + ind = defs::VB_COMP_FE; + notImplementedInd = defs::VSVP; + break; + case defs::MYTHEN3: + ind = defs::VTH2; + notImplementedInd = defs::VSVP; + break; + default: + break; } - { - std::ostringstream oss; - proxy.Call("scan", {}, -1, GET, oss); - CHECK(oss.str() == "scan [enabled\ndac " + ToString(ind) + - "\nstart 500\nstop 1500\nstep " - "500\nsettleTime 1ms\n]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {ToString(ind), "500", "1500", "500", "2s"}, -1, - PUT, oss); - CHECK(oss.str() == - "scan [" + ToString(ind) + ", 500, 1500, 500, 2s]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {}, -1, GET, oss); - CHECK(oss.str() == "scan [enabled\ndac " + ToString(ind) + - "\nstart 500\nstop 1500\nstep " - "500\nsettleTime 2s\n]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {"0"}, -1, PUT, oss); - CHECK(oss.str() == "scan [0]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {}, -1, GET, oss); - CHECK(oss.str() == "scan [disabled]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {ToString(ind), "1500", "500", "-500"}, -1, PUT, - oss); - CHECK(oss.str() == - "scan [" + ToString(ind) + ", 1500, 500, -500]\n"); - } - CHECK_THROWS(proxy.Call( - "scan", {ToString(notImplementedInd), "500", "1500", "500"}, -1, - PUT)); - CHECK_THROWS(proxy.Call("scan", {ToString(ind), "500", "1500", "-500"}, - -1, PUT)); - CHECK_THROWS( - proxy.Call("scan", {ToString(ind), "1500", "500", "500"}, -1, PUT)); - - if (det_type == defs::MYTHEN3 || defs::EIGER) { - { - std::ostringstream oss; - proxy.Call("scan", {"trimbits", "0", "63", "16", "2s"}, -1, PUT, - oss); - CHECK(oss.str() == "scan [trimbits, 0, 63, 16, 2s]\n"); - } - { - std::ostringstream oss; - proxy.Call("scan", {}, -1, GET, oss); - CHECK(oss.str() == - "scan [enabled\ndac trimbits\nstart 0\nstop 48\nstep " - "16\nsettleTime 2s\n]\n"); - } - } - - // Switch off scan for future tests - det.setScan(defs::scanParameters()); - // acquire for each? // when taking acquisition - // Reset all dacs to previous value - // for (int i = 0; i != det.size(); ++i) { - // det.setDAC(ind, previous[i], false, {i}); - // det.setDAC(notImplementedInd, notImplementedPrevious[i], false, - // {i}); - // } + // auto previous = det.getDAC(ind, false); + // auto notImplementedPrevious = det.getDAC(notImplementedInd, false); + + if (det_type == defs::MYTHEN3 && det.size() > 1) { + ; // scan only allowed for single module due to sync + } else { + { + std::ostringstream oss; + caller.call("scan", {ToString(ind), "500", "1500", "500"}, -1, + PUT, oss); + CHECK(oss.str() == + "scan [" + ToString(ind) + ", 500, 1500, 500]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {}, -1, GET, oss); + CHECK(oss.str() == "scan [enabled\ndac " + ToString(ind) + + "\nstart 500\nstop 1500\nstep " + "500\nsettleTime 1ms\n]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {ToString(ind), "500", "1500", "500", "2s"}, + -1, PUT, oss); + CHECK(oss.str() == + "scan [" + ToString(ind) + ", 500, 1500, 500, 2s]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {}, -1, GET, oss); + CHECK(oss.str() == "scan [enabled\ndac " + ToString(ind) + + "\nstart 500\nstop 1500\nstep " + "500\nsettleTime 2s\n]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {"0"}, -1, PUT, oss); + CHECK(oss.str() == "scan [0]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {}, -1, GET, oss); + CHECK(oss.str() == "scan [disabled]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {ToString(ind), "1500", "500", "-500"}, -1, + PUT, oss); + CHECK(oss.str() == + "scan [" + ToString(ind) + ", 1500, 500, -500]\n"); + } + CHECK_THROWS(caller.call( + "scan", {ToString(notImplementedInd), "500", "1500", "500"}, -1, + PUT)); + CHECK_THROWS(caller.call( + "scan", {ToString(ind), "500", "1500", "-500"}, -1, PUT)); + CHECK_THROWS(caller.call( + "scan", {ToString(ind), "1500", "500", "500"}, -1, PUT)); + + if (det_type == defs::MYTHEN3 || defs::EIGER) { + { + std::ostringstream oss; + caller.call("scan", {"trimbits", "0", "63", "16", "2s"}, -1, + PUT, oss); + CHECK(oss.str() == "scan [trimbits, 0, 63, 16, 2s]\n"); + } + { + std::ostringstream oss; + caller.call("scan", {}, -1, GET, oss); + CHECK(oss.str() == + "scan [enabled\ndac trimbits\nstart 0\nstop 48\nstep " + "16\nsettleTime 2s\n]\n"); + } + } + + // Switch off scan for future tests + det.setScan(defs::scanParameters()); + // acquire for each? + + // when taking acquisition + // Reset all dacs to previous value + // for (int i = 0; i != det.size(); ++i) { + // det.setDAC(ind, previous[i], false, {i}); + // det.setDAC(notImplementedInd, notImplementedPrevious[i], + // false, {i}); + // } + } + } else { + REQUIRE_THROWS(caller.call( + "scan", {ToString(defs::DAC_0), "500", "1500", "500"}, -1, PUT)); } } -TEST_CASE("scanerrmsg", "[.cmd]") { +TEST_CASE("CALLER::scanerrmsg", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("scanerrmsg", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("scanerrmsg", {""}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("scanerrmsg", {}, -1, GET)); + REQUIRE_THROWS(caller.call("scanerrmsg", {""}, -1, PUT)); } /* Network Configuration (Detector<->Receiver) */ -TEST_CASE("numinterfaces", "[.cmd]") { +TEST_CASE("CALLER::numinterfaces", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { auto prev_val = det.getNumberofUDPInterfaces().tsquash( "inconsistent numinterfaces to test"); { std::ostringstream oss; - proxy.Call("numinterfaces", {"2"}, -1, PUT, oss); + caller.call("numinterfaces", {"2"}, -1, PUT, oss); REQUIRE(oss.str() == "numinterfaces 2\n"); } { std::ostringstream oss; - proxy.Call("numinterfaces", {"1"}, -1, PUT, oss); + caller.call("numinterfaces", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "numinterfaces 1\n"); } { std::ostringstream oss; - proxy.Call("numinterfaces", {}, -1, GET, oss); + caller.call("numinterfaces", {}, -1, GET, oss); REQUIRE(oss.str() == "numinterfaces 1\n"); } det.setNumberofUDPInterfaces(prev_val); } else if (det_type == defs::EIGER) { - REQUIRE_THROWS(proxy.Call("numinterfaces", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("numinterfaces", {"1"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("numinterfaces", {}, -1, GET, oss); + caller.call("numinterfaces", {}, -1, GET, oss); REQUIRE(oss.str() == "numinterfaces 2\n"); } } else { std::ostringstream oss; - proxy.Call("numinterfaces", {}, -1, GET, oss); + caller.call("numinterfaces", {}, -1, GET, oss); REQUIRE(oss.str() == "numinterfaces 1\n"); - REQUIRE_THROWS(proxy.Call("numinterfaces", {"1"}, -1, PUT)); + REQUIRE_THROWS(caller.call("numinterfaces", {"1"}, -1, PUT)); } - REQUIRE_THROWS(proxy.Call("numinterfaces", {"3"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("numinterfaces", {"0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("numinterfaces", {"3"}, -1, PUT)); + REQUIRE_THROWS(caller.call("numinterfaces", {"0"}, -1, PUT)); } -TEST_CASE("udp_srcip", "[.cmd]") { +TEST_CASE("CALLER::udp_srcip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getSourceUDPIP(); - REQUIRE_THROWS(proxy.Call("udp_srcip", {"0.0.0.0"}, -1, PUT)); - { - std::ostringstream oss; - proxy.Call("udp_srcip", {"129.129.205.12"}, -1, PUT, oss); - REQUIRE(oss.str() == "udp_srcip 129.129.205.12\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setSourceUDPIP(prev_val[i], {i}); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getSourceUDPIP(); + REQUIRE_THROWS(caller.call("udp_srcip", {"0.0.0.0"}, -1, PUT)); + { + std::ostringstream oss; + caller.call("udp_srcip", {"129.129.205.12"}, -1, PUT, oss); + REQUIRE(oss.str() == "udp_srcip 129.129.205.12\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.setSourceUDPIP(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("udp_srcip", {}, -1, GET)); } } -TEST_CASE("udp_dstlist", "[.cmd]") { +TEST_CASE("CALLER::udp_dstlist", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_NOTHROW(proxy.Call("udp_dstlist", {}, 0, GET, std::cout, 0)); - REQUIRE_THROWS(proxy.Call( + REQUIRE_NOTHROW(caller.call("udp_dstlist", {}, 0, GET, std::cout, 0)); + REQUIRE_THROWS(caller.call( "udp_dstlist", {"ip=0.0.0.0", "mac=00:00:00:00:00:00", "port=1233"}, -1, PUT, std::cout, 0)); } else { - REQUIRE_THROWS(proxy.Call("udp_dstlist", {}, -1, GET, std::cout, 0)); + REQUIRE_THROWS(caller.call("udp_dstlist", {}, -1, GET, std::cout, 0)); } } -TEST_CASE("udp_numdst", "[.cmd]") { +TEST_CASE("CALLER::udp_numdst", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::EIGER || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { - REQUIRE_NOTHROW(proxy.Call("udp_numdst", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("udp_numdst", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("udp_numdst", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_numdst", {}, -1, GET)); } } -TEST_CASE("udp_cleardst", "[.cmd]") { +TEST_CASE("CALLER::udp_cleardst", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("udp_cleardst", {}, -1, GET)); - /* dont clear all udp destinations */ - /*REQUIRE_NOTHROW(proxy.Call("udp_cleardst", {}, -1, PUT));*/ + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("udp_cleardst", {}, -1, GET)); + /* dont clear all udp destinations */ + /*REQUIRE_NOTHROW(caller.call("udp_cleardst", {}, -1, PUT));*/ + } else { + REQUIRE_THROWS(caller.call("udp_cleardst", {}, -1, PUT)); + } } -TEST_CASE("udp_firstdst", "[.cmd]") { +TEST_CASE("CALLER::udp_firstdst", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { auto prev_val = det.getFirstUDPDestination(); { std::ostringstream oss; - proxy.Call("udp_firstdst", {"0"}, -1, PUT, oss); + caller.call("udp_firstdst", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "udp_firstdst 0\n"); } { std::ostringstream oss; - proxy.Call("udp_firstdst", {}, -1, GET, oss); + caller.call("udp_firstdst", {}, -1, GET, oss); REQUIRE(oss.str() == "udp_firstdst 0\n"); } /* { std::ostringstream oss; - proxy.Call("udp_firstdst", {"1"}, -1, PUT, oss); + caller.call("udp_firstdst", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "udp_firstdst 1\n"); } */ - REQUIRE_THROWS(proxy.Call("udp_firstdst", {"33"}, -1, PUT)); + REQUIRE_THROWS(caller.call("udp_firstdst", {"33"}, -1, PUT)); for (int i = 0; i != det.size(); ++i) { det.setFirstUDPDestination(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("udp_firstdst", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_firstdst", {}, -1, GET)); } } -TEST_CASE("udp_dstip", "[.cmd]") { +TEST_CASE("CALLER::udp_dstip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("udp_dstip", {"0.0.0.0"}, -1, PUT)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("udp_dstip", {"0.0.0.0"}, -1, PUT)); } -TEST_CASE("udp_srcmac", "[.cmd]") { +TEST_CASE("CALLER::udp_srcmac", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getSourceUDPMAC(); - REQUIRE_THROWS(proxy.Call("udp_srcmac", {"00:00:00:00:00:00"}, -1, PUT)); - { - std::ostringstream oss; - proxy.Call("udp_srcmac", {"00:50:c2:42:34:12"}, -1, PUT, oss); - REQUIRE(oss.str() == "udp_srcmac 00:50:c2:42:34:12\n"); - } - for (int i = 0; i != det.size(); ++i) { - if (prev_val[i].str() != "00:00:00:00:00:00") { - det.setSourceUDPMAC(prev_val[i], {i}); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getSourceUDPMAC(); + REQUIRE_THROWS( + caller.call("udp_srcmac", {"00:00:00:00:00:00"}, -1, PUT)); + { + std::ostringstream oss; + caller.call("udp_srcmac", {"00:50:c2:42:34:12"}, -1, PUT, oss); + REQUIRE(oss.str() == "udp_srcmac 00:50:c2:42:34:12\n"); } + for (int i = 0; i != det.size(); ++i) { + if (prev_val[i].str() != "00:00:00:00:00:00") { + det.setSourceUDPMAC(prev_val[i], {i}); + } + } + } else { + REQUIRE_THROWS(caller.call("udp_srcmac", {}, -1, GET)); } } -TEST_CASE("udp_dstmac", "[.cmd]") { +TEST_CASE("CALLER::udp_dstmac", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("udp_dstmac", {"00:00:00:00:00:00"}, -1, PUT)); + Caller caller(&det); + REQUIRE_THROWS(caller.call("udp_dstmac", {"00:00:00:00:00:00"}, -1, PUT)); } -TEST_CASE("udp_dstport", "[.cmd]") { +TEST_CASE("CALLER::udp_dstport", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getDestinationUDPPort(); - { - std::ostringstream oss; - proxy.Call("udp_dstport", {"50084"}, -1, PUT, oss); - REQUIRE(oss.str() == "udp_dstport 50084\n"); - } - test_valid_port("udp_dstport", {}, -1, PUT); - test_valid_port("udp_dstport", {}, 0, PUT); - // should fail for the second module - if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("udp_dstport", {"65535"}, -1, PUT)); - } - for (int i = 0; i != det.size(); ++i) { - det.setDestinationUDPPort(prev_val[i], {i}); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + auto prev_val = det.getDestinationUDPPort(); + { + std::ostringstream oss; + caller.call("udp_dstport", {"50084"}, -1, PUT, oss); + REQUIRE(oss.str() == "udp_dstport 50084\n"); + } + test_valid_port_caller("udp_dstport", {}, -1, PUT); + test_valid_port_caller("udp_dstport", {}, 0, PUT); + // should fail for the second module + if (det.size() > 1) { + REQUIRE_THROWS(caller.call("udp_dstport", {"65535"}, -1, PUT)); + } + + for (int i = 0; i != det.size(); ++i) { + det.setDestinationUDPPort(prev_val[i], {i}); + } + } else { + REQUIRE_THROWS(caller.call("udp_dstport", {}, -1, GET)); } } -TEST_CASE("udp_srcip2", "[.cmd]") { +TEST_CASE("CALLER::udp_srcip2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2) { auto prev_val = det.getSourceUDPIP2(); - REQUIRE_THROWS(proxy.Call("udp_srcip2", {"0.0.0.0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("udp_srcip2", {"0.0.0.0"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("udp_srcip2", {"129.129.205.12"}, -1, PUT, oss); + caller.call("udp_srcip2", {"129.129.205.12"}, -1, PUT, oss); REQUIRE(oss.str() == "udp_srcip2 129.129.205.12\n"); } for (int i = 0; i != det.size(); ++i) { @@ -2729,34 +2807,34 @@ TEST_CASE("udp_srcip2", "[.cmd]") { det.setSourceUDPIP2(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("udp_srcip2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_srcip2", {}, -1, GET)); } } -TEST_CASE("udp_dstip2", "[.cmd]") { +TEST_CASE("CALLER::udp_dstip2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2) { - REQUIRE_THROWS(proxy.Call("udp_dstip2", {"0.0.0.0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("udp_dstip2", {"0.0.0.0"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("udp_dstip2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_dstip2", {}, -1, GET)); } } -TEST_CASE("udp_srcmac2", "[.cmd]") { +TEST_CASE("CALLER::udp_srcmac2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2) { auto prev_val = det.getSourceUDPMAC2(); REQUIRE_THROWS( - proxy.Call("udp_srcmac2", {"00:00:00:00:00:00"}, -1, PUT)); + caller.call("udp_srcmac2", {"00:00:00:00:00:00"}, -1, PUT)); { std::ostringstream oss; - proxy.Call("udp_srcmac2", {"00:50:c2:42:34:12"}, -1, PUT, oss); + caller.call("udp_srcmac2", {"00:50:c2:42:34:12"}, -1, PUT, oss); REQUIRE(oss.str() == "udp_srcmac2 00:50:c2:42:34:12\n"); } for (int i = 0; i != det.size(); ++i) { @@ -2765,41 +2843,40 @@ TEST_CASE("udp_srcmac2", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("udp_srcmac2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_srcmac2", {}, -1, GET)); } } -TEST_CASE("udp_dstmac2", "[.cmd]") { +TEST_CASE("CALLER::udp_dstmac2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2) { REQUIRE_THROWS( - proxy.Call("udp_dstmac2", {"00:00:00:00:00:00"}, -1, PUT)); + caller.call("udp_dstmac2", {"00:00:00:00:00:00"}, -1, PUT)); } else { - REQUIRE_THROWS(proxy.Call("udp_dstmac2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_dstmac2", {}, -1, GET)); } } -TEST_CASE("udp_dstport2", "[.cmd]") { +TEST_CASE("CALLER::udp_dstport2", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::GOTTHARD2 || det_type == defs::EIGER) { auto prev_val = det.getDestinationUDPPort2(); { std::ostringstream oss; - proxy.Call("udp_dstport2", {"50084"}, -1, PUT, oss); + caller.call("udp_dstport2", {"50084"}, -1, PUT, oss); REQUIRE(oss.str() == "udp_dstport2 50084\n"); } - - test_valid_port("udp_dstport2", {}, -1, PUT); - test_valid_port("udp_dstport2", {}, 0, PUT); + test_valid_port_caller("udp_dstport2", {}, -1, PUT); + test_valid_port_caller("udp_dstport2", {}, 0, PUT); // should fail for the second module if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("udp_dstport2", {"65535"}, -1, PUT)); + REQUIRE_THROWS(caller.call("udp_dstport2", {"65535"}, -1, PUT)); } for (int i = 0; i != det.size(); ++i) { @@ -2808,27 +2885,37 @@ TEST_CASE("udp_dstport2", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("udp_dstport2", {}, -1, GET)); + REQUIRE_THROWS(caller.call("udp_dstport2", {}, -1, GET)); } } -TEST_CASE("udp_reconfigure", "[.cmd]") { +TEST_CASE("CALLER::udp_reconfigure", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("udp_reconfigure", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("udp_reconfigure", {}, -1, PUT)); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("udp_reconfigure", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("udp_reconfigure", {}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("udp_reconfigure", {}, -1, PUT)); + } } -TEST_CASE("udp_validate", "[.cmd]") { +TEST_CASE("CALLER::udp_validate", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_THROWS(proxy.Call("udp_validate", {}, -1, GET)); - REQUIRE_NOTHROW(proxy.Call("udp_validate", {}, -1, PUT)); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("udp_validate", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("udp_validate", {}, -1, PUT)); + } else { + REQUIRE_THROWS(caller.call("udp_validate", {}, -1, PUT)); + } } -TEST_CASE("tengiga", "[.cmd]") { +TEST_CASE("CALLER::tengiga", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::CHIPTESTBOARD || @@ -2837,22 +2924,22 @@ TEST_CASE("tengiga", "[.cmd]") { det.setTenGiga(false); std::ostringstream oss1, oss2; - proxy.Call("tengiga", {"1"}, -1, PUT, oss1); + caller.call("tengiga", {"1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "tengiga 1\n"); - proxy.Call("tengiga", {}, -1, GET, oss2); + caller.call("tengiga", {}, -1, GET, oss2); REQUIRE(oss2.str() == "tengiga 1\n"); for (int i = 0; i != det.size(); ++i) { det.setTenGiga(tengiga[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("tengiga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("tengiga", {}, -1, GET)); } } -TEST_CASE("flowcontrol10g", "[.cmd]") { +TEST_CASE("CALLER::flowcontrol10g", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || @@ -2860,30 +2947,30 @@ TEST_CASE("flowcontrol10g", "[.cmd]") { auto prev_val = det.getTenGigaFlowControl(); { std::ostringstream oss; - proxy.Call("flowcontrol10g", {"1"}, -1, PUT, oss); + caller.call("flowcontrol10g", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "flowcontrol10g 1\n"); } { std::ostringstream oss; - proxy.Call("flowcontrol10g", {"0"}, -1, PUT, oss); + caller.call("flowcontrol10g", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "flowcontrol10g 0\n"); } { std::ostringstream oss; - proxy.Call("flowcontrol10g", {}, -1, GET, oss); + caller.call("flowcontrol10g", {}, -1, GET, oss); REQUIRE(oss.str() == "flowcontrol10g 0\n"); } for (int i = 0; i != det.size(); ++i) { det.setTenGigaFlowControl(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("flowcontrol10g", {}, -1, GET)); + REQUIRE_THROWS(caller.call("flowcontrol10g", {}, -1, GET)); } } -TEST_CASE("txdelay_frame", "[.cmd]") { +TEST_CASE("CALLER::txdelay_frame", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::MYTHEN3) { @@ -2896,22 +2983,22 @@ TEST_CASE("txdelay_frame", "[.cmd]") { std::string sval = std::to_string(val); { std::ostringstream oss1, oss2; - proxy.Call("txdelay_frame", {sval}, -1, PUT, oss1); + caller.call("txdelay_frame", {sval}, -1, PUT, oss1); REQUIRE(oss1.str() == "txdelay_frame " + sval + "\n"); - proxy.Call("txdelay_frame", {}, -1, GET, oss2); + caller.call("txdelay_frame", {}, -1, GET, oss2); REQUIRE(oss2.str() == "txdelay_frame " + sval + "\n"); } for (int i = 0; i != det.size(); ++i) { det.setTransmissionDelayFrame(prev_val[i]); } } else { - REQUIRE_THROWS(proxy.Call("txdelay_frame", {}, -1, GET)); + REQUIRE_THROWS(caller.call("txdelay_frame", {}, -1, GET)); } } -TEST_CASE("txdelay", "[.cmd]") { +TEST_CASE("CALLER::txdelay", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::EIGER || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::MYTHEN3) { @@ -2920,12 +3007,12 @@ TEST_CASE("txdelay", "[.cmd]") { if ((det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::MYTHEN3) && (det.size() < 2)) { - REQUIRE_THROWS(proxy.Call("txdelay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("txdelay", {}, -1, GET)); int val = 5; std::string sval = std::to_string(val); { std::ostringstream oss1; - proxy.Call("txdelay", {sval}, -1, PUT, oss1); + caller.call("txdelay", {sval}, -1, PUT, oss1); REQUIRE(oss1.str() == "txdelay " + sval + "\n"); } } @@ -2947,9 +3034,9 @@ TEST_CASE("txdelay", "[.cmd]") { std::string sval = std::to_string(val); { std::ostringstream oss1, oss2; - proxy.Call("txdelay", {sval}, -1, PUT, oss1); + caller.call("txdelay", {sval}, -1, PUT, oss1); REQUIRE(oss1.str() == "txdelay " + sval + "\n"); - proxy.Call("txdelay", {}, -1, GET, oss2); + caller.call("txdelay", {}, -1, GET, oss2); REQUIRE(oss2.str() == "txdelay " + sval + "\n"); } // test other mods @@ -2967,8 +3054,8 @@ TEST_CASE("txdelay", "[.cmd]") { } } // not a module level command - REQUIRE_THROWS(proxy.Call("txdelay", {"5"}, 0, PUT)); - REQUIRE_THROWS(proxy.Call("txdelay", {}, 0, GET)); + REQUIRE_THROWS(caller.call("txdelay", {"5"}, 0, PUT)); + REQUIRE_THROWS(caller.call("txdelay", {}, 0, GET)); for (int i = 0; i != det.size(); ++i) { if (eiger) { @@ -2979,15 +3066,15 @@ TEST_CASE("txdelay", "[.cmd]") { } } } else { - REQUIRE_THROWS(proxy.Call("txdelay", {}, -1, GET)); + REQUIRE_THROWS(caller.call("txdelay", {}, -1, GET)); } } /* ZMQ Streaming Parameters (Receiver<->Client) */ -TEST_CASE("zmqport", "[.cmd]") { +TEST_CASE("CALLER::zmqport", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); int socketsperdetector = 1; auto det_type = det.getDetectorType().squash(); @@ -3003,12 +3090,12 @@ TEST_CASE("zmqport", "[.cmd]") { auto port_str = std::to_string(port); { std::ostringstream oss; - proxy.Call("zmqport", {port_str}, -1, PUT, oss); + caller.call("zmqport", {port_str}, -1, PUT, oss); REQUIRE(oss.str() == "zmqport " + port_str + '\n'); } for (int i = 0; i != det.size(); ++i) { std::ostringstream oss; - proxy.Call("zmqport", {}, i, GET, oss); + caller.call("zmqport", {}, i, GET, oss); REQUIRE(oss.str() == "zmqport " + std::to_string(port + i * socketsperdetector) + '\n'); @@ -3018,65 +3105,69 @@ TEST_CASE("zmqport", "[.cmd]") { port_str = std::to_string(port); { std::ostringstream oss; - proxy.Call("zmqport", {port_str}, -1, PUT, oss); + caller.call("zmqport", {port_str}, -1, PUT, oss); REQUIRE(oss.str() == "zmqport " + port_str + '\n'); } for (int i = 0; i != det.size(); ++i) { std::ostringstream oss; - proxy.Call("zmqport", {}, i, GET, oss); + caller.call("zmqport", {}, i, GET, oss); REQUIRE(oss.str() == "zmqport " + std::to_string(port + i * socketsperdetector) + '\n'); } - test_valid_port("zmqport", {}, -1, PUT); - test_valid_port("zmqport", {}, 0, PUT); + test_valid_port_caller("zmqport", {}, -1, PUT); + test_valid_port_caller("zmqport", {}, 0, PUT); // should fail for the second module if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("zmqport", {"65535"}, -1, PUT)); + REQUIRE_THROWS(caller.call("zmqport", {"65535"}, -1, PUT)); } + if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { det.setNumberofUDPInterfaces(prev); } } -TEST_CASE("zmqip", "[.cmd]") { +TEST_CASE("CALLER::zmqip", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - std::ostringstream oss1, oss2; - auto zmqip = det.getClientZmqIp(); - proxy.Call("zmqip", {}, 0, GET, oss1); - REQUIRE(oss1.str() == "zmqip " + zmqip[0].str() + '\n'); + Caller caller(&det); + auto det_type = det.getDetectorType().squash(); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + std::ostringstream oss1, oss2; + auto zmqip = det.getClientZmqIp(); + caller.call("zmqip", {}, 0, GET, oss1); + REQUIRE(oss1.str() == "zmqip " + zmqip[0].str() + '\n'); - proxy.Call("zmqip", {zmqip[0].str()}, 0, PUT, oss2); - REQUIRE(oss2.str() == "zmqip " + zmqip[0].str() + '\n'); + caller.call("zmqip", {zmqip[0].str()}, 0, PUT, oss2); + REQUIRE(oss2.str() == "zmqip " + zmqip[0].str() + '\n'); - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqIP(zmqip[i], {i}); + for (int i = 0; i != det.size(); ++i) { + det.setRxZmqIP(zmqip[i], {i}); + } } } -TEST_CASE("zmqhwm", "[.cmd]") { +TEST_CASE("CALLER::zmqhwm", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getClientZmqHwm(); { std::ostringstream oss; - proxy.Call("zmqhwm", {"50"}, -1, PUT, oss); + caller.call("zmqhwm", {"50"}, -1, PUT, oss); REQUIRE(oss.str() == "zmqhwm 50\n"); } { std::ostringstream oss; - proxy.Call("zmqhwm", {}, -1, GET, oss); + caller.call("zmqhwm", {}, -1, GET, oss); REQUIRE(oss.str() == "zmqhwm 50\n"); } { std::ostringstream oss; - proxy.Call("zmqhwm", {"0"}, -1, PUT, oss); + caller.call("zmqhwm", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "zmqhwm 0\n"); } { std::ostringstream oss; - proxy.Call("zmqhwm", {"-1"}, -1, PUT, oss); + caller.call("zmqhwm", {"-1"}, -1, PUT, oss); REQUIRE(oss.str() == "zmqhwm -1\n"); } det.setClientZmqHwm(prev_val); @@ -3084,183 +3175,187 @@ TEST_CASE("zmqhwm", "[.cmd]") { /* Advanced */ -TEST_CASE("adcpipeline", "[.cmd]") { +TEST_CASE("CALLER::adcpipeline", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD || det_type == defs::MOENCH) { auto prev_val = det.getADCPipeline(); { std::ostringstream oss; - proxy.Call("adcpipeline", {"1"}, -1, PUT, oss); + caller.call("adcpipeline", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "adcpipeline 1\n"); } { std::ostringstream oss; - proxy.Call("adcpipeline", {"0"}, -1, PUT, oss); + caller.call("adcpipeline", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "adcpipeline 0\n"); } { std::ostringstream oss; - proxy.Call("adcpipeline", {"15"}, -1, PUT, oss); + caller.call("adcpipeline", {"15"}, -1, PUT, oss); REQUIRE(oss.str() == "adcpipeline 15\n"); } { std::ostringstream oss; - proxy.Call("adcpipeline", {}, -1, GET, oss); + caller.call("adcpipeline", {}, -1, GET, oss); REQUIRE(oss.str() == "adcpipeline 15\n"); } for (int i = 0; i != det.size(); ++i) { det.setADCPipeline(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("adcpipeline", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcpipeline", {}, -1, GET)); } } -TEST_CASE("programfpga", "[.cmd]") { +TEST_CASE("CALLER::programfpga", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD || det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { // TODO program a real board? /// afs/psi.ch/project/sls_det_firmware/jungfrau_firmware/cyclone_V/v0_8/Jungfrau_MCB.pof - REQUIRE_THROWS(proxy.Call("programfpga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("programfpga", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("programfpga", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("programfpga", {"/tmp/test.pof"}, -1, PUT)); + REQUIRE_THROWS(caller.call("programfpga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("programfpga", {"/tmp/test.pof"}, -1, PUT)); } } -TEST_CASE("resetfpga", "[.cmd]") { +TEST_CASE("CALLER::resetfpga", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::CHIPTESTBOARD || det_type == defs::MOENCH) { // reset will also reset udp info from config file (comment out for - // invdividual tests) std::ostringstream oss; proxy.Call("resetfpga", + // invdividual tests) std::ostringstream oss; caller.call("resetfpga", // {}, -1, PUT, oss); REQUIRE(oss.str() == "resetfpga successful\n"); - REQUIRE_THROWS(proxy.Call("resetfpga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("resetfpga", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("resetfpga", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("resetfpga", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("resetfpga", {}, -1, GET)); + REQUIRE_THROWS(caller.call("resetfpga", {}, -1, PUT)); } } -TEST_CASE("updatekernel", "[.cmd]") { +TEST_CASE("CALLER::updatekernel", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { // TODO: send real server? // std::ostringstream oss; - // proxy.Call("updatekernel",{"juImage_detector.lzma", + // caller.call("updatekernel",{"juImage_detector.lzma", // "pc13784"}, -1, PUT, oss); // REQUIRE(oss.str() == "updatekernel successful\n"); - REQUIRE_THROWS(proxy.Call("updatekernel", {}, -1, GET)); + REQUIRE_THROWS(caller.call("updatekernel", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("updatekernel", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("updatekernel", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("updatekernel", {}, -1, GET)); + REQUIRE_THROWS(caller.call("updatekernel", {}, -1, PUT)); } } -TEST_CASE("rebootcontroller", "[.cmd]") { +TEST_CASE("CALLER::rebootcontroller", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2 || det_type == defs::GOTTHARD) { // TODO: reboot real server? - // REQUIRE_NOTHROW(proxy.Call("rebootcontroller", {}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("rebootcontroller", {}, -1, GET)); + // REQUIRE_NOTHROW(caller.call("rebootcontroller", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("rebootcontroller", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("rebootcontroller", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("rebootcontroller", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("rebootcontroller", {}, -1, GET)); + REQUIRE_THROWS(caller.call("rebootcontroller", {}, -1, PUT)); } } -TEST_CASE("update", "[.cmd]") { +TEST_CASE("CALLER::update", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD) { // TODO: update real server and firmware? - // REQUIRE_NOTHROW(proxy.Call("update", + // REQUIRE_NOTHROW(caller.call("update", // {"jungfrauDetectorServerv4.0.1.0", "pc13784", // "/afs/psi.ch/project/sls_det_firmware/jungfrau_firmware/cyclone_V/v0_8/Jungfrau_MCB.pof"}, // -1, PUT)); - REQUIRE_THROWS(proxy.Call("update", {}, -1, GET)); + REQUIRE_THROWS(caller.call("update", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("update", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("update", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("update", {}, -1, GET)); + REQUIRE_THROWS(caller.call("update", {}, -1, PUT)); } } -TEST_CASE("reg", "[.cmd]") { +TEST_CASE("CALLER::reg", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::EIGER) { - uint32_t addr = 0x64; - std::string saddr = ToStringHex(addr); - auto prev_val = det.readRegister(addr); - { - std::ostringstream oss1, oss2; - proxy.Call("reg", {saddr, "0x5"}, -1, PUT, oss1); - REQUIRE(oss1.str() == "reg [" + saddr + ", 0x5]\n"); - proxy.Call("reg", {saddr}, -1, GET, oss2); - REQUIRE(oss2.str() == "reg 0x5\n"); + if (det_type != defs::XILINX_CHIPTESTBOARD) { + if (det_type != defs::EIGER) { + uint32_t addr = 0x64; + std::string saddr = ToStringHex(addr); + auto prev_val = det.readRegister(addr); + { + std::ostringstream oss1, oss2; + caller.call("reg", {saddr, "0x5"}, -1, PUT, oss1); + REQUIRE(oss1.str() == "reg [" + saddr + ", 0x5]\n"); + caller.call("reg", {saddr}, -1, GET, oss2); + REQUIRE(oss2.str() == "reg 0x5\n"); + } + for (int i = 0; i != det.size(); ++i) { + det.writeRegister(addr, prev_val[i], {i}); + } } - for (int i = 0; i != det.size(); ++i) { - det.writeRegister(addr, prev_val[i], {i}); + // cannot check for eiger virtual server + else { + REQUIRE_NOTHROW(caller.call("reg", {"0x64"}, -1, GET)); } - } - // cannot check for eiger virtual server - else { - REQUIRE_NOTHROW(proxy.Call("reg", {"0x64"}, -1, GET)); + } else { + REQUIRE_THROWS(caller.call("reg", {}, -1, GET)); } } -TEST_CASE("adcreg", "[.cmd]") { +TEST_CASE("CALLER::adcreg", "[.cmdcall]") { // TODO! what is a safe value to use? Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::GOTTHARD) { std::ostringstream oss; - proxy.Call("adcreg", {"0x8", "0x3"}, -1, PUT, oss); + caller.call("adcreg", {"0x8", "0x3"}, -1, PUT, oss); REQUIRE(oss.str() == "adcreg [0x8, 0x3]\n"); // This is a put only command - REQUIRE_THROWS(proxy.Call("adcreg", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcreg", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("adcreg", {"0x0", "0"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("adcreg", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcreg", {"0x0", "0"}, -1, PUT)); + REQUIRE_THROWS(caller.call("adcreg", {}, -1, GET)); } } -TEST_CASE("setbit", "[.cmd]") { +TEST_CASE("CALLER::setbit", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::EIGER) { + if (det_type != defs::EIGER && det_type != defs::XILINX_CHIPTESTBOARD) { uint32_t addr = 0x64; std::string saddr = ToStringHex(addr); auto prev_val = det.readRegister(addr); { std::ostringstream oss1, oss2; - proxy.Call("reg", {saddr, "0x0"}, -1, PUT); - proxy.Call("setbit", {saddr, "1"}, -1, PUT, oss1); + caller.call("reg", {saddr, "0x0"}, -1, PUT); + caller.call("setbit", {saddr, "1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "setbit [" + saddr + ", 1]\n"); - proxy.Call("reg", {saddr}, -1, GET, oss2); + caller.call("reg", {saddr}, -1, GET, oss2); REQUIRE(oss2.str() == "reg 0x2\n"); } for (int i = 0; i != det.size(); ++i) { @@ -3269,20 +3364,20 @@ TEST_CASE("setbit", "[.cmd]") { } } -TEST_CASE("clearbit", "[.cmd]") { +TEST_CASE("CALLER::clearbit", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::EIGER) { + if (det_type != defs::EIGER && det_type != defs::XILINX_CHIPTESTBOARD) { uint32_t addr = 0x64; std::string saddr = ToStringHex(addr); auto prev_val = det.readRegister(addr); { std::ostringstream oss1, oss2; - proxy.Call("reg", {saddr, "0x3"}, -1, PUT); - proxy.Call("clearbit", {saddr, "1"}, -1, PUT, oss1); + caller.call("reg", {saddr, "0x3"}, -1, PUT); + caller.call("clearbit", {saddr, "1"}, -1, PUT, oss1); REQUIRE(oss1.str() == "clearbit [" + saddr + ", 1]\n"); - proxy.Call("reg", {saddr}, -1, GET, oss2); + caller.call("reg", {saddr}, -1, GET, oss2); REQUIRE(oss2.str() == "reg 0x1\n"); } for (int i = 0; i != det.size(); ++i) { @@ -3291,18 +3386,20 @@ TEST_CASE("clearbit", "[.cmd]") { } } -TEST_CASE("getbit", "[.cmd]") { +TEST_CASE("CALLER::getbit", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); - if (det_type != defs::EIGER) { + if (det_type == defs::XILINX_CHIPTESTBOARD) { + REQUIRE_THROWS(caller.call("getbit", {"0x64", "1"}, -1, GET)); + } else if (det_type != defs::EIGER) { uint32_t addr = 0x64; std::string saddr = ToStringHex(addr); auto prev_val = det.readRegister(addr); { std::ostringstream oss1, oss2; - proxy.Call("reg", {saddr, "0x3"}, -1, PUT); - proxy.Call("getbit", {saddr, "1"}, -1, GET, oss1); + caller.call("reg", {saddr, "0x3"}, -1, PUT); + caller.call("getbit", {saddr, "1"}, -1, GET, oss1); REQUIRE(oss1.str() == "getbit 1\n"); } for (int i = 0; i != det.size(); ++i) { @@ -3311,69 +3408,69 @@ TEST_CASE("getbit", "[.cmd]") { } // cannot check for eiger virtual server else { - REQUIRE_NOTHROW(proxy.Call("getbit", {"0x64", "1"}, -1, GET)); + REQUIRE_NOTHROW(caller.call("getbit", {"0x64", "1"}, -1, GET)); } } -TEST_CASE("firmwaretest", "[.cmd]") { +TEST_CASE("CALLER::firmwaretest", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::GOTTHARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { std::ostringstream oss; - proxy.Call("firmwaretest", {}, -1, PUT, oss); + caller.call("firmwaretest", {}, -1, PUT, oss); REQUIRE(oss.str() == "firmwaretest successful\n"); - REQUIRE_THROWS(proxy.Call("firmwaretest", {}, -1, GET)); + REQUIRE_THROWS(caller.call("firmwaretest", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("firmwaretest", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("firmwaretest", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("firmwaretest", {}, -1, GET)); + REQUIRE_THROWS(caller.call("firmwaretest", {}, -1, PUT)); } } -TEST_CASE("bustest", "[.cmd]") { +TEST_CASE("CALLER::bustest", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::GOTTHARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { std::ostringstream oss; - proxy.Call("bustest", {}, -1, PUT, oss); + caller.call("bustest", {}, -1, PUT, oss); REQUIRE(oss.str() == "bustest successful\n"); - REQUIRE_THROWS(proxy.Call("bustest", {}, -1, GET)); + REQUIRE_THROWS(caller.call("bustest", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("bustest", {}, -1, GET)); - REQUIRE_THROWS(proxy.Call("bustest", {}, -1, PUT)); + REQUIRE_THROWS(caller.call("bustest", {}, -1, GET)); + REQUIRE_THROWS(caller.call("bustest", {}, -1, PUT)); } } -TEST_CASE("initialchecks", "[.cmd]") { +TEST_CASE("CALLER::initialchecks", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto check = det.getInitialChecks(); { std::ostringstream oss; - proxy.Call("initialchecks", {"0"}, -1, PUT, oss); + caller.call("initialchecks", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "initialchecks 0\n"); } { std::ostringstream oss; - proxy.Call("initialchecks", {}, -1, GET, oss); + caller.call("initialchecks", {}, -1, GET, oss); REQUIRE(oss.str() == "initialchecks 0\n"); } { std::ostringstream oss; - proxy.Call("initialchecks", {}, -1, GET, oss); + caller.call("initialchecks", {}, -1, GET, oss); REQUIRE(oss.str() == "initialchecks 0\n"); } det.setInitialChecks(check); } -TEST_CASE("adcinvert", "[.cmd]") { +TEST_CASE("CALLER::adcinvert", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::CHIPTESTBOARD || det_type == defs::JUNGFRAU || @@ -3381,87 +3478,89 @@ TEST_CASE("adcinvert", "[.cmd]") { auto prev_val = det.getADCInvert(); { std::ostringstream oss; - proxy.Call("adcinvert", {"0x8d0a21d4"}, -1, PUT, oss); + caller.call("adcinvert", {"0x8d0a21d4"}, -1, PUT, oss); REQUIRE(oss.str() == "adcinvert 0x8d0a21d4\n"); } { std::ostringstream oss; - proxy.Call("adcinvert", {}, -1, GET, oss); + caller.call("adcinvert", {}, -1, GET, oss); REQUIRE(oss.str() == "adcinvert 0x8d0a21d4\n"); } for (int i = 0; i != det.size(); ++i) { det.setADCInvert(prev_val[i], {i}); } } else { - REQUIRE_THROWS(proxy.Call("adcinvert", {}, -1, GET)); + REQUIRE_THROWS(caller.call("adcinvert", {}, -1, GET)); } } /* Insignificant */ -TEST_CASE("port", "[.cmd]") { +TEST_CASE("CALLER::port", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getControlPort({0}).squash(); { std::ostringstream oss; - proxy.Call("port", {"1942"}, 0, PUT, oss); + caller.call("port", {"1942"}, 0, PUT, oss); REQUIRE(oss.str() == "port 1942\n"); } { std::ostringstream oss; - proxy.Call("port", {}, 0, GET, oss); + caller.call("port", {}, 0, GET, oss); REQUIRE(oss.str() == "port 1942\n"); } - test_valid_port("port", {}, -1, PUT); - test_valid_port("port", {}, 0, PUT); + test_valid_port_caller("port", {}, -1, PUT); + test_valid_port_caller("port", {}, 0, PUT); // should fail for the second module if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("port", {"65536"}, -1, PUT)); + REQUIRE_THROWS(caller.call("port", {"65536"}, -1, PUT)); } + det.setControlPort(prev_val, {0}); } -TEST_CASE("stopport", "[.cmd]") { +TEST_CASE("CALLER::stopport", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getStopPort({0}).squash(); { std::ostringstream oss; - proxy.Call("stopport", {"1942"}, 0, PUT, oss); + caller.call("stopport", {"1942"}, 0, PUT, oss); REQUIRE(oss.str() == "stopport 1942\n"); } { std::ostringstream oss; - proxy.Call("stopport", {}, 0, GET, oss); + caller.call("stopport", {}, 0, GET, oss); REQUIRE(oss.str() == "stopport 1942\n"); } - test_valid_port("stopport", {}, -1, PUT); - test_valid_port("stopport", {}, 0, PUT); + test_valid_port_caller("stopport", {}, -1, PUT); + test_valid_port_caller("stopport", {}, 0, PUT); // should fail for the second module if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("stopport", {"65536"}, -1, PUT)); + REQUIRE_THROWS(caller.call("stopport", {"65536"}, -1, PUT)); } + det.setStopPort(prev_val, {0}); } -TEST_CASE("lock", "[.cmd]") { +TEST_CASE("CALLER::lock", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto prev_val = det.getDetectorLock(); { std::ostringstream oss; - proxy.Call("lock", {"1"}, -1, PUT, oss); + caller.call("lock", {"1"}, -1, PUT, oss); REQUIRE(oss.str() == "lock 1\n"); } { std::ostringstream oss; - proxy.Call("lock", {}, -1, GET, oss); + caller.call("lock", {}, -1, GET, oss); REQUIRE(oss.str() == "lock 1\n"); } { std::ostringstream oss; - proxy.Call("lock", {"0"}, -1, PUT, oss); + caller.call("lock", {"0"}, -1, PUT, oss); REQUIRE(oss.str() == "lock 0\n"); } for (int i = 0; i != det.size(); ++i) { @@ -3469,74 +3568,74 @@ TEST_CASE("lock", "[.cmd]") { } } -TEST_CASE("execcommand", "[.cmd]") { +TEST_CASE("CALLER::execcommand", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("execcommand", {"ls"}, -1, PUT)); + Caller caller(&det); + REQUIRE_NOTHROW(caller.call("execcommand", {"ls *.txt"}, -1, PUT)); } -TEST_CASE("framecounter", "[.cmd]") { +TEST_CASE("CALLER::framecounter", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { auto framecounter = det.getNumberOfFramesFromStart().squash(); std::ostringstream oss; - proxy.Call("framecounter", {}, -1, GET, oss); + caller.call("framecounter", {}, -1, GET, oss); REQUIRE(oss.str() == "framecounter " + std::to_string(framecounter) + "\n"); - REQUIRE_NOTHROW(proxy.Call("framecounter", {}, -1, GET)); + REQUIRE_NOTHROW(caller.call("framecounter", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("framecounter", {}, -1, GET)); + REQUIRE_THROWS(caller.call("framecounter", {}, -1, GET)); } } -TEST_CASE("runtime", "[.cmd]") { +TEST_CASE("CALLER::runtime", "[.cmdcall]") { // TODO! can we test this? Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { std::ostringstream oss; - proxy.Call("runtime", {}, -1, GET, oss); + caller.call("runtime", {}, -1, GET, oss); // Get only - REQUIRE_THROWS(proxy.Call("runtime", {"2019"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("runtime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("runtime", {"2019"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("runtime", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("runtime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("runtime", {}, -1, GET)); } } -TEST_CASE("frametime", "[.cmd]") { +TEST_CASE("CALLER::frametime", "[.cmdcall]") { // TODO! can we test this? Detector det; - CmdProxy proxy(&det); + Caller caller(&det); auto det_type = det.getDetectorType().squash(); if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH || det_type == defs::CHIPTESTBOARD || det_type == defs::MYTHEN3 || det_type == defs::GOTTHARD2) { std::ostringstream oss; - proxy.Call("frametime", {}, -1, GET, oss); + caller.call("frametime", {}, -1, GET, oss); // Get only - REQUIRE_THROWS(proxy.Call("frametime", {"2019"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("frametime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("frametime", {"2019"}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("frametime", {}, -1, GET)); } else { - REQUIRE_THROWS(proxy.Call("frametime", {}, -1, GET)); + REQUIRE_THROWS(caller.call("frametime", {}, -1, GET)); } } -TEST_CASE("user", "[.cmd]") { +TEST_CASE("CALLER::user", "[.cmdcall]") { Detector det; - CmdProxy proxy(&det); - proxy.Call("user", {}, -1, GET); + Caller caller(&det); + caller.call("user", {}, -1, GET); // This is a get only command - REQUIRE_THROWS(proxy.Call("user", {}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("user", {}, -1, GET)); + REQUIRE_THROWS(caller.call("user", {}, -1, PUT)); + REQUIRE_NOTHROW(caller.call("user", {}, -1, GET)); } -} // namespace sls +} // namespace sls \ No newline at end of file diff --git a/slsDetectorSoftware/tests/test-CmdProxy-global.h b/slsDetectorSoftware/tests/test-CmdProxy-global.h deleted file mode 100644 index 164fbbc8a..000000000 --- a/slsDetectorSoftware/tests/test-CmdProxy-global.h +++ /dev/null @@ -1,17 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#pragma once -#include "sls/sls_detector_defs.h" - -namespace sls { - -void test_valid_port(const std::string &command, - const std::vector &arguments, int detector_id, - int action); - -void test_dac(slsDetectorDefs::dacIndex index, const std::string &dacname, - int dacvalue); -void test_onchip_dac(slsDetectorDefs::dacIndex index, - const std::string &dacname, int dacvalue); - -} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy-gotthard.cpp b/slsDetectorSoftware/tests/test-CmdProxy-gotthard.cpp deleted file mode 100644 index 4c26986c2..000000000 --- a/slsDetectorSoftware/tests/test-CmdProxy-gotthard.cpp +++ /dev/null @@ -1,164 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" -#include "catch.hpp" -#include "sls/Detector.h" -#include "sls/sls_detector_defs.h" -#include - -#include "sls/Result.h" -#include "sls/ToString.h" -#include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" -#include "tests/globals.h" - -namespace sls { - -using test::GET; -using test::PUT; - -/* dacs */ - -TEST_CASE("Setting and reading back GOTTHARD dacs", "[.cmd][.dacs]") { - // vref_ds, vcascn_pb, vcascp_pb, vout_cm, vcasc_out, vin_cm, vref_comp, - // ib_test_c - - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::GOTTHARD) { - SECTION("vref_ds") { test_dac(defs::VREF_DS, "vref_ds", 660); } - SECTION("vcascn_pb") { test_dac(defs::VCASCN_PB, "vcascn_pb", 650); } - SECTION("vcascp_pb") { test_dac(defs::VCASCP_PB, "vcascp_pb", 1480); } - SECTION("vout_cm") { test_dac(defs::VOUT_CM, "vout_cm", 1520); } - SECTION("vcasc_out") { test_dac(defs::VCASC_OUT, "vcasc_out", 1320); } - SECTION("vin_cm") { test_dac(defs::VIN_CM, "vin_cm", 1350); } - SECTION("vref_comp") { test_dac(defs::VREF_COMP, "vref_comp", 350); } - SECTION("ib_test_c") { test_dac(defs::IB_TESTC, "ib_test_c", 2001); } - // eiger - REQUIRE_THROWS(proxy.Call("dac", {"vthreshold"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vsvp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vsvn"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtgstv"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_ll"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_lr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rl"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcmp_rr"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_rb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"rxb_lb"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcn"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"iodelay"}, -1, GET)); - // jungfrau - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdd_prot"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vin_com"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_prech"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_pixbuf"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_ds"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vref_ds"}, -1, GET)); - // REQUIRE_THROWS(proxy.Call("dac", {"vref_comp"}, -1, GET)); - // mythen3 - REQUIRE_THROWS(proxy.Call("dac", {"vrpreamp"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vrshaper_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vishaper"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vdcsh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth2"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vth3"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_n"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcal_p"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vtrim"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcassh"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcas"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vicin"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vipre_out"}, -1, GET)); - // gotthard2 - REQUIRE_THROWS(proxy.Call("dac", {"vref_h_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_comp_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_rstore"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_1st"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_comp_fe"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc1"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_l_adc"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vref_cds"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_cs"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vb_opa_fd"}, -1, GET)); - REQUIRE_THROWS(proxy.Call("dac", {"vcom_adc2"}, -1, GET)); - } -} - -/* Gotthard Specific */ - -TEST_CASE("roi", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - - if (det_type == defs::GOTTHARD) { - if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("roi", {"0", "255"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("roi", {}, -1, GET)); - } else { - auto prev_val = det.getROI(); - { - std::ostringstream oss; - proxy.Call("roi", {"0", "255"}, -1, PUT, oss); - REQUIRE(oss.str() == "roi [0, 255]\n"); - } - { - std::ostringstream oss; - proxy.Call("roi", {"256", "511"}, -1, PUT, oss); - REQUIRE(oss.str() == "roi [256, 511]\n"); - } - REQUIRE_THROWS(proxy.Call("roi", {"0", "256"}, -1, PUT)); - for (int i = 0; i != det.size(); ++i) { - det.setROI(prev_val[i], i); - } - } - } else { - REQUIRE_THROWS(proxy.Call("roi", {}, -1, GET)); - } -} - -TEST_CASE("clearroi", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - - if (det_type == defs::GOTTHARD) { - auto prev_val = det.getROI(); - { - std::ostringstream oss; - proxy.Call("clearroi", {}, -1, PUT, oss); - REQUIRE(oss.str() == "clearroi successful\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setROI(prev_val[i], i); - } - } else { - REQUIRE_THROWS(proxy.Call("clearroi", {}, -1, PUT)); - } -} - -TEST_CASE("exptimel", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::GOTTHARD) { - REQUIRE_NOTHROW(proxy.Call("exptimel", {}, -1, GET)); - } else { - REQUIRE_THROWS(proxy.Call("exptimel", {}, -1, GET)); - } -} - -} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy-moench.cpp b/slsDetectorSoftware/tests/test-CmdProxy-moench.cpp deleted file mode 100644 index 78319f98b..000000000 --- a/slsDetectorSoftware/tests/test-CmdProxy-moench.cpp +++ /dev/null @@ -1,22 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" -#include "catch.hpp" -#include "sls/Detector.h" -#include "sls/sls_detector_defs.h" -#include - -#include "sls/Result.h" -#include "sls/ToString.h" -#include "sls/versionAPI.h" -#include "test-CmdProxy-global.h" -#include "tests/globals.h" - -namespace sls { - -using test::GET; -using test::PUT; - -/* dacs */ - -} // namespace sls diff --git a/slsDetectorSoftware/tests/test-CmdProxy-rx.cpp b/slsDetectorSoftware/tests/test-CmdProxy-rx.cpp deleted file mode 100644 index 364335450..000000000 --- a/slsDetectorSoftware/tests/test-CmdProxy-rx.cpp +++ /dev/null @@ -1,1035 +0,0 @@ -// SPDX-License-Identifier: LGPL-3.0-or-other -// Copyright (C) 2021 Contributors to the SLS Detector Package -#include "CmdProxy.h" -#include "catch.hpp" -#include "sls/Detector.h" -#include "sls/Version.h" -#include "sls/sls_detector_defs.h" -#include "test-CmdProxy-global.h" -#include - -#include "sls/versionAPI.h" -#include "tests/globals.h" - -namespace sls { - -using test::GET; -using test::PUT; - -/* -This file should contain receiver specific tests use -python/scripts/list_tested_cmd.py to check if all commands are covered -*/ - -/* configuration */ - -TEST_CASE("rx_version", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - std::ostringstream oss; - proxy.Call("rx_version", {}, -1, GET, oss); - sls::Version v(APIRECEIVER); - std::ostringstream vs; - vs << "rx_version " << v.concise() << '\n'; - REQUIRE(oss.str() == vs.str()); - - REQUIRE_THROWS(proxy.Call("rx_version", {"0"}, -1, PUT)); -} - -/* acquisition */ -TEST_CASE("rx_start", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - det.setFileWrite(false); // avoid writing or error on file creation - // PUT only command - REQUIRE_THROWS(proxy.Call("rx_start", {}, -1, GET)); - { - std::ostringstream oss; - proxy.Call("rx_start", {}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_start successful\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_status", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_status running\n"); - } -} - -TEST_CASE("rx_stop", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - // PUT only command - REQUIRE_THROWS(proxy.Call("rx_stop", {}, -1, GET)); - { - std::ostringstream oss; - proxy.Call("rx_stop", {}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_stop successful\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_status", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_status idle\n"); - } -} - -TEST_CASE("rx_status", "[.cmd][.rx]") { - Detector det; - det.setFileWrite(false); // avoid writing or error on file creation - CmdProxy proxy(&det); - det.startReceiver(); - { - std::ostringstream oss; - proxy.Call("rx_status", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_status running\n"); - } - det.stopReceiver(); - { - std::ostringstream oss; - proxy.Call("rx_status", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_status idle\n"); - } -} - -TEST_CASE("rx_framescaught", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - - // This ensures 0 caught frames - auto prev_val = det.getFileWrite(); - det.setFileWrite(false); // avoid writing or error on file creation - det.startReceiver(); - det.stopReceiver(); - { - std::ostringstream oss; - proxy.Call("rx_framescaught", {}, -1, GET, oss); - if (det.getNumberofUDPInterfaces().tsquash( - "inconsistent number of interfaces") == 1) { - REQUIRE(oss.str() == "rx_framescaught [0]\n"); - } else { - REQUIRE(oss.str() == "rx_framescaught [0, 0]\n"); - } - } - - // Currently disabled may activate if we have a stable env - // Now take one frame and see that we caught it - // det.setNumberOfFrames(1); - // det.acquire(); - // { - // std::ostringstream oss; - // proxy.Call("rx_framescaught", {}, -1, GET, oss); - // REQUIRE(oss.str() == "rx_framescaught 1\n"); - // } - - for (int i = 0; i != det.size(); ++i) { - det.setFileWrite(prev_val[i], {i}); - } -} - -TEST_CASE("rx_missingpackets", "[.cmd][.rx]") { - Detector det; - auto prev_val = det.getFileWrite(); - det.setFileWrite(false); // avoid writing or error on file creation - CmdProxy proxy(&det); - auto prev_frames = - det.getNumberOfFrames().tsquash("inconsistent #frames in test"); - det.setNumberOfFrames(100); - { - // some missing packets - det.startReceiver(); - det.stopReceiver(); - std::ostringstream oss; - proxy.Call("rx_missingpackets", {}, -1, GET, oss); - if (det.getNumberofUDPInterfaces().tsquash( - "inconsistent number of interfaces") == 1) { - REQUIRE(oss.str() != "rx_missingpackets [0]\n"); - } else { - REQUIRE(oss.str() != "rx_missingpackets [0, 0]\n"); - } - } - auto det_type = det.getDetectorType().squash(); - if (det_type != defs::CHIPTESTBOARD && det_type != defs::MOENCH) { - // 0 missing packets (takes into account that acquisition is stopped) - det.startReceiver(); - det.startDetector(); - det.stopDetector(); - det.stopReceiver(); - std::ostringstream oss; - proxy.Call("rx_missingpackets", {}, -1, GET, oss); - if (det.getNumberofUDPInterfaces().tsquash( - "inconsistent number of interfaces") == 1) { - REQUIRE(oss.str() == "rx_missingpackets [0]\n"); - } else { - REQUIRE(oss.str() == "rx_missingpackets [0, 0]\n"); - } - } - for (int i = 0; i != det.size(); ++i) { - det.setFileWrite(prev_val[i], {i}); - } - det.setNumberOfFrames(prev_frames); -} - -TEST_CASE("rx_frameindex", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - proxy.Call("rx_frameindex", {}, -1, GET); - - // This is a get only command - REQUIRE_THROWS(proxy.Call("rx_frameindex", {"2"}, -1, PUT)); -} - -/* Network Configuration (Detector<->Receiver) */ - -TEST_CASE("rx_printconfig", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - REQUIRE_NOTHROW(proxy.Call("rx_printconfig", {}, -1, GET)); -} - -/* Receiver Config */ - -TEST_CASE("rx_hostname", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxHostname(); - - // Cannot set rx_hostname (will reset parameters in rxr and no shm variables - // to update) - // { - // // disable receiver - // std::ostringstream oss; - // proxy.Call("rx_hostname", {"none"}, -1, PUT, oss); - // REQUIRE(oss.str() == "rx_hostname [none]\n"); - // } - // { - // std::ostringstream oss; - // proxy.Call("rx_hostname", {}, -1, GET, oss); - // REQUIRE(oss.str() == "rx_hostname none\n"); - // // receiver should be disabled - // REQUIRE(det.getUseReceiverFlag().tsquash( - // "different values of flag in test") == false); - // } - // put back old values (not necessary when we dont set it to none) - // for (int i = 0; i != det.size(); ++i) { - // det.setRxHostname(prev_val[i], {i}); - // } - { - std::ostringstream oss; - proxy.Call("rx_hostname", {}, 0, GET, oss); - REQUIRE(oss.str() == "rx_hostname " + prev_val[0] + "\n"); - } -} - -TEST_CASE("rx_tcpport", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxPort(); - - uint16_t port = 3500; - proxy.Call("rx_tcpport", {std::to_string(port)}, -1, PUT); - for (int i = 0; i != det.size(); ++i) { - std::ostringstream oss; - proxy.Call("rx_tcpport", {}, i, GET, oss); - REQUIRE(oss.str() == "rx_tcpport " + std::to_string(port + i) + '\n'); - } - port = 5754; - proxy.Call("rx_tcpport", {std::to_string(port)}, -1, PUT); - for (int i = 0; i != det.size(); ++i) { - std::ostringstream oss; - proxy.Call("rx_tcpport", {}, i, GET, oss); - REQUIRE(oss.str() == "rx_tcpport " + std::to_string(port + i) + '\n'); - } - - test_valid_port("rx_tcpport", {}, -1, PUT); - test_valid_port("rx_tcpport", {}, 0, PUT); - // should fail for the second module - if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("rx_tcpport", {"65535"}, -1, PUT)); - auto rxHostname = det.getRxHostname().squash("none"); - if (rxHostname != "none") { - std::ostringstream oss; - for (int i = 0; i != det.size(); ++i) { - oss << rxHostname << ":" << 65536 + i << "+"; - } - REQUIRE_THROWS(proxy.Call("rx_hostname", {oss.str()}, -1, PUT)); - } - } - - for (int i = 0; i != det.size(); ++i) { - det.setRxPort(prev_val[i], i); - } -} - -TEST_CASE("rx_fifodepth", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxFifoDepth(); - { - std::ostringstream oss; - proxy.Call("rx_fifodepth", {"10"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_fifodepth 10\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_fifodepth", {"100"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_fifodepth 100\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_fifodepth", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_fifodepth 100\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxFifoDepth(prev_val[i], {i}); - } -} - -TEST_CASE("rx_silent", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxSilentMode(); - { - std::ostringstream oss; - proxy.Call("rx_silent", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_silent 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_silent", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_silent 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_silent", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_silent 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxSilentMode(prev_val[i], {i}); - } -} - -TEST_CASE("rx_discardpolicy", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxFrameDiscardPolicy(); - { - std::ostringstream oss; - proxy.Call("rx_discardpolicy", {"discardempty"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_discardpolicy discardempty\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_discardpolicy", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_discardpolicy discardempty\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_discardpolicy", {"discardpartial"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_discardpolicy discardpartial\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_discardpolicy", {"nodiscard"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_discardpolicy nodiscard\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxFrameDiscardPolicy(prev_val[i], {i}); - } -} - -TEST_CASE("rx_padding", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getPartialFramesPadding(); - { - std::ostringstream oss; - proxy.Call("rx_padding", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_padding 0\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_padding", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_padding 0\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_padding", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_padding 1\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setPartialFramesPadding(prev_val[i], {i}); - } -} - -TEST_CASE("rx_udpsocksize", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - int64_t prev_val = det.getRxUDPSocketBufferSize().tsquash( - "Need same udp socket buffer size to test"); - std::string s_new_val = std::to_string(prev_val); - /*std::string s_new_val = std::to_string(prev_val - 1000); - { Need permissions - std::ostringstream oss; - proxy.Call("rx_udpsocksize", {s_new_val}, -1, PUT, oss); - REQUIRE(oss.str() >= "rx_udpsocksize " + s_new_val + "\n"); - }*/ - { - std::ostringstream oss; - proxy.Call("rx_udpsocksize", {}, -1, GET, oss); - REQUIRE(oss.str() >= "rx_udpsocksize " + s_new_val + "\n"); - } - det.setRxUDPSocketBufferSize(prev_val); -} - -TEST_CASE("rx_realudpsocksize", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - uint64_t val = 0; - { - std::ostringstream oss; - proxy.Call("rx_udpsocksize", {}, -1, GET, oss); - std::string s = (oss.str()).erase(0, strlen("rx_udpsocksize ")); - val = std::stol(s); - } - { - std::ostringstream oss; - proxy.Call("rx_realudpsocksize", {}, -1, GET, oss); - std::string s = (oss.str()).erase(0, strlen("rx_realudpsocksize ")); - uint64_t rval = std::stol(s); - REQUIRE(rval >= val * 2); - } -} - -TEST_CASE("rx_lock", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxLock(); - { - std::ostringstream oss; - proxy.Call("rx_lock", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_lock 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_lock", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_lock 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_lock", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_lock 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxLock(prev_val[i], {i}); - } -} - -TEST_CASE("rx_lastclient", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("rx_lastclient", {}, -1, GET, oss)); - if (test::my_ip != "undefined") { - REQUIRE(oss.str() == "rx_lastclient " + test::my_ip + "\n"); - } -} - -TEST_CASE("rx_threads", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - std::ostringstream oss; - REQUIRE_NOTHROW(proxy.Call("rx_threads", {}, -1, GET, oss)); -} - -TEST_CASE("rx_arping", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxArping(); - { - std::ostringstream oss; - proxy.Call("rx_arping", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_arping 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_arping", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_arping 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_arping", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_arping 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxArping(prev_val[i], {i}); - } -} - -TEST_CASE("rx_roi", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - - if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_THROWS(proxy.Call("rx_roi", {"5", "10"}, -1, PUT)); - } else { - auto prev_val = det.getRxROI(); - defs::xy detsize = det.getDetectorSize(); - - // 1d - if (det_type == defs::GOTTHARD || det_type == defs::GOTTHARD2 || - det_type == defs::MYTHEN3) { - { - std::ostringstream oss; - proxy.Call("rx_roi", {"5", "10"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_roi [5, 10]\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_roi", {"10", "15"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_roi [10, 15]\n"); - } - REQUIRE_THROWS(proxy.Call("rx_roi", {"-1", "-1"}, -1, PUT)); - REQUIRE_THROWS( - proxy.Call("rx_roi", {"10", "15", "25", "30"}, -1, PUT)); - } - // 2d - else { - { - std::ostringstream oss; - proxy.Call("rx_roi", {"10", "15", "1", "5"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_roi [10, 15, 1, 5]\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_roi", {"10", "22", "18", "19"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_roi [10, 22, 18, 19]\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_roi", - {"1", std::to_string(detsize.x - 5), "1", - std::to_string(detsize.y - 5)}, - -1, PUT, oss); - REQUIRE(oss.str() == std::string("rx_roi [1, ") + - std::to_string(detsize.x - 5) + - std::string(", 1, ") + - std::to_string(detsize.y - 5) + - std::string("]\n")); - } - REQUIRE_THROWS( - proxy.Call("rx_roi", {"-1", "-1", "-1", "-1"}, -1, PUT)); - } - - for (int i = 0; i != det.size(); ++i) { - det.setRxROI(prev_val); - } - } -} - -TEST_CASE("rx_clearroi", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - - if (det_type == defs::CHIPTESTBOARD) { - REQUIRE_THROWS(proxy.Call("rx_clearroi", {}, -1, PUT)); - } else { - auto prev_val = det.getRxROI(); - { - std::ostringstream oss; - proxy.Call("rx_clearroi", {}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_clearroi successful\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxROI(prev_val); - } - } -} - -/* File */ - -TEST_CASE("fformat", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFileFormat(); - { - std::ostringstream oss; - proxy.Call("fformat", {"binary"}, -1, PUT, oss); - REQUIRE(oss.str() == "fformat binary\n"); - } - { - std::ostringstream oss; - proxy.Call("fformat", {}, -1, GET, oss); - REQUIRE(oss.str() == "fformat binary\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setFileFormat(prev_val[i], {i}); - } -} - -TEST_CASE("fpath", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFilePath(); - { - std::ostringstream oss; - proxy.Call("fpath", {"/tmp"}, -1, PUT, oss); - REQUIRE(oss.str() == "fpath /tmp\n"); - } - { - std::ostringstream oss; - proxy.Call("fpath", {}, -1, GET, oss); - REQUIRE(oss.str() == "fpath /tmp\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setFilePath(prev_val[i], {i}); - } -} - -TEST_CASE("fname", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFileNamePrefix(); - { - std::ostringstream oss; - proxy.Call("fname", {"somename"}, -1, PUT, oss); - REQUIRE(oss.str() == "fname somename\n"); - } - { - std::ostringstream oss; - proxy.Call("fname", {}, -1, GET, oss); - REQUIRE(oss.str() == "fname somename\n"); - } - { - std::ostringstream oss; - proxy.Call("fname", {"run"}, -1, PUT, oss); - REQUIRE(oss.str() == "fname run\n"); - } - REQUIRE_THROWS(proxy.Call("fname", {"fdf/dfd"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("fname", {"fdf dfd"}, -1, PUT)); - - for (int i = 0; i != det.size(); ++i) { - det.setFileNamePrefix(prev_val[i], {i}); - } -} - -TEST_CASE("findex", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getAcquisitionIndex(); - { - std::ostringstream oss; - proxy.Call("findex", {"57"}, -1, PUT, oss); - REQUIRE(oss.str() == "findex 57\n"); - } - { - std::ostringstream oss; - proxy.Call("findex", {}, -1, GET, oss); - REQUIRE(oss.str() == "findex 57\n"); - } - { - std::ostringstream oss; - proxy.Call("findex", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "findex 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setAcquisitionIndex(prev_val[i], {i}); - } -} - -TEST_CASE("fwrite", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFileWrite(); - { - std::ostringstream oss; - proxy.Call("fwrite", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "fwrite 1\n"); - } - { - std::ostringstream oss; - proxy.Call("fwrite", {}, -1, GET, oss); - REQUIRE(oss.str() == "fwrite 1\n"); - } - { - std::ostringstream oss; - proxy.Call("fwrite", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "fwrite 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setFileWrite(prev_val[i], {i}); - } -} - -TEST_CASE("fmaster", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getMasterFileWrite(); - { - std::ostringstream oss; - proxy.Call("fmaster", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "fmaster 0\n"); - } - { - std::ostringstream oss; - proxy.Call("fmaster", {}, -1, GET, oss); - REQUIRE(oss.str() == "fmaster 0\n"); - } - { - std::ostringstream oss; - proxy.Call("fmaster", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "fmaster 1\n"); - } - det.setMasterFileWrite(prev_val); -} - -TEST_CASE("foverwrite", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFileOverWrite(); - { - std::ostringstream oss; - proxy.Call("foverwrite", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "foverwrite 1\n"); - } - { - std::ostringstream oss; - proxy.Call("foverwrite", {}, -1, GET, oss); - REQUIRE(oss.str() == "foverwrite 1\n"); - } - { - std::ostringstream oss; - proxy.Call("foverwrite", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "foverwrite 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setFileOverWrite(prev_val[i], {i}); - } -} - -TEST_CASE("rx_framesperfile", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getFramesPerFile(); - { - std::ostringstream oss; - proxy.Call("rx_framesperfile", {"50"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_framesperfile 50\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_framesperfile", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_framesperfile 50\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_framesperfile", {"10000"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_framesperfile 10000\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_framesperfile", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_framesperfile 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setFramesPerFile(prev_val[i], {i}); - } -} - -/* ZMQ Streaming Parameters (Receiver<->Client) */ - -TEST_CASE("rx_zmqstream", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxZmqDataStream(); - { - std::ostringstream oss; - proxy.Call("rx_zmqstream", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqstream 1\n"); - REQUIRE(det.getRxZmqDataStream().squash() == true); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqstream", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_zmqstream 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqstream", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqstream 0\n"); - REQUIRE(det.getRxZmqDataStream().squash() == false); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqDataStream(prev_val[i], {i}); - } -} - -TEST_CASE("rx_zmqfreq", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxZmqFrequency(); - { - std::ostringstream oss; - proxy.Call("rx_zmqfreq", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqfreq 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqfreq", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_zmqfreq 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqfreq", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqfreq 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqFrequency(prev_val[i], {i}); - } -} - -TEST_CASE("rx_zmqstartfnum", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxZmqStartingFrame(); - { - std::ostringstream oss; - proxy.Call("rx_zmqstartfnum", {"5"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqstartfnum 5\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqstartfnum", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_zmqstartfnum 5\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqstartfnum", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqstartfnum 0\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqStartingFrame(prev_val[i], {i}); - } -} - -TEST_CASE("rx_zmqport", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val_zmqport = det.getRxZmqPort(); - auto prev_val_numinterfaces = det.getNumberofUDPInterfaces().tsquash( - "inconsistent number of udp interfaces to test"); - - int socketsperdetector = 1; - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::EIGER) { - socketsperdetector *= 2; - } else if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - proxy.Call("numinterfaces", {"2"}, -1, PUT); - socketsperdetector *= 2; - } - uint16_t port = 3500; - proxy.Call("rx_zmqport", {std::to_string(port)}, -1, PUT); - for (int i = 0; i != det.size(); ++i) { - std::ostringstream oss; - proxy.Call("rx_zmqport", {}, i, GET, oss); - REQUIRE(oss.str() == "rx_zmqport " + - std::to_string(port + i * socketsperdetector) + - '\n'); - } - port = 30001; - proxy.Call("rx_zmqport", {std::to_string(port)}, -1, PUT); - for (int i = 0; i != det.size(); ++i) { - std::ostringstream oss; - proxy.Call("rx_zmqport", {}, i, GET, oss); - REQUIRE(oss.str() == "rx_zmqport " + - std::to_string(port + i * socketsperdetector) + - '\n'); - } - - test_valid_port("rx_zmqport", {}, -1, PUT); - test_valid_port("rx_zmqport", {}, 0, PUT); - // should fail for the second module - if (det.size() > 1) { - REQUIRE_THROWS(proxy.Call("rx_zmqport", {"65535"}, -1, PUT)); - } - - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqPort(prev_val_zmqport[i], i); - } - if (det_type == defs::JUNGFRAU || det_type == defs::MOENCH) { - det.setNumberofUDPInterfaces(prev_val_numinterfaces); - } -} - -TEST_CASE("rx_zmqip", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getRxZmqIP(); - { - std::ostringstream oss; - proxy.Call("rx_zmqip", {"127.0.0.1"}, 0, PUT, oss); - REQUIRE(oss.str() == "rx_zmqip 127.0.0.1\n"); - std::cout << "ZMQIP: " << det.getRxZmqIP() << '\n'; - } - { - std::ostringstream oss; - proxy.Call("rx_zmqip", {}, 0, GET, oss); - REQUIRE(oss.str() == "rx_zmqip 127.0.0.1\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxZmqIP(prev_val[i], {i}); - } -} - -TEST_CASE("rx_zmqhwm", "[.cmd]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = - det.getRxZmqHwm().tsquash("Inconsistent values for rx_zmqhwm to test"); - { - std::ostringstream oss; - proxy.Call("rx_zmqhwm", {"50"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqhwm 50\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqhwm", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_zmqhwm 50\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqhwm", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqhwm 0\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_zmqhwm", {"-1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_zmqhwm -1\n"); - } - det.setRxZmqHwm(prev_val); -} - -/* CTB Specific */ - -TEST_CASE("rx_dbitlist", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { - auto prev_val = det.getRxDbitList(); - { - std::ostringstream oss; - proxy.Call("rx_dbitlist", - {"0", "4", "5", "8", "9", "10", "52", "63"}, -1, PUT, - oss); - REQUIRE(oss.str() == "rx_dbitlist [0, 4, 5, 8, 9, 10, 52, 63]\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_dbitlist", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_dbitlist [0, 4, 5, 8, 9, 10, 52, 63]\n"); - } - REQUIRE_THROWS(proxy.Call("rx_dbitlist", {"67"}, -1, PUT)); - REQUIRE_THROWS(proxy.Call("rx_dbitlist", {"-1"}, -1, PUT)); - REQUIRE_NOTHROW(proxy.Call("rx_dbitlist", {"all"}, -1, PUT)); - for (int i = 0; i != det.size(); ++i) { - det.setRxDbitList(prev_val[i], {i}); - } - } else { - REQUIRE_THROWS(proxy.Call("rx_dbitlist", {}, -1, GET)); - } -} - -TEST_CASE("rx_dbitoffset", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto det_type = det.getDetectorType().squash(); - if (det_type == defs::CHIPTESTBOARD) { - auto prev_val = det.getRxDbitOffset(); - { - std::ostringstream oss; - proxy.Call("rx_dbitoffset", {"1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_dbitoffset 1\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_dbitoffset", {"0"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_dbitoffset 0\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_dbitoffset", {"15"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_dbitoffset 15\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_dbitoffset", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_dbitoffset 15\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setRxDbitOffset(prev_val[i], {i}); - } - } else { - REQUIRE_THROWS(proxy.Call("rx_dbitoffset", {}, -1, GET)); - } -} - -TEST_CASE("rx_jsonaddheader", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getAdditionalJsonHeader(); - - { - std::ostringstream oss; - proxy.Call("rx_jsonaddheader", {"key1", "value1", "key2", "value2"}, -1, - PUT, oss); - REQUIRE(oss.str() == "rx_jsonaddheader {key1: value1, key2: value2}\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_jsonaddheader", {}, -1, GET, oss); - REQUIRE(oss.str() == "rx_jsonaddheader {key1: value1, key2: value2}\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_jsonaddheader", {}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_jsonaddheader {}\n"); - } - for (int i = 0; i != det.size(); ++i) { - det.setAdditionalJsonHeader(prev_val[i], {i}); - } -} - -TEST_CASE("rx_jsonpara", "[.cmd][.rx]") { - Detector det; - CmdProxy proxy(&det); - auto prev_val = det.getAdditionalJsonHeader(); - { - std::ostringstream oss; - proxy.Call("rx_jsonpara", {"key1", "value1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_jsonpara {key1: value1}\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_jsonpara", {"key1", "value2"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_jsonpara {key1: value2}\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_jsonpara", {"key1"}, -1, GET, oss); - REQUIRE(oss.str() == "rx_jsonpara value2\n"); - } - { - std::ostringstream oss; - proxy.Call("rx_jsonpara", {"key1"}, -1, PUT, oss); - REQUIRE(oss.str() == "rx_jsonpara key1 deleted\n"); - } - REQUIRE_THROWS(proxy.Call("rx_jsonpara", {"key1"}, -1, GET)); - for (int i = 0; i != det.size(); ++i) { - det.setAdditionalJsonHeader(prev_val[i], {i}); - } -} - -/* Insignificant */ - -} // namespace sls diff --git a/slsDetectorSoftware/tests/test-Result.cpp b/slsDetectorSoftware/tests/test-Result.cpp index 6763a43d0..c921dcfb1 100644 --- a/slsDetectorSoftware/tests/test-Result.cpp +++ b/slsDetectorSoftware/tests/test-Result.cpp @@ -196,4 +196,24 @@ TEST_CASE("String conversions") { "[{one: 1}, {one: 1, three: 3, two: 2}, {one: 1}]"); } +TEST_CASE("Any element is equal") { + Result r{1, 2, 3, 4, 5}; + REQUIRE(r.any(3)); + REQUIRE_FALSE(r.any(9)); +} + +TEST_CASE("Result contains only the specified elements") { + Result r{1, 1, 1}; + REQUIRE(r.contains_only(1)); + REQUIRE(r.contains_only(1, 1)); +} + +TEST_CASE("Only with multiple values") { + Result r{1, 1, 2, 1, 2, 1, 1}; + REQUIRE_FALSE(r.contains_only(1)); + REQUIRE_FALSE(r.contains_only(2)); + REQUIRE(r.contains_only(1, 2)); + REQUIRE(r.contains_only(2, 1)); +} + } // namespace sls diff --git a/slsSupportLib/include/sls/TypeTraits.h b/slsSupportLib/include/sls/TypeTraits.h index cbbeb7bea..042d5d58e 100644 --- a/slsSupportLib/include/sls/TypeTraits.h +++ b/slsSupportLib/include/sls/TypeTraits.h @@ -103,4 +103,13 @@ template struct is_vector : public std::false_type {}; template struct is_vector> : public std::true_type {}; +template struct Conjunction : std::true_type {}; +template struct Conjunction : B1 {}; +template +struct Conjunction + : std::conditional, B1>::type {}; + +template +using AllSame = + typename std::enable_if...>::value>::type; } // namespace sls \ No newline at end of file diff --git a/slsSupportLib/include/sls/ZmqSocket.h b/slsSupportLib/include/sls/ZmqSocket.h index 679cb7f20..772d6bc65 100644 --- a/slsSupportLib/include/sls/ZmqSocket.h +++ b/slsSupportLib/include/sls/ZmqSocket.h @@ -24,8 +24,9 @@ #include //json header in zmq stream #pragma GCC diagnostic pop -#include +//#include +class zmq_msg_t; namespace sls { #define MAX_STR_LENGTH 1000 diff --git a/slsSupportLib/include/sls/sls_detector_defs.h b/slsSupportLib/include/sls/sls_detector_defs.h index a90890a90..d7eafd5fd 100644 --- a/slsSupportLib/include/sls/sls_detector_defs.h +++ b/slsSupportLib/include/sls/sls_detector_defs.h @@ -96,6 +96,7 @@ class slsDetectorDefs { MOENCH, MYTHEN3, GOTTHARD2, + XILINX_CHIPTESTBOARD }; /** return values */ @@ -683,6 +684,7 @@ struct detParameters { nChipY = 2; nDacs = 8; break; + case slsDetectorDefs::detectorType::XILINX_CHIPTESTBOARD: case slsDetectorDefs::detectorType::CHIPTESTBOARD: nChanX = 36; nChanY = 1; diff --git a/slsSupportLib/include/sls/versionAPI.h b/slsSupportLib/include/sls/versionAPI.h index d830030bf..0c01badcc 100644 --- a/slsSupportLib/include/sls/versionAPI.h +++ b/slsSupportLib/include/sls/versionAPI.h @@ -4,10 +4,11 @@ #define RELEASE "developer" #define APILIB "developer 0x230224" #define APIRECEIVER "developer 0x230224" -#define APICTB "developer 0x230922" -#define APIGOTTHARD "developer 0x230922" -#define APIGOTTHARD2 "developer 0x230922" -#define APIMYTHEN3 "developer 0x230922" -#define APIMOENCH "developer 0x230922" -#define APIEIGER "developer 0x230922" -#define APIJUNGFRAU "developer 0x230928" +#define APICTB "developer 0x240110" +#define APIGOTTHARD "developer 0x240110" +#define APIGOTTHARD2 "developer 0x240110" +#define APIJUNGFRAU "developer 0x240110" +#define APIMYTHEN3 "developer 0x240110" +#define APIMOENCH "developer 0x240110" +#define APIEIGER "developer 0x240110" +#define APIXILINXCTB "developer 0x240111" diff --git a/slsSupportLib/src/ToString.cpp b/slsSupportLib/src/ToString.cpp index 66206fe16..fa8541ce9 100644 --- a/slsSupportLib/src/ToString.cpp +++ b/slsSupportLib/src/ToString.cpp @@ -207,6 +207,8 @@ std::string ToString(const defs::detectorType s) { return std::string("Mythen3"); case defs::GOTTHARD2: return std::string("Gotthard2"); + case defs::XILINX_CHIPTESTBOARD: + return std::string("Xilinx_ChipTestBoard"); default: return std::string("Unknown"); } @@ -694,6 +696,8 @@ template <> defs::detectorType StringTo(const std::string &s) { return defs::MYTHEN3; if (s == "Gotthard2") return defs::GOTTHARD2; + if (s == "Xilinx_ChipTestBoard") + return defs::XILINX_CHIPTESTBOARD; throw RuntimeError("Unknown detector type " + s); } diff --git a/slsSupportLib/src/ZmqSocket.cpp b/slsSupportLib/src/ZmqSocket.cpp index 2ab6e583f..d727d61dc 100644 --- a/slsSupportLib/src/ZmqSocket.cpp +++ b/slsSupportLib/src/ZmqSocket.cpp @@ -10,7 +10,7 @@ #include #include #include - +#include namespace sls { using namespace rapidjson; diff --git a/slsSupportLib/tests/test-ToString.cpp b/slsSupportLib/tests/test-ToString.cpp index 56b591eba..5018a77ea 100644 --- a/slsSupportLib/tests/test-ToString.cpp +++ b/slsSupportLib/tests/test-ToString.cpp @@ -136,6 +136,7 @@ TEST_CASE("string to detectorType") { REQUIRE(StringTo
("Moench") == dt::MOENCH); REQUIRE(StringTo
("Mythen3") == dt::MYTHEN3); REQUIRE(StringTo
("Gotthard2") == dt::GOTTHARD2); + REQUIRE(StringTo
("Xilinx_ChipTestBoard") == dt::XILINX_CHIPTESTBOARD); } TEST_CASE("vec") { diff --git a/tests/scripts/test_simulators.py b/tests/scripts/test_simulators.py index 24ee6f4dd..1d26c96e7 100644 --- a/tests/scripts/test_simulators.py +++ b/tests/scripts/test_simulators.py @@ -4,7 +4,7 @@ This file is used to start up simulators, receivers and run all the tests on them and finally kill the simulators and receivers. ''' import argparse -import os, sys, subprocess, time, colorama, signal, psutil +import os, sys, subprocess, time, colorama, signal from colorama import Fore from slsdet import Detector, detectorType, detectorSettings @@ -21,29 +21,37 @@ class RuntimeException (Exception): def Log(color, message): print('\n' + color + message, flush=True) + def checkIfProcessRunning(processName): - ''' - Check if there is any running process that contains the given name processName. - https://gist.github.com/Sanix-Darker/8cbed2ff6f8eb108ce2c8c51acd2aa5a - ''' - # Iterate over the all the running process - for proc in psutil.process_iter(): - try: - # Check if process name contains the given name string. - if processName.lower() in proc.name().lower(): - return True - except (psutil.NoSuchProcess, psutil.AccessDenied, psutil.ZombieProcess): - pass - return False; + cmd = "ps -ef | grep " + processName + print(cmd) + res=subprocess.getoutput(cmd) + print(res) + # eg. of output + #l_user 250506 243295 0 14:38 pts/5 00:00:00 /bin/sh -c ps -ef | grep slsReceiver + #l_user 250508 250506 0 14:38 pts/5 00:00:00 grep slsReceiver + + print('how many') + cmd = "ps -ef | grep " + processName + " | wc -l" + print(cmd) + res=subprocess.getoutput(cmd) + print(res) + + if res == '2': + return False + return True + def killProcess(name): if checkIfProcessRunning(name): Log(Fore.GREEN, 'killing ' + name) p = subprocess.run(['killall', name]) if p.returncode != 0: - raise RuntimeException('error in killall ' + name) + raise RuntimeException('killall failed for ' + name) + else: + print('process not running : ' + name) -def cleanup(name, d): +def cleanup(name): ''' kill both servers, receivers and clean shared memory ''' @@ -51,18 +59,27 @@ def cleanup(name, d): killProcess(name + 'DetectorServer_virtual') killProcess('slsReceiver') killProcess('slsMultiReceiver') - d.freeSharedMemory() + cleanSharedmemory() + +def cleanSharedmemory(): + Log(Fore.GREEN, 'Cleaning up shared memory...') + try: + p = subprocess.run(['sls_detector_get', 'free'], stdout=fp, stderr=fp) + except: + Log(Fore.RED, 'Could not free shared memory') + raise def startProcessInBackground(name): try: # in background and dont print output - p = subprocess.Popen(name.split(), stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) + p = subprocess.Popen(name.split(), stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, restore_signals=False) Log(Fore.GREEN, 'Starting up ' + name + ' ...') except: Log(Fore.RED, 'Could not start ' + name) raise def startServer(name): + startProcessInBackground(name + 'DetectorServer_virtual') # second half if name == 'eiger': @@ -79,9 +96,12 @@ def startReceiver(name): time.sleep(2) def loadConfig(name, rx_hostname, settingsdir): + Log(Fore.GREEN, 'Loading config') try: d = Detector() - if name == 'eiger': + if name == 'xilinx_ctb': + d.hostname = 'localhost' + elif name == 'eiger': d.hostname = 'localhost:' + str(DEFAULT_TCP_CNTRL_PORTNO) + '+localhost:' + str(HALFMOD2_TCP_CNTRL_PORTNO) #d.udp_dstport = {2: 50003} # will set up for every module @@ -106,25 +126,36 @@ def loadConfig(name, rx_hostname, settingsdir): Log(Fore.RED, 'Could not load config for ' + name) raise -def startCmdTests(name, fp): - try: - p = subprocess.run(['tests', '--abort', '[.cmd]'], stdout=fp, stderr=fp) - if p.returncode != 0: - raise Exception - except: - Log(Fore.RED, 'Cmd tests failed for ' + name) - raise +def startCmdTests(name, fp, fname): + Log(Fore.GREEN, 'Cmd Tests for ' + name) + cmd = 'tests --abort [.cmdcall] -s -o ' + fname + p = subprocess.run(cmd.split(), stdout=fp, stderr=fp, check=True, text=True) + p.check_returncode() + + with open (fname, 'r') as f: + for line in f: + if "FAILED" in line: + msg = 'Cmd tests failed for ' + name + '!!!' + Log(Fore.RED, msg) + raise Exception(msg) + + Log(Fore.GREEN, 'Cmd Tests successful for ' + name) + +def startGeneralTests(fp, fname): + Log(Fore.GREEN, 'General Tests') + cmd = 'tests --abort -s -o ' + fname + p = subprocess.run(cmd.split(), stdout=fp, stderr=fp, check=True, text=True) + p.check_returncode() + + with open (fname, 'r') as f: + for line in f: + if "FAILED" in line: + msg = 'General tests failed !!!' + Log(Fore.RED, msg) + raise Exception(msg) + + Log(Fore.GREEN, 'General Tests successful') -def startNormalTests(d, fp): - try: - Log(Fore.BLUE, '\nNormal tests') - p = subprocess.run(['tests', '--abort' ], stdout=fp, stderr=fp) - if p.returncode != 0: - raise Exception - d.freeSharedMemory() - except: - Log(Fore.RED, 'Normal tests failed') - raise # parse cmd line for rx_hostname and settingspath using the argparse library @@ -145,50 +176,56 @@ if args.servers is None: 'gotthard', 'ctb', 'moench', + 'xilinx_ctb' ] else: servers = args.servers -Log(Fore.WHITE, 'rx_hostname: ' + args.rx_hostname + '\settingspath: \'' + args.settingspath + '\'') - -# handle zombies (else killing slsReceivers will fail) -# dont care about child process success -signal.signal(signal.SIGCHLD, signal.SIG_IGN) +Log(Fore.WHITE, 'Arguments:\nrx_hostname: ' + args.rx_hostname + '\nsettingspath: \'' + args.settingspath + '\'') # redirect to file +prefix_fname = '/tmp/slsDetectorPackage_virtual_test' original_stdout = sys.stdout original_stderr = sys.stderr -fname = '/tmp/slsDetectorPackage_virtual_test.txt' -Log(Fore.BLUE, 'Tests -> ' + fname) +fname = prefix_fname + '_log.txt' +Log(Fore.BLUE, '\nLog File: ' + fname) + with open(fname, 'w') as fp: + + # general tests + file_results = prefix_fname + '_results_general.txt' + Log(Fore.BLUE, 'General tests (results: ' + file_results + ')') sys.stdout = fp sys.stderr = fp - - d = Detector() - # TODO: redirect Detector object print out also to file - startNormalTests(d, fp) + Log(Fore.BLUE, 'General tests (results: ' + file_results + ')') + startGeneralTests(fp, file_results) for server in servers: try: # print to terminal for progress sys.stdout = original_stdout sys.stderr = original_stderr - Log(Fore.BLUE, server + ' tests') + file_results = prefix_fname + '_results_cmd_' + server + '.txt' + Log(Fore.BLUE, 'Cmd tests for ' + server + ' (results: ' + file_results + ')') sys.stdout = fp sys.stderr = fp + Log(Fore.BLUE, 'Cmd tests for ' + server + ' (results: ' + file_results + ')') # cmd tests for det - Log(Fore.BLUE, 'Cmd Tests for ' + server) - cleanup(server, d) + cleanup(server) startServer(server) startReceiver(server) loadConfig(server, args.rx_hostname, args.settingspath) - startCmdTests(server, fp) - cleanup(server, d) + startCmdTests(server, fp, file_results) + cleanup(server) except: - cleanup(server, d) + Log(log.RED, 'Exception caught. Cleaning up.') + cleanup(server) + sys.stdout = original_stdout + sys.stderr = original_stderr + Log(Fore.RED, 'Cmd tests failed for ' + server + '!!!') raise