FlxCard
Loading...
Searching...
No Matches
Configuration

Functions

u_int FlxCard::card_model ()
u_int FlxCard::card_type ()
u_int FlxCard::firmware_type ()
std::string FlxCard::firmware_type_string ()
std::string FlxCard::firmware_string ()
bool FlxCard::lpgbt_type ()
bool FlxCard::lpgbt_fec12 ()
bool FlxCard::lpgbt_5gbps ()
bool FlxCard::fullmode_type ()
void FlxCard::soft_reset ()
void FlxCard::cr_fromhost_reset ()
u_int FlxCard::number_of_endpoints ()
u_int FlxCard::endpoint ()
u_int FlxCard::number_of_channels ()
std::pair< int, int > FlxCard::ec_elink_indices ()
int FlxCard::ec_elink_tohost_index ()
int FlxCard::ec_elink_fromhost_index ()
std::pair< int, int > FlxCard::ic_elink_indices ()
int FlxCard::ic_elink_tohost_index ()
int FlxCard::ic_elink_fromhost_index ()
void FlxCard::configure (std::string filename, bool do_links=true, bool do_registers=true)
void FlxCard::readConfiguration (std::string filename)
void FlxCard::read_configuration (std::string filename)
void FlxCard::readConfiguration ()
void FlxCard::read_configuration ()
u_int FlxCard::number_of_elinks_tohost (int dma_index=-1)
u_int FlxCard::number_of_elinks_toflx ()
u_int FlxCard::number_of_elinks_fromhost ()
std::vector< flxcard::elink_descr_t > FlxCard::elinks_tohost (int dma_index=-1)
std::vector< flxcard::elink_descr_t > FlxCard::elinks_toflx ()
std::vector< flxcard::elink_descr_t > FlxCard::elinks_fromhost ()
std::vector< flxcard::elink_descr_t > FlxCard::elinks_toflx_broadcast ()
std::vector< flxcard::elink_descr_t > FlxCard::elinks_fromhost_broadcast ()
u_int FlxCard::number_of_dma_tohost ()
bool FlxCard::uses_dma_index_mask ()
void FlxCard::set_hdlc_instant_timeout (bool b)
bool FlxCard::hdlc_instant_timeout ()
unsigned int FlxCard::link_mode ()
bool FlxCard::is_elink_enabled (u_int channel, u_int egroup, u_int epath, bool is_to_flx)
unsigned int FlxCard::tohost_elink_dmaid (u_int channel, u_int egroup, u_int epath)
unsigned int FlxCard::tohost_elink_dmaid (uint16_t elinknr)
bool FlxCard::has_tohost_elink_streams (u_int channel, u_int egroup, u_int epath)
uint8_t FlxCard::detector_id ()
uint16_t FlxCard::connector_id (uint16_t channel)
uint32_t FlxCard::number_of_epaths_per_egroup (bool to_flx=false)
uint32_t FlxCard::number_of_egroups (bool to_flx=false)
uint16_t FlxCard::elink_number (uint32_t channel, uint32_t egroup, uint32_t epath, bool to_flx=false)
uint16_t FlxCard::channel_number (uint32_t elinknr)
uint16_t FlxCard::link_number (uint32_t elinknr)
uint16_t FlxCard::egroup_number (uint32_t elinknr, bool to_flx=false)
uint16_t FlxCard::epath_number (uint32_t elinknr, bool to_flx=false)

Detailed Description

Functions pertaining to configuration of an FLX device and its (e-)links

Function Documentation

◆ card_model()

u_int FlxCard::card_model ( )
inline

Returns the H/W type of the FLX card, read in card_open(). Currently these types are known (and supported): FLX-709, FLX-710, FLX-711, FLX-712, FLX-128, FLX-181, FLX-182, FLX-155

Returns
integer value of the card model, a number like 709, 712, etc.

◆ firmware_type()

u_int FlxCard::firmware_type ( )
inline

Returns the firmware type of the FLX card, read in card_open().

◆ firmware_type_string()

std::string FlxCard::firmware_type_string ( )
inline

Returns the firmware type of the FLX card as a (short) string.

◆ firmware_string()

std::string FlxCard::firmware_string ( )
inline

Returns a descriptive name of the firmware type and version running on the FLX card.

◆ lpgbt_type()

bool FlxCard::lpgbt_type ( )
inline

Returns whether the firmware type is an lpGBT-type firmware.

◆ lpgbt_fec12()

bool FlxCard::lpgbt_fec12 ( )
inline

Returns whether the lpGBT-type firmware uses FEC12 (otherwise FEC5)

◆ lpgbt_5gbps()

bool FlxCard::lpgbt_5gbps ( )
inline

Returns whether the lpGBT-type firmware has lpGBT at 5Gbps (default 10Gbps)

◆ fullmode_type()

bool FlxCard::fullmode_type ( )
inline

Returns whether the firmware type is a FULLMODE-type firmware.

◆ soft_reset()

void FlxCard::soft_reset ( )

Triggers a reset by the SOFT_RESET register in BAR0.

◆ cr_fromhost_reset()

void FlxCard::cr_fromhost_reset ( )

Triggers a reset by the CRFROMHOST_RESET register in BAR2.

◆ number_of_endpoints()

u_int FlxCard::number_of_endpoints ( )
inline
Returns
Number of PCIe endpoints of the FELIX card.

◆ endpoint()

u_int FlxCard::endpoint ( )
inline
Returns
Index of the PCIe endpoint of this FELIX device.

◆ number_of_channels()

u_int FlxCard::number_of_channels ( )
inline
Returns
Number of physical links connected to the PCIe endpoint.

◆ ec_elink_indices()

std::pair< int, int > FlxCard::ec_elink_indices ( )
Returns
Indices of the e-link number for EC ToHost (receive) and FromHost (send).

◆ ic_elink_indices()

std::pair< int, int > FlxCard::ic_elink_indices ( )
Returns
Indices of the e-link number for IC ToHost (receive) and FromHost (send).

◆ configure()

void FlxCard::configure ( std::string filename,
bool do_links = true,
bool do_registers = true )

Reads a FELIX device (e-)link configuration -plus additional register settings, if any- from a .yelc configuration file, stores it in a member structure, and writes the configuration to this FELIX device (or -optionally- not, and/or optionally skipping any register settings present in the file).

◆ readConfiguration() [1/2]

void FlxCard::readConfiguration ( std::string filename)

Reads a FELIX device (e-)link configuration -plus additional register settings, if any- from a .yelc file, and stores it in a member structure.

◆ readConfiguration() [2/2]

void FlxCard::readConfiguration ( )

Reads a FELIX device (e-)link configuration from this FELIX device and stores it in a member structure. Leaves any stored additional register settings untouched.

◆ number_of_elinks_tohost()

u_int FlxCard::number_of_elinks_tohost ( int dma_index = -1)

Returns the number of enabled ToHost e-link numbers of this FELIX device, optionally only those assigned to the given DMA index.

◆ number_of_elinks_toflx()

u_int FlxCard::number_of_elinks_toflx ( )

Returns the number of enabled FromHost e-link numbers of this FELIX device, including TTC-type e-links.

◆ elinks_tohost()

std::vector< flxcard::elink_descr_t > FlxCard::elinks_tohost ( int dma_index = -1)

Returns a list of the enabled ToHost e-link numbers of this FELIX device, optionally only those assigned to the given DMA index.

◆ elinks_toflx()

std::vector< flxcard::elink_descr_t > FlxCard::elinks_toflx ( )

Returns a list of the enabled FromHost e-link numbers of this FELIX device, not including TTC-type e-links.

◆ number_of_dma_tohost()

u_int FlxCard::number_of_dma_tohost ( )
inline

Returns the number of ToHost DMA descriptors of this FELIX device.

◆ uses_dma_index_mask()

bool FlxCard::uses_dma_index_mask ( )
inline

Returns true if this FELIX device uses a DMA index bitmask for its e-links, rather than a single DMA index number.

◆ link_mode()

unsigned int FlxCard::link_mode ( )

Returns the link mode, defined in LinkConfig.h

◆ is_elink_enabled()

bool FlxCard::is_elink_enabled ( u_int channel,
u_int egroup,
u_int epath,
bool is_to_flx )

Returns true if the e-link is enabled.

◆ tohost_elink_dmaid() [1/2]

unsigned int FlxCard::tohost_elink_dmaid ( u_int channel,
u_int egroup,
u_int epath )

Returns the DMA id assigned to the given e-link

◆ tohost_elink_dmaid() [2/2]

unsigned int FlxCard::tohost_elink_dmaid ( uint16_t elinknr)

Returns the DMA id assigned to the given e-link

◆ has_tohost_elink_streams()

bool FlxCard::has_tohost_elink_streams ( u_int channel,
u_int egroup,
u_int epath )

Returns true if the e-link is enabled.

◆ detector_id()

uint8_t FlxCard::detector_id ( )
Returns
the detector id set up in the register map.

Returns -1 if the VALID bit is not set.

◆ connector_id()

uint16_t FlxCard::connector_id ( uint16_t channel)
Returns
the connector id set up in the register map.

Returns the connector number from 0 to 3 if the register is not set

Parameters
channelthe channel number to resolve the connector ID in case of an FLX-155 card with more than 24 links.