CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
HcalSourcePositionData Class Reference

#include <HcalSourcePositionData.h>

Public Member Functions

int driverId () const
 
void getDAQTimestamp (int &seconds, int &useconds) const
 
void getDriverTimestamp (int &seconds, int &useconds) const
 
 HcalSourcePositionData ()
 
int indexCounter () const
 
std::string lastCommand () const
 
std::string message () const
 
int messageCounter () const
 
int motorCurrent () const
 
int motorVoltage () const
 
int reelCounter () const
 
void set (int message_counter, int timestamp1_sec, int timestamp1_usec, int timestamp2_sec, int timestamp2_usec, int status, int index_counter, int reel_counter, int motor_current, int motor_voltage, int driver_id, int source_id, std::string tubeNameFromCoord, std::string tubeDescFromSD, std::string lastCommand, std::string message)
 
int sourceId () const
 
int speed () const
 
int status () const
 
std::string tubeDescriptionFromSD () const
 
int tubeId () const
 
std::string tubeNameFromCoord () const
 
 ~HcalSourcePositionData ()
 

Private Attributes

int driverId_
 
int indexCounter_
 
std::string lastCommand_
 
std::string message_
 
int messageCounter_
 
int motorCurrent_
 
int motorVoltage_
 
int reelCounter_
 
int sourceId_
 
int status_
 
int timestamp1_sec_
 
int timestamp1_usec_
 
int timestamp2_sec_
 
int timestamp2_usec_
 
std::string tubeDescriptionFromSD_
 
int tubeId_
 
std::string tubeNameFromCoord_
 

Detailed Description

Definition at line 8 of file HcalSourcePositionData.h.

Constructor & Destructor Documentation

◆ HcalSourcePositionData()

HcalSourcePositionData::HcalSourcePositionData ( )

Definition at line 6 of file HcalSourcePositionData.cc.

6  {
7  messageCounter_ = 0;
8  indexCounter_ = 0;
9  reelCounter_ = 0;
10  timestamp1_sec_ = 0;
11  timestamp1_usec_ = 0;
12  timestamp2_sec_ = 0;
13  timestamp2_usec_ = 0;
14  status_ = 0;
15  motorCurrent_ = 0;
16  motorVoltage_ = 0;
17  tubeId_ = -1;
18  driverId_ = -1;
19  sourceId_ = -1;
20  tubeNameFromCoord_ = "";
22  lastCommand_ = "";
23  message_ = "";
24 }

◆ ~HcalSourcePositionData()

HcalSourcePositionData::~HcalSourcePositionData ( )
inline

Definition at line 11 of file HcalSourcePositionData.h.

11 {}

Member Function Documentation

◆ driverId()

int HcalSourcePositionData::driverId ( ) const
inline

Definition at line 21 of file HcalSourcePositionData.h.

21 { return driverId_; }

References driverId_.

Referenced by operator<<().

◆ getDAQTimestamp()

void HcalSourcePositionData::getDAQTimestamp ( int &  seconds,
int &  useconds 
) const

Definition at line 65 of file HcalSourcePositionData.cc.

65  {
67  useconds = timestamp2_usec_;
68 }

References seconds().

Referenced by operator<<().

◆ getDriverTimestamp()

void HcalSourcePositionData::getDriverTimestamp ( int &  seconds,
int &  useconds 
) const

Definition at line 60 of file HcalSourcePositionData.cc.

60  {
62  useconds = timestamp1_usec_;
63 }

References seconds().

Referenced by operator<<().

◆ indexCounter()

int HcalSourcePositionData::indexCounter ( ) const
inline

Definition at line 15 of file HcalSourcePositionData.h.

15 { return indexCounter_; }

References indexCounter_.

Referenced by operator<<().

◆ lastCommand()

std::string HcalSourcePositionData::lastCommand ( ) const
inline

Definition at line 25 of file HcalSourcePositionData.h.

25 { return lastCommand_; }

References lastCommand_.

Referenced by operator<<().

◆ message()

std::string HcalSourcePositionData::message ( ) const
inline

Definition at line 26 of file HcalSourcePositionData.h.

26 { return message_; }

References message_.

Referenced by operator<<().

◆ messageCounter()

int HcalSourcePositionData::messageCounter ( ) const
inline

Definition at line 13 of file HcalSourcePositionData.h.

13 { return messageCounter_; }

References messageCounter_.

Referenced by operator<<().

◆ motorCurrent()

int HcalSourcePositionData::motorCurrent ( ) const
inline

Definition at line 17 of file HcalSourcePositionData.h.

17 { return motorCurrent_; }

References motorCurrent_.

Referenced by operator<<().

◆ motorVoltage()

int HcalSourcePositionData::motorVoltage ( ) const
inline

Definition at line 19 of file HcalSourcePositionData.h.

19 { return motorVoltage_; }

References motorVoltage_.

Referenced by operator<<().

◆ reelCounter()

int HcalSourcePositionData::reelCounter ( ) const
inline

Definition at line 16 of file HcalSourcePositionData.h.

16 { return reelCounter_; }

References reelCounter_.

Referenced by operator<<().

◆ set()

void HcalSourcePositionData::set ( int  message_counter,
int  timestamp1_sec,
int  timestamp1_usec,
int  timestamp2_sec,
int  timestamp2_usec,
int  status,
int  index_counter,
int  reel_counter,
int  motor_current,
int  motor_voltage,
int  driver_id,
int  source_id,
std::string  tubeNameFromCoord,
std::string  tubeDescFromSD,
std::string  lastCommand,
std::string  message 
)

Definition at line 26 of file HcalSourcePositionData.cc.

41  {
42  messageCounter_ = message_counter;
43  indexCounter_ = index_counter;
44  reelCounter_ = reel_counter;
45  timestamp1_sec_ = timestamp1_sec;
46  timestamp1_usec_ = timestamp1_usec;
47  timestamp2_sec_ = timestamp2_sec;
48  timestamp2_usec_ = timestamp2_usec;
49  status_ = status;
50  motorCurrent_ = motor_current;
51  motorVoltage_ = motor_voltage;
52  driverId_ = driver_id;
53  sourceId_ = source_id;
55  tubeDescriptionFromSD_ = tubeDescFromSD;
57  message_ = message;
58 }

References mps_update::status.

Referenced by hcaltb::HcalTBSourcePositionDataUnpacker::unpack().

◆ sourceId()

int HcalSourcePositionData::sourceId ( ) const
inline

Definition at line 22 of file HcalSourcePositionData.h.

22 { return sourceId_; }

References sourceId_.

Referenced by operator<<().

◆ speed()

int HcalSourcePositionData::speed ( ) const
inline

Definition at line 18 of file HcalSourcePositionData.h.

18 { return -1; } // no longer implemented

◆ status()

int HcalSourcePositionData::status ( ) const
inline

Definition at line 14 of file HcalSourcePositionData.h.

14 { return status_; }

References status_.

Referenced by operator<<().

◆ tubeDescriptionFromSD()

std::string HcalSourcePositionData::tubeDescriptionFromSD ( ) const
inline

Definition at line 24 of file HcalSourcePositionData.h.

24 { return tubeDescriptionFromSD_; }

References tubeDescriptionFromSD_.

Referenced by operator<<().

◆ tubeId()

int HcalSourcePositionData::tubeId ( ) const
inline

Definition at line 20 of file HcalSourcePositionData.h.

20 { return -1; } // no longer implemented

Referenced by operator<<().

◆ tubeNameFromCoord()

std::string HcalSourcePositionData::tubeNameFromCoord ( ) const
inline

Definition at line 23 of file HcalSourcePositionData.h.

23 { return tubeNameFromCoord_; }

References tubeNameFromCoord_.

Referenced by operator<<().

Member Data Documentation

◆ driverId_

int HcalSourcePositionData::driverId_
private

Definition at line 60 of file HcalSourcePositionData.h.

Referenced by driverId().

◆ indexCounter_

int HcalSourcePositionData::indexCounter_
private

Definition at line 50 of file HcalSourcePositionData.h.

Referenced by indexCounter().

◆ lastCommand_

std::string HcalSourcePositionData::lastCommand_
private

Definition at line 64 of file HcalSourcePositionData.h.

Referenced by lastCommand().

◆ message_

std::string HcalSourcePositionData::message_
private

Definition at line 65 of file HcalSourcePositionData.h.

Referenced by message().

◆ messageCounter_

int HcalSourcePositionData::messageCounter_
private

Definition at line 49 of file HcalSourcePositionData.h.

Referenced by messageCounter().

◆ motorCurrent_

int HcalSourcePositionData::motorCurrent_
private

Definition at line 57 of file HcalSourcePositionData.h.

