Interferometry in manual mode with software version 5.0.3

Author: Complete rewrite. 2008 April 4. RAL.

  • added DTX clock incantation 20080408 RI
  • added note to kill log 20080411 RI
  • removed DTX clock incantation (no longer needed), and updated the hot load and Walsh switching sections. 20080430 RR
  • Twiki tweak AH

Changes for version 5.0.3:
  • Recommended method is to use execfile to run a complete CCL script, modified from template example files.
  • CorrGUI run on oper01 (if you run it at all)
  • Pointing model run automatically
  • Frequency for refraction correction set in scripts.

All sessions should be run on oper01.

In what follows:

  • > denotes the unix shell prompt,
  • >>> the python prompt,
  • CCL>>> the CCL prompt and
  • psi> the prompt for psi scripts.

To get the PSI prompt type:

>cd /groups/psi/Public_PSI

>./psi

.Prerequisites

The following assumes that the system has been set up (by the Operator) according to:

  1. Antenna Startup and Shutdown
  2. System Software Setup
  3. Radiometer Software Setup

This will ensure that the antennas are movable and in focus, with pointing models loaded, the receivers are set up, the line-length correction is turned on and being logged.

-1.Open Observing Log File and Report activities in the ATF Journal.

You must post your nightly activity in the ATF Activity Journal. The observed sources, SB/script used, and UID must be written down here, as this is the only way to keep track of what is being done every night. This is expected to be replaced soon by a proper logger system.

Optionally, You can also open the current month Log File for editing. Here you can add any log entries for the night, and also crucial information as UTC date, uid number and objects observed in each executed SB. It is a simple text file that can be edited in your preferred editor (e.g emacs, vi):

>cd /groups/sci/logs/

> emacs may.notes &

0.Run the logpower script

This utility will log total power data, az,el position and the hotload status and temperature from the specified antenna into an ASCII file in /groups/sci/interferometry/YYYYMMDD. Needed if you are planning to use the hot load for calibration.

>/groups/sci/scripts/5.0.2/logpower.py -a both -s 4

Will log data from both antennas, creating the YYYYMMDD directory if it does not already exist. Note that if the system crashes, logpower will halt and will need to be restarted.

1. Take a Skydip on both antennas to measure Receiver Temperature and Sky Opacity each night

(This should be run by the operators before the start of each night).

Execute the following script, which will run a SkyDip on both antennas. This command will write the Receiver Temperature and sky opacity to the SkyDipResults_yyyymmdd.txt file (Note that you need to edit the right yyyymmdd).

>cd /groups/sci/scripts/skydipData

For Vertex:

*> ./SkyDip503.py -a DV01 -p 0 | tee -a SkyDipResults_yyyymmdd.txt

For Alcatel:

*> ./SkyDip503.py -a DA41 -p 0 | tee -a SkyDipResults_yyyymmdd.txt

2 Run InterferometryTest in Manual Mode to check the system is fringing:

Create a Manual Array

On the OMC

View -> create array

This brings up a panel showing all potential antennas

Click Manual -> indicators for antennas 1 and 2 turn green

Left click on 1

Shift left click on 2

Both indicators should turn blue

Click on Create

Wait until the antennas are assigned to the array (click on Alma -> antennas; both antennas should be assigned to the new array CONTROL/Arraynnn).

Run the Interferometry Test Script in Manual Mode:

>mmc --arrayname=CONTROL/Arraynnn

where nnn is the number of the array you created in (3) - 001, 002, etc. This brings up the CCL prompt CCL>>>

Execute the InterferometryTest Script (*Check it has the right source for current LST, and correct cable delay, edit accordingly otherwise *):

CCL>>>execfile('/groups/sci/scripts/5.0.3/InterferometryTest.py')

In the OMC dataflow window, wait until the Scan number changes from 0-0 to 1-0. Once this has happened you can start the CorrGUI:

>CorrGUI

Here you should see fringes if everything is OK. Once the execution has ended, execute in the following order:

  1. Close the CorrGUI.
  2. Control-D the CCL shell
  3. In the OMC destroy the array

You can proceed to your observing

3. Set up a data directory

IF you have NOT run the logpower script and the data directory does not yet exist, create it:

>mkdir /groups/sci/interferometry/YYYYMMDD

where YYYYMMDD is the current UT date.

4. Create an array

On the OMC

View -> create array

This brings up a panel showing all potential antennas

Click Manual -> indicators for antennas 1 and 2 turn green

Left click on 1

Shift left click on 2

Both indicators should turn blue

Click on Create

Wait until the antennas are assigned to the array (click on Alma -> antennas; both antennas should be assigned to the new array CONTROL/Arraynnn).

5. Create an observing script

Please refer to Creating an observing script

6. Check that the correlator is synchronised with the rest of the system

>ssh ccc

>arrayTimeCompare CORR/ARRAY_TIME/CDP_NODE/N01

>exit

You should see a line:

delta = remote-local: 0[acs]

If the number is NOT 0, then the correlator subsystem will have to be restarted and the correlator computers power cycled (see Appendix C).

7. Start a CCL session and execute the observing script

* It is recommended that you have your observing script available in * * an emacs window so that you can follow execution and cut/paste * * non-CCL commands from it. But beware of indentation when doing so. *

>mmc --arrayname=CONTROL/Arraynnn

where nnn is the number of the array you created in (3) - 001, 002, etc. This brings up the CCL prompt CCL>>>

Execute your main observing Script:

CCL>>>execfile('/groups/sci/scripts/observations.py')

