mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-23 10:07:59 +02:00
clang format
This commit is contained in:
@ -92,7 +92,7 @@ patternParameters *setChipStatusRegisterPattern(int csr) {
|
||||
for (int i = 0; i < 8; i++)
|
||||
pat->word[iaddr++] = patword;
|
||||
//#This version of the serializer pushes in the MSB first (compatible with
|
||||
//the CSR bit numbering)
|
||||
// the CSR bit numbering)
|
||||
for (int ib = nbits - 1; ib >= 0; ib--) {
|
||||
if (csr & (1 << ib))
|
||||
patword = setBit(SIGNAL_serialIN, patword);
|
||||
|
@ -33,25 +33,27 @@
|
||||
#define SIGNAL_CHSclk (24)
|
||||
#define SIGNAL_exposing (25)
|
||||
|
||||
|
||||
//CHIP STARTUS REGISTER BITS
|
||||
// CHIP STARTUS REGISTER BITS
|
||||
#define CSR_spypads 0
|
||||
#define CSR_invpol 4
|
||||
#define CSR_dpulse 5
|
||||
#define CSR_interp 6
|
||||
#define CSR_invpol 4
|
||||
#define CSR_dpulse 5
|
||||
#define CSR_interp 6
|
||||
#define _CSR_C10pre 7 //#default, negative polarity
|
||||
#define CSR_pumprobe 8
|
||||
#define CSR_apulse 9
|
||||
#define CSR_C15sh 10
|
||||
#define CSR_C30sh 11 //#default
|
||||
#define CSR_C50sh 12
|
||||
#define CSR_C225ACsh 13 // Connects 225fF SHAPER AC cap (1: 225 to shaper, 225 to GND. 0: 450 to shaper)
|
||||
#define _CSR_C15pre 14 // negative polarity
|
||||
#define CSR_pumprobe 8
|
||||
#define CSR_apulse 9
|
||||
#define CSR_C15sh 10
|
||||
#define CSR_C30sh 11 //#default
|
||||
#define CSR_C50sh 12
|
||||
#define CSR_C225ACsh \
|
||||
13 // Connects 225fF SHAPER AC cap (1: 225 to shaper, 225 to GND. 0: 450 to
|
||||
// shaper)
|
||||
#define _CSR_C15pre 14 // negative polarity
|
||||
|
||||
#define CSR_default (1<<_CSR_C10pre )|(1<< CSR_C30sh)
|
||||
|
||||
#define GAIN_MASK ((1 << _CSR_C10pre) | ( 1 << CSR_C15sh) | (1 << CSR_C30sh) | (1 << CSR_C50sh) | (1 << CSR_C225ACsh) | ( 1 << _CSR_C15pre))
|
||||
#define CSR_default (1 << _CSR_C10pre) | (1 << CSR_C30sh)
|
||||
|
||||
#define GAIN_MASK \
|
||||
((1 << _CSR_C10pre) | (1 << CSR_C15sh) | (1 << CSR_C30sh) | \
|
||||
(1 << CSR_C50sh) | (1 << CSR_C225ACsh) | (1 << _CSR_C15pre))
|
||||
|
||||
int setBit(int ibit, int patword);
|
||||
int clearBit(int ibit, int patword);
|
||||
|
@ -283,7 +283,6 @@ u_int32_t getDetectorNumber() {
|
||||
return bus_r(MCB_SERIAL_NO_REG);
|
||||
}
|
||||
|
||||
|
||||
int getModuleId(int *ret, char *mess) {
|
||||
return ((bus_r(MOD_ID_REG) & MOD_ID_MSK) >> MOD_ID_OFST);
|
||||
}
|
||||
@ -543,18 +542,18 @@ int resetToDefaultDacs(int hardReset) {
|
||||
for (int i = 0; i < NDAC; ++i) {
|
||||
defaultDacValues[i] = vals[i];
|
||||
}
|
||||
const int vals_standard[] = SPECIAL_DEFAULT_STANDARD_DAC_VALS;
|
||||
const int vals_standard[] = SPECIAL_DEFAULT_STANDARD_DAC_VALS;
|
||||
for (int i = 0; i < NSPECIALDACS; ++i) {
|
||||
defaultDacValue_standard[i] = vals_standard[i];
|
||||
}
|
||||
}
|
||||
const int vals_fast[] = SPECIAL_DEFAULT_FAST_DAC_VALS;
|
||||
for (int i = 0; i < NSPECIALDACS; ++i) {
|
||||
defaultDacValue_fast[i] = vals_fast[i];
|
||||
}
|
||||
const int vals_highgain[] = SPECIAL_DEFAULT_HIGHGAIN_DAC_VALS;
|
||||
}
|
||||
const int vals_highgain[] = SPECIAL_DEFAULT_HIGHGAIN_DAC_VALS;
|
||||
for (int i = 0; i < NSPECIALDACS; ++i) {
|
||||
defaultDacValue_highgain[i] = vals_highgain[i];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// remember settings
|
||||
|
Reference in New Issue
Block a user