VEX_rev = 1.5;
*    SCHED vers: Release 11.4.  March 14, 2015
*    VEX/SCHED:  1.5.87
*    Other versions: Sched:  11.4  Plot: 1.06  JPL-ephem: 1.01
*------------------------------------------------------------------------------
$GLOBAL;
     ref $EXPER = el053h;
*                                                      +------------+
*                         PI revision number:          |    1.0300  |
*                                                      +------------+
*    mode:       8 GHz, RadioAstron sat. tracking
*------------------------------------------------------------------------------
$EXPER;
*
def el053h;
     exper_name = el053h;
     exper_description = "RadioAstron sat. tracking";
     PI_name = "Dmitry Litvinov";
     PI_email = litvda@yandex.ru;
*    address:   Sternberg Astronomical Institute
*               Moscow State University
*                
*               Russia
*    phone:     +7 495 9395327
*    during obs:+7 495 9395327
*    fax:        
*    notes:     Mk5 raw data should be e-transferred to ASC/Moscow
*               Single pol RCP
*
*    year, doy: 2016, 166
*    date     : Tue 14 Jun 2016
*    MJD      : 57553
     exper_nominal_start=2016y166d19h00m00s;
     exper_nominal_stop=2016y166d19h30m00s;
*
     target_correlator = ASC;
*
*    integr_time    :     2.000 s
*    number_channels:   256
*    number_antenna :  4
*    cross_polarize : No
*    weight_func    : UNIFORM
*    distrib_medium : DAT
*    distrib_format : FITS
*    source_pos_cat : STANDARD
*    distribute_to  : 
*                     e-transfer to ASC/Moscow
*
enddef;
*------------------------------------------------------------------------------
$MODE;
*
def raxevn;
     ref $PROCEDURES = Mode_01;
     ref $FREQ = 8398.75MHz4x4MHz#02:Ef;
     ref $FREQ = 8398.75MHz4x4MHz:Sv:Zc;
     ref $FREQ = 8398.75MHz4x4MHz#03:Wn;
     ref $IF = LO@7700MHzRPolNoTone:Ef;
     ref $IF = LO@8080MHzRPolNoTone:Sv:Zc;
     ref $IF = LO@7580MHzRPolNoTone:Wn;
     ref $BBC = 4BBCs#02:Ef;
     ref $BBC = 4BBCs:Sv:Zc;
     ref $BBC = 4BBCs#03:Wn;
     ref $TRACKS = VDIF.4Ch2bit1to1:Ef;
     ref $TRACKS = MARK5B.4Ch2bit1to1:Sv:Zc;
     ref $TRACKS = MARK5B.4Ch2bit1to1#02:Wn;
*    ref $HEAD_POS = DiskVoid <= obsolete definition
     ref $ROLL = NoRoll:Ef:Sv:Zc:Wn;
*    ref $PASS_ORDER = DiskVoid <= obsolete definition
     ref $PHASE_CAL_DETECT = NoDetect:Ef:Sv:Zc:Wn;
enddef;
*
def ra6cm2;
     ref $PROCEDURES = Mode_02;
     ref $FREQ = 4836.00MHz4x16MHz:Pu;
     ref $IF = LO@4500MHzDPolTone/1:Pu;
     ref $BBC = 2BBCs:Pu;
     ref $TRACKS = MARK5B.4Ch2bit1to1#03:Pu;
*    ref $HEAD_POS = DiskVoid <= obsolete definition
     ref $ROLL = NoRoll:Pu;
*    ref $PASS_ORDER = DiskVoid <= obsolete definition
     ref $PHASE_CAL_DETECT = DsbDetect:Pu;
enddef;
*------------------------------------------------------------------------------
$STATION;
*
def Ef;
     ref $SITE = EFLSBERG;
     ref $ANTENNA = EFLSBERG;
     ref $DAS = 2DBBC+NONE<;
enddef;
*
def Sv;
     ref $SITE = SVETLOE;
     ref $ANTENNA = SVETLOE;
     ref $DAS = 2R1002+NONE<;