In the OMC dataflow window, *Write down the exec block id (which will be something like uid://X1eb/X2482/X1)*, as this is needed for data reduction. You will need to resize the field to see this. You will be able to see the progress of the observation in the scan and subscan fields. After the end of execution, the indicator on the left of the dataflow entry will be green, the numbers of completed scans and subscans should be as you set them in the script and control will be returned to the CCL prompt.

8. Executing CCL commands by hand

For debugging purposes, you may want to execute commands from the script by cutting and pasting from an emacs window. Be careful to preserve the indentation: - Avoid extra spaces at the beginnings of lines - Preserve indentation in for loops - Paste lines inside for loops one at a time - Terminate a for loop with a blank line

When executing a subscan in this way, paste in the sfi_obs_mode.endSubscan() command as soon as the sfi_obs_mode.beginSubscan(spectSpec,corrConf,[SubscanIntentMod.ON_SOURCE] command returns control - otherwise the subscan will not finish. Also take care to make sure that there are no unmatched begin/end execution. scan or subscan commands.

9. Tidying up after an observation

  1. Exit from CCL by typing CTRL D on the CCL>> shell
  2. Destroy the array: On OMC Scheduler -> Destroy array

wait until the antennas panel shows both DV01 and DA41 unassigned to be sure that the array has actually been destroyed.

In OMC, you can get rid of the defunct array's tab by going to View->Manage Display.

You can now start another observation.

10. Exporting the data and making a measurement set

>cd /groups/sci/interferometry/YYYYMMDD

>asdmExport -b uid://X1eb/Xnnnn/X1

where nnnn is the number of the exec block noted earlier. This creates a directory uid___X1eb_Xnnnn_X1

>asdm2MS --ocm ca uid___X1eb_Xnnnn_X1

creates a measurement set called uid___X1eb_Xnnnn_X1.ms.

Now change permissions so that everyone can read/write it:

>chmod -R ugo+wrx uid___X1eb_Xnnnn_X1.ms

11. Plotting the data using CASA

Data reduction in CASA and LLC correction

###########################

A1. Correcting a delay error

###########################

After a change of electronics modules (e.g. digitizer clock), fibre length etc., the cable delay may change. The symptom is a linear phase change across the band. For a variation with a positive slope and about 2 wraps across the bandwidth, the delay should be increased by about 1 ns. To correct:

CCL>>>sds.getAntennaCableDelay('DA41')

reports the current cable delay (which should be as set by the observing script). To set a new value:

CCL>>>sds.setAntennaCableDelay('DA41',delay)

where delay is in s (e.g. 511.8375e-9).

Make sure that the delay server is set up and that the antennas are tracking by executing the standard observing script commands as far as

CCL>>>sfi_obs_mode.setDirection(ra1, dec1, fieldName=name1)

Do not start a scan from CCL. Then start CorrGUI and initiate continuous subscans: - Select TDM mode - Integration set to a multiple of 1.008s -

###################

A2. Walsh functions

###################

Walsh Funtions only after tunning ! (after set_frequency(xxe9) function call)

In order to remove spurious signals such as DC offsets, ALMA will use 180 phase modulation at the rirst LO, decoded after the digitizer. In order to test this, without desynchronization problems, we can apply Walsh functions 0 (constant) and 1 (Emerson, ALMA Memo 565), essentially as in traditional phase switching. To do this:

Set up the receivers as usual

# Install Walsh functions 0 and 1 in Vertex and Alcatel respectively. 0 and 1 can also be replaced with 3 and 4.

PSI>rs walsh 0,1

# Enable Walsh function switching

PSI>rs walsh ef

If you are watching in CorrGUI, and in TDM mode, you should still see the internal beacon signal in channel 180, but the spurious 250MHz harmonics should vanish.

# Disable Walsh switching

PSI>rs walsh d

Walsh switching works wonders if you do not tune to another frequency while it is on. If you do, performance will be degraded.

Appendix B: Trouble-shooting

#######################

B1. Correlator problems

#######################

If you get a timeout error when trying to start CorrGUI, the times are probably not synchronised between the correlator and the rest of the world.

exit CorrGUI

Check whether the correlator containers are up (green) on OMC. If they are all OK:

correlator subsystem -> shutdown -> operational

If any of the containers are down:

correlator subsystem -> shutdown

You need to power-cycle ccc (if CCC containers are down) and/or cdp00 (for CDP containers).

'>pstrip -u almaproc cob-pdu list

which gives a listing

1 - cdp ON 2 - ccc ON ..........

so to power-cycle ccc and cdp00:

'>pstrip -u almaproc cob-pdu cycle 1
'>pstrip -u almaproc cob-pdu cycle 2

To check:

'>ssh ccc
'>ssh cdp00

You should be able to log in to both machines once they are up. Then exit.

Then restart the containers and bring the correlator subsystem to operational.

#################################################

B2.On-line monitoring of the LLC for phase jumps

#################################################

To monitor LLC phase jumps visually, look at the LLC Labview displays on snickers. To get these, click on LLC1 -> details on the central lo rack display; similarly for LLC2. The frequency of phase jumps depends on the rate of ambient temperature change, and are more often on AEC due to the extra fibre length. These data will be stored in: /groups/psi/Public_PSI/Data/Daily/2007/yyyy-mm-dd-LLC_02/ provided that the psi monitor script has been started (see system software startup checklist). A new file is created at UT midnight automatically.

-- AntonioHales - 04 May 2008

This topic: ALMA > WebHome > AlmaSci > AlmImcal > ControNotes
Topic revision: 2008-05-23, AntonioHales
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding NRAO Public Wiki? Send feedback