Referenced by motorCurrent().

◆ motorVoltage_

int HcalSourcePositionData::motorVoltage_
private

Definition at line 58 of file HcalSourcePositionData.h.

Referenced by motorVoltage().

◆ reelCounter_

int HcalSourcePositionData::reelCounter_
private

Definition at line 51 of file HcalSourcePositionData.h.

Referenced by reelCounter().

◆ sourceId_

int HcalSourcePositionData::sourceId_
private

Definition at line 61 of file HcalSourcePositionData.h.

Referenced by sourceId().

◆ status_

int HcalSourcePositionData::status_
private

Definition at line 56 of file HcalSourcePositionData.h.

Referenced by status().

◆ timestamp1_sec_

int HcalSourcePositionData::timestamp1_sec_
private

Definition at line 52 of file HcalSourcePositionData.h.

◆ timestamp1_usec_

int HcalSourcePositionData::timestamp1_usec_
private

Definition at line 53 of file HcalSourcePositionData.h.

◆ timestamp2_sec_

int HcalSourcePositionData::timestamp2_sec_
private

Definition at line 54 of file HcalSourcePositionData.h.

◆ timestamp2_usec_

int HcalSourcePositionData::timestamp2_usec_
private

Definition at line 55 of file HcalSourcePositionData.h.

◆ tubeDescriptionFromSD_

std::string HcalSourcePositionData::tubeDescriptionFromSD_
private

Definition at line 63 of file HcalSourcePositionData.h.

Referenced by tubeDescriptionFromSD().

◆ tubeId_

int HcalSourcePositionData::tubeId_
private

Definition at line 59 of file HcalSourcePositionData.h.

◆ tubeNameFromCoord_

std::string HcalSourcePositionData::tubeNameFromCoord_
private

Definition at line 62 of file HcalSourcePositionData.h.

Referenced by tubeNameFromCoord().

HcalSourcePositionData::status_
int status_
Definition: HcalSourcePositionData.h:56
HcalSourcePositionData::message_
std::string message_
Definition: HcalSourcePositionData.h:65
HcalSourcePositionData::message
std::string message() const
Definition: HcalSourcePositionData.h:26
HcalSourcePositionData::messageCounter_
int messageCounter_
Definition: HcalSourcePositionData.h:49
HcalSourcePositionData::sourceId_
int sourceId_
Definition: HcalSourcePositionData.h:61
seconds
double seconds()
HcalSourcePositionData::lastCommand
std::string lastCommand() const
Definition: HcalSourcePositionData.h:25
HcalSourcePositionData::timestamp1_usec_
int timestamp1_usec_
Definition: HcalSourcePositionData.h:53
HcalSourcePositionData::motorVoltage_
int motorVoltage_
Definition: HcalSourcePositionData.h:58
HcalSourcePositionData::lastCommand_
std::string lastCommand_
Definition: HcalSourcePositionData.h:64
HcalSourcePositionData::driverId_
int driverId_
Definition: HcalSourcePositionData.h:60
HcalSourcePositionData::tubeNameFromCoord_
std::string tubeNameFromCoord_
Definition: HcalSourcePositionData.h:62
HcalSourcePositionData::motorCurrent_
int motorCurrent_
Definition: HcalSourcePositionData.h:57
HcalSourcePositionData::tubeId_
int tubeId_
Definition: HcalSourcePositionData.h:59
HcalSourcePositionData::reelCounter_
int reelCounter_
Definition: HcalSourcePositionData.h:51
HcalSourcePositionData::timestamp2_sec_
int timestamp2_sec_
Definition: HcalSourcePositionData.h:54
HcalSourcePositionData::timestamp1_sec_
int timestamp1_sec_
Definition: HcalSourcePositionData.h:52
HcalSourcePositionData::tubeDescriptionFromSD_
std::string tubeDescriptionFromSD_
Definition: HcalSourcePositionData.h:63
HcalSourcePositionData::timestamp2_usec_
int timestamp2_usec_
Definition: HcalSourcePositionData.h:55
HcalSourcePositionData::indexCounter_
int indexCounter_
Definition: HcalSourcePositionData.h:50
HcalSourcePositionData::status
int status() const
Definition: HcalSourcePositionData.h:14
HcalSourcePositionData::tubeNameFromCoord
std::string tubeNameFromCoord() const
Definition: HcalSourcePositionData.h:23