-- VincenzoMonaco - 07 Aug 2011

DAQ and trigger layout

List of readout controllers and location of the MBS software (LynxOS)

  • master trigger + detectors of the interaction region
    • R2F-37 (mbsrun/jul_2011/vme_trig)
  • TOF
    • R2F-5 (mbsrun/jul_2011/vme_aladin_tof/fbus/mbs)
  • Music (left)
    • R3-15 (mbsrun/jul_2011/vme_music_0/fadc/mbs)
  • Music (right)
    • R3-17 (mbsrun/jul_2011/vme_music_0/fadc/mbs)
  • Land
    • R3-52 (mbsrun/jul_2011/vme_land_tecquila/simple)

Event builder

  • x86g-10 (mbsrun/jul_2011)

RFIO server (server on a Linux PC for data saving on disk)

  • any linux PC to save data on scratch area /s/s371
  • any linux PC connectd to lustre to save date on lustre (list)
  • remote gstore rfio server

Event server (server on a Linux PC for data online monitoring)

  • any linux PC

Trigger controls and monitors

The Trigger logic is built inside a Vulom VME board controlled by R2F-37. The master trigger is the OR of different logic combinations (trigger outputs) of trigger primitivies.(trigger inputs). It is possible to enable/disable single trigger outputs independently and to downscale them.

List of trigger inputs

Slot trigger description
1 SC Start Counter (Margherita)
2 VETO Veto counter
3 TOF-AND AND of front and read TOF
4 KENTROS trigger from the Kentros calorimeter
5 LAND-Ph physics trigger from LAND
6 LAND-Cos cosmics trigger from LAND
7 TOF-OR OF or front and rear TOF

List of trigger outputs

Slot triggerSorted ascending on/off-spill (MBS trg type)
9 KENTRO Cosm off-spill (2)
6 LAND-Cosm on-spill (1)
8 LAND-Cosm off-spill (2)
1 SC on-spill (1)
2 SC & .not.VETO on-spill (1)
4 SC & KENTROS on-spill (1)
5 SC & LAND-Ph on-spill (1)
3 SC & TOF-AND on-spill (1)
7 VETO on-spill (1)

How to monitor the trigger rates

Connect to R2F-37

R2f-37> cd ~/mbsrun/jul_2011/vme_trig/TRLO

R2F-37> trloctrl --scalers

The monitor shows the following informations

  • counts and rate in Hz of the trigger inputs
  • counts and rate in Hz of the trigger outputs
  • counts and rate in Hz of the trigger outputs after the MBS dead-time
  • counts and rate of the enabled trigger outputs after the reduction

The last counters are the accepted triggers with events saved on file.

Other two scalers are used as auxiliary monitors:

  • Input ch.15: number/rate in Hz of VETO signals provided by the fast-clear logic of the interaction region
  • Input ch.16: number/rate in Hz of original triggers from Margherita (no dead-time)

The dead-time locker mechanism is partially included in the fast-clear logic. The ratio between the number of accepted SC trigger and the number of original SC triggers is a measurement of the efficieny of the DAQ system.

How to reset the scalers

~/mbsrun/jul_2011/vme_trig/TRLO directory on R2F-37

R2F-37> trloctrl --reset-scalers

How to enable a set of trigger outputs

~/mbsrun/jul_2011/vme_trig/TRLO directory on R2F-37

R2F-37> trloctrl --tpat-enable=A,B,C,...    

(A,B,C,.. are the slot numbers of the output triggers to be enabled; i.e tpat-enable=1,3 to enable slots 1,3)

How to set a prescale factor on a output trigger

~/mbsrun/jul_2011/vme_trig/TRLO directory on R2F-37

R2F-37> trloctrl --reduction=X=Y

The trigger rate of output slot X is reduced by a factor 2^Y

DAQ controls and monitors

The DAQ is controlled and monitored by the LynxOS PC where the event builder runs (x86g-10)

1) DAQ startup (if it is not running)

The DAQ should be restarted every time the MBS software has to be recompiled, or in case of problems. Avoid to restart MBS if not needed.

x86g-10> cd ~/mbsrun/jul_2011

x86g-10> resa      (resets all local and remote processes)

Wait all connections to the RIO are closed (use netstat command to check if there are open ports with the RIOs). When all the connections are closed:

x86g-10> prm       (starts the MBS message prompter)

prm opens the MBS remote message servers. Check for errors !

mbs> set disp x86g-10     (if needed, this command sets the scope of the MBS prompter to the event builder)

mbs x86g-10> @startup

Check for errors !

