ITkPixV2 emulator with digital, analog, threshold scan and global/pixel tuning working + minor changes to the encoder
This introduces new library libItkpixv2Emu, which holds the core functionality of the emulator divided into 3 classes:
- Itkpixv2Emu: holds the top-level loop listening to commands & executing them
- Itkpixv2CommandInterpreter: parses the input command stream and forms it into concrete commands / addresses / payloads / ...
- Itkpixv2CommandExe: takes commands from the interpreter and does the appropriate action, sends data back to yarr
All the bells and whistles of register writing are implemented (single/multiple/pixel broadcasting), and so far the digital scan (generating ToT 8 in all pixels) is fully working through the scan console, using the newly introduced configs/controller/emuCfg_itkpixv2.json controller config. The controller itself is heavily adapted from the existing one for RD53A emulator. The emulator book-keeps active pixels at all times and updates the info after an appropriate pixel portal write.
Analog scan is working too, with preliminary DAC -> charge -> ToT calibrations.
Minor change occurred to the encoders as well: the hit map representation was changed from vector<vector<uint16_t>> to a templated 1-D std::array with overloaded access operator, mimicking the (col, row) access. Columns are stored after one another in the array. This structure is found in src/libUtil/include/ItkpixLayout.h. For the encoders, this is largely an internal change that has no effect on the actual way of using the tools in e. g. tests. Next planned change is to incorporate the compile/run time generated QCore encoding LUT instead of the enormous hard-coded array that is currently in use.