commands code generation (#871)

* commands code generation  (#803)

* commands code generation for only frames command

* fix cmake file and add Caller files

* working exptime, fully extended commands file and its variants

* start adding template commands

* add INT_CMD_VEC_ID template

* add list command, generate multiple bins, format code

* reach 208 commands using the cpp macros

* add tests for command parser

* start adding tests for commands parser

* fix typo to use commands.yaml

* add more tests for command_parser

* add all template functions (up to 218 commands)

* finish template functions and add more CmdProxy.cpp functions (250+)

* 257 commands

* 300 commands the rest are very special commands

* add special commands without generation

* separate special functions from generated c++ file

* implementing one command for put and get (buggy)

* add infer action in a separate file

* generate header for special commands from yaml

* allow only 0 or 1 for bool inputs

* group all commands in gen_commands.py

* add help to gen_commands.py

* add autocomplete bash script

* autocompletion: add support for module levels and help

* remove debugging line

* add autocompletion, help to commands, change int [0,1] to bool

* copy tests for Caller.cpp. Tests pass

* update with the new developer branch changes

* fix errors after merging (there is problems with tests)

* fixed port/stopport in yaml (intput typo), added '_caller' to the test dac and test on chip dac command in global test for cmdcaller

* undo previous test simulator debug change

* add documentation for the generated code

* reducing the comment to be replaced in length so formatting does not split into 2 lines

* removed formatting specific style of C++11 in gen_commands.py to keep with the top level clang format of the project
* regeneratign code for commands

* automation generated

* Redirect deprecated commands (#872)

* working implementation, need to fix dac

* fixed deprecation redirect for dac command

* Detector specific autocomplete (#873)

* working implementation, need to fix dac

* fixed deprecation redirect for dac command

* detector specific completion for dac

* added autocomplete using detector specific

* fixed error when autocompleting partial words

* Generate commands/fix commands (#875)

* fix vm_a, im_a etc have deg Celsius suffix, also help missing or changed in some places

* dac: require det id for all, arg0 to be printed at output, help for onchip dac and dac, onchipdac: spacing

* getscan detid and blocking trigger help

* udp_Dstlist det_id fixed, but rx_id invalid

* cmdApp in line with cmdLineApp (missing version, receiver_id, not creating det object in help action

* added set_command to differentiate between check_det_id and require_det_id (mixed up), args: -1 needs to check for at least one argument

* reordering

* reordering and checked till integer_command_hex

* fixed a lot more commands

* fix caller tests for eiger

* changes to tests after Bechir left

* changing .cmd to .cmdcall for the caller commands

* fixed tests for caller, still warning for setexptime about cast input

* autocomplete ran

* add moench test

* regenerating autocomplete and commands

* fixing other things from merge conflicts (renaming slsDetectorDefs to defs in commands.yaml)

* formatting

* added code injection to help (#876)

* updated 3 commands to have get output that can be put into put (#877)

* updated some commands to have get output that can be put into put

* fix tests for clkdiv

* adding help to free (#878)

* removing old commands and renaming them, (also making it work for parameters command as it was still calling cmdproxy) (#879)

* More helpful error messages for unsupported actions (#880)

* removing old commands and renaming them, (also making it work for parameters command as it was still calling cmdproxy)

* Added specific help for unsupported actions

* fixed a vetofile get special exception message. more specific warning for special exception message instead of no function warning

* added condition checking true in exceptions for special message

---------
Co-authored-by: Bechir Brahem <bachbrahem@gmail.com>
Co-authored-by: Erik Frojdh <erik.frojdh@gmail.com>
Co-authored-by: Dhanya Thattil <dhanya.thattil@psi.ch>
This commit is contained in:
2023-12-13 14:43:38 +01:00
committed by GitHub
parent d72c9e29a4
commit ce7270e8a2
63 changed files with 180123 additions and 9134 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,878 @@
// This file is used as input to generate the caller class
#include "CmdParser.h"
#include "HelpDacs.h"
#include "sls/Detector.h"
#include <iostream>
#include <string>
#include <vector>
namespace sls {
class Caller {
public:
Caller(Detector *ptr) : det(ptr) {}
void call(const std::string &command,
const std::vector<std::string> &arguments, int detector_id,
int action, std::ostream &os = std::cout, int receiver_id = -1);
IpAddr getDstIpFromAuto();
IpAddr getSrcIpFromAuto();
UdpDestination getUdpEntry();
void GetLevelAndUpdateArgIndex(int action,
std::string levelSeparatedCommand,
int &level, int &iArg, size_t nGetArgs,
size_t nPutArgs);
void WrongNumberOfParameters(size_t expected);
template <typename V> std::string OutStringHex(const V &value) {
if (value.equal())
return ToStringHex(value.front());
return ToStringHex(value);
}
template <typename V> std::string OutStringHex(const V &value, int width) {
if (value.equal())
return ToStringHex(value.front(), width);
return ToStringHex(value, width);
}
template <typename V> std::string OutString(const Result<V> &value) {
if (value.equal())
return ToString(value.front());
return ToString(value);
}
template <typename V> std::string OutString(const V &value) {
return ToString(value);
}
template <typename V>
std::string OutString(const V &value, const std::string &unit) {
if (value.equal())
return ToString(value.front(), unit);
return ToString(value, unit);
}
std::vector<std::string> getAllCommands();
std::string list(int action);
std::string acquire(int action);
std::string activate(int action);
std::string adcclk(int action);
std::string adcenable(int action);
std::string adcenable10g(int action);
std::string adcindex(int action);
std::string adcinvert(int action);
std::string adclist(int action);
std::string adcname(int action);
std::string adcphase(int action);
std::string adcpipeline(int action);
std::string adcreg(int action);
std::string adcvpp(int action);
std::string apulse(int action);
std::string asamples(int action);
std::string autocompdisable(int action);
std::string badchannels(int action);
std::string blockingtrigger(int action);
std::string burstmode(int action);
std::string burstperiod(int action);
std::string bursts(int action);
std::string burstsl(int action);
std::string bustest(int action);
std::string cdsgain(int action);
std::string chipversion(int action);
std::string clearbit(int action);
std::string clearbusy(int action);
std::string clearroi(int action);
std::string clientversion(int action);
std::string clkdiv(int action);
std::string clkfreq(int action);
std::string clkphase(int action);
std::string column(int action);
std::string compdisabletime(int action);
std::string confadc(int action);
std::string config(int action);
std::string counters(int action);
std::string currentsource(int action);
std::string dac(int action);
std::string dacindex(int action);
std::string daclist(int action);
std::string dacname(int action);
std::string dacvalues(int action);
std::string datastream(int action);
std::string dbitclk(int action);
std::string dbitphase(int action);
std::string dbitpipeline(int action);
std::string defaultdac(int action);
std::string defaultpattern(int action);
std::string delay(int action);
std::string delayl(int action);
std::string detectorserverversion(int action);
std::string detsize(int action);
std::string diodelay(int action);
std::string dpulse(int action);
std::string dr(int action);
std::string drlist(int action);
std::string dsamples(int action);
std::string execcommand(int action);
std::string exptime(int action);
std::string exptime1(int action);
std::string exptime2(int action);
std::string exptime3(int action);
std::string exptimel(int action);
std::string extrastoragecells(int action);
std::string extsampling(int action);
std::string extsamplingsrc(int action);
std::string extsig(int action);
std::string fformat(int action);
std::string filtercells(int action);
std::string filterresistor(int action);
std::string findex(int action);
std::string firmwaretest(int action);
std::string firmwareversion(int action);
std::string fliprows(int action);
std::string flowcontrol10g(int action);
std::string fmaster(int action);
std::string fname(int action);
std::string foverwrite(int action);
std::string fpath(int action);
std::string framecounter(int action);
std::string frames(int action);
std::string framesl(int action);
std::string frametime(int action);
std::string free(int action);
std::string fwrite(int action);
std::string gaincaps(int action);
std::string gainmode(int action);
std::string gappixels(int action);
std::string gatedelay(int action);
std::string gatedelay1(int action);
std::string gatedelay2(int action);
std::string gatedelay3(int action);
std::string gates(int action);
std::string getbit(int action);
std::string hardwareversion(int action);
std::string highvoltage(int action);
std::string hostname(int action);
std::string im_a(int action);
std::string im_b(int action);
std::string im_c(int action);
std::string im_d(int action);
std::string im_io(int action);
std::string imagetest(int action);
std::string initialchecks(int action);
std::string inj_ch(int action);
std::string interpolation(int action);
std::string interruptsubframe(int action);
std::string kernelversion(int action);
std::string lastclient(int action);
std::string led(int action);
std::string lock(int action);
std::string master(int action);
std::string maxadcphaseshift(int action);
std::string maxclkphaseshift(int action);
std::string maxdbitphaseshift(int action);
std::string measuredperiod(int action);
std::string measuredsubperiod(int action);
std::string moduleid(int action);
std::string nextframenumber(int action);
std::string nmod(int action);
std::string numinterfaces(int action);
std::string overflow(int action);
std::string packageversion(int action);
std::string parallel(int action);
std::string parameters(int action);
std::string partialreset(int action);
std::string patfname(int action);
std::string patioctrl(int action);
std::string patlimits(int action);
std::string patloop(int action);
std::string patloop0(int action);
std::string patloop1(int action);
std::string patloop2(int action);
std::string patmask(int action);
std::string patnloop(int action);
std::string patnloop0(int action);
std::string patnloop1(int action);
std::string patnloop2(int action);
std::string patsetbit(int action);
std::string pattern(int action);
std::string patternstart(int action);
std::string patwait(int action);
std::string patwait0(int action);
std::string patwait1(int action);
std::string patwait2(int action);
std::string patwaittime(int action);
std::string patwaittime0(int action);
std::string patwaittime1(int action);
std::string patwaittime2(int action);
std::string patword(int action);
std::string pedestalmode(int action);
std::string period(int action);
std::string periodl(int action);
std::string polarity(int action);
std::string port(int action);
std::string powerchip(int action);
std::string powerindex(int action);
std::string powerlist(int action);
std::string powername(int action);
std::string powervalues(int action);
std::string programfpga(int action);
std::string pulse(int action);
std::string pulsechip(int action);
std::string pulsenmove(int action);
std::string pumpprobe(int action);
std::string quad(int action);
std::string ratecorr(int action);
std::string readnrows(int action);
std::string readout(int action);
std::string readoutspeed(int action);
std::string readoutspeedlist(int action);
std::string rebootcontroller(int action);
std::string reg(int action);
std::string resetdacs(int action);
std::string resetfpga(int action);
std::string roi(int action);
std::string romode(int action);
std::string row(int action);
std::string runclk(int action);
std::string runtime(int action);
std::string rx_arping(int action);
std::string rx_clearroi(int action);
std::string rx_dbitlist(int action);
std::string rx_dbitoffset(int action);
std::string rx_discardpolicy(int action);
std::string rx_fifodepth(int action);
std::string rx_frameindex(int action);
std::string rx_framescaught(int action);
std::string rx_framesperfile(int action);
std::string rx_hostname(int action);
std::string rx_jsonaddheader(int action);
std::string rx_jsonpara(int action);
std::string rx_lastclient(int action);
std::string rx_lock(int action);
std::string rx_missingpackets(int action);
std::string rx_padding(int action);
std::string rx_printconfig(int action);
std::string rx_realudpsocksize(int action);
std::string rx_roi(int action);
std::string rx_silent(int action);
std::string rx_start(int action);
std::string rx_status(int action);
std::string rx_stop(int action);
std::string rx_tcpport(int action);
std::string rx_threads(int action);
std::string rx_udpsocksize(int action);
std::string rx_version(int action);
std::string rx_zmqfreq(int action);
std::string rx_zmqhwm(int action);
std::string rx_zmqip(int action);
std::string rx_zmqport(int action);
std::string rx_zmqstartfnum(int action);
std::string rx_zmqstream(int action);
std::string samples(int action);
std::string savepattern(int action);
std::string scan(int action);
std::string scanerrmsg(int action);
std::string selinterface(int action);
std::string serialnumber(int action);
std::string setbit(int action);
std::string settings(int action);
std::string settingslist(int action);
std::string settingspath(int action);
std::string signalindex(int action);
std::string signallist(int action);
std::string signalname(int action);
std::string slowadc(int action);
std::string slowadcindex(int action);
std::string slowadclist(int action);
std::string slowadcname(int action);
std::string slowadcvalues(int action);
std::string start(int action);
std::string status(int action);
std::string stop(int action);
std::string stopport(int action);
std::string storagecell_delay(int action);
std::string storagecell_start(int action);
std::string subdeadtime(int action);
std::string subexptime(int action);
std::string sync(int action);
std::string syncclk(int action);
std::string temp_10ge(int action);
std::string temp_adc(int action);
std::string temp_control(int action);
std::string temp_dcdc(int action);
std::string temp_event(int action);
std::string temp_fpga(int action);
std::string temp_fpgaext(int action);
std::string temp_fpgafl(int action);
std::string temp_fpgafr(int action);
std::string temp_slowadc(int action);
std::string temp_sodl(int action);
std::string temp_sodr(int action);
std::string temp_threshold(int action);
std::string templist(int action);
std::string tempvalues(int action);
std::string tengiga(int action);
std::string threshold(int action);
std::string timing(int action);
std::string timinglist(int action);
std::string timingsource(int action);
std::string top(int action);
std::string transceiverenable(int action);
std::string trigger(int action);
std::string triggers(int action);
std::string triggersl(int action);
std::string trimbits(int action);
std::string trimen(int action);
std::string trimval(int action);
std::string tsamples(int action);
std::string txdelay(int action);
std::string txdelay_frame(int action);
std::string txdelay_left(int action);
std::string txdelay_right(int action);
std::string type(int action);
std::string udp_cleardst(int action);
std::string udp_dstip(int action);
std::string udp_dstip2(int action);
std::string udp_dstlist(int action);
std::string udp_dstmac(int action);
std::string udp_dstmac2(int action);
std::string udp_dstport(int action);
std::string udp_dstport2(int action);
std::string udp_firstdst(int action);
std::string udp_numdst(int action);
std::string udp_reconfigure(int action);
std::string udp_srcip(int action);
std::string udp_srcip2(int action);
std::string udp_srcmac(int action);
std::string udp_srcmac2(int action);
std::string udp_validate(int action);
std::string update(int action);
std::string updatedetectorserver(int action);
std::string updatekernel(int action);
std::string updatemode(int action);
std::string user(int action);
std::string v_a(int action);
std::string v_b(int action);
std::string v_c(int action);
std::string v_chip(int action);
std::string v_d(int action);
std::string v_io(int action);
std::string v_limit(int action);
std::string vchip_comp_adc(int action);
std::string vchip_comp_fe(int action);
std::string vchip_cs(int action);
std::string vchip_opa_1st(int action);
std::string vchip_opa_fd(int action);
std::string vchip_ref_comp_fe(int action);
std::string versions(int action);
std::string veto(int action);
std::string vetoalg(int action);
std::string vetofile(int action);
std::string vetophoton(int action);
std::string vetoref(int action);
std::string vetostream(int action);
std::string virtualFunction(int action);
std::string vm_a(int action);
std::string vm_b(int action);
std::string vm_c(int action);
std::string vm_d(int action);
std::string vm_io(int action);
std::string zmqhwm(int action);
std::string zmqip(int action);
std::string zmqport(int action);
std::vector<std::string> args;
std::string cmd;
Detector *det;
int det_id{-1};
int rx_id{-1};
private:
bool ReplaceIfDepreciated(std::string &command);
using FunctionMap = std::map<std::string, std::string (Caller::*)(int)>;
using StringMap = std::map<std::string, std::string>;
Detector *ptr; // pointer to the detector that executes the command
FunctionMap functions{
{"list", &Caller::list},
{"acquire", &Caller::acquire},
{"activate", &Caller::activate},
{"adcclk", &Caller::adcclk},
{"adcenable", &Caller::adcenable},
{"adcenable10g", &Caller::adcenable10g},
{"adcindex", &Caller::adcindex},
{"adcinvert", &Caller::adcinvert},
{"adclist", &Caller::adclist},
{"adcname", &Caller::adcname},
{"adcphase", &Caller::adcphase},
{"adcpipeline", &Caller::adcpipeline},
{"adcreg", &Caller::adcreg},
{"adcvpp", &Caller::adcvpp},
{"apulse", &Caller::apulse},
{"asamples", &Caller::asamples},
{"autocompdisable", &Caller::autocompdisable},
{"badchannels", &Caller::badchannels},
{"blockingtrigger", &Caller::blockingtrigger},
{"burstmode", &Caller::burstmode},
{"burstperiod", &Caller::burstperiod},
{"bursts", &Caller::bursts},
{"burstsl", &Caller::burstsl},
{"bustest", &Caller::bustest},
{"cdsgain", &Caller::cdsgain},
{"chipversion", &Caller::chipversion},
{"clearbit", &Caller::clearbit},
{"clearbusy", &Caller::clearbusy},
{"clearroi", &Caller::clearroi},
{"clientversion", &Caller::clientversion},
{"clkdiv", &Caller::clkdiv},
{"clkfreq", &Caller::clkfreq},
{"clkphase", &Caller::clkphase},
{"column", &Caller::column},
{"compdisabletime", &Caller::compdisabletime},
{"confadc", &Caller::confadc},
{"config", &Caller::config},
{"counters", &Caller::counters},
{"currentsource", &Caller::currentsource},
{"dac", &Caller::dac},
{"dacindex", &Caller::dacindex},
{"daclist", &Caller::daclist},
{"dacname", &Caller::dacname},
{"dacvalues", &Caller::dacvalues},
{"datastream", &Caller::datastream},
{"dbitclk", &Caller::dbitclk},
{"dbitphase", &Caller::dbitphase},
{"dbitpipeline", &Caller::dbitpipeline},
{"defaultdac", &Caller::defaultdac},
{"defaultpattern", &Caller::defaultpattern},
{"delay", &Caller::delay},
{"delayl", &Caller::delayl},
{"detectorserverversion", &Caller::detectorserverversion},
{"detsize", &Caller::detsize},
{"diodelay", &Caller::diodelay},
{"dpulse", &Caller::dpulse},
{"dr", &Caller::dr},
{"drlist", &Caller::drlist},
{"dsamples", &Caller::dsamples},
{"execcommand", &Caller::execcommand},
{"exptime", &Caller::exptime},
{"exptime1", &Caller::exptime1},
{"exptime2", &Caller::exptime2},
{"exptime3", &Caller::exptime3},
{"exptimel", &Caller::exptimel},
{"extrastoragecells", &Caller::extrastoragecells},
{"extsampling", &Caller::extsampling},
{"extsamplingsrc", &Caller::extsamplingsrc},
{"extsig", &Caller::extsig},
{"fformat", &Caller::fformat},
{"filtercells", &Caller::filtercells},
{"filterresistor", &Caller::filterresistor},
{"findex", &Caller::findex},
{"firmwaretest", &Caller::firmwaretest},
{"firmwareversion", &Caller::firmwareversion},
{"fliprows", &Caller::fliprows},
{"flowcontrol10g", &Caller::flowcontrol10g},
{"fmaster", &Caller::fmaster},
{"fname", &Caller::fname},
{"foverwrite", &Caller::foverwrite},
{"fpath", &Caller::fpath},
{"framecounter", &Caller::framecounter},
{"frames", &Caller::frames},
{"framesl", &Caller::framesl},
{"frametime", &Caller::frametime},
{"free", &Caller::free},
{"fwrite", &Caller::fwrite},
{"gaincaps", &Caller::gaincaps},
{"gainmode", &Caller::gainmode},
{"gappixels", &Caller::gappixels},
{"gatedelay", &Caller::gatedelay},
{"gatedelay1", &Caller::gatedelay1},
{"gatedelay2", &Caller::gatedelay2},
{"gatedelay3", &Caller::gatedelay3},
{"gates", &Caller::gates},
{"getbit", &Caller::getbit},
{"hardwareversion", &Caller::hardwareversion},
{"highvoltage", &Caller::highvoltage},
{"hostname", &Caller::hostname},
{"im_a", &Caller::im_a},
{"im_b", &Caller::im_b},
{"im_c", &Caller::im_c},
{"im_d", &Caller::im_d},
{"im_io", &Caller::im_io},
{"imagetest", &Caller::imagetest},
{"initialchecks", &Caller::initialchecks},
{"inj_ch", &Caller::inj_ch},
{"interpolation", &Caller::interpolation},
{"interruptsubframe", &Caller::interruptsubframe},
{"kernelversion", &Caller::kernelversion},
{"lastclient", &Caller::lastclient},
{"led", &Caller::led},
{"lock", &Caller::lock},
{"master", &Caller::master},
{"maxadcphaseshift", &Caller::maxadcphaseshift},
{"maxclkphaseshift", &Caller::maxclkphaseshift},
{"maxdbitphaseshift", &Caller::maxdbitphaseshift},
{"measuredperiod", &Caller::measuredperiod},
{"measuredsubperiod", &Caller::measuredsubperiod},
{"moduleid", &Caller::moduleid},
{"nextframenumber", &Caller::nextframenumber},
{"nmod", &Caller::nmod},
{"numinterfaces", &Caller::numinterfaces},
{"overflow", &Caller::overflow},
{"packageversion", &Caller::packageversion},
{"parallel", &Caller::parallel},
{"parameters", &Caller::parameters},
{"partialreset", &Caller::partialreset},
{"patfname", &Caller::patfname},
{"patioctrl", &Caller::patioctrl},
{"patlimits", &Caller::patlimits},
{"patloop", &Caller::patloop},
{"patloop0", &Caller::patloop0},
{"patloop1", &Caller::patloop1},
{"patloop2", &Caller::patloop2},
{"patmask", &Caller::patmask},
{"patnloop", &Caller::patnloop},
{"patnloop0", &Caller::patnloop0},
{"patnloop1", &Caller::patnloop1},
{"patnloop2", &Caller::patnloop2},
{"patsetbit", &Caller::patsetbit},
{"patternX", &Caller::pattern},
{"patternstart", &Caller::patternstart},
{"patwait", &Caller::patwait},
{"patwait0", &Caller::patwait0},
{"patwait1", &Caller::patwait1},
{"patwait2", &Caller::patwait2},
{"patwaittime", &Caller::patwaittime},
{"patwaittime0", &Caller::patwaittime0},
{"patwaittime1", &Caller::patwaittime1},
{"patwaittime2", &Caller::patwaittime2},
{"patword", &Caller::patword},
{"pedestalmode", &Caller::pedestalmode},
{"period", &Caller::period},
{"periodl", &Caller::periodl},
{"polarity", &Caller::polarity},
{"port", &Caller::port},
{"powerchip", &Caller::powerchip},
{"powerindex", &Caller::powerindex},
{"powerlist", &Caller::powerlist},
{"powername", &Caller::powername},
{"powervalues", &Caller::powervalues},
{"programfpga", &Caller::programfpga},
{"pulse", &Caller::pulse},
{"pulsechip", &Caller::pulsechip},
{"pulsenmove", &Caller::pulsenmove},
{"pumpprobe", &Caller::pumpprobe},
{"quad", &Caller::quad},
{"ratecorr", &Caller::ratecorr},
{"readnrows", &Caller::readnrows},
{"readout", &Caller::readout},
{"readoutspeed", &Caller::readoutspeed},
{"readoutspeedlist", &Caller::readoutspeedlist},
{"rebootcontroller", &Caller::rebootcontroller},
{"reg", &Caller::reg},
{"resetdacs", &Caller::resetdacs},
{"resetfpga", &Caller::resetfpga},
{"roi", &Caller::roi},
{"romode", &Caller::romode},
{"row", &Caller::row},
{"runclk", &Caller::runclk},
{"runtime", &Caller::runtime},
{"rx_arping", &Caller::rx_arping},
{"rx_clearroi", &Caller::rx_clearroi},
{"rx_dbitlist", &Caller::rx_dbitlist},
{"rx_dbitoffset", &Caller::rx_dbitoffset},
{"rx_discardpolicy", &Caller::rx_discardpolicy},
{"rx_fifodepth", &Caller::rx_fifodepth},
{"rx_frameindex", &Caller::rx_frameindex},
{"rx_framescaught", &Caller::rx_framescaught},
{"rx_framesperfile", &Caller::rx_framesperfile},
{"rx_hostname", &Caller::rx_hostname},
{"rx_jsonaddheader", &Caller::rx_jsonaddheader},
{"rx_jsonpara", &Caller::rx_jsonpara},
{"rx_lastclient", &Caller::rx_lastclient},
{"rx_lock", &Caller::rx_lock},
{"rx_missingpackets", &Caller::rx_missingpackets},
{"rx_padding", &Caller::rx_padding},
{"rx_printconfig", &Caller::rx_printconfig},
{"rx_realudpsocksize", &Caller::rx_realudpsocksize},
{"rx_roi", &Caller::rx_roi},
{"rx_silent", &Caller::rx_silent},
{"rx_start", &Caller::rx_start},
{"rx_status", &Caller::rx_status},
{"rx_stop", &Caller::rx_stop},
{"rx_tcpport", &Caller::rx_tcpport},
{"rx_threads", &Caller::rx_threads},
{"rx_udpsocksize", &Caller::rx_udpsocksize},
{"rx_version", &Caller::rx_version},
{"rx_zmqfreq", &Caller::rx_zmqfreq},
{"rx_zmqhwm", &Caller::rx_zmqhwm},
{"rx_zmqip", &Caller::rx_zmqip},
{"rx_zmqport", &Caller::rx_zmqport},
{"rx_zmqstartfnum", &Caller::rx_zmqstartfnum},
{"rx_zmqstream", &Caller::rx_zmqstream},
{"samples", &Caller::samples},
{"savepattern", &Caller::savepattern},
{"scan", &Caller::scan},
{"scanerrmsg", &Caller::scanerrmsg},
{"selinterface", &Caller::selinterface},
{"serialnumber", &Caller::serialnumber},
{"setbit", &Caller::setbit},
{"settings", &Caller::settings},
{"settingslist", &Caller::settingslist},
{"settingspath", &Caller::settingspath},
{"signalindex", &Caller::signalindex},
{"signallist", &Caller::signallist},
{"signalname", &Caller::signalname},
{"slowadc", &Caller::slowadc},
{"slowadcindex", &Caller::slowadcindex},
{"slowadclist", &Caller::slowadclist},
{"slowadcname", &Caller::slowadcname},
{"slowadcvalues", &Caller::slowadcvalues},
{"start", &Caller::start},
{"status", &Caller::status},
{"stop", &Caller::stop},
{"stopport", &Caller::stopport},
{"storagecell_delay", &Caller::storagecell_delay},
{"storagecell_start", &Caller::storagecell_start},
{"subdeadtime", &Caller::subdeadtime},
{"subexptime", &Caller::subexptime},
{"sync", &Caller::sync},
{"syncclk", &Caller::syncclk},
{"temp_10ge", &Caller::temp_10ge},
{"temp_adc", &Caller::temp_adc},
{"temp_control", &Caller::temp_control},
{"temp_dcdc", &Caller::temp_dcdc},
{"temp_event", &Caller::temp_event},
{"temp_fpga", &Caller::temp_fpga},
{"temp_fpgaext", &Caller::temp_fpgaext},
{"temp_fpgafl", &Caller::temp_fpgafl},
{"temp_fpgafr", &Caller::temp_fpgafr},
{"temp_slowadc", &Caller::temp_slowadc},
{"temp_sodl", &Caller::temp_sodl},
{"temp_sodr", &Caller::temp_sodr},
{"temp_threshold", &Caller::temp_threshold},
{"templist", &Caller::templist},
{"tempvalues", &Caller::tempvalues},
{"tengiga", &Caller::tengiga},
{"threshold", &Caller::threshold},
{"thresholdnotb", &Caller::threshold},
{"timing", &Caller::timing},
{"timinglist", &Caller::timinglist},
{"timingsource", &Caller::timingsource},
{"top", &Caller::top},
{"transceiverenable", &Caller::transceiverenable},
{"trigger", &Caller::trigger},
{"triggers", &Caller::triggers},
{"triggersl", &Caller::triggersl},
{"trimbits", &Caller::trimbits},
{"trimen", &Caller::trimen},
{"trimval", &Caller::trimval},
{"tsamples", &Caller::tsamples},
{"txdelay", &Caller::txdelay},
{"txdelay_frame", &Caller::txdelay_frame},
{"txdelay_left", &Caller::txdelay_left},
{"txdelay_right", &Caller::txdelay_right},
{"type", &Caller::type},
{"udp_cleardst", &Caller::udp_cleardst},
{"udp_dstip", &Caller::udp_dstip},
{"udp_dstip2", &Caller::udp_dstip2},
{"udp_dstlist", &Caller::udp_dstlist},
{"udp_dstmac", &Caller::udp_dstmac},
{"udp_dstmac2", &Caller::udp_dstmac2},
{"udp_dstport", &Caller::udp_dstport},
{"udp_dstport2", &Caller::udp_dstport2},
{"udp_firstdst", &Caller::udp_firstdst},
{"udp_numdst", &Caller::udp_numdst},
{"udp_reconfigure", &Caller::udp_reconfigure},
{"udp_srcip", &Caller::udp_srcip},
{"udp_srcip2", &Caller::udp_srcip2},
{"udp_srcmac", &Caller::udp_srcmac},
{"udp_srcmac2", &Caller::udp_srcmac2},
{"udp_validate", &Caller::udp_validate},
{"update", &Caller::update},
{"updatedetectorserver", &Caller::updatedetectorserver},
{"updatekernel", &Caller::updatekernel},
{"updatemode", &Caller::updatemode},
{"user", &Caller::user},
{"v_a", &Caller::v_a},
{"v_b", &Caller::v_b},
{"v_c", &Caller::v_c},
{"v_chip", &Caller::v_chip},
{"v_d", &Caller::v_d},
{"v_io", &Caller::v_io},
{"v_limit", &Caller::v_limit},
{"vchip_comp_adc", &Caller::vchip_comp_adc},
{"vchip_comp_fe", &Caller::vchip_comp_fe},
{"vchip_cs", &Caller::vchip_cs},
{"vchip_opa_1st", &Caller::vchip_opa_1st},
{"vchip_opa_fd", &Caller::vchip_opa_fd},
{"vchip_ref_comp_fe", &Caller::vchip_ref_comp_fe},
{"versions", &Caller::versions},
{"veto", &Caller::veto},
{"vetoalg", &Caller::vetoalg},
{"vetofile", &Caller::vetofile},
{"vetophoton", &Caller::vetophoton},
{"vetoref", &Caller::vetoref},
{"vetostream", &Caller::vetostream},
{"virtual", &Caller::virtualFunction},
{"vm_a", &Caller::vm_a},
{"vm_b", &Caller::vm_b},
{"vm_c", &Caller::vm_c},
{"vm_d", &Caller::vm_d},
{"vm_io", &Caller::vm_io},
{"zmqhwm", &Caller::zmqhwm},
{"zmqip", &Caller::zmqip},
{"zmqport", &Caller::zmqport}
};
StringMap depreciated_functions{
{"detectorversion", "firmwareversion"},
{"softwareversion", "detectorserverversion"},
{"receiverversion", "rx_version"},
{"detectornumber", "serialnumber"},
{"thisversion", "clientversion"},
{"detsizechan", "detsize"},
{"trimdir", "settingspath"},
{"settingsdir", "settingspath"},
{"flippeddatax", "fliprows"},
{"cycles", "triggers"},
{"cyclesl", "triggersl"},
{"clkdivider", "readoutspeed"},
{"speed", "readoutspeed"},
{"vhighvoltage", "highvoltage"},
{"digitest", "imagetest"},
{"filter", "filterresistor"},
{"readnlines", "readnrows"},
{"vtr", "vtrim"},
{"vrf", "vrpreamp"},
{"vrs", "vrshaper"},
{"vcall", "vcal"},
{"vis", "vishaper"},
{"vshaper", "vrshaper"},
{"vpreamp", "vrpreamp"},
{"vshaperneg", "vrshaper_n"},
{"viinsh", "vishaper"},
{"vpl", "vcal_n"},
{"vph", "vcal_p"},
{"vthreshold", "dac"},
{"vsvp", "dac"},
{"vsvn", "dac"},
{"vtrim", "dac"},
{"vrpreamp", "dac"},
{"vrshaper", "dac"},
{"vtgstv", "dac"},
{"vcmp_ll", "dac"},
{"vcmp_lr", "dac"},
{"vcal", "dac"},
{"vcmp_rl", "dac"},
{"vcmp_rr", "dac"},
{"rxb_rb", "dac"},
{"rxb_lb", "dac"},
{"vcp", "dac"},
{"vcn", "dac"},
{"vishaper", "dac"},
{"iodelay", "dac"},
{"vref_ds", "dac"},
{"vcascn_pb", "dac"},
{"vcascp_pb", "dac"},
{"vout_cm", "dac"},
{"vcasc_out", "dac"},
{"vin_cm", "dac"},
{"vref_comp", "dac"},
{"ib_test_c", "dac"},
{"vrshaper_n", "dac"},
{"vipre", "dac"},
{"vdcsh", "dac"},
{"vth1", "dac"},
{"vth2", "dac"},
{"vth3", "dac"},
{"vcal_n", "dac"},
{"vcal_p", "dac"},
{"vcassh", "dac"},
{"vcas", "dac"},
{"vicin", "dac"},
{"vipre_out", "dac"},
{"vref_h_adc", "dac"},
{"vb_comp_fe", "dac"},
{"vb_comp_adc", "dac"},
{"vcom_cds", "dac"},
{"vref_rstore", "dac"},
{"vb_opa_1st", "dac"},
{"vref_comp_fe", "dac"},
{"vcom_adc1", "dac"},
{"vref_prech", "dac"},
{"vref_l_adc", "dac"},
{"vref_cds", "dac"},
{"vb_cs", "dac"},
{"vb_opa_fd", "dac"},
{"vcom_adc2", "dac"},
{"vb_ds", "dac"},
{"vb_comp", "dac"},
{"vb_pixbuf", "dac"},
{"vin_com", "dac"},
{"vdd_prot", "dac"},
{"vbp_colbuf", "dac"},
{"vb_sda", "dac"},
{"vcasc_sfp", "dac"},
{"vipre_cds", "dac"},
{"ibias_sfp", "dac"},
{"defaultdacs", "resetdacs"},
{"busy", "clearbusy"},
{"receiver", "rx_status"},
{"framescaught", "rx_framescaught"},
{"startingfnum", "nextframenumber"},
{"detectorip", "udp_srcip"},
{"detectorip2", "udp_srcip2"},
{"detectormac", "udp_srcmac"},
{"detectormac2", "udp_srcmac2"},
{"rx_udpip", "udp_dstip"},
{"rx_udpip2", "udp_dstip2"},
{"rx_udpmac", "udp_dstmac"},
{"rx_udpmac2", "udp_dstmac2"},
{"rx_udpport", "udp_dstport"},
{"rx_udpport2", "udp_dstport2"},
{"flowcontrol_10g", "flowcontrol10g"},
{"txndelay_frame", "txdelay_frame"},
{"txndelay_left", "txdelay_left"},
{"txndelay_right", "txdelay_right"},
{"r_silent", "rx_silent"},
{"r_discardpolicy", "rx_discardpolicy"},
{"r_padding", "rx_padding"},
{"r_lock", "rx_lock"},
{"r_lastclient", "rx_lastclient"},
{"fileformat", "fformat"},
{"outdir", "fpath"},
{"index", "findex"},
{"enablefwrite", "fwrite"},
{"masterfile", "fmaster"},
{"overwrite", "foverwrite"},
{"r_framesperfile", "rx_framesperfile"},
{"r_readfreq", "rx_zmqfreq"},
{"rx_readfreq", "rx_zmqfreq"},
{"rx_datastream", "rx_zmqstream"},
{"resmat", "partialreset"},
{"storagecells", "extrastoragecells"},
{"auto_comp_disable", "autocompdisable"},
{"comp_disable_time", "compdisabletime"},
{"adc", "slowadc"},
{"flags", "romode"},
{"i_a", "im_a"},
{"i_b", "im_b"},
{"i_c", "im_c"},
{"i_d", "im_d"},
{"i_io", "im_io"},
{"copydetectorserver", "updatedetectorserver"},
{"nframes", "framecounter"},
{"now", "runtime"},
{"timestamp", "frametime"},
{"frameindex", "rx_frameindex"},
};
};
} // namespace sls

File diff suppressed because it is too large Load Diff

View File

@@ -1,22 +1,12 @@
// SPDX-License-Identifier: LGPL-3.0-or-other
// Copyright (C) 2021 Contributors to the SLS Detector Package
/*
This file is used to generate the command line binaries
(sls_detector_get/put/acquire/help). By defines in CMake
we get the different files.
*/
#include "sls/Detector.h"
#include "Caller.h"
#include "CmdParser.h"
#include "CmdProxy.h"
#include "sls/sls_detector_defs.h"
#include "inferAction.h"
#include "sls/Detector.h"
#include "sls/logger.h"
#include "sls/versionAPI.h"
#include <cstring> //strcmp
#include <iostream>
int main(int argc, char *argv[]) {
// To genereate sepereate binaries for put, get, acquire and help
#ifdef PUT
int action = slsDetectorDefs::PUT_ACTION;
@@ -33,6 +23,9 @@ int main(int argc, char *argv[]) {
#ifdef HELP
int action = slsDetectorDefs::HELP_ACTION;
#endif
#ifdef INFER
int action = -1;
#endif
// Check for --version in the arguments
for (int i = 1; i < argc; ++i) {
@@ -45,14 +38,12 @@ int main(int argc, char *argv[]) {
sls::CmdParser parser;
parser.Parse(argc, argv);
// If we called sls_detector_acquire, add the acquire command
if (action == slsDetectorDefs::READOUT_ACTION)
parser.setCommand("acquire");
if (parser.isHelp())
action = slsDetectorDefs::HELP_ACTION;
else {
// Free shared memory should work also without a detector
// if we have an option for verify in the detector constructor
// we could avoid this but clutter the code
@@ -65,22 +56,30 @@ int main(int argc, char *argv[]) {
}
}
// prevent mem size check
if (parser.command() == "config" && action == slsDetectorDefs::PUT_ACTION) {
sls::freeSharedMemory(parser.multi_id());
}
sls::InferAction inferAction = sls::InferAction();
try {
std::unique_ptr<sls::Detector> det{nullptr};
if (action != slsDetectorDefs::HELP_ACTION) {
det = sls::make_unique<sls::Detector>(parser.multi_id());
if (action == -1) {
action = inferAction.infer(parser);
std::string actionString =
(action == slsDetectorDefs::GET_ACTION) ? "GET" : "PUT";
std::cout << "inferred action: " << actionString << std::endl;
}
sls::CmdProxy proxy(det.get());
proxy.Call(parser.command(), parser.arguments(), parser.detector_id(),
action, std::cout, parser.receiver_id());
} catch (const sls::RuntimeError &e) {
std::unique_ptr<sls::Detector> d{nullptr};
if (action != slsDetectorDefs::HELP_ACTION) {
d = sls::make_unique<sls::Detector>(parser.multi_id());
}
sls::Caller c(d.get());
c.call(parser.command(), parser.arguments(), parser.detector_id(),
action, std::cout, parser.receiver_id());
} catch (sls::RuntimeError &e) {
exit(EXIT_FAILURE);
}
exit(EXIT_SUCCESS);
}

View File

@@ -20,7 +20,6 @@ reason that the header file is not exposed.
#include <vector>
namespace sls {
class CmdParser {
public:
void Parse(int argc, const char *const argv[]);

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -4,7 +4,7 @@
#include "sls/detectorData.h"
#include "CmdParser.h"
#include "CmdProxy.h"
#include "Caller.h"
#include "CtbConfig.h"
#include "DetectorImpl.h"
#include "Module.h"
@@ -91,11 +91,11 @@ void Detector::loadParameters(const std::string &fname) {
}
void Detector::loadParameters(const std::vector<std::string> &parameters) {
CmdProxy proxy(this);
Caller caller(this);
CmdParser parser;
for (const auto &current_line : parameters) {
parser.Parse(current_line);
proxy.Call(parser.command(), parser.arguments(), parser.detector_id(),
caller.call(parser.command(), parser.arguments(), parser.detector_id(),
defs::PUT_ACTION, std::cout, parser.receiver_id());
}
}

View File

@@ -0,0 +1,319 @@
// SPDX-License-Identifier: LGPL-3.0-or-other
// Copyright (C) 2021 Contributors to the SLS Detector Package
#include "sls/string_utils.h"
#include "sls/sls_detector_defs.h"
#include <sstream>
namespace sls {
std::string GetHelpDac(std::string dac) {
if (sls::is_int(dac)) {
return std::string("[dac name] [dac or mV value] [(optional unit) mV] "
"\n\t[Ctb] Use dac index for dac name.");
}
if (dac == "vthreshold") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger][Mythen3] "
"Detector threshold voltage for single photon counters.\n\t[Eiger] "
"Sets vcmp_ll, vcmp_lr, vcmp_rl, vcmp_rr and vcp to the same "
"value. \n\t[Mythen3] Sets vth1, vth2 and vth3 to the same value "
"for enabled counters.");
}
if (dac == "vsvp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? ");
}
if (dac == "vsvn") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define "
"feedback resistance of the first shaper");
}
if (dac == "vtrim") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? "
"\n\t[Mythen3] Dac for the voltage defining the trim bit size.");
}
if (dac == "vrpreamp") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define the "
"preamplifier feedback resistance.");
}
if (dac == "vrshaper") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define "
"feedback resistance of the first shaper");
}
if (dac == "vtgstv") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_ll") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_lr") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcal") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_rl") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_rr") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "rxb_rb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "rxb_lb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcn") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vishaper") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "iodelay") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vref_ds") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard][Jungfrau] Dac for ??");
}
if (dac == "vcascn_pb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vcascp_pb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vout_cm") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 5");
}
if (dac == "vcasc_out") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vin_cm") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 2");
}
if (dac == "vref_comp") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard][Jungfrau] Dac for ??");
}
if (dac == "ib_test_c") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vrshaper_n") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] voltage to "
"define feedback resistance of the second shaper.");
}
if (dac == "vipre") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"preamplifier's input transistor current.\n\t[Moench] Dac for 1");
}
if (dac == "vdcsh") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"reference (DC) voltage for the shaper.");
}
if (dac == "vth1") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for first "
"detector threshold voltage. Overwrites even if counter disabled.");
}
if (dac == "vth2") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for "
"second detector threshold voltage. Overwrites even if counter "
"disabled.");
}
if (dac == "vth3") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for third "
"detector threshold voltage. Overwrites even if counter disabled.");
}
if (dac == "vcal_n") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"low voltage for analog pulsing.");
}
if (dac == "vcal_p") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"high voltage for analog pulsing.");
}
if (dac == "vcassh") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"shaper's cascode voltage.");
}
if (dac == "vcas") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"preamplifier's cascode voltage.");
}
if (dac == "vicin") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"bias current for the comparator.");
}
if (dac == "vipre_out") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for "
"preamplifier's output transistor current.");
}
if (dac == "vref_h_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage high of ADC.");
}
if (dac == "vb_comp_fe") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"comparator current of analogue front end.");
}
if (dac == "vb_comp_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"comparator current of ADC.");
}
if (dac == "vcom_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of CDS stage.");
}
if (dac == "vref_rstore") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard2] Dac for reference charging voltage "
"of temparory storage cell in high gain.");
}
if (dac == "vb_opa_1st") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] dac dac for "
"opa current for driving the other DACs in chip.");
}
if (dac == "vref_comp_fe") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage of the comparator of analogue front end.");
}
if (dac == "vcom_adc1") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of ADC DAC bank 1.");
}
if (dac == "vref_prech") {
return std::string(
"[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard2][Jungfrau] "
"Dac for reference votlage for precharing the preamplifier.");
}
if (dac == "vref_l_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage low for ADC.");
}
if (dac == "vref_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage of CDS applied to the temporary storage cell in "
"medium and low gain.");
}
if (dac == "vb_cs") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"current injection into preamplifier.");
}
if (dac == "vb_opa_fd") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"current for CDS opa stage.");
}
if (dac == "vcom_adc2") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of ADC DAC bank 2.");
}
if (dac == "vb_ds") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vb_comp") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vb_pixbuf") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vin_com") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vdd_prot") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vbp_colbuf") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 0");
}
if (dac == "vb_sda") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 3");
}
if (dac == "vcasc_sfp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 4");
}
if (dac == "vipre_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 6");
}
if (dac == "ibias_sfp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 7");
}
// clang-format off
if (dac == "vtgstv") { return std::string(""); }
// clang-format on
throw sls::RuntimeError("Unknown dac command");
}
std::string GetHelpDacWrapper(const std::string &cmd,
const std::vector<std::string> &args) {
std::ostringstream os;
os << cmd << ' ';
if (args.size() == 0) {
os << GetHelpDac(std::to_string(0)) << '\n';
} else {
os << args[0] << ' ' << GetHelpDac(args[0]) << '\n';
}
return os.str();
}
} // namespace sls