enddef;
*
def Zc;
     ref $SITE = ZELENCHK;
     ref $ANTENNA = ZELENCHK;
     ref $DAS = 2R1002+NONE<;
enddef;
*
def Wn;
     ref $SITE = WETTZ13N;
     ref $ANTENNA = WETTZ13N;
     ref $DAS = 2DBBC+NONE<#02;
enddef;
*
def Pu;
     ref $SITE = PUSH;
     ref $ANTENNA = PUSH;
     ref $DAS = 2NONE<;
enddef;
*------------------------------------------------------------------------------
$PROCEDURES;
*
def Mode_01;
     procedure_name_prefix =  "01";
     tape_change =  420 sec;
     headstack_motion =    6 sec;
     new_source_command =    5 sec;
     new_tape_setup =   20 sec;
     setup_always = on :  20 sec;
     parity_check = off : 100 sec;
     tape_prepass = off : 600 sec;
     preob_cal  = on :  10 sec : preob;
     midob_cal  = on :  15 sec : midob;
     postob_cal = on :   0 sec : postob;
enddef;
*
def Mode_02;
     procedure_name_prefix =  "02";
     tape_change =  420 sec;
     headstack_motion =    6 sec;
     new_source_command =    5 sec;
     new_tape_setup =   20 sec;
     setup_always = on :  20 sec;
     parity_check = off : 100 sec;
     tape_prepass = off : 600 sec;
     preob_cal  = on :  10 sec : preob;
     midob_cal  = on :  15 sec : midob;
     postob_cal = on :   0 sec : postob;
enddef;
*------------------------------------------------------------------------------
$SITE;
*
def EFLSBERG;
     site_type = fixed;
     site_name = EFLSBERG;
     site_ID = Ef;
*    elev=  416.72 long=-006:53:01. lat= 50:31:29.4
     site_position = 4033947.26160 m:  486990.78660 m: 4900430.99150 m;
     site_velocity = -0.013620   m/yr:  0.016920   m/yr:  0.010770  m/yr;
*    First line below is VEX standard format.  Use only when readers are ready.
*    site_position_epoch = 2013y001d;
     site_position_epoch =   56293;
     horizon_map_az =  0.0 deg: 10.0: 20.0: 30.0: 40.0: 50.0: 60.0: 70.0: 80.0:
                                90.0:100.0:110.0:120.0:130.0:140.0:150.0:160.0:
                               170.0:180.0:190.0:200.0:210.0:220.0:230.0:240.0:
                               250.0:260.0:270.0:280.0:290.0:300.0:310.0:320.0:
                               330.0:340.0:350.0:360.0;
     horizon_map_el = 11.0 deg: 13.0: 16.0: 19.0: 21.0: 21.0: 21.0: 20.0: 18.0:
                                15.0: 16.0: 16.0: 15.0: 15.0: 13.0:  8.0:  7.0:
                                 7.0:  7.0:  7.0:  9.0: 11.0: 11.0: 11.0: 10.0:
                                 9.0:  8.0: 12.0: 14.0: 14.0: 14.0: 14.0: 13.0:
                                 8.0:  7.0:  8.0: 11.0;
enddef;
*
def SVETLOE;
     site_type = fixed;
     site_name = SVETLOE;
     site_ID = Sv;
*    elev=   86.05 long=-029:46:55. lat= 60:31:56.4
     site_position = 2730173.67230 m: 1562442.79340 m: 5529969.14130 m;
     site_velocity = -0.018290   m/yr:  0.013280   m/yr:  0.007820  m/yr;
*    First line below is VEX standard format.  Use only when readers are ready.
*    site_position_epoch = 2013y001d;
     site_position_epoch =   56293;
enddef;
*
def ZELENCHK;
     site_type = fixed;
     site_name = ZELENCHK;
     site_ID = Zc;
*    elev= 1175.06 long=-041:33:54. lat= 43:47:16.1
     site_position = 3451207.53530 m: 3060375.41390 m: 4391915.03840 m;
     site_velocity = -0.022680   m/yr:  0.013460   m/yr:  0.006220  m/yr;
