transientskp / aartfaac-control

AARTFAAC control scripts
0 stars 0 forks source link

Subband/Freq from rspctl #1

Closed Error323 closed 9 years ago

Error323 commented 9 years ago

Currently the 8 subbands are fixed from 590 til 604 for X polarization in code. We need to obtain these values from querying the sdo (subband data output) mode on the stations:

rspctl --sdo
hsuyeep commented 9 years ago

Since we mostly will not be able to run cmdClients on the station LCUs, and since the rspctl is a command guarenteed (I think?) to exit, maybe it is better to do this via an ssh -c for the setting and querying of the chosen subbands?

hsuyeep commented 9 years ago

After discussions with the LOFAR guys on security issues, it is decided that we will provide them with a script that we can call. We get access on the stations to execute only this script. The LOFAR side will validate the script and add it to the station code repository.

hsuyeep commented 9 years ago

Created script runaartfaacrspctl.py which takes a csv list of subbands to set with a -s or --subbands command line option. It then:

hsuyeep commented 9 years ago

(contd.) sets the other subbands to 0

Script tested on CS002C. Sample interaction:

[lofarsys@CS002C ~]$ ./runaartfaacrspctl.py -s 8,9,10,2,3,4,5,6,7,1,2,3,4,5,6,7,1,2,3,4 4
<-- Running command:  ['rspctl', '--sdo=8,9,10,2,3,4,5,6,7,1,2,3,4,5,6,7,1,2,3,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0']
log4cplus:ERROR Unable to open file: /opt/lofar/var/log/rspctl.log
log4cplus:ERROR Unable to open file: /opt/lofar/var/log/rspctl.log
rcumask.count()=96
Cmd output is : bits per sample=16
3; 144
setsdoack.timestamp=0 - Thu, 01 Jan 1970 00:00:00.000000  +0000

log4cplus:ERROR Unable to open file: /opt/lofar/var/log/rspctl.log
log4cplus:ERROR Unable to open file: /opt/lofar/var/log/rspctl.log
<-- AARTFAAC subbands successfully set.
[lofarsys@CS002C ~]$