3.4. So how does all this work anyway?

By now you are probably pretty confused. Here's a thumbnail of how this all hangs together - that is what does what and who orchestrates each move.

When the data source starts, getEccServer, and nscldatarouter are forcefully killed in the spdaq that interfaces to the GET microTCA crate. Similarly the ring merge program is also killed in localhost.

Next the data source creates the requested ring buffers and starts up an instance of getEccServer and nscldatarouter in the spdaq interfaced to the GET crates. An instance of ring merge is also started in the same host as the ReadoutGUI. When asked to check if the data source is alive,the data source will check for the existence of all of these processes and will declare itself to be dead if any are missing. This normally causes ReadoutGUI ask all data sources to shutdown, which the GET source does by killing off the remaining programs it started.

The Start of the data source is not sufficient to prepare to take data. In addition to that:

  1. A CoBo/ASAD configuration must be selected and loaded into the hardware.

  2. A data connection has to be made between the CoBo and the nscldata router so that when the CoBo starts taking data nscldata router receives it.

Both of these tasks are handled by the GET software GetController (located in /usr/opt/GET/bin). This software is handed the data router configuration, and each configuration (or test as they are called) contains the network configuration of the CoBo it configures.

When GetController configures and loads the CoBo it makes the hardware ready for data taking with the desired configuration. It also forms the required connection between the CoBo and the nscldatarouter so that the latter receives any data the former emits.

The Begin button causes to data source to, in order:

  1. Send a begin run item to one of the ringbuffers monitored by ring merge. This ring item will be placed in ring merge's output ring.

  2. After a delay to allow the begin item to make it through the system, The daqstart program is used to ask the CoBo to start taking data. Data received by the data router (frames) are wrapped inside a physics event ring item and inserted into the other ring monitored by ringmerge. ringmerge then relays those items to its output ring in turn as well.

The end button essentialy does the reverse of begin: daqstop is used to stop data taking and, after a delay, an end run item is emitted into a ring buffer monitored by ringmerge.