*    First line below is VEX standard format.  Use only when readers are ready.
*    site_position_epoch = 2013y001d;
     site_position_epoch =   56293;
enddef;
*
def WETTZ13N;
     site_type = fixed;
     site_name = WETTZ13N;
     site_ID = Wn;
*    elev=  672.54 long=-012:52:39. lat= 49:08:38.1
     site_position = 4075627.78800 m:  931774.12800 m: 4801552.27700 m;
     site_velocity =  0.000000   m/yr:  0.000000   m/yr:  0.000000  m/yr;
*    First line below is VEX standard format.  Use only when readers are ready.
*    site_position_epoch = 1858y322d;
     site_position_epoch =       0;
enddef;
*
def PUSH;
     site_type = fixed;
     site_name = PUSH;
     site_ID = Pu;
*    elev=  239.09 long=-037:37:41. lat= 54:49:14.2
     site_position = 2916948.88700 m: 2248648.24300 m: 5190099.79800 m;
     site_velocity = -0.014450   m/yr:  0.014460   m/yr:  0.009940  m/yr;
*    First line below is VEX standard format.  Use only when readers are ready.
*    site_position_epoch = 1997y001d;
     site_position_epoch =   50449;
enddef;
*------------------------------------------------------------------------------
$ANTENNA;
*
def EFLSBERG;
     axis_type = az : el;
     antenna_motion = el :  15.0 deg/min :  0 sec;  *    0.020 deg/sec/sec
     antenna_motion = az :  25.0 deg/min :  0 sec;  *    0.020 deg/sec/sec
     axis_offset =    0.01450 m;
enddef;
*
def SVETLOE;
     axis_type = az : el;
     antenna_motion = el :  30.0 deg/min :  0 sec;  *    0.050 deg/sec/sec
     antenna_motion = az :  60.0 deg/min :  0 sec;  *    0.050 deg/sec/sec
     axis_offset =   -0.00730 m;
enddef;
*
def ZELENCHK;
     axis_type = az : el;
     antenna_motion = el :  30.0 deg/min :  0 sec;  *    0.050 deg/sec/sec
     antenna_motion = az :  60.0 deg/min :  0 sec;  *    0.050 deg/sec/sec
     axis_offset =   -0.01160 m;
enddef;
*
def WETTZ13N;
     axis_type = az : el;
     antenna_motion = el :  90.0 deg/min :  0 sec;  * 1000.000 deg/sec/sec
     antenna_motion = az : 180.0 deg/min :  0 sec;  * 1000.000 deg/sec/sec
     axis_offset =    0.00000 m;
enddef;
*
def PUSH;
     axis_type = az : el;
     antenna_motion = el :  30.0 deg/min : 20 sec;  * 1000.000 deg/sec/sec
     antenna_motion = az :  15.0 deg/min : 20 sec;  * 1000.000 deg/sec/sec
     axis_offset =    0.00000 m;
enddef;
*------------------------------------------------------------------------------
$DAS;
*
def 2DBBC+NONE<;
     record_transport_type = Mark5C;
     electronics_rack_type = DBBC;
     number_drives = 2;
     headstack = 1 :            : 0 ;
     headstack = 2 :            : 1 ;
     tape_motion = adaptive : 0 min: 0 min: 10 sec;
enddef;
*
def 2R1002+NONE<;
     record_transport_type = Mark5B;
     electronics_rack_type = Mark4;
     number_drives = 2;
     headstack = 1 :            : 0 ;
     headstack = 2 :            : 1 ;
     tape_motion = adaptive : 0 min: 0 min: 10 sec;
enddef;
*
def 2DBBC+NONE<#02;
     record_transport_type = Mark5B;
     electronics_rack_type = DBBC;
     number_drives = 2;
     headstack = 1 :            : 0 ;
     headstack = 2 :            : 1 ;
     tape_motion = adaptive : 0 min: 0 min: 10 sec;
