fdhwlib
2.0.25
|
#include <fe4timing.h>
It is necessary to synchronize all subsystems of the Auger experiment with a resolution in time of 100ns.
The time base of the FD system is defined by two long words with a resolution of one second and 50ns.
Every Second a strobe signal is trigged. Possible sources are (THIS HAS CHANGED FOR V4 - Till 2009-04-09)
The methods forceStrobe() immediately triggers the second strobe.
The electronic will automatically count the number of time atoms, where no normal operation was possible. This will allow to determine the exact observation period.
Changes:
Definition at line 56 of file fe4timing.h.
FE4timing::FE4timing | ( | hw4::SubrackAuger * | s | ) |
void FE4timing::disableDeadTimeCounter | ( | ) | [virtual] |
Disable the counters for veto- and dead-time.
Implements FEbaseTiming.
void FE4timing::disableSyncErr | ( | ) | [virtual] |
Reimplemented from FEbaseTiming.
void FE4timing::enableDeadTimeCounter | ( | ) | [virtual] |
Enable the counters for veto- and dead-time.
Before starting the data aquisition the veto- and and dead-time counters should be disabled and a reset should be performed. The value of the counters will be set to zero with the reset command. Directly after starting the data aquisition the inhibit is released and the counters should be enabled.
Note: If the dead-time counters are enabled before the inhibit is released the time between this two commands will be counted as dead-time.
Implements FEbaseTiming.
void FE4timing::enableSyncErr | ( | ) | [virtual] |
Reimplemented from FEbaseTiming.
void FE4timing::forceStrobe | ( | ) | [virtual] |
Implements FEbaseTiming.
void FE4timing::getActualTime | ( | FE4timeStamp * | t | ) |
Get the actual time from the FD Electronics.
t | Timestamp containing second and subsecond values |
void FE4timing::getActualTime | ( | unsigned long * | second, |
unsigned long * | subSecond | ||
) | [virtual] |
Get the actual time from the FD Electronics.
second | Value of the second counter |
subSecond | Value of the subsecond counter |
Implements FEbaseTiming.
void FE4timing::getDeadTime | ( | unsigned long * | high, |
unsigned long * | low | ||
) | [virtual] |
Read the dead time counter.
Implements FEbaseTiming.
void FE4timing::getDeadTime | ( | unsigned long long * | time | ) | [virtual] |
Read the dead time counter.
Implements FEbaseTiming.
void FE4timing::getRunTime | ( | unsigned long * | high, |
unsigned long * | low | ||
) | [virtual] |
Read the run time counter.
Reimplemented from FEbaseTiming.
void FE4timing::getRunTime | ( | unsigned long long * | time | ) | [virtual] |
Read the run time counter.
Reimplemented from FEbaseTiming.
unsigned long FE4timing::getSecond | ( | ) | [virtual] |
Read the second counter.
Note: This command can be used only in conjunction with getSubSecond. Every call of getSubSecond will copy both second and subsecond counter.
Implements FEbaseTiming.
int FE4timing::getStrobeSource | ( | ) | [virtual] |
Implements FEbaseTiming.
unsigned long FE4timing::getSubSecond | ( | ) | [virtual] |
The SubSecond field is divided in SubSecond1 (bit 24-11) and.
SubSecond2 (bit 10-0). SubSecond2 counts from 0..1999 with a resolution equal to 50ns. SubSecond1 counts from 0..9999 and has a resolution equal to 100us.
Implements FEbaseTiming.
void FE4timing::getVetoTime | ( | unsigned long * | high, |
unsigned long * | low | ||
) | [virtual] |
Read the veto time counter.
Implements FEbaseTiming.
void FE4timing::getVetoTime | ( | unsigned long long * | time | ) | [virtual] |
Read the veto time counter.
Implements FEbaseTiming.
bool FE4timing::isEnabledDeadTimeCounter | ( | ) | [virtual] |
Request the status of the veto- and dead-time counters.
Implements FEbaseTiming.
bool FE4timing::isEnabledSyncErr | ( | ) | [virtual] |
Reimplemented from FEbaseTiming.
void FE4timing::resetDeadTimeCounter | ( | ) | [virtual] |
Reset veto and dead time counter.
Implements FEbaseTiming.
unsigned long FE4timing::setActualTime | ( | ) | [virtual] |
Write the actual time to the second counter.
From the PC Clock the appropriate number of GPS seconds is calulated and writen in the "midle" of the (PC) second to the hardware register. The command returns the GPS second writen to the hardware.
Implements FEbaseTiming.
void FE4timing::setSecond | ( | unsigned long | sec | ) | [virtual] |
Write a certain value to the second counter register.
The functions takes into account, that the new value will be set with the next second strobe and always writes sec + 1 to the second counter.
Implements FEbaseTiming.
void FE4timing::setStrobeSource | ( | int | source | ) | [virtual] |
Implements FEbaseTiming.
int FE4timing::waitForSyncErr | ( | ) | [virtual] |
A synchronization error may occur in every FPGA.
All interrupt are collected in this function
Reimplemented from FEbaseTiming.
hw4::SubrackAuger* FE4timing::s [private] |
Definition at line 174 of file fe4timing.h.