13 event.getByToken(static_cast<const GTTokens*>(toks)->getAlgToken(), algs);
15 unsigned int wdPerBX = 6;
19 for(
int blk=0; blk<9; blk++) {
21 unsigned int blkID = blk*2+33;
23 unsigned int algOffset = (2*blk+1)/2;
24 algOffset = (algOffset%3)*192;
27 std::vector<uint32_t>
load;
31 for (
auto j = algs->
begin(
i); j != algs->
end(
i); ++j) {
33 for(
unsigned int wd=0; wd<wdPerBX; wd++) {
37 if( (blk+1)%3 > 0 || wd<4 ) {
39 unsigned int startAlg = wd*32+algOffset;
40 for(
unsigned bt=0; bt<32; bt++) {
43 if(j->getAlgoDecisionInitial(bt+startAlg)) word |= (0x1 << bt);
45 if(j->getAlgoDecisionInterm(bt+startAlg)) word |= (0x1 << bt);
47 if(j->getAlgoDecisionFinal(bt+startAlg)) word |= (0x1 << bt);
51 }
else if(blk==2 && (wd==4 || wd==5) ) {
54 if(wd==4) word |= (j->getL1MenuUUID() & 0xFFFFFFFF);
55 if(wd==5) word |= (j->getL1FirmwareUUID() & 0xFFFFFFFF);
60 if(j->getFinalOR()) word |= (0x1 << 16);
61 if(j->getFinalORVeto()) word |= (0x1 << 8);
62 if(j->getFinalORPreVeto()) word |= (0x1 << 0);
64 word |= (j->getPreScColumn() & 0xFF);
76 res.push_back(
Block(blkID, load));
const_iterator end(int bx) const
virtual Blocks pack(const edm::Event &, const PackerTokens *) override
std::vector< Block > Blocks
#define DEFINE_L1T_PACKER(type)
const_iterator begin(int bx) const