enddef;
*
def 2NONE<;
     record_transport_type = Mark5B;
     electronics_rack_type = none;
     number_drives = 2;
     headstack = 1 :            : 0 ;
     headstack = 2 :            : 1 ;
     tape_motion = adaptive : 0 min: 0 min: 10 sec;
enddef;
*------------------------------------------------------------------------------
$SOURCE;
*
def EL053H;
     source_name = EL053H;
*    this source had calibrator code:  
*    fake circumpolar target for a TS to look at
     ra = 12h00m00.0000000s; dec =  85d00'00.000000"; ref_coord_frame = J2000;
*    ra = 11h57m21.7692993s; dec =  85d16'41.778887"; ref_coord_frame = B1950;
*    ra = 12h00m44.2579572s; dec =  84d54'51.929313"; ref_coord_frame = Date;
enddef;
*------------------------------------------------------------------------------
$FREQ;
*
def 8398.75MHz4x4MHz;
* mode =  1    stations =Sv:Zc
     sample_rate =   8.000 Ms/sec;  * (2bits/sample)
     chan_def = :  8398.75 MHz : U :   4.00 MHz : &CH01 : &BBC01 : &NoCal; *Rcp
     chan_def = :  8398.50 MHz : U :   4.00 MHz : &CH02 : &BBC02 : &NoCal; *Rcp
     chan_def = :  8398.25 MHz : U :   4.00 MHz : &CH03 : &BBC03 : &NoCal; *Rcp
     chan_def = :  8398.00 MHz : U :   4.00 MHz : &CH04 : &BBC04 : &NoCal; *Rcp
enddef;
*
def 8398.75MHz4x4MHz#02;
* mode =  1    stations =Ef
     sample_rate =   8.000 Ms/sec;  * (2bits/sample)
     chan_def = :  8398.75 MHz : U :   4.00 MHz : &CH01 : &BBC01 : &NoCal; *Rcp
     chan_def = :  8398.50 MHz : U :   4.00 MHz : &CH02 : &BBC03 : &NoCal; *Rcp
     chan_def = :  8398.25 MHz : U :   4.00 MHz : &CH03 : &BBC05 : &NoCal; *Rcp
     chan_def = :  8398.00 MHz : U :   4.00 MHz : &CH04 : &BBC07 : &NoCal; *Rcp
enddef;
*
def 8398.75MHz4x4MHz#03;
* mode =  1    stations =Wn
     sample_rate =   8.000 Ms/sec;  * (2bits/sample)
     chan_def = :  8398.75 MHz : U :   4.00 MHz : &CH01 : &BBC05 : &NoCal; *Rcp
     chan_def = :  8398.50 MHz : U :   4.00 MHz : &CH02 : &BBC06 : &NoCal; *Rcp
     chan_def = :  8398.25 MHz : U :   4.00 MHz : &CH03 : &BBC07 : &NoCal; *Rcp
     chan_def = :  8398.00 MHz : U :   4.00 MHz : &CH04 : &BBC08 : &NoCal; *Rcp
enddef;
*
def 4836.00MHz4x16MHz;
* mode =  2    stations =Pu
     sample_rate =  32.000 Ms/sec;  * (2bits/sample)
     chan_def = :  4836.00 MHz : U :  16.00 MHz : &CH01 : &BBC01 : &U_Cal; *Lcp
     chan_def = :  4836.00 MHz : L :  16.00 MHz : &CH02 : &BBC01 : &U_Cal; *Lcp
     chan_def = :  4836.00 MHz : U :  16.00 MHz : &CH03 : &BBC02 : &U_Cal; *Rcp
     chan_def = :  4836.00 MHz : L :  16.00 MHz : &CH04 : &BBC02 : &U_Cal; *Rcp
enddef;
*------------------------------------------------------------------------------
$IF;
*
def LO@8080MHzRPolNoTone;
* mode =  1    stations =Sv:Zc
     if_def = &IF_A : A : R :  8080.00 MHz : U ; * PCall off!   0.0   0.0  4cm     0 NA
