mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-02-08 07:48:40 +01:00
Jf: Electron collection mode (#983)
* electron collection mode for jungfrau. also removing the config chip when using register command * collectionMode: HOLE/ELECTRON (enum)
This commit is contained in:
@@ -85,21 +85,7 @@ u_int32_t readRegister(u_int32_t offset) {
|
||||
}
|
||||
|
||||
void writeRegister(u_int32_t offset, u_int32_t data) {
|
||||
// if electron mode bit touched
|
||||
#ifdef JUNGFRAUD
|
||||
int electronCollectionModeChange = 0;
|
||||
if ((offset << MEM_MAP_SHIFT) == DAQ_REG) {
|
||||
if ((readRegister(offset) ^ data) & DAQ_ELCTRN_CLLCTN_MDE_MSK) {
|
||||
electronCollectionModeChange = 1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
bus_w(offset << MEM_MAP_SHIFT, data);
|
||||
#ifdef JUNGFRAUD
|
||||
if (electronCollectionModeChange) {
|
||||
configureChip();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
u_int32_t readRegister16(u_int32_t offset) {
|
||||
|
||||
Reference in New Issue
Block a user