evn-vlbi / VLBI-utilities

Utilities that can be used at stations to help with VLBI observations.
GNU General Public License v3.0
3 stars 2 forks source link

antabfs.py: Confusion about "fb_mode" used in modern FS10 setups #7

Open varenius opened 2 years ago

varenius commented 2 years ago

I have a logfile which contains the line 2021.266.11:25:21.03&setupbb/fb_mode=vdif,,,64 antabfs.py does not like this, I get:

oper@fulla:~/eskil/VLBI-utilities.git$ ./antabfs.py /usr2/log/fm2160oe.log 
Traceback (most recent call last):
  File "./antabfs.py", line 2544, in <module>
    main(sys.argv)
  File "./antabfs.py", line 2380, in main
    logF = logFile(logFileName)
  File "./antabfs.py", line 486, in __init__
    self.__readLog()
  File "./antabfs.py", line 528, in __readLog
    if self.__getGenVar(line):
  File "./antabfs.py", line 1004, in __getGenVar
    self.__recMode[self.__currentSetup] = int(line.split(',')[1],16)
ValueError: invalid literal for int() with base 16: ''
varenius commented 2 years ago

It seems the logic is that we are looking for a line like (taken from DBBC2 S/X log) 2021.265.11:51:21.51&setupsx/mk5c_mode=vdif,0xffffffff,,32.000 where the python int conversion would do

>>> int("0xffffffff",16)
4294967295

But for the DBBC3, we have (up to) 16 possible different bitmasks, one per core3h card. (See https://github.com/nvi-inc/fs/blob/ed/dbbc3/help/mk5b_mode.___#L29 and then https://github.com/nvi-inc/fs/blob/ed/dbbc3/help/mk5b_mode.___#L123). So we need to make antabfs.py instead read the core3h commands like

2021.266.11:25:26.27&core3hbb/core3h_mode1=,0xcccccccc,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode2=,0xcccccccc,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode3=,0x33333333,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode4=,0x33333333,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode5=,0x33333333,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode6=,0x33333333,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode7=,0x33333333,,64.0,$
2021.266.11:25:26.27&core3hbb/core3h_mode8=,0x33333333,,64.0,$