<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>October</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>MANAGER FOR DC-280 CYCLOTRON CONTROL SYSTEM</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>V. Zabanova</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>V. Aleinikov</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>S. Pashchenko</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>K. Sychev</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>FLNR JINR</string-name>
          <email>badver@jinr.ru</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Dubna</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Russia</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Veronika Zabanova</institution>
          ,
          <addr-line>Vitaly Aleinikov, Sergey Pashchenko, Kirill Sychev</addr-line>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2019</year>
      </pub-date>
      <volume>4</volume>
      <issue>2019</issue>
      <fpage>367</fpage>
      <lpage>370</lpage>
      <abstract>
        <p>On March 25, 2019 the experimental hall of the Superheavy Elements Factory (SHE) was opened at the FLNR JINR and its basic facility-the DC-280 cyclotron-was launched. The control system software of DC-280 is based on the NI LabVIEW platform with the Datalogging and Supervisory Control (DSC) module. It consists of many software programs that perform the corresponding tasks: device drivers, alarm monitoring, beam diagnostics, user interfacing, etc. The Program Manager was developed to supervise running processes and to inform operator in case of failures. The control of the new version and the update of the software modules are implemented. This paper describes the algorithm and the user interface of the Program Manager.</p>
      </abstract>
      <kwd-group>
        <kwd>DC-280</kwd>
        <kwd>control system</kwd>
        <kwd>Program Manager</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1.Introduction</title>
      <p>
        To simplify design and ease of maintenance, the control system was divided into three
subsystems: Injection (ECR source, axial injector), Accelerator (cyclotron, extraction, transport), and
Low-Level RF. Each of them describes certain tasks. They are simply as follows: to produce, inject,
accelerate, extract, and to transport the beam to the target. The total amount of the process variables is
about 9000. Every subsystem requires specific drivers. Twenty drivers for field devices of various
types were implemented [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ].
      </p>
      <p>Each subsystem project consists of many software modules that need automated control. For
this purpose, a Program Manager was developed. It performs the following tasks:
 Automatically runs software modules package at startup;
 Controls each module individually (run, stop, restart);
 Updates new versions of programs from a centralized repository;
 Monitors the performance of the modules.</p>
      <p>The program was developed in the LabView environment just as was the entire control system
of the DC-280 cyclotron.</p>
    </sec>
    <sec id="sec-2">
      <title>2.Algorithm</title>
      <p>
        To implement the tasks, a version of the Producer/Consumer design pattern was used, where a
user interface (producer) produces messages and tasks (consumers) consume them [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. In this
program, messages are also produced from a consumer loop (Fig. 1).
1. The user interacts with the front panel, adding a user command to the queue. The watchdog
command is added in queue periodically.
2. The consumer reads the command, removes it from the queue, and executes it.
3. The consumer produces another command by the results of execution and adds it to the queue.
      </p>
    </sec>
    <sec id="sec-3">
      <title>3.User Interface</title>
      <p>The Program Manager starts automatically on each computer of the DC-280 network. Then it
automatically starts program modules listed in the configuration file.</p>
      <p>In the Program Manager, each program module is presented as an object with a set of
parameters: a name, a path to the executable file, control buttons, a startup checkbox, control buttons
and an operation status indicator, and version information (See Figure 2). The list of program modules
can be edited in the operating mode and saved as a new list in the file if necessary. Different
configuration files can be used for different subsystems. The user can also change the location of the
new version repository, adjust the volume of the voice alarm, and choose the voice type.</p>
      <p>The startup checkbox indicates that all program modules marked with a checkbox will
automatically start when the manager starts.</p>
      <p>To ensure the reliability of the system, it is very important to know that all the modules are
running and not hanging. Two techniques were used for this purpose: the one that checks whether the
module name is present in the list of the Windows Task Manager and the Watchdog Logic.</p>
      <p>Based on these two techniques for checking the status of the modules, the manager generates
an alarm if necessary.</p>
      <p>
        Every driver executes at least one process that interacts with the dedicated device. Every
process has its own time counter that is supervised by a driver. If any of these processes stop, the
driver will increment the value of the “watchdog variable”. The Program Manager reads this variable
and if it is greater than zero, an alarm occurs. To exchange data on the network, HMI uses shared
variables. All user interfaces are clients or subscribers to the Shared Variable Engine [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] (Fig. 3).
      </p>
      <p>The Program Manager was used on all project computers for a year. During this time, it coped
well with all the assigned tasks. It automatically launched all the necessary software modules after the
server restarted. Voice notification allowed the operator to respond quickly and call service personnel
to resolve the problem, which increased the reliability of the project.</p>
      <p>Auto run of modules allows to simplify the startup of the software.</p>
      <p>The available update service significantly saves system maintenance time.</p>
      <p>The Program Manager is a standalone application and can be used on other systems as well.</p>
      <p>at:</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>V.</given-names>
            <surname>Aleinikov</surname>
          </string-name>
          ,
          <string-name>
            <surname>I. Borina</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Krylov</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Pachtchenko</surname>
          </string-name>
          , K. Sychev, “
          <article-title>Using LABVIEW to build distributed control system of a particle accelerator</article-title>
          .
          <source>” ICALEPCS</source>
          <year>2017</year>
          . Barcelona, Spain.
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>National</given-names>
            <surname>Instruments</surname>
          </string-name>
          .
          <article-title>Queued Message Handler Template documentation</article-title>
          . Available at: http://www.ni.com/tutorial/53391/en/ (
          <year>accessed24</year>
          .
          <fpage>09</fpage>
          .
          <year>2019</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>National</given-names>
            <surname>Instruments</surname>
          </string-name>
          .
          <article-title>Using the LabVIEW Shared Variable</article-title>
          . http://www.ni.com/product-documentation/4679/en/ (accessed 24.09.
          <year>2019</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>