enddef;
*
def LO@7700MHzRPolNoTone;
* mode =  1    stations =Ef
     if_def = &IF_A1 : A1 : R :  7700.00 MHz : U ; * PCall off!   0.0   0.0  NA     0 NA
     if_def = &IF_B1 : B1 : R :  7700.00 MHz : U ; * PCall off!   0.0   0.0  NA     0 NA
enddef;
*
def LO@7580MHzRPolNoTone;
* mode =  1    stations =Wn
     if_def = &IF_B : B : R :  7580.00 MHz : U ; * PCall off!   0.0   0.0  omit     0 NA
enddef;
*
def LO@4500MHzDPolTone/1;
* mode =  2    stations =Pu
     if_def = &IF_A : A : L :  4500.00 MHz : U : 1 MHz ; *   0.0   0.0  omit     0 NA
     if_def = &IF_B : B : R :  4500.00 MHz : U : 1 MHz ; *   0.0   0.0  omit     0 NA
enddef;
*------------------------------------------------------------------------------
$BBC;
*
def 4BBCs;
* mode =  1    stations =Sv:Zc
     BBC_assign = &BBC01 :  1 : &IF_A;
     BBC_assign = &BBC02 :  2 : &IF_A;
     BBC_assign = &BBC03 :  3 : &IF_A;
     BBC_assign = &BBC04 :  4 : &IF_A;
enddef;
*
def 4BBCs#02;
* mode =  1    stations =Ef
     BBC_assign = &BBC01 :  1 : &IF_A1;
     BBC_assign = &BBC03 :  3 : &IF_A1;
     BBC_assign = &BBC05 :  5 : &IF_B1;
     BBC_assign = &BBC07 :  7 : &IF_B1;
enddef;
*
def 4BBCs#03;
* mode =  1    stations =Wn
     BBC_assign = &BBC05 :  5 : &IF_B;
     BBC_assign = &BBC06 :  6 : &IF_B;
     BBC_assign = &BBC07 :  7 : &IF_B;
     BBC_assign = &BBC08 :  8 : &IF_B;
enddef;
*
def 2BBCs;
* mode =  2    stations =Pu
     BBC_assign = &BBC01 :  1 : &IF_A;
     BBC_assign = &BBC02 :  2 : &IF_B;
enddef;
*------------------------------------------------------------------------------
$PHASE_CAL_DETECT;
*
def NoDetect;
* mode =  1    stations =Ef:Sv:Zc:Wn
     phase_cal_detect = &NoCal;
enddef;
*
def DsbDetect;
* mode =  2    stations =Pu
     phase_cal_detect = &U_Cal :  2 : 16 :  0;
enddef;
*------------------------------------------------------------------------------
$TRACKS;
*
def MARK5B.4Ch2bit1to1;
* mode =  1    stations =Sv:Zc
*    format = MARK5B, and fan-out = 1
*    mode requires   8.00Mb/s/tr; stations using disks
     track_frame_format = MARK5B;
     fanout_def =   : &CH01 : sign : 1:  2;
     fanout_def =   : &CH01 :  mag : 1:  3;
     fanout_def =   : &CH02 : sign : 1:  4;
     fanout_def =   : &CH02 :  mag : 1:  5;
     fanout_def =   : &CH03 : sign : 1:  6;
     fanout_def =   : &CH03 :  mag : 1:  7;
     fanout_def =   : &CH04 : sign : 1:  8;
     fanout_def =   : &CH04 :  mag : 1:  9;
enddef;
*
def VDIF.4Ch2bit1to1;
* mode =  1    stations =Ef
*    firmware_type = DBBC_DDC;
*    format = VDIF, and fan-out = 1
*    mode requires   8.00Mb/s/tr; stations using disks
     track_frame_format = VDIF5032;
     fanout_def =   : &CH01 : sign : 1:  1;
     fanout_def =   : &CH01 :  mag : 1:  1;
     fanout_def =   : &CH02 : sign : 1:  2;
     fanout_def =   : &CH02 :  mag : 1:  2;
     fanout_def =   : &CH03 : sign : 1:  3;
     fanout_def =   : &CH03 :  mag : 1:  3;
     fanout_def =   : &CH04 : sign : 1:  4;
     fanout_def =   : &CH04 :  mag : 1:  4;