View File

@@ -1,305 +1,13 @@
// SPDX-License-Identifier: LGPL-3.0-or-other
// Copyright (C) 2021 Contributors to the SLS Detector Package
#include "sls/string_utils.h"
#include <string>
#include <vector>
namespace sls {
std::string GetHelpDac(std::string dac) {
if (sls::is_int(dac)) {
return std::string("[dac name] [dac or mV value] [(optional unit) mV] "
"\n\t[Ctb] Use dac index for dac name.");
}
if (dac == "vthreshold") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger][Mythen3] "
"Detector threshold voltage for single photon counters.\n\t[Eiger] "
"Sets vcmp_ll, vcmp_lr, vcmp_rl, vcmp_rr and vcp to the same "
"value. \n\t[Mythen3] Sets vth1, vth2 and vth3 to the same value "
"for enabled counters.");
}
if (dac == "vsvp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? ");
}
if (dac == "vsvn") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define "
"feedback resistance of the first shaper");
}
if (dac == "vtrim") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ?? "
"\n\t[Mythen3] Dac for the voltage defining the trim bit size.");
}
if (dac == "vrpreamp") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define the "
"preamplifier feedback resistance.");
}
if (dac == "vrshaper") {
return std::string("[dac or mV value][(optional unit) mV] \n\t[Eiger] "
"Dac for ?? \n\t[Mythen3] voltage to define "
"feedback resistance of the first shaper");
}
if (dac == "vtgstv") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_ll") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_lr") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcal") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_rl") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcmp_rr") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "rxb_rb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "rxb_lb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vcn") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vishaper") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "iodelay") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Eiger] Dac for ??");
}
if (dac == "vref_ds") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard][Jungfrau] Dac for ??");
}
if (dac == "vcascn_pb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vcascp_pb") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vout_cm") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 5");
}
if (dac == "vcasc_out") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vin_cm") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard] Dac for ??\n\t[Moench] Dac for 2");
}
if (dac == "vref_comp") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard][Jungfrau] Dac for ??");
}
if (dac == "ib_test_c") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard] Dac for ??");
}
if (dac == "vrshaper_n") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] voltage to "
"define feedback resistance of the second shaper.");
}
if (dac == "vipre") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"preamplifier's input transistor current.\n\t[Moench] Dac for 1");
}
if (dac == "vdcsh") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"reference (DC) voltage for the shaper.");
}
if (dac == "vth1") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for first "
"detector threshold voltage. Overwrites even if counter disabled.");
}
if (dac == "vth2") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for "
"second detector threshold voltage. Overwrites even if counter "
"disabled.");
}
if (dac == "vth3") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for third "
"detector threshold voltage. Overwrites even if counter disabled.");
}
if (dac == "vcal_n") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"low voltage for analog pulsing.");
}
if (dac == "vcal_p") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"high voltage for analog pulsing.");
}
if (dac == "vcassh") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"shaper's cascode voltage.");
}
if (dac == "vcas") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"preamplifier's cascode voltage.");
}
if (dac == "vicin") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for the "
"bias current for the comparator.");
}
if (dac == "vipre_out") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Mythen3] Dac for "
"preamplifier's output transistor current.");
}
if (dac == "vref_h_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage high of ADC.");
}
if (dac == "vb_comp_fe") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"comparator current of analogue front end.");
}
if (dac == "vb_comp_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"comparator current of ADC.");
}
if (dac == "vcom_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of CDS stage.");
}
if (dac == "vref_rstore") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard2] Dac for reference charging voltage "
"of temparory storage cell in high gain.");
}
if (dac == "vb_opa_1st") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] dac dac for "
"opa current for driving the other DACs in chip.");
}
if (dac == "vref_comp_fe") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage of the comparator of analogue front end.");
}
if (dac == "vcom_adc1") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of ADC DAC bank 1.");
}
if (dac == "vref_prech") {
return std::string(
"[dac or mV value][(optional unit) mV] "
"\n\t[Gotthard2][Jungfrau] "
"Dac for reference votlage for precharing the preamplifier.");
}
if (dac == "vref_l_adc") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage low for ADC.");
}
if (dac == "vref_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"reference voltage of CDS applied to the temporary storage cell in "
"medium and low gain.");
}
if (dac == "vb_cs") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"current injection into preamplifier.");
}
if (dac == "vb_opa_fd") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"current for CDS opa stage.");
}
if (dac == "vcom_adc2") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Gotthard2] Dac for "
"common mode voltage of ADC DAC bank 2.");
}
if (dac == "vb_ds") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vb_comp") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vb_pixbuf") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vin_com") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vdd_prot") {
return std::string("[dac or mV value][(optional unit) mV] "
"\n\t[Jungfrau] Dac for ??");
}
if (dac == "vbp_colbuf") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 0");
}
if (dac == "vb_sda") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 3");
}
if (dac == "vcasc_sfp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 4");
}
if (dac == "vipre_cds") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 6");
}
if (dac == "ibias_sfp") {
return std::string(
"[dac or mV value][(optional unit) mV] \n\t[Moench] Dac for 7");
}
std::string GetHelpDac(std::string dac);
// clang-format off
if (dac == "vtgstv") { return std::string(""); }
// clang-format on
throw sls::RuntimeError("Unknown dac command");
}
std::string GetHelpDacWrapper(const std::string &cmd,
const std::vector<std::string> &args);
} // namespace sls

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,681 @@
#include "CmdParser.h"
#include <iostream>
#include <map>
#include <vector>
namespace sls {
class InferAction {
public:
InferAction() {}
int infer(sls::CmdParser &parser, std::ostream &os = std::cout);
std::vector<std::string> args;
std::string cmd;
// generated functions
int acquire();
int activate();
int adcclk();
int adcenable();
int adcenable10g();
int adcindex();
int adcinvert();
int adclist();
int adcname();
int adcphase();
int adcpipeline();
int adcreg();
int adcvpp();
int apulse();
int asamples();
int autocompdisable();
int badchannels();
int blockingtrigger();
int burstmode();
int burstperiod();
int bursts();
int burstsl();
int bustest();
int cdsgain();
int chipversion();
int clearbit();
int clearbusy();
int clearroi();
int clientversion();
int clkdiv();
int clkfreq();
int clkphase();
int column();
int compdisabletime();
int confadc();
int config();
int counters();
int currentsource();
int dac();
int dacindex();
int daclist();
int dacname();
int dacvalues();
int datastream();
int dbitclk();
int dbitphase();
int dbitpipeline();
int defaultdac();
int defaultpattern();
int delay();
int delayl();
int detectorserverversion();
int detsize();
int diodelay();
int dpulse();
int dr();
int drlist();
int dsamples();
int execcommand();
int exptime();
int exptime1();
int exptime2();
int exptime3();
int exptimel();
int extrastoragecells();
int extsampling();
int extsamplingsrc();
int extsig();
int fformat();
int filtercells();
int filterresistor();
int findex();
int firmwaretest();
int firmwareversion();
int fliprows();
int flowcontrol10g();
int fmaster();
int fname();
int foverwrite();
int fpath();
int framecounter();
int frames();
int framesl();
int frametime();
int free();
int fwrite();
int gaincaps();
int gainmode();
int gappixels();
int gatedelay();
int gatedelay1();
int gatedelay2();
int gatedelay3();
int gates();
int getbit();
int hardwareversion();
int highvoltage();
int hostname();
int im_a();
int im_b();
int im_c();
int im_d();
int im_io();
int imagetest();
int initialchecks();
int inj_ch();
int interpolation();
int interruptsubframe();
int kernelversion();
int lastclient();
int led();
int lock();
int master();
int maxadcphaseshift();
int maxclkphaseshift();
int maxdbitphaseshift();
int measuredperiod();
int measuredsubperiod();
int moduleid();
int nextframenumber();
int nmod();
int numinterfaces();
int overflow();
int packageversion();
int parallel();
int parameters();
int partialreset();
int patfname();
int patioctrl();
int patlimits();
int patloop();
int patloop0();
int patloop1();
int patloop2();
int patmask();
int patnloop();
int patnloop0();
int patnloop1();
int patnloop2();
int patsetbit();
int pattern();
int patternstart();
int patwait();
int patwait0();
int patwait1();
int patwait2();
int patwaittime();
int patwaittime0();
int patwaittime1();
int patwaittime2();
int patword();
int pedestalmode();
int period();
int periodl();
int polarity();
int port();
int powerchip();
int powerindex();
int powerlist();
int powername();
int powervalues();
int programfpga();
int pulse();
int pulsechip();
int pulsenmove();
int pumpprobe();
int quad();
int ratecorr();
int readnrows();
int readout();
int readoutspeed();
int readoutspeedlist();
int rebootcontroller();
int reg();
int resetdacs();
int resetfpga();
int roi();
int romode();
int row();
int runclk();
int runtime();
int rx_arping();
int rx_clearroi();
int rx_dbitlist();
int rx_dbitoffset();
int rx_discardpolicy();
int rx_fifodepth();
int rx_frameindex();
int rx_framescaught();
int rx_framesperfile();
int rx_hostname();
int rx_jsonaddheader();
int rx_jsonpara();
int rx_lastclient();
int rx_lock();
int rx_missingpackets();
int rx_padding();
int rx_printconfig();
int rx_realudpsocksize();
int rx_roi();
int rx_silent();
int rx_start();
int rx_status();
int rx_stop();
int rx_tcpport();
int rx_threads();
int rx_udpsocksize();
int rx_version();
int rx_zmqfreq();
int rx_zmqhwm();
int rx_zmqip();
int rx_zmqport();
int rx_zmqstartfnum();
int rx_zmqstream();
int samples();
int savepattern();
int scan();
int scanerrmsg();
int selinterface();
int serialnumber();
int setbit();
int settings();
int settingslist();
int settingspath();
int signalindex();
int signallist();
int signalname();
int slowadc();
int slowadcindex();
int slowadclist();
int slowadcname();
int slowadcvalues();
int start();
int status();
int stop();
int stopport();
int storagecell_delay();
int storagecell_start();
int subdeadtime();
int subexptime();
int sync();
int syncclk();
int temp_10ge();
int temp_adc();
int temp_control();
int temp_dcdc();
int temp_event();
int temp_fpga();
int temp_fpgaext();
int temp_fpgafl();
int temp_fpgafr();
int temp_slowadc();
int temp_sodl();
int temp_sodr();
int temp_threshold();
int templist();
int tempvalues();
int tengiga();
int threshold();
int timing();
int timinglist();
int timingsource();
int top();
int transceiverenable();
int trigger();
int triggers();
int triggersl();
int trimbits();
int trimen();
int trimval();
int tsamples();
int txdelay();
int txdelay_frame();
int txdelay_left();
int txdelay_right();
int type();
int udp_cleardst();
int udp_dstip();
int udp_dstip2();
int udp_dstlist();
int udp_dstmac();
int udp_dstmac2();
int udp_dstport();
int udp_dstport2();
int udp_firstdst();
int udp_numdst();
int udp_reconfigure();
int udp_srcip();
int udp_srcip2();
int udp_srcmac();
int udp_srcmac2();
int udp_validate();
int update();
int updatedetectorserver();
int updatekernel();
int updatemode();
int user();
int v_a();
int v_b();
int v_c();
int v_chip();
int v_d();
int v_io();
int v_limit();
int vchip_comp_adc();
int vchip_comp_fe();
int vchip_cs();
int vchip_opa_1st();
int vchip_opa_fd();
int vchip_ref_comp_fe();
int versions();
int veto();
int vetoalg();
int vetofile();
int vetophoton();
int vetoref();
int vetostream();
int virtualFunction();
int vm_a();
int vm_b();
int vm_c();
int vm_d();
int vm_io();
int zmqhwm();
int zmqip();
int zmqport();
// int frames();
private:
using FunctionMap = std::map<std::string, int (InferAction::*)()>;
FunctionMap functions{
// generated functions
{"acquire", &InferAction::acquire},
{"activate", &InferAction::activate},
{"adcclk", &InferAction::adcclk},
{"adcenable", &InferAction::adcenable},
{"adcenable10g", &InferAction::adcenable10g},
{"adcindex", &InferAction::adcindex},
{"adcinvert", &InferAction::adcinvert},
{"adclist", &InferAction::adclist},
{"adcname", &InferAction::adcname},
{"adcphase", &InferAction::adcphase},
{"adcpipeline", &InferAction::adcpipeline},
{"adcreg", &InferAction::adcreg},
{"adcvpp", &InferAction::adcvpp},
{"apulse", &InferAction::apulse},
{"asamples", &InferAction::asamples},
{"autocompdisable", &InferAction::autocompdisable},
{"badchannels", &InferAction::badchannels},
{"blockingtrigger", &InferAction::blockingtrigger},
{"burstmode", &InferAction::burstmode},
{"burstperiod", &InferAction::burstperiod},
{"bursts", &InferAction::bursts},
{"burstsl", &InferAction::burstsl},
{"bustest", &InferAction::bustest},
{"cdsgain", &InferAction::cdsgain},
{"chipversion", &InferAction::chipversion},
{"clearbit", &InferAction::clearbit},
{"clearbusy", &InferAction::clearbusy},
{"clearroi", &InferAction::clearroi},
{"clientversion", &InferAction::clientversion},
{"clkdiv", &InferAction::clkdiv},
{"clkfreq", &InferAction::clkfreq},
{"clkphase", &InferAction::clkphase},
{"column", &InferAction::column},
{"compdisabletime", &InferAction::compdisabletime},
{"confadc", &InferAction::confadc},
{"config", &InferAction::config},
{"counters", &InferAction::counters},
{"currentsource", &InferAction::currentsource},
{"dac", &InferAction::dac},
{"dacindex", &InferAction::dacindex},
{"daclist", &InferAction::daclist},
{"dacname", &InferAction::dacname},
{"dacvalues", &InferAction::dacvalues},
{"datastream", &InferAction::datastream},
{"dbitclk", &InferAction::dbitclk},
{"dbitphase", &InferAction::dbitphase},
{"dbitpipeline", &InferAction::dbitpipeline},
{"defaultdac", &InferAction::defaultdac},
{"defaultpattern", &InferAction::defaultpattern},
{"delay", &InferAction::delay},
{"delayl", &InferAction::delayl},
{"detectorserverversion", &InferAction::detectorserverversion},
{"detsize", &InferAction::detsize},
{"diodelay", &InferAction::diodelay},
{"dpulse", &InferAction::dpulse},
{"dr", &InferAction::dr},
{"drlist", &InferAction::drlist},
{"dsamples", &InferAction::dsamples},
{"execcommand", &InferAction::execcommand},
{"exptime", &InferAction::exptime},
{"exptime1", &InferAction::exptime1},
{"exptime2", &InferAction::exptime2},
{"exptime3", &InferAction::exptime3},
{"exptimel", &InferAction::exptimel},
{"extrastoragecells", &InferAction::extrastoragecells},
{"extsampling", &InferAction::extsampling},
{"extsamplingsrc", &InferAction::extsamplingsrc},
{"extsig", &InferAction::extsig},
{"fformat", &InferAction::fformat},
{"filtercells", &InferAction::filtercells},
{"filterresistor", &InferAction::filterresistor},
{"findex", &InferAction::findex},
{"firmwaretest", &InferAction::firmwaretest},
{"firmwareversion", &InferAction::firmwareversion},
{"fliprows", &InferAction::fliprows},
{"flowcontrol10g", &InferAction::flowcontrol10g},
{"fmaster", &InferAction::fmaster},
{"fname", &InferAction::fname},
{"foverwrite", &InferAction::foverwrite},
{"fpath", &InferAction::fpath},
{"framecounter", &InferAction::framecounter},
{"frames", &InferAction::frames},
{"framesl", &InferAction::framesl},
{"frametime", &InferAction::frametime},
{"free", &InferAction::free},
{"fwrite", &InferAction::fwrite},
{"gaincaps", &InferAction::gaincaps},
{"gainmode", &InferAction::gainmode},
{"gappixels", &InferAction::gappixels},
{"gatedelay", &InferAction::gatedelay},
{"gatedelay1", &InferAction::gatedelay1},
{"gatedelay2", &InferAction::gatedelay2},
{"gatedelay3", &InferAction::gatedelay3},
{"gates", &InferAction::gates},
{"getbit", &InferAction::getbit},
{"hardwareversion", &InferAction::hardwareversion},
{"highvoltage", &InferAction::highvoltage},
{"hostname", &InferAction::hostname},
{"im_a", &InferAction::im_a},
{"im_b", &InferAction::im_b},
{"im_c", &InferAction::im_c},
{"im_d", &InferAction::im_d},
{"im_io", &InferAction::im_io},
{"imagetest", &InferAction::imagetest},
{"initialchecks", &InferAction::initialchecks},
{"inj_ch", &InferAction::inj_ch},
{"interpolation", &InferAction::interpolation},
{"interruptsubframe", &InferAction::interruptsubframe},
{"kernelversion", &InferAction::kernelversion},
{"lastclient", &InferAction::lastclient},
{"led", &InferAction::led},
{"lock", &InferAction::lock},
{"master", &InferAction::master},
{"maxadcphaseshift", &InferAction::maxadcphaseshift},
{"maxclkphaseshift", &InferAction::maxclkphaseshift},
{"maxdbitphaseshift", &InferAction::maxdbitphaseshift},
{"measuredperiod", &InferAction::measuredperiod},
{"measuredsubperiod", &InferAction::measuredsubperiod},
{"moduleid", &InferAction::moduleid},
{"nextframenumber", &InferAction::nextframenumber},
{"nmod", &InferAction::nmod},
{"numinterfaces", &InferAction::numinterfaces},
{"overflow", &InferAction::overflow},
{"packageversion", &InferAction::packageversion},
{"parallel", &InferAction::parallel},
{"parameters", &InferAction::parameters},
{"partialreset", &InferAction::partialreset},
{"patfname", &InferAction::patfname},
{"patioctrl", &InferAction::patioctrl},
{"patlimits", &InferAction::patlimits},
{"patloop", &InferAction::patloop},
{"patloop0", &InferAction::patloop0},
{"patloop1", &InferAction::patloop1},
{"patloop2", &InferAction::patloop2},
{"patmask", &InferAction::patmask},
{"patnloop", &InferAction::patnloop},
{"patnloop0", &InferAction::patnloop0},
{"patnloop1", &InferAction::patnloop1},
{"patnloop2", &InferAction::patnloop2},
{"patsetbit", &InferAction::patsetbit},
{"patternX", &InferAction::pattern},
{"patternstart", &InferAction::patternstart},
{"patwait", &InferAction::patwait},
{"patwait0", &InferAction::patwait0},
{"patwait1", &InferAction::patwait1},
{"patwait2", &InferAction::patwait2},
{"patwaittime", &InferAction::patwaittime},
{"patwaittime0", &InferAction::patwaittime0},
{"patwaittime1", &InferAction::patwaittime1},
{"patwaittime2", &InferAction::patwaittime2},
{"patword", &InferAction::patword},
{"pedestalmode", &InferAction::pedestalmode},
{"period", &InferAction::period},
{"periodl", &InferAction::periodl},
{"polarity", &InferAction::polarity},
{"port", &InferAction::port},
{"powerchip", &InferAction::powerchip},
{"powerindex", &InferAction::powerindex},
{"powerlist", &InferAction::powerlist},
{"powername", &InferAction::powername},
{"powervalues", &InferAction::powervalues},
{"programfpga", &InferAction::programfpga},
{"pulse", &InferAction::pulse},
{"pulsechip", &InferAction::pulsechip},
{"pulsenmove", &InferAction::pulsenmove},
{"pumpprobe", &InferAction::pumpprobe},
{"quad", &InferAction::quad},
{"ratecorr", &InferAction::ratecorr},
{"readnrows", &InferAction::readnrows},
{"readout", &InferAction::readout},
{"readoutspeed", &InferAction::readoutspeed},
{"readoutspeedlist", &InferAction::readoutspeedlist},
{"rebootcontroller", &InferAction::rebootcontroller},
{"reg", &InferAction::reg},
{"resetdacs", &InferAction::resetdacs},
{"resetfpga", &InferAction::resetfpga},
{"roi", &InferAction::roi},
{"romode", &InferAction::romode},
{"row", &InferAction::row},
{"runclk", &InferAction::runclk},
{"runtime", &InferAction::runtime},
{"rx_arping", &InferAction::rx_arping},
{"rx_clearroi", &InferAction::rx_clearroi},
{"rx_dbitlist", &InferAction::rx_dbitlist},
{"rx_dbitoffset", &InferAction::rx_dbitoffset},
{"rx_discardpolicy", &InferAction::rx_discardpolicy},
{"rx_fifodepth", &InferAction::rx_fifodepth},
{"rx_frameindex", &InferAction::rx_frameindex},
{"rx_framescaught", &InferAction::rx_framescaught},
{"rx_framesperfile", &InferAction::rx_framesperfile},
{"rx_hostname", &InferAction::rx_hostname},
{"rx_jsonaddheader", &InferAction::rx_jsonaddheader},
{"rx_jsonpara", &InferAction::rx_jsonpara},
{"rx_lastclient", &InferAction::rx_lastclient},
{"rx_lock", &InferAction::rx_lock},
{"rx_missingpackets", &InferAction::rx_missingpackets},
{"rx_padding", &InferAction::rx_padding},
{"rx_printconfig", &InferAction::rx_printconfig},
{"rx_realudpsocksize", &InferAction::rx_realudpsocksize},
{"rx_roi", &InferAction::rx_roi},
{"rx_silent", &InferAction::rx_silent},
{"rx_start", &InferAction::rx_start},
{"rx_status", &InferAction::rx_status},
{"rx_stop", &InferAction::rx_stop},
{"rx_tcpport", &InferAction::rx_tcpport},
{"rx_threads", &InferAction::rx_threads},
{"rx_udpsocksize", &InferAction::rx_udpsocksize},
{"rx_version", &InferAction::rx_version},
{"rx_zmqfreq", &InferAction::rx_zmqfreq},
{"rx_zmqhwm", &InferAction::rx_zmqhwm},
{"rx_zmqip", &InferAction::rx_zmqip},
{"rx_zmqport", &InferAction::rx_zmqport},
{"rx_zmqstartfnum", &InferAction::rx_zmqstartfnum},
{"rx_zmqstream", &InferAction::rx_zmqstream},
{"samples", &InferAction::samples},
{"savepattern", &InferAction::savepattern},
{"scan", &InferAction::scan},
{"scanerrmsg", &InferAction::scanerrmsg},
{"selinterface", &InferAction::selinterface},
{"serialnumber", &InferAction::serialnumber},
{"setbit", &InferAction::setbit},
{"settings", &InferAction::settings},
{"settingslist", &InferAction::settingslist},
{"settingspath", &InferAction::settingspath},
{"signalindex", &InferAction::signalindex},
{"signallist", &InferAction::signallist},
{"signalname", &InferAction::signalname},
{"slowadc", &InferAction::slowadc},
{"slowadcindex", &InferAction::slowadcindex},
{"slowadclist", &InferAction::slowadclist},
{"slowadcname", &InferAction::slowadcname},
{"slowadcvalues", &InferAction::slowadcvalues},
{"start", &InferAction::start},
{"status", &InferAction::status},
{"stop", &InferAction::stop},
{"stopport", &InferAction::stopport},
{"storagecell_delay", &InferAction::storagecell_delay},
{"storagecell_start", &InferAction::storagecell_start},
{"subdeadtime", &InferAction::subdeadtime},
{"subexptime", &InferAction::subexptime},
{"sync", &InferAction::sync},
{"syncclk", &InferAction::syncclk},
{"temp_10ge", &InferAction::temp_10ge},
{"temp_adc", &InferAction::temp_adc},
{"temp_control", &InferAction::temp_control},
{"temp_dcdc", &InferAction::temp_dcdc},
{"temp_event", &InferAction::temp_event},
{"temp_fpga", &InferAction::temp_fpga},
{"temp_fpgaext", &InferAction::temp_fpgaext},
{"temp_fpgafl", &InferAction::temp_fpgafl},
{"temp_fpgafr", &InferAction::temp_fpgafr},
{"temp_slowadc", &InferAction::temp_slowadc},
{"temp_sodl", &InferAction::temp_sodl},
{"temp_sodr", &InferAction::temp_sodr},
{"temp_threshold", &InferAction::temp_threshold},
{"templist", &InferAction::templist},
{"tempvalues", &InferAction::tempvalues},
{"tengiga", &InferAction::tengiga},
{"threshold", &InferAction::threshold},
{"thresholdnotb", &InferAction::threshold},
{"timing", &InferAction::timing},
{"timinglist", &InferAction::timinglist},
{"timingsource", &InferAction::timingsource},
{"top", &InferAction::top},
{"transceiverenable", &InferAction::transceiverenable},
{"trigger", &InferAction::trigger},
{"triggers", &InferAction::triggers},
{"triggersl", &InferAction::triggersl},
{"trimbits", &InferAction::trimbits},
{"trimen", &InferAction::trimen},
{"trimval", &InferAction::trimval},
{"tsamples", &InferAction::tsamples},
{"txdelay", &InferAction::txdelay},
{"txdelay_frame", &InferAction::txdelay_frame},
{"txdelay_left", &InferAction::txdelay_left},
{"txdelay_right", &InferAction::txdelay_right},
{"type", &InferAction::type},
{"udp_cleardst", &InferAction::udp_cleardst},
{"udp_dstip", &InferAction::udp_dstip},
{"udp_dstip2", &InferAction::udp_dstip2},
{"udp_dstlist", &InferAction::udp_dstlist},
{"udp_dstmac", &InferAction::udp_dstmac},
{"udp_dstmac2", &InferAction::udp_dstmac2},
{"udp_dstport", &InferAction::udp_dstport},
{"udp_dstport2", &InferAction::udp_dstport2},
{"udp_firstdst", &InferAction::udp_firstdst},
{"udp_numdst", &InferAction::udp_numdst},
{"udp_reconfigure", &InferAction::udp_reconfigure},
{"udp_srcip", &InferAction::udp_srcip},
{"udp_srcip2", &InferAction::udp_srcip2},
{"udp_srcmac", &InferAction::udp_srcmac},
{"udp_srcmac2", &InferAction::udp_srcmac2},
{"udp_validate", &InferAction::udp_validate},
{"update", &InferAction::update},
{"updatedetectorserver", &InferAction::updatedetectorserver},
{"updatekernel", &InferAction::updatekernel},
{"updatemode", &InferAction::updatemode},
{"user", &InferAction::user},
{"v_a", &InferAction::v_a},
{"v_b", &InferAction::v_b},
{"v_c", &InferAction::v_c},
{"v_chip", &InferAction::v_chip},
{"v_d", &InferAction::v_d},
{"v_io", &InferAction::v_io},
{"v_limit", &InferAction::v_limit},
{"vchip_comp_adc", &InferAction::vchip_comp_adc},
{"vchip_comp_fe", &InferAction::vchip_comp_fe},
{"vchip_cs", &InferAction::vchip_cs},
{"vchip_opa_1st", &InferAction::vchip_opa_1st},
{"vchip_opa_fd", &InferAction::vchip_opa_fd},
{"vchip_ref_comp_fe", &InferAction::vchip_ref_comp_fe},
{"versions", &InferAction::versions},
{"veto", &InferAction::veto},
{"vetoalg", &InferAction::vetoalg},
{"vetofile", &InferAction::vetofile},
{"vetophoton", &InferAction::vetophoton},
{"vetoref", &InferAction::vetoref},
{"vetostream", &InferAction::vetostream},
{"virtual", &InferAction::virtualFunction},
{"vm_a", &InferAction::vm_a},
{"vm_b", &InferAction::vm_b},
{"vm_c", &InferAction::vm_c},
{"vm_d", &InferAction::vm_d},
{"vm_io", &InferAction::vm_io},
{"zmqhwm", &InferAction::zmqhwm},
{"zmqip", &InferAction::zmqip},
{"zmqport", &InferAction::zmqport}
// {"frames",&InferAction::frames}
};
};
} // namespace sls