pflib v3.9.5-18-g30f792c
Pretty Fine HGCROC Interaction Library
Loading...
Searching...
No Matches
pflib::EcalSingleModuleMotherboard Class Reference

a target for Ecal motherboards holding a single module More...

#include <EcalSingleModuleMotherboard.h>

Inheritance diagram for pflib::EcalSingleModuleMotherboard:
[legend]
Collaboration diagram for pflib::EcalSingleModuleMotherboard:
[legend]

Public Member Functions

void init (lpGBT &daq_lpgbt, lpGBT &trg_lpgbt, int module_i2c_bus, int roc_mask)
 common initialization given the DAQ/TRG lpGBTs and a mask labeling which ROCs on the module are active
 
virtual const std::vector< std::pair< int, int > > & getHardwareRocErxMapping () override
 Define the ROC-half -> eRx input into the ECON-D for the hardware.
 
virtual int nrocs () override
 number of boards
 
virtual int necons () override
 number of econds
 
virtual bool have_roc (int iroc) const override
 do we have a roc with this id?
 
virtual bool have_econ (int iecon) const override
 do we have an econ with this id?
 
virtual std::vector< int > roc_ids () const override
 get a list of the IDs we have set up
 
virtual std::vector< int > econ_ids () const override
 get a list of the econ IDs we have set up
 
virtual ROCroc (int which) override
 Get a ROC interface for the given HGCROC board.
 
virtual ECONecon (int which) override
 get a ECON interface for the given econ board
 
virtual void softResetROC (int which) override
 Generate a soft reset to a specific HGCROC board, -1 for all.
 
virtual void softResetECON (int which=-1) override
 Generate a soft reset to a specific ECON board, -1 for all.
 
virtual void hardResetROCs () override
 Generate a hard reset to all the HGCROC boards.
 
virtual void hardResetECONs () override
 generate a hard reset to all the ECON boards
 
virtual void setup_run (int irun, Target::DaqFormat format, int contrib_id) override
 
- Public Member Functions inherited from pflib::Target
virtual uint32_t getFirmwareVersion ()
 Get the firmware version.
 
virtual Elinkselinks ()=0
 get the Elinks object
 
virtual FastControlfc ()=0
 get the FastControl object
 
virtual DAQdaq ()=0
 get the DAQ object
 
std::vector< std::stringi2c_bus_names ()
 names of different I2C busses we could talk to
 
I2Cget_i2c_bus (const std::string &name)
 get an I2C bus by name
 
std::vector< std::stringopto_link_names () const
 names of different Optical Links we could talk to
 
OptoLinkget_opto_link (const std::string &name) const
 get an OptoLink by name
 
const packing::SingleECONDRocErxMappinggetRocErxMapping ()
 get the mapping that can be used to convert between (i_erx, link_chan) and (i_roc, chan) indices
 
virtual std::vector< uint32_t > read_event ()=0
 
virtual bool has_event ()
 

Protected Attributes

std::shared_ptr< EcalModulethe_module_
 handle to the hexa-module that we are connected to
 
Target::DaqFormat format_
 the format we are using for DAQ
 
int contrib_id_
 the contributor ID for DAQ
 
- Protected Attributes inherited from pflib::Target
std::map< std::string, std::shared_ptr< I2C > > i2c_
 
std::map< std::string, std::shared_ptr< OptoLink > > opto_
 
logging::logger the_log_ {logging::get("Target")}
 

Additional Inherited Members

- Public Types inherited from pflib::Target
enum class  DaqFormat { SIMPLEROC = 1 , ECOND_SW_HEADERS = 2 }
 types of daq formats that we can do More...
 

Detailed Description

a target for Ecal motherboards holding a single module

common accessors and initialization procedures between the ZCU and Bittware targets Since there is just one module, the ROC/ECON accessors and resets are just forwarding calls to our held instance of an EcalModule.

Member Function Documentation

◆ econ()

ECON & pflib::EcalSingleModuleMotherboard::econ ( int which)
overridevirtual

get a ECON interface for the given econ board

Implements pflib::Target.

◆ econ_ids()

std::vector< int > pflib::EcalSingleModuleMotherboard::econ_ids ( ) const
overridevirtual

get a list of the econ IDs we have set up

Implements pflib::Target.

◆ getHardwareRocErxMapping()

const std::vector< std::pair< int, int > > & pflib::EcalSingleModuleMotherboard::getHardwareRocErxMapping ( )
overridevirtual

Define the ROC-half -> eRx input into the ECON-D for the hardware.

This does not include which ROCs are active (i.e. assume all the ROCs are active). This is used when constructing the SingleECONDRocErxMapping object that is used to to the index conversions for us.

Implements pflib::Target.

◆ hardResetECONs()

void pflib::EcalSingleModuleMotherboard::hardResetECONs ( )
overridevirtual

generate a hard reset to all the ECON boards

Implements pflib::Target.

◆ hardResetROCs()

void pflib::EcalSingleModuleMotherboard::hardResetROCs ( )
overridevirtual

Generate a hard reset to all the HGCROC boards.

Implements pflib::Target.

◆ have_econ()

bool pflib::EcalSingleModuleMotherboard::have_econ ( int iecon) const
overridevirtual

do we have an econ with this id?

Implements pflib::Target.

◆ have_roc()

bool pflib::EcalSingleModuleMotherboard::have_roc ( int iroc) const
overridevirtual

do we have a roc with this id?

Implements pflib::Target.

◆ init()

void pflib::EcalSingleModuleMotherboard::init ( lpGBT & daq_lpgbt,
lpGBT & trg_lpgbt,
int module_i2c_bus,
int roc_mask )

common initialization given the DAQ/TRG lpGBTs and a mask labeling which ROCs on the module are active

This should be called after the optical links are properly setup and used to create access to the lpGBTs.

◆ necons()

int pflib::EcalSingleModuleMotherboard::necons ( )
overridevirtual

number of econds

Implements pflib::Target.

◆ nrocs()

int pflib::EcalSingleModuleMotherboard::nrocs ( )
overridevirtual

number of boards

Implements pflib::Target.

◆ roc()

ROC & pflib::EcalSingleModuleMotherboard::roc ( int which)
overridevirtual

Get a ROC interface for the given HGCROC board.

Implements pflib::Target.

◆ roc_ids()

std::vector< int > pflib::EcalSingleModuleMotherboard::roc_ids ( ) const
overridevirtual

get a list of the IDs we have set up

Implements pflib::Target.

◆ setup_run()

void pflib::EcalSingleModuleMotherboard::setup_run ( int irun,
Target::DaqFormat format,
int contrib_id )
overridevirtual

Implements pflib::Target.

◆ softResetECON()

void pflib::EcalSingleModuleMotherboard::softResetECON ( int which = -1)
overridevirtual

Generate a soft reset to a specific ECON board, -1 for all.

the soft reset is applied to all ECONs on the board

Implements pflib::Target.

◆ softResetROC()

void pflib::EcalSingleModuleMotherboard::softResetROC ( int which)
overridevirtual

Generate a soft reset to a specific HGCROC board, -1 for all.

the soft reset is applied to all ROCs on the board

Implements pflib::Target.


The documentation for this class was generated from the following files: