DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dunedaq::appmodel::WIBPulserSettings Class Reference

#include <WIBPulserSettings.hpp>

Inheritance diagram for dunedaq::appmodel::WIBPulserSettings:
[legend]
Collaboration diagram for dunedaq::appmodel::WIBPulserSettings:
[legend]

Public Member Functions

virtual void print (unsigned int offset, bool print_header, std::ostream &s) const
 Print details of the WIBPulserSettings object.
 
virtual std::vector< const dunedaq::conffwk::DalObject * > get (const std::string &name, bool upcast_unregistered=true) const
 Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject pointers.
 
bool get_enabled_0 () const
 Get "enabled_0" attribute value. Enable WIB pulser for FEMB 0.
 
void set_enabled_0 (bool value)
 Set "enabled_0" attribute value. Enable WIB pulser for FEMB 0.
 
bool get_enabled_1 () const
 Get "enabled_1" attribute value. Enable WIB pulser for FEMB 1.
 
void set_enabled_1 (bool value)
 Set "enabled_1" attribute value. Enable WIB pulser for FEMB 1.
 
bool get_enabled_2 () const
 Get "enabled_2" attribute value. Enable WIB pulser for FEMB 2.
 
void set_enabled_2 (bool value)
 Set "enabled_2" attribute value. Enable WIB pulser for FEMB 2.
 
bool get_enabled_3 () const
 Get "enabled_3" attribute value. Enable WIB pulser for FEMB 3.
 
void set_enabled_3 (bool value)
 Set "enabled_3" attribute value. Enable WIB pulser for FEMB 3.
 
uint16_t get_pulse_dac () const
 Get "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].
 
void set_pulse_dac (uint16_t value)
 Set "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].
 
uint32_t get_pulse_period () const
 Get "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].
 
void set_pulse_period (uint32_t value)
 Set "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].
 
uint8_t get_pulse_phase () const
 Get "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].
 
void set_pulse_phase (uint8_t value)
 Set "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].
 
uint32_t get_pulse_duration () const
 Get "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].
 
void set_pulse_duration (uint32_t value)
 Set "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].
 
virtual void print (unsigned int offset, bool print_header, std::ostream &s) const
 Print details of the WIBPulserSettings object.
 
virtual std::vector< const dunedaq::conffwk::DalObject * > get (const std::string &name, bool upcast_unregistered=true) const
 Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject pointers.
 
bool get_enabled_0 () const
 Get "enabled_0" attribute value. Enable WIB pulser for FEMB 0.
 
void set_enabled_0 (bool value)
 Set "enabled_0" attribute value. Enable WIB pulser for FEMB 0.
 
bool get_enabled_1 () const
 Get "enabled_1" attribute value. Enable WIB pulser for FEMB 1.
 
void set_enabled_1 (bool value)
 Set "enabled_1" attribute value. Enable WIB pulser for FEMB 1.
 
bool get_enabled_2 () const
 Get "enabled_2" attribute value. Enable WIB pulser for FEMB 2.
 
void set_enabled_2 (bool value)
 Set "enabled_2" attribute value. Enable WIB pulser for FEMB 2.
 
bool get_enabled_3 () const
 Get "enabled_3" attribute value. Enable WIB pulser for FEMB 3.
 
void set_enabled_3 (bool value)
 Set "enabled_3" attribute value. Enable WIB pulser for FEMB 3.
 
uint16_t get_pulse_dac () const
 Get "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].
 
void set_pulse_dac (uint16_t value)
 Set "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].
 
uint32_t get_pulse_period () const
 Get "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].
 
void set_pulse_period (uint32_t value)
 Set "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].
 
uint8_t get_pulse_phase () const
 Get "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].
 
void set_pulse_phase (uint8_t value)
 Set "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].
 
uint32_t get_pulse_duration () const
 Get "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].
 
void set_pulse_duration (uint32_t value)
 Set "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].
 
- Public Member Functions inherited from dunedaq::conffwk::DalObject
const std::string & UID () const noexcept
 
const std::string & class_name () const noexcept
 
bool castable (const std::string &target) const noexcept
 
bool castable (const std::string *target) const noexcept
 
template<class TARGET >
const TARGET * cast () const noexcept
 Casts object to different class.
 
std::string full_name () const noexcept
 
const ConfigObjectconfig_object () const
 
DalRegistryregistry () const noexcept
 
Configurationconfiguration () const noexcept
 
void unread ()
 
void set (const ConfigObject &o) noexcept
 
void move (const std::string &at)
 
void rename (const std::string &new_id)
 
void p_hdr (std::ostream &s, unsigned int indent, const std::string &cl, const char *nm=nullptr) const
 print object headers
 
std::ostream & print_object (std::ostream &s) const
 print object details
 
void throw_init_ex (dunedaq::conffwk::Exception &ex)
 throw object initialisation exception (i.e.
 

Static Public Member Functions

static const std::string & __get_enabled_0_str () noexcept
 
static const std::string & __get_enabled_1_str () noexcept
 
static const std::string & __get_enabled_2_str () noexcept
 
static const std::string & __get_enabled_3_str () noexcept
 
static const std::string & __get_pulse_dac_str () noexcept
 
static const std::string & __get_pulse_period_str () noexcept
 
static const std::string & __get_pulse_phase_str () noexcept
 
static const std::string & __get_pulse_duration_str () noexcept
 
static const std::string & __get_enabled_0_str () noexcept
 
static const std::string & __get_enabled_1_str () noexcept
 
static const std::string & __get_enabled_2_str () noexcept
 
static const std::string & __get_enabled_3_str () noexcept
 
static const std::string & __get_pulse_dac_str () noexcept
 
static const std::string & __get_pulse_period_str () noexcept
 
static const std::string & __get_pulse_phase_str () noexcept
 
static const std::string & __get_pulse_duration_str () noexcept
 
- Static Public Member Functions inherited from dunedaq::conffwk::DalObject
static void p_null (std::ostream &s)
 print "(null)"
 
static void p_rm (std::ostream &s)
 print "(deleted object)"
 
static void p_error (std::ostream &s, dunedaq::conffwk::Exception &ex)
 print error text
 
static void throw_get_ex (const std::string &what, const std::string &class_name, const DalObject *obj)
 throw exception in generated get method (i.e.
 
static bool is_null (const DalObject *ref) noexcept
 check a pointer on DAL object is null
 

Static Public Attributes

static const std::string & s_class_name
 
static const std::string s_enabled_0 = "enabled_0"
 
static const std::string s_enabled_1 = "enabled_1"
 
static const std::string s_enabled_2 = "enabled_2"
 
static const std::string s_enabled_3 = "enabled_3"
 
static const std::string s_pulse_dac = "pulse_dac"
 
static const std::string s_pulse_period = "pulse_period"
 
static const std::string s_pulse_phase = "pulse_phase"
 
static const std::string s_pulse_duration = "pulse_duration"
 

Protected Member Functions

 WIBPulserSettings (conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
 
virtual ~WIBPulserSettings () noexcept
 
virtual void init (bool init_children)
 
bool get (const std::string &name, std::vector< const dunedaq::conffwk::DalObject * > &vec, bool upcast_unregistered, bool first_call) const
 
 WIBPulserSettings (conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
 
virtual ~WIBPulserSettings () noexcept
 
virtual void init (bool init_children)
 
bool get (const std::string &name, std::vector< const dunedaq::conffwk::DalObject * > &vec, bool upcast_unregistered, bool first_call) const
 
- Protected Member Functions inherited from dunedaq::conffwk::DalObject
 DalObject (DalRegistry &db, const ConfigObject &o) noexcept
 
virtual ~DalObject ()
 
void clear () noexcept
 
void check () const
 
bool is_deleted () const
 
void increment_created () noexcept
 
void increment_read () noexcept
 
void check_init () const
 Check and initialize object if necessary.
 
template<typename T >
void _set_object (const std::string &name, const T *value)
 Helper method for generated set single-value relationship methods.
 
template<typename T >
void _set_objects (const std::string &name, const std::vector< const T * > &value)
 Helper method for generated set multi-value relationship methods.
 
bool get_rel_objects (const std::string &name, bool upcast_unregistered, std::vector< const DalObject * > &objs) const
 Read relationship values as DAL objects using DAL factory.
 
bool get_algo_objects (const std::string &name, std::vector< const DalObject * > &objs) const
 Run algorithm and return result as DAL objects using DAL factory.
 

Private Attributes

bool m_enabled_0
 
bool m_enabled_1
 
bool m_enabled_2
 
bool m_enabled_3
 
uint16_t m_pulse_dac
 
uint32_t m_pulse_period
 
uint8_t m_pulse_phase
 
uint32_t m_pulse_duration
 

Friends

class conffwk::Configuration
 
class conffwk::DalObject
 
class conffwk::DalFactory
 
class conffwk::DalRegistry
 

Additional Inherited Members

- Protected Attributes inherited from dunedaq::conffwk::DalObject
std::mutex m_mutex
 Used to protect changes of DAL object.
 
bool p_was_read
 is true, if the object was read
 
DalRegistryp_registry
 Configuration object.
 
ConfigObject p_obj
 Config object used by given template object.
 
std::string p_UID
 Is used for template objects (see dqm_conffwk)
 

Detailed Description

WIB Pulser settings

Definition at line 24 of file WIBPulserSettings.hpp.

Constructor & Destructor Documentation

◆ WIBPulserSettings() [1/2]

dunedaq::appmodel::WIBPulserSettings::WIBPulserSettings ( conffwk::DalRegistry & db,
const conffwk::ConfigObject & obj )
protectednoexcept

Definition at line 26 of file WIBPulserSettings.cpp.

26 :
28 {
29 ;
30 }
The base class for any generated DAL object.
Definition DalObject.hpp:45

◆ ~WIBPulserSettings() [1/2]

dunedaq::appmodel::WIBPulserSettings::~WIBPulserSettings ( )
protectedvirtualnoexcept

Definition at line 82 of file WIBPulserSettings.cpp.

83 {
84 }

◆ WIBPulserSettings() [2/2]

dunedaq::appmodel::WIBPulserSettings::WIBPulserSettings ( conffwk::DalRegistry & db,
const conffwk::ConfigObject & obj )
protectednoexcept

◆ ~WIBPulserSettings() [2/2]

virtual dunedaq::appmodel::WIBPulserSettings::~WIBPulserSettings ( )
protectedvirtualnoexcept

Member Function Documentation

◆ __get_enabled_0_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_0_str ( )
inlinestaticnoexcept

Definition at line 98 of file WIBPulserSettings.hpp.

98{ return s_enabled_0; }

◆ __get_enabled_0_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_0_str ( )
inlinestaticnoexcept

Definition at line 98 of file WIBPulserSettings.hpp.

98{ return s_enabled_0; }

◆ __get_enabled_1_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_1_str ( )
inlinestaticnoexcept

Definition at line 99 of file WIBPulserSettings.hpp.

99{ return s_enabled_1; }

◆ __get_enabled_1_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_1_str ( )
inlinestaticnoexcept

Definition at line 99 of file WIBPulserSettings.hpp.

99{ return s_enabled_1; }

◆ __get_enabled_2_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_2_str ( )
inlinestaticnoexcept

Definition at line 100 of file WIBPulserSettings.hpp.

100{ return s_enabled_2; }

◆ __get_enabled_2_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_2_str ( )
inlinestaticnoexcept

Definition at line 100 of file WIBPulserSettings.hpp.

100{ return s_enabled_2; }

◆ __get_enabled_3_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_3_str ( )
inlinestaticnoexcept

Definition at line 101 of file WIBPulserSettings.hpp.

101{ return s_enabled_3; }

◆ __get_enabled_3_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_enabled_3_str ( )
inlinestaticnoexcept

Definition at line 101 of file WIBPulserSettings.hpp.

101{ return s_enabled_3; }

◆ __get_pulse_dac_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_dac_str ( )
inlinestaticnoexcept

Definition at line 102 of file WIBPulserSettings.hpp.

102{ return s_pulse_dac; }

◆ __get_pulse_dac_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_dac_str ( )
inlinestaticnoexcept

Definition at line 102 of file WIBPulserSettings.hpp.

102{ return s_pulse_dac; }

◆ __get_pulse_duration_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_duration_str ( )
inlinestaticnoexcept

Definition at line 105 of file WIBPulserSettings.hpp.

105{ return s_pulse_duration; }
static const std::string s_pulse_duration

◆ __get_pulse_duration_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_duration_str ( )
inlinestaticnoexcept

Definition at line 105 of file WIBPulserSettings.hpp.

105{ return s_pulse_duration; }

◆ __get_pulse_period_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_period_str ( )
inlinestaticnoexcept

Definition at line 103 of file WIBPulserSettings.hpp.

103{ return s_pulse_period; }

◆ __get_pulse_period_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_period_str ( )
inlinestaticnoexcept

Definition at line 103 of file WIBPulserSettings.hpp.

103{ return s_pulse_period; }

◆ __get_pulse_phase_str() [1/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_phase_str ( )
inlinestaticnoexcept

Definition at line 104 of file WIBPulserSettings.hpp.

104{ return s_pulse_phase; }

◆ __get_pulse_phase_str() [2/2]

static const std::string & dunedaq::appmodel::WIBPulserSettings::__get_pulse_phase_str ( )
inlinestaticnoexcept

Definition at line 104 of file WIBPulserSettings.hpp.

104{ return s_pulse_phase; }

◆ get() [1/4]

std::vector< const dunedaq::conffwk::DalObject * > dunedaq::appmodel::WIBPulserSettings::get ( const std::string & name,
bool upcast_unregistered = true ) const
virtual

Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject pointers.

Parameters are:

Parameters
namename of the relationship or algorithm
Returns
value of relationship or result of algorithm
Exceptions
std::exceptionif there is no relationship or algorithm with such name in this and base classes

Implements dunedaq::conffwk::DalObject.

Definition at line 86 of file WIBPulserSettings.cpp.

87 {
88 std::vector<const dunedaq::conffwk::DalObject *> vec;
89
90 if (!get(name, vec, upcast_unregistered, true))
91 throw_get_ex(name, s_class_name, this);
92
93 return vec;
94 }
static const std::string & s_class_name
virtual std::vector< const dunedaq::conffwk::DalObject * > get(const std::string &name, bool upcast_unregistered=true) const
Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject...
static void throw_get_ex(const std::string &what, const std::string &class_name, const DalObject *obj)
throw exception in generated get method (i.e.
Definition DalObject.cpp:82

◆ get() [2/4]

virtual std::vector< const dunedaq::conffwk::DalObject * > dunedaq::appmodel::WIBPulserSettings::get ( const std::string & name,
bool upcast_unregistered = true ) const
virtual

Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject pointers.

Parameters are:

Parameters
namename of the relationship or algorithm
Returns
value of relationship or result of algorithm
Exceptions
std::exceptionif there is no relationship or algorithm with such name in this and base classes

Implements dunedaq::conffwk::DalObject.

◆ get() [3/4]

bool dunedaq::appmodel::WIBPulserSettings::get ( const std::string & name,
std::vector< const dunedaq::conffwk::DalObject * > & vec,
bool upcast_unregistered,
bool first_call ) const
protected

Definition at line 96 of file WIBPulserSettings.cpp.

97 {
98 if (first_call)
99 {
100 std::lock_guard scoped_lock(m_mutex);
101
102 check();
103 check_init();
104
105 if (get_rel_objects(name, upcast_unregistered, vec))
106 return true;
107 }
108
109 if (first_call)
110 return get_algo_objects(name, vec);
111
112 return false;
113 }
bool get_rel_objects(const std::string &name, bool upcast_unregistered, std::vector< const DalObject * > &objs) const
Read relationship values as DAL objects using DAL factory.
Definition DalObject.cpp:8
std::mutex m_mutex
Used to protect changes of DAL object.
bool get_algo_objects(const std::string &name, std::vector< const DalObject * > &objs) const
Run algorithm and return result as DAL objects using DAL factory.
Definition DalObject.cpp:25
void check_init() const
Check and initialize object if necessary.

◆ get() [4/4]

bool dunedaq::appmodel::WIBPulserSettings::get ( const std::string & name,
std::vector< const dunedaq::conffwk::DalObject * > & vec,
bool upcast_unregistered,
bool first_call ) const
protected

◆ get_enabled_0() [1/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_0 ( ) const
inline

Get "enabled_0" attribute value. Enable WIB pulser for FEMB 0.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 116 of file WIBPulserSettings.hpp.

117 {
118 std::lock_guard scoped_lock(m_mutex);
119 check();
120 check_init();
121 return m_enabled_0;
122 }

◆ get_enabled_0() [2/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_0 ( ) const
inline

Get "enabled_0" attribute value. Enable WIB pulser for FEMB 0.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 116 of file WIBPulserSettings.hpp.

117 {
118 std::lock_guard scoped_lock(m_mutex);
119 check();
120 check_init();
121 return m_enabled_0;
122 }

◆ get_enabled_1() [1/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_1 ( ) const
inline

Get "enabled_1" attribute value. Enable WIB pulser for FEMB 1.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 149 of file WIBPulserSettings.hpp.

150 {
151 std::lock_guard scoped_lock(m_mutex);
152 check();
153 check_init();
154 return m_enabled_1;
155 }

◆ get_enabled_1() [2/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_1 ( ) const
inline

Get "enabled_1" attribute value. Enable WIB pulser for FEMB 1.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 149 of file WIBPulserSettings.hpp.

150 {
151 std::lock_guard scoped_lock(m_mutex);
152 check();
153 check_init();
154 return m_enabled_1;
155 }

◆ get_enabled_2() [1/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_2 ( ) const
inline

Get "enabled_2" attribute value. Enable WIB pulser for FEMB 2.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 182 of file WIBPulserSettings.hpp.

183 {
184 std::lock_guard scoped_lock(m_mutex);
185 check();
186 check_init();
187 return m_enabled_2;
188 }

◆ get_enabled_2() [2/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_2 ( ) const
inline

Get "enabled_2" attribute value. Enable WIB pulser for FEMB 2.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 182 of file WIBPulserSettings.hpp.

183 {
184 std::lock_guard scoped_lock(m_mutex);
185 check();
186 check_init();
187 return m_enabled_2;
188 }

◆ get_enabled_3() [1/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_3 ( ) const
inline

Get "enabled_3" attribute value. Enable WIB pulser for FEMB 3.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 215 of file WIBPulserSettings.hpp.

216 {
217 std::lock_guard scoped_lock(m_mutex);
218 check();
219 check_init();
220 return m_enabled_3;
221 }

◆ get_enabled_3() [2/2]

bool dunedaq::appmodel::WIBPulserSettings::get_enabled_3 ( ) const
inline

Get "enabled_3" attribute value. Enable WIB pulser for FEMB 3.

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 215 of file WIBPulserSettings.hpp.

216 {
217 std::lock_guard scoped_lock(m_mutex);
218 check();
219 check_init();
220 return m_enabled_3;
221 }

◆ get_pulse_dac() [1/2]

uint16_t dunedaq::appmodel::WIBPulserSettings::get_pulse_dac ( ) const
inline

Get "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 248 of file WIBPulserSettings.hpp.

249 {
250 std::lock_guard scoped_lock(m_mutex);
251 check();
252 check_init();
253 return m_pulse_dac;
254 }

◆ get_pulse_dac() [2/2]

uint16_t dunedaq::appmodel::WIBPulserSettings::get_pulse_dac ( ) const
inline

Get "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 248 of file WIBPulserSettings.hpp.

249 {
250 std::lock_guard scoped_lock(m_mutex);
251 check();
252 check_init();
253 return m_pulse_dac;
254 }

◆ get_pulse_duration() [1/2]

uint32_t dunedaq::appmodel::WIBPulserSettings::get_pulse_duration ( ) const
inline

Get "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 347 of file WIBPulserSettings.hpp.

348 {
349 std::lock_guard scoped_lock(m_mutex);
350 check();
351 check_init();
352 return m_pulse_duration;
353 }

◆ get_pulse_duration() [2/2]

uint32_t dunedaq::appmodel::WIBPulserSettings::get_pulse_duration ( ) const
inline

Get "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 347 of file WIBPulserSettings.hpp.

348 {
349 std::lock_guard scoped_lock(m_mutex);
350 check();
351 check_init();
352 return m_pulse_duration;
353 }

◆ get_pulse_period() [1/2]

uint32_t dunedaq::appmodel::WIBPulserSettings::get_pulse_period ( ) const
inline

Get "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 281 of file WIBPulserSettings.hpp.

282 {
283 std::lock_guard scoped_lock(m_mutex);
284 check();
285 check_init();
286 return m_pulse_period;
287 }

◆ get_pulse_period() [2/2]

uint32_t dunedaq::appmodel::WIBPulserSettings::get_pulse_period ( ) const
inline

Get "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 281 of file WIBPulserSettings.hpp.

282 {
283 std::lock_guard scoped_lock(m_mutex);
284 check();
285 check_init();
286 return m_pulse_period;
287 }

◆ get_pulse_phase() [1/2]

uint8_t dunedaq::appmodel::WIBPulserSettings::get_pulse_phase ( ) const
inline

Get "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 314 of file WIBPulserSettings.hpp.

315 {
316 std::lock_guard scoped_lock(m_mutex);
317 check();
318 check_init();
319 return m_pulse_phase;
320 }

◆ get_pulse_phase() [2/2]

uint8_t dunedaq::appmodel::WIBPulserSettings::get_pulse_phase ( ) const
inline

Get "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].

Returns
the attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 314 of file WIBPulserSettings.hpp.

315 {
316 std::lock_guard scoped_lock(m_mutex);
317 check();
318 check_init();
319 return m_pulse_phase;
320 }

◆ init() [1/2]

void dunedaq::appmodel::WIBPulserSettings::init ( bool init_children)
protectedvirtual

Initialize object (method generated by genconffwk)

Parameters
init_childrenif true, initialize referenced objects

Implements dunedaq::conffwk::DalObject.

Definition at line 61 of file WIBPulserSettings.cpp.

62 {
63 p_was_read = true;
65 TLOG_DEBUG(5) << "read object " << this << " (class " << s_class_name << ')';
66
67 try {
76 }
77 catch (dunedaq::conffwk::Exception & ex) {
78 throw_init_ex(ex);
79 }
80 }
void get(const std::string &name, T &value)
Get value of object's attribute or relationship.
void throw_init_ex(dunedaq::conffwk::Exception &ex)
throw object initialisation exception (i.e.
Definition DalObject.cpp:74
void increment_read() noexcept
bool p_was_read
is true, if the object was read
ConfigObject p_obj
Config object used by given template object.
#define TLOG_DEBUG(lvl,...)
Definition Logging.hpp:112

◆ init() [2/2]

virtual void dunedaq::appmodel::WIBPulserSettings::init ( bool init_children)
protectedvirtual

Initialize object (method generated by genconffwk)

Parameters
init_childrenif true, initialize referenced objects

Implements dunedaq::conffwk::DalObject.

◆ print() [1/2]

void dunedaq::appmodel::WIBPulserSettings::print ( unsigned int offset,
bool print_header,
std::ostream & s ) const
virtual

Print details of the WIBPulserSettings object.

Parameters are:

Parameters
offsetnumber of spaces to shift object right (useful to print nested objects)
print_headerif false, do not print object header (to print attributes of base classes)
soutput stream

Implements dunedaq::conffwk::DalObject.

Definition at line 33 of file WIBPulserSettings.cpp.

34 {
35 check_init();
36
37 try {
38 const std::string str(indent+2, ' ');
39
40 if (print_header)
41 p_hdr(s, indent, s_class_name, "dunedaq::appmodel");
42
43
44 // print direct attributes
45
54 }
55 catch (dunedaq::conffwk::Exception & ex) {
57 }
58 }
void p_hdr(std::ostream &s, unsigned int indent, const std::string &cl, const char *nm=nullptr) const
print object headers
Definition DalObject.cpp:65
static void p_error(std::ostream &s, dunedaq::conffwk::Exception &ex)
print error text
Definition DalObject.cpp:59
void p_sv_attr(std::ostream &s, const std::string &str, const std::string &name, const T &val) noexcept
print single-value attribute

◆ print() [2/2]

virtual void dunedaq::appmodel::WIBPulserSettings::print ( unsigned int offset,
bool print_header,
std::ostream & s ) const
virtual

Print details of the WIBPulserSettings object.

Parameters are:

Parameters
offsetnumber of spaces to shift object right (useful to print nested objects)
print_headerif false, do not print object header (to print attributes of base classes)
soutput stream

Implements dunedaq::conffwk::DalObject.

◆ set_enabled_0() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_0 ( bool value)
inline

Set "enabled_0" attribute value. Enable WIB pulser for FEMB 0.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 132 of file WIBPulserSettings.hpp.

133 {
134 std::lock_guard scoped_lock(m_mutex);
135 check();
136 clear();
138 }
void set_by_val(const std::string &name, T value)
Set attribute value.

◆ set_enabled_0() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_0 ( bool value)
inline

Set "enabled_0" attribute value. Enable WIB pulser for FEMB 0.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 132 of file WIBPulserSettings.hpp.

133 {
134 std::lock_guard scoped_lock(m_mutex);
135 check();
136 clear();
138 }

◆ set_enabled_1() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_1 ( bool value)
inline

Set "enabled_1" attribute value. Enable WIB pulser for FEMB 1.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 165 of file WIBPulserSettings.hpp.

166 {
167 std::lock_guard scoped_lock(m_mutex);
168 check();
169 clear();
171 }

◆ set_enabled_1() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_1 ( bool value)
inline

Set "enabled_1" attribute value. Enable WIB pulser for FEMB 1.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 165 of file WIBPulserSettings.hpp.

166 {
167 std::lock_guard scoped_lock(m_mutex);
168 check();
169 clear();
171 }

◆ set_enabled_2() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_2 ( bool value)
inline

Set "enabled_2" attribute value. Enable WIB pulser for FEMB 2.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 198 of file WIBPulserSettings.hpp.

199 {
200 std::lock_guard scoped_lock(m_mutex);
201 check();
202 clear();
204 }

◆ set_enabled_2() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_2 ( bool value)
inline

Set "enabled_2" attribute value. Enable WIB pulser for FEMB 2.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 198 of file WIBPulserSettings.hpp.

199 {
200 std::lock_guard scoped_lock(m_mutex);
201 check();
202 clear();
204 }

◆ set_enabled_3() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_3 ( bool value)
inline

Set "enabled_3" attribute value. Enable WIB pulser for FEMB 3.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 231 of file WIBPulserSettings.hpp.

232 {
233 std::lock_guard scoped_lock(m_mutex);
234 check();
235 clear();
237 }

◆ set_enabled_3() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_enabled_3 ( bool value)
inline

Set "enabled_3" attribute value. Enable WIB pulser for FEMB 3.

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 231 of file WIBPulserSettings.hpp.

232 {
233 std::lock_guard scoped_lock(m_mutex);
234 check();
235 clear();
237 }

◆ set_pulse_dac() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_dac ( uint16_t value)
inline

Set "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 264 of file WIBPulserSettings.hpp.

265 {
266 std::lock_guard scoped_lock(m_mutex);
267 check();
268 clear();
270 }

◆ set_pulse_dac() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_dac ( uint16_t value)
inline

Set "pulse_dac" attribute value. WIB pulser DAC setting. 16 bits [0-65535].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 264 of file WIBPulserSettings.hpp.

265 {
266 std::lock_guard scoped_lock(m_mutex);
267 check();
268 clear();
270 }

◆ set_pulse_duration() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_duration ( uint32_t value)
inline

Set "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 363 of file WIBPulserSettings.hpp.

364 {
365 std::lock_guard scoped_lock(m_mutex);
366 check();
367 clear();
369 }

◆ set_pulse_duration() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_duration ( uint32_t value)
inline

Set "pulse_duration" attribute value. WIB pulser pulse duration in system clock units (16 ns). 27 bits [0-134217727].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 363 of file WIBPulserSettings.hpp.

364 {
365 std::lock_guard scoped_lock(m_mutex);
366 check();
367 clear();
369 }

◆ set_pulse_period() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_period ( uint32_t value)
inline

Set "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 297 of file WIBPulserSettings.hpp.

298 {
299 std::lock_guard scoped_lock(m_mutex);
300 check();
301 clear();
303 }

◆ set_pulse_period() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_period ( uint32_t value)
inline

Set "pulse_period" attribute value. WIB pulser period in ADC clock units (512 ns). 21 bits [0-2097151].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 297 of file WIBPulserSettings.hpp.

298 {
299 std::lock_guard scoped_lock(m_mutex);
300 check();
301 clear();
303 }

◆ set_pulse_phase() [1/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_phase ( uint8_t value)
inline

Set "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 330 of file WIBPulserSettings.hpp.

331 {
332 std::lock_guard scoped_lock(m_mutex);
333 check();
334 clear();
336 }

◆ set_pulse_phase() [2/2]

void dunedaq::appmodel::WIBPulserSettings::set_pulse_phase ( uint8_t value)
inline

Set "pulse_phase" attribute value. WIB pulser phase relative to digitization clock [0-31].

Parameters
valuenew attribute value
Exceptions
dunedaq::conffwk::Generic,dunedaq::conffwk::DeletedObject

Definition at line 330 of file WIBPulserSettings.hpp.

331 {
332 std::lock_guard scoped_lock(m_mutex);
333 check();
334 clear();
336 }

Friends And Related Symbol Documentation

◆ conffwk::Configuration

Definition at line 26 of file WIBPulserSettings.hpp.

◆ conffwk::DalFactory

conffwk::DalFactory
friend

Definition at line 28 of file WIBPulserSettings.hpp.

◆ conffwk::DalObject

Definition at line 27 of file WIBPulserSettings.hpp.

◆ conffwk::DalRegistry

Definition at line 29 of file WIBPulserSettings.hpp.

Member Data Documentation

◆ m_enabled_0

bool dunedaq::appmodel::WIBPulserSettings::m_enabled_0
private

Definition at line 75 of file WIBPulserSettings.hpp.

◆ m_enabled_1

bool dunedaq::appmodel::WIBPulserSettings::m_enabled_1
private

Definition at line 76 of file WIBPulserSettings.hpp.

◆ m_enabled_2

bool dunedaq::appmodel::WIBPulserSettings::m_enabled_2
private

Definition at line 77 of file WIBPulserSettings.hpp.

◆ m_enabled_3

bool dunedaq::appmodel::WIBPulserSettings::m_enabled_3
private

Definition at line 78 of file WIBPulserSettings.hpp.

◆ m_pulse_dac

uint16_t dunedaq::appmodel::WIBPulserSettings::m_pulse_dac
private

Definition at line 79 of file WIBPulserSettings.hpp.

◆ m_pulse_duration

uint32_t dunedaq::appmodel::WIBPulserSettings::m_pulse_duration
private

Definition at line 82 of file WIBPulserSettings.hpp.

◆ m_pulse_period

uint32_t dunedaq::appmodel::WIBPulserSettings::m_pulse_period
private

Definition at line 80 of file WIBPulserSettings.hpp.

◆ m_pulse_phase

uint8_t dunedaq::appmodel::WIBPulserSettings::m_pulse_phase
private

Definition at line 81 of file WIBPulserSettings.hpp.

◆ s_class_name

static const std::string & dunedaq::appmodel::WIBPulserSettings::s_class_name
static

The name of the configuration class.

Definition at line 41 of file WIBPulserSettings.hpp.

◆ s_enabled_0

static const std::string dunedaq::appmodel::WIBPulserSettings::s_enabled_0 = "enabled_0"
inlinestatic

Definition at line 89 of file WIBPulserSettings.hpp.

◆ s_enabled_1

static const std::string dunedaq::appmodel::WIBPulserSettings::s_enabled_1 = "enabled_1"
inlinestatic

Definition at line 90 of file WIBPulserSettings.hpp.

◆ s_enabled_2

static const std::string dunedaq::appmodel::WIBPulserSettings::s_enabled_2 = "enabled_2"
inlinestatic

Definition at line 91 of file WIBPulserSettings.hpp.

◆ s_enabled_3

static const std::string dunedaq::appmodel::WIBPulserSettings::s_enabled_3 = "enabled_3"
inlinestatic

Definition at line 92 of file WIBPulserSettings.hpp.

◆ s_pulse_dac

static const std::string dunedaq::appmodel::WIBPulserSettings::s_pulse_dac = "pulse_dac"
inlinestatic

Definition at line 93 of file WIBPulserSettings.hpp.

◆ s_pulse_duration

static const std::string dunedaq::appmodel::WIBPulserSettings::s_pulse_duration = "pulse_duration"
inlinestatic

Definition at line 96 of file WIBPulserSettings.hpp.

◆ s_pulse_period

static const std::string dunedaq::appmodel::WIBPulserSettings::s_pulse_period = "pulse_period"
inlinestatic

Definition at line 94 of file WIBPulserSettings.hpp.

◆ s_pulse_phase

static const std::string dunedaq::appmodel::WIBPulserSettings::s_pulse_phase = "pulse_phase"
inlinestatic

Definition at line 95 of file WIBPulserSettings.hpp.


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