Skip to content
Snippets Groups Projects
Commit 56f982b2 authored by Tamara Vazquez Schroeder's avatar Tamara Vazquez Schroeder
Browse files

Merge branch '21.0-AFPToF_pulseLength' into '21.0'

Add pulse length information to AFP time-of-flight

See merge request !6504

(cherry picked from commit 6cf4e1db [formerly 97a75554d63fa9a5ee4952bae5e8fe0947db2a58])

02271e02 AFPSOFT-25 Add information about pulse length in AFP time-of-flight detector
494d17df Updated documentation about pulse length of AFP time-of-flight detector.

Former-commit-id: 5ffccec9dbce89246105f993f8f8187e225f864f
parent 0c63d0ad
No related branches found
No related tags found
No related merge requests found
...@@ -64,8 +64,10 @@ namespace xAOD { ...@@ -64,8 +64,10 @@ namespace xAOD {
/// @brief Lenght of the signal pulse which is proportional to the signal /// @brief Lenght of the signal pulse which is proportional to the signal
/// amplitude /// amplitude
/// ///
/// The returned value is roughly lenght of the signal above /// The returned value is lenght of the signal above
/// threshold expressed in nanoseconds. /// threshold expressed in nanoseconds. Available values should be
/// multiples of 0.521. Pulse lenght of 1 nanosecond corresponds
/// roughtly to signal of about 67 mV.
float pulseLength() const; float pulseLength() const;
void setPulseLength(float pulseLength); void setPulseLength(float pulseLength);
......
...@@ -159,6 +159,7 @@ StatusCode AFP_ByteStream2RawCnv::fillCollection(const OFFLINE_FRAGMENTS_NAMESPA ...@@ -159,6 +159,7 @@ StatusCode AFP_ByteStream2RawCnv::fillCollection(const OFFLINE_FRAGMENTS_NAMESPA
ToFData.setHeader( m_wordReadout.getBits (23, 21) ); ToFData.setHeader( m_wordReadout.getBits (23, 21) );
ToFData.setEdge( m_wordReadout.getBits (20, 20) ); ToFData.setEdge( m_wordReadout.getBits (20, 20) );
ToFData.setChannel( m_wordReadout.getBits (19, 16) ); ToFData.setChannel( m_wordReadout.getBits (19, 16) );
ToFData.setPulseLength( m_wordReadout.getBits (15, 10) );
ToFData.setTime( m_wordReadout.getBits (9, 0) ); ToFData.setTime( m_wordReadout.getBits (9, 0) );
setDataHeader (&ToFData); setDataHeader (&ToFData);
......
...@@ -119,7 +119,7 @@ void AFP_Raw2DigiTool::newXAODHitToF (xAOD::AFPToFHitContainer* tofHitContainer, ...@@ -119,7 +119,7 @@ void AFP_Raw2DigiTool::newXAODHitToF (xAOD::AFPToFHitContainer* tofHitContainer,
const uint32_t hitLink = data.link(); const uint32_t hitLink = data.link();
const unsigned int robID = collection.robId(); const unsigned int robID = collection.robId();
xAODToFHit->setTime(data.time()*s_timeConversionFactor); xAODToFHit->setTime(data.time()*s_timeConversionFactor);
xAODToFHit->setPulseLength(0); // currently there is no information in raw data about pulse length xAODToFHit->setPulseLength(data.pulseLength()*s_pulseLengthFactor);
xAODToFHit->setHptdcChannel(data.channel()); xAODToFHit->setHptdcChannel(data.channel());
// set station ID // set station ID
......
...@@ -52,6 +52,11 @@ protected: ...@@ -52,6 +52,11 @@ protected:
/// The value of the factor is 25/1024 nanoseconds /// The value of the factor is 25/1024 nanoseconds
static constexpr double s_timeConversionFactor = 25./1024.; static constexpr double s_timeConversionFactor = 25./1024.;
/// @brief Factor converting pulse length to time
///
/// The value of the factor is 0.521 nanoseconds
static constexpr double s_pulseLengthFactor = 0.521;
/// @brief Function that transforms time-over-threshold to charge /// @brief Function that transforms time-over-threshold to charge
/// ///
/// Transformation function can be set in steering cards /// Transformation function can be set in steering cards
......
...@@ -32,6 +32,10 @@ public: ...@@ -32,6 +32,10 @@ public:
uint32_t time() const {return m_time;} uint32_t time() const {return m_time;}
void setTime(const uint32_t time) {m_time = time;} void setTime(const uint32_t time) {m_time = time;}
/// @copydoc AFP_ToFRawData::m_pulseLength
uint32_t pulseLength() const {return m_pulseLength;}
void setPulseLength(const uint32_t pulseLength) {m_pulseLength = pulseLength;}
private: private:
/// @brief Value of 9-11 most significant bits /// @brief Value of 9-11 most significant bits
/// ///
...@@ -61,5 +65,12 @@ private: ...@@ -61,5 +65,12 @@ private:
/// In the following record: `xxxx xxxx xxxx xxxx xxxx xxtt tttt tttt` /// In the following record: `xxxx xxxx xxxx xxxx xxxx xxtt tttt tttt`
/// it means bits marked with `t`. Contains information about time. /// it means bits marked with `t`. Contains information about time.
uint32_t m_time; uint32_t m_time;
/// @brief Value of 11-16 least significant bits
///
/// In the following record: `xxxx xxxx xxxx xxxx LLLL LLxx xxxx xxxx`
/// it means bits marked with `L`. Contains information how long
/// signal from the bar was above threshold.
uint32_t m_pulseLength;
}; };
#endif #endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment