DABC (Data Acquisition Backbone Core)  2.9.9

Example of a user defined readout plugin


This Plugin provides an example implementation of a user Input transport. The data is formatted as MBS events and can be provided at a stream server for monitoring software like Go4, or stored into an lmd file. By default, the example fills one subevent with random gauss data that can be used for the standard Go4 example unpackers.


The plugin will be automatically compiled inside DABC and the library libDabcUser.so is placed under $DABCSYS/lib. If copied to another location, after ". dabclogin" the libraries can be build locally under subdirectory x86_64/lib.


To run the example, use dabc with the corresponding configuration file

dabc_exe UserReadout.xml

All parameters of the user input can be passed as url options in the port definition of the first (and only) data input:

<InputPort name="Input0" url="user://host:12345" urlopt1="size=2000&cratid=1&procid=9&ctrlid=3&debugR}c
<OutputPort name="Output0" url="mbs://Stream:6900"/>

To activate writing an additional lmd file, the number of ouputs must be set to 2:

<NumOutputs value="2"/>

File name can be defined with

<OutputPort name="Output1" url="lmd://myfile.lmd?maxsize=1500&log=2"/>


Once running, the dabc application can be monitored and controlled by default with a standard web browser using the address:


This offers a simple ratemeter available at


Additionally, the State of the Application may be changed from remote using the command handles at subfoler App:

  • DoConfigure : Initialize DAQ
  • DoStart : Start Acquisition
  • DoStop : Stop Acquisition
  • DoHalt : shutdown DAQ (does not terminate DABC process!)

How to adjust the example

The class user::Input offers several user functions that can be modified to adjust the code to a custom data acquisition system:

Additionally, constructor and destructor of this class and the member variables may be modified as you like.

One may just change these functions directly in the private DABCSYS installation and recompile DABC.

However, to run several readout variants with the same DABC installation, it is recommended to copy the directory plugins/user to another location and compile it locally. PLEASE NOTE that this case the full (relative) path to the local library libDabcUser.so must be specified in the <Run> section of the configuration file UserReadout.xml, e.g.

 <lib value="x86_64/lib/libDabcUser.so"/>

Otherwise, the dabc will load the default library from $DABCSYS/lib instead the modified one!

Additionally, the class user::Input may be further modified with additional data members and configuration file tags. Extracting valules from the configuration url is donein constructor of user::Input class.