c33bbfaa3507c4665f64520b4fd3f33a82ddfe64
Main experimental magnet PS
This repository contains the driver code and Midas frontend for the main experimental magnet PS. There are two different versions of this driver - one using LAN-GPIB to run the magnets and a second one which uses the EPICS interface provided by GFA. The respective CMake targets are:
expmag(LAN-GPIB)expmag_epics(EPICS interface)
Requirements
Requires a Midas installation with the environment variable MIDASSYS pointing
to the built Midas artifacts and headers.
Build
Clone this repository, enter the cloned directory, and then build via CMake.
cmake -S "$(pwd)" -B <directory-to-build-in> -DBUILD_FRONTENDS=ON
cmake --build <directory-to-build-in> --clean-first -- -j8
Run
<directory-to-build-in>/expmag_scfe -e <instrument-name>
Including in Custom Frontend
To include this driver in a custom frontend, you should ensure the environment
variable MIDASSYS points to your system install and include a snippet in your
CMakeLists.txt similar to the following:
# If the path to the expmag repository is outside of the frontend
# repository, you also need to provide a location for the expmag
# artifacts as a second argument to `add_subdirectory`
# e.g. `./device/expmag`
add_subdirectory(
<path-to-expmag-repository>
)
default_expmag_frontend(
Magnets_instr_scfe # Target Name
Magnets_instr # Frontend Name
16 # Event ID
4 # Number of channels
)
Languages
C++
95.1%
C
4.3%
CMake
0.6%