Skip to content
Snippets Groups Projects
README.adoc 4.1 KiB
Newer Older
= FofbTool Module

This python module provides functions to deal with the Fofb MTCA platform.
It connects to the OPCUAProxy tango devices.

The module is packaged in sections
* FofbTool.Configuration: For application configuration
* FofbTool.Operation: Function to perform operation (start, stop...)
* FofbTool.DeviceAttributeConfiguration: contains functions to apply tango attribute configuration
BRONES Romain's avatar
BRONES Romain committed
* FofbTool.Utils: Usefull function that relies on ConfigParser files and call the operation/configuration. Used by the command line tool.

There is also a Command Line Interface bin/FofbTool written in python.

BRONES Romain's avatar
BRONES Romain committed

BRONES Romain's avatar
BRONES Romain committed
= Command Line Interface: Basic usages
BRONES Romain's avatar
BRONES Romain committed

== Classic: stop, config, start
BRONES Romain's avatar
BRONES Romain committed

This stops the communication on all the nodes.
Also stops Bpm to CellNode communication blocks.

Then apply the default configuration on FPGA blocks:

* ComCellNode (Expected packets, correct MAC size...)
* ComBPM (BPM ID filter Filter for each CellNode...)
* ComCorr (Default PSCID on output...)

IMPORTANT: This do not configure Orbit Reference or Inv Response Matrix.
This do not start the FOFB, only the communication.

WARNING: PSC will receive frames upon start. Better stop the FOFB beforehand. The CLI won't let you do that.

BRONES Romain's avatar
BRONES Romain committed
[source,console]
----
BRONES Romain's avatar
BRONES Romain committed
$ FofbTool --stop --conf --start
----

== Synchronize BPMs

[source,console]
----
$ FofbTool --sync
BRONES Romain's avatar
BRONES Romain committed
----

BRONES Romain's avatar
BRONES Romain committed
== Align Electron and LBP FA stream

[source,console]
----
$ FofbTool --align-fa cellnode-c09
----
BRONES Romain's avatar
BRONES Romain committed

== Configure OPCUAProxy DS

BRONES Romain's avatar
BRONES Romain committed

Upon restart of OPCUAProxy Tango DS, to reapply attribute configuration (units, alarm level, descriptions...)

[source,console]
----
BRONES Romain's avatar
BRONES Romain committed
$ FofbTool --DS-conf
BRONES Romain's avatar
BRONES Romain committed

BRONES Romain's avatar
BRONES Romain committed
----
BRONES Romain's avatar
BRONES Romain committed

BRONES Romain's avatar
BRONES Romain committed
== More help
BRONES Romain's avatar
BRONES Romain committed

BRONES Romain's avatar
BRONES Romain committed
[source,console]
----
BRONES Romain's avatar
BRONES Romain committed
usage: FofbTool [-h] [--log LOG] [--force] [--fileconfig FILECONFIG]
                [--DS-init-opcua] [--DS-init-watcher] [--DS-conf] [--stop]
                [--stop-combpm] [--stop-ccn] [--stop-comlbp]
                [--dump-configuration DUMP_CONFIGURATION]
                [--configure [{combpm,ccn,comcorr,corr,all}]]
                [--align-fa cellnode-cXX] [--nolbp] [--start] [--start-combpm]
                [--start-comlbp] [--start-ccn] [--sync]

version x.x
BRONES Romain's avatar
BRONES Romain committed

optional arguments:
  -h, --help            show this help message and exit
  --log LOG             Log level (error, warning, info, debug)
BRONES Romain's avatar
BRONES Romain committed
  --force               Force operation even if FOFB is running.
  --fileconfig FILECONFIG
BRONES Romain's avatar
BRONES Romain committed
                        Path to config file to apply.
  --DS-init-opcua       Run init on opcua devices.
  --DS-init-watcher     Run init on the Fofb-Watcher device, and then the
                        Fofb-Command.
  --DS-conf             Applying attribute configuration on Tango Device
                        Servers. This is required after restart of devices.
  --stop                Stop command for the CCN and ComBPM applications
                        blocks.
  --stop-combpm         Stop command for the ComBPM applications blocks.
  --stop-ccn            Stop command for the ComBPM applications blocks.
BRONES Romain's avatar
BRONES Romain committed
  --stop-comlbp         Stop command for the ComLBP applications blocks.
  --dump-configuration DUMP_CONFIGURATION
                        Dump the current configuration in a file at the giver
                        path.
  --configure [{combpm,ccn,comcorr,corr,all}]
BRONES Romain's avatar
BRONES Romain committed
                        Configuration commands for the Fofb applications
BRONES Romain's avatar
BRONES Romain committed
                        blocs. 'all' is for all com and corrector. Default is
                        'all'
  --align-fa cellnode-cXX
                        Start alignement process for electron and brillance
                        plus FA sequence. The designation of the cellnode must
                        be set as argument.
  --nolbp               Do not start comlbp module when doing start.
BRONES Romain's avatar
BRONES Romain committed
  --start               Start command for the CCN and ComBPM applications
                        blocks.
  --start-combpm        Start command for the ComBPM applications blocks.
BRONES Romain's avatar
BRONES Romain committed
  --start-comlbp        Start command for the ComLBP applications blocks.
BRONES Romain's avatar
BRONES Romain committed
  --start-ccn           Start command for the ComBPM applications blocks.
BRONES Romain's avatar
BRONES Romain committed
  --sync                Start synchronization sequence for Libera Electron and
                        Libera Brillance Plus.

BRONES Romain's avatar
BRONES Romain committed
----