Once MBS has been started, the acquisition can be started/stopped giving commands from the MBS message prompter (within the R2F-37 scope). Avoid to shutdown MBS if not needed.

2) open a monitor program on a dedicated terminal to check data rates

connect to x86g-10

x86g-10> rate

3) Start acquisition (if it is not running)

mbs x86g-10> set disp r2f-37     (set the prm scope to r2f-37, if needed)

mbs r2f-37> sta acq              (starts the acquisition)

Check for errors !

mbs r2f-37> set disp x86g-10     (set the prm scope to the ev.builder, if needed)

4) Connect to the gstore RFIO file server (the acquisition must run)

mbs> set disp x86g-10    (if needed)

mbs x86g-10> connect rfio lxgstore -archive

5) Connect a remote event server for online monitoring

Open a remote event server on any linux PC lx++++

lx++++> mrevserver x86g-10

If the remote server is still running, it is not necessary to restart it.

6) Open a file (the acquisition must run and the connection to the RFIO must be established)

prm> set disp x86g-10    (if needed)

prm x86g-10) open file /first_r/DATA/PRODUCTION/production_ size=500 -auto -rfio
. An incremental integer number is appended to the file.

The file is automatically closed when its size reaches a maximum size and a new file is open. The max. size is XX MB if the size is specified, otherwise the default max size is 1 GB. You can use the commands 'sh acq' or 'sh fi' to check the name of the current output file and the amount of data written on file.

Check messages on MBS mbs prompter to see when a file is open.

7) check rate

Checks if data are transfered to file. The 'rate' monitor program running on x86g-10 shows the data flow to the output file.

8) close a file

Close a file only when the acquisition is finished, or when running conditions have to be changed, or in case of problems. During normal data acquisition, it is not necessary to close a file (they are closed and open again automatically).

prm> set disp x86g-10    (if needed)

prm x86g-10> close file

After a file saved on tape has been closed, copy it to lustre and the scratch area.

From a PC connected to the lustre fils system (i.e. lennylust64, lennylust32, lxg811):

cd /lustre/bio/first/DATA

gstore ret '/lustre/bio/first/DATA/PRODUCTION/production_XXXX.lmd' first_r DATA/PRODUCTION   (/first_r/dir/.. 

cp PRODUCTION/file_name.lmd /SAT/s/s371/PRODUCTION/.

8) Shutdown MBS (files must be closed)

prm> set disp x86g-10            (if needed)

prm x86g-10> disconnect rfio     (if an RFIo server is connected)

prm x86g-10> set disp r2f-37     (change the prm scope to r2f-37)

prm r2f-37> @shutdown

To exit from prm:

prm> exit   

Useful MBS commands

The following commands can be executed during the data acquisition from x86g-10 using the MBS event prompter

*
mbs x86g-10> sh rate
shows the total size and the number of events collected from the start of the acquisition

*
mbs x86g-10> ty ev
shows informations on headers from each RIO for the last event

*
mbs x86g-10> ty ev -v
dump of the last event in hex format

*
mbs x86g-10>sh acq
statistics on the current acquisition

*

mbs x86g-10>sh file
informations on the opened file

Troubleshooting

To reload the Mimosa firmware through JTAG

connect to R2F-37

R2F-37> cd  /bio/usr/s371/mbsrun/jul_2011/vme_trig/M26-JTAG-lynxos

R2F-37> readconfigM26

In case of Fastbus errors from R2f-5

The following error messages from R2f-5 report errors in the fastbus:

R2F-5  :read_meb   :E-f_check_fb_read_ready-ERR: seq error:      0x0000c080.

R2F-5  :read_meb   :E-f_check_fb_read_ready-ERR: fb_stat1:       0x00000000.

R2F-5  :read_meb   :E-f_check_fb_read_ready-ERR: fb_stat2:       0x0000a200.

R2F-5  :read_meb   :E-f_check_fb_read_ready-ERR: last seq. code: 0xffff08a4.

R2f-5  :read_meb   :E-f_check_fb_read_ready-ERR: next seq addr:  0xffff0000.

R2F-5  :read_meb   :E-f_check_fb_read_ready-ERR: last FB PA:      8.

R2F-5  :read_meb   :E-f_user_readout_fb-ERR: try to recover from fastbus and/or ngf error.

If they appear too often:

shutdown MBS running on the event builder

connect to R2F-5

R2F-5> cd mbsrun/jul_2011/vme_aladin_tof/fbus/mbs

R2F-5> vme_init

restart the event builder
Topic revision: r8 - 2011-08-11, VincenzoPatera
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding GSI Wiki? Send feedback | Legal notice | Privacy Policy (german)