Tigress Trigger Parameters
From tigwiki
Contents |
[edit] Intro
The TIG-10 system has lots of trigger flexibility, but as a consequence, also lots of parameters. This document describes the set of Basic Trigger Modes that are typically used in experiments, then describes how the Trigger Module Parameters are programmed. The selection of the basic trigger mode is done through a single ODB entry that is accessed by the front-end readout computer; the various module parameters are programmed at the beginning of a run based on this setting.
[edit] Basic Trigger Modes
As of the date of this document, the trigger modes are explained by this snippet of code from tigcol.c:
if ( final_trigger_mode == 0 ){ master_pattern = 0x000; /* all boxes, all triggers */
} else if( final_trigger_mode == 1 ){ master_pattern = 0xffe; /* box1 all singles */
} else if( final_trigger_mode == 2 ){ master_pattern = 0xffd; /* box2 singles Ge */
} else if( final_trigger_mode == 3 ){ master_pattern = 0xffb; /* box3 Si anySingles */
} else if( final_trigger_mode == 4 ){ master_pattern = 0xff7; /* box4 Si-Ge Coinc (was P/S Ds Si Singl) */
} else if( final_trigger_mode == 5 ){ master_pattern = 0xfef; /* box5 *** Si Singles */
} else if( final_trigger_mode == 6 ){ master_pattern = 0xfdf; /* box6 Si-Si Coinc */
} else if( final_trigger_mode == 7 ){ master_pattern = 0xfbf; /* box7 BGO Singles */
} else if( final_trigger_mode == 8 ){ master_pattern = 0xfd7; /* NOGOOD box4|6*** Si-Si|PS-Ds-Si */
} else if( final_trigger_mode == 9 ){ master_pattern = 0xfeb; /* box5|3*** Si Singles + pulser */
} else if( final_trigger_mode == 10 ){ master_pattern = 0xff9; /* box2|3 singles Ge + pulser */
} else if( final_trigger_mode == 11 ){ master_pattern = 0xfed; /* box2|5 singles {Ge|Si} */
} else {
fprintf(stdout,"Unknown Trigger Mode\n");
}
[edit] Trigger module parameters
There is a trigger module in each Collector (1 Master TIG-C, 6 Slave TIG-C, 60 TIG10 Collectors). Each trigger module contains 8 pretrigger units and 4 final trigger units. Each trigger unit takes 12 parameters, making a total of around 10,000 parameters to set the desired trigger condition. Most are unused - not all pretriggers/final triggers are used in each collector. The trigger parameters are all currently hardcoded in the frontend (file tigcol.c). There were some attempts to put these in the odb, but there are too many numbers with only about 1% actually used at any one time. (Some way where only the non-default parameters can be specified needs to be found for this to be convenient).
The TIG-C trigger programming is done by writing to addresses on the appropriate card. The parameter mechanism is not used for these.
The TIG10-Collectors are not attached to the VMEbus, and so the parameter mechanism needs to be used to set their trigger parameters - this was added for the Dec07 experiment (before this there was no trigger or in fact any parameter-related firmware contained in the tig10-collectors). The channel 0xe is used to address the collector (0-9 are channels 1-10, 0xf is broadcast to all channels 1-10)
TIGC-address TIG10-C-par# Name 0x0100 0 Set-Trigger-Unit# 0x0108 1 duration [10ns] 0x0110 2 delay [10ns] 0x0118 3 ? 0x0120 4 disable_mask 0x0128 5 required_mask 0x0130 6 multiplicity 0x0138 7 prescale_factor 0x0140 8 trigger-select lower 12bits 0x0148 9 trigger-select upper 12bits 0x0150 10 veto 0x0158 11 always_active_mask
- Set-Trigger-Unit#: All subsequent access to TIGC addresses 0x108 to 0x158 act on the selected unit.
- Unit 0: Special Global Unit
- Units 1-7: Pretrigger Units. These get their inputs from the 12 front-panel ports.
- Units 16-19: Final Trigger Units 0 to 3 for trigger types 1 to 4. These get their inputs from the seven pre-trigger units.
- Duration, Delay: Units of 10 ns
- Disable_Mask: bit pattern. Set to 1 to disable, leave as 1 to enable inputs from this "channel"
- Required_mask:
- For Units 1-7, Bits 0-11 correspond to PORTS 1-12.
- For Units 16-19, Bits 0-6 correspond to UNITS 1-7
- Multiplicity: Minimum number of unmasked inputs required to generate output
- Prescale: self-explanatory (I hope)
- Trigger-select: For Pretrigger Units 1-7, these words specify the types of triggers to accept from the front-panel ports.
- The trigger type is encoded in the two bits. 00=Type 1, 01=Type 2, 10=Type 3, 11=Type 4.
- Word for Lower 12 bits: Bits 0-1 for Port 1, Bits 2-3 for Port 2 .... Bits 10-11 for Port 6.
- Word for Upper 12 bits: Bits 0-1 for Port 7, Bits 2-3 for Port 8, ... Bits 10-11 for Port 12.
- Veto
- Always-Active-Mask
The TIG10-Collector trigger modules were currently only used to enable zero-suppression within a 10-channel TIG10 module, for the silicons. This special case is set in the frontend, for slave-collector !=4 the always active_mask is set to 0x3ff (i.e. chan1-10 are always read, the default is NOW that only the active channels are read).
[edit] Recent Changes ...
The Pattern duration and delay were hardcoded to 0x70 and 1 (These provide the overlap between the trigger accept and the active ports - trigger accepts are only sent to ports where these overlap) For delayed gammas, delayed over 400ns the active patterns start after the trigger accept and so are too late to cause the gamma to be included (It is not possible to make these start earlier!). The trigger accept can be delayed, and now the duration and delay can be changed to allow for the late triggers. The defaults are 0x20 and 1 (those for the STB boxed) so these now need programming in each slave as these defaults are too short.
The delayed trigger is likely to cause some problems in the frontends.