enddef;
*
def MARK5B.4Ch2bit1to1#02;
* mode =  1    stations =Wn
*    firmware_type = DBBC_DDC;
*    format = MARK5B, and fan-out = 1
*    mode requires   8.00Mb/s/tr; stations using disks
     track_frame_format = MARK5B;
     fanout_def =   : &CH01 : sign : 1:  2;
     fanout_def =   : &CH01 :  mag : 1:  3;
     fanout_def =   : &CH02 : sign : 1:  4;
     fanout_def =   : &CH02 :  mag : 1:  5;
     fanout_def =   : &CH03 : sign : 1:  6;
     fanout_def =   : &CH03 :  mag : 1:  7;
     fanout_def =   : &CH04 : sign : 1:  8;
     fanout_def =   : &CH04 :  mag : 1:  9;
enddef;
*
def MARK5B.4Ch2bit1to1#03;
* mode =  2    stations =Pu
*    format = MARK5B, and fan-out = 1
*    mode requires  32.00Mb/s/tr; stations using disks
     track_frame_format = MARK5B;
     fanout_def =   : &CH01 : sign : 1:  2;
     fanout_def =   : &CH01 :  mag : 1:  3;
     fanout_def =   : &CH02 : sign : 1:  4;
     fanout_def =   : &CH02 :  mag : 1:  5;
     fanout_def =   : &CH03 : sign : 1:  6;
     fanout_def =   : &CH03 :  mag : 1:  7;
     fanout_def =   : &CH04 : sign : 1:  8;
     fanout_def =   : &CH04 :  mag : 1:  9;
enddef;
*------------------------------------------------------------------------------
$HEAD_POS;
def DiskVoid;
* mode =  1    stations =Ef:Sv:Zc:Wn
* mode =  2    stations =Pu
*     Head positions irrelevant for Disk: empty def
enddef;
*------------------------------------------------------------------------------
$PASS_ORDER;
*
def DiskVoid;
* mode =  1    stations =Ef:Sv:Zc:Wn
* mode =  2    stations =Pu
*     Pass orders irrelevant for Disk: empty def
enddef;
*------------------------------------------------------------------------------
$ROLL;
*
def NoRoll;
* mode =  1    stations =Ef:Sv:Zc:Wn
* mode =  2    stations =Pu
*    barrel-roll set to 'roll_off', so reverse-roll by  0 (1 head)
     roll = off;
enddef;
*------------------------------------------------------------------------------
$SCHED;
* schedule section for experiment el053h  
* RadioAstron sat. tracking                                               
scan No0001;
*     Note a COMMENT was inserted during scheduling: 
*       X-band scans
     start=2016y166d19h00m00s; mode=raxevn; source=EL053H;
*              :data_good:data_stop:goto_foot: pass:  wrap :driv:tape at
     station=Ef:    0 sec: 1800 sec:    0.000 GB:   :       : 1;
     station=Sv:    0 sec: 1800 sec:    0.000 GB:   :       : 1;
     station=Zc:    0 sec: 1800 sec:    0.000 GB:   :       : 1;
     station=Wn:    0 sec: 1800 sec:    0.000 GB:   :       : 1;
endscan;
scan No0002;
*     Note a COMMENT was inserted during scheduling: 
*       The following is to control the PUSH tracking station recorder
     start=2016y166d19h00m00s; mode=ra6cm2; source=EL053H;
     station=Pu:    0 sec:  570 sec:    0.000 GB:   :       : 1;
endscan;
scan No0003;
     start=2016y166d19h10m00s; mode=ra6cm2; source=EL053H;
     station=Pu:    0 sec:  570 sec:   18.269 GB:   :       : 1;
endscan;
scan No0004;
     start=2016y166d19h20m00s; mode=ra6cm2; source=EL053H;
     station=Pu:    0 sec:  600 sec:   36.538 GB:   :       : 1;
endscan;
