Changeset 10734
- Timestamp:
- 05/17/11 20:49:14 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/HeadersFTM.h
r10726 r10734 157 157 kMaxSequence = 0x1f, 158 158 kMaxDAC = 0xfff, 159 kMaxPixelIdx = 1439, 159 160 kMaskSettings = 0xf, 160 161 kMaskLEDs = 0xf, … … 226 227 void ToggleFTU(int i) { fActiveFTU[i/10] ^= (1<<(i%10)); } 227 228 228 void Enable(GeneralSettings type, bool enable) { 229 void Enable(GeneralSettings type, bool enable) 230 { 229 231 if (enable) 230 232 fGeneralSettings |= uint16_t(type); … … 233 235 234 236 bool IsEnabled(GeneralSettings type) { return fGeneralSettings&uint16_t(type); } 237 238 void EnablePixel(int idx, bool enable) 239 { 240 const int board = idx%40; 241 const int patch = (idx/40)/9; 242 const int pixel = (idx/40)%9; 243 244 uint16_t &pix = fBoard[board/10][board%10].fEnable[patch]; 245 246 if (enable) 247 pix |= (1<<pixel); 248 else 249 pix &= ~(1<<pixel); 250 } 235 251 236 252 uint8_t GetSequencePed() const { return (fTriggerSequence>>10)&0x1f; }
Note:
See TracChangeset
for help on using the changeset viewer.