Changeset 17403 for trunk/FACT++


Ignore:
Timestamp:
11/30/13 19:10:00 (11 years ago)
Author:
tbretz
Message:
Only park telescope during ovtest when it is deep dark time.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/scripts/Main.js

    r17356 r17403  
    683683// ----------------------------------------------------------------
    684684dim.log("Entering main loop.");
     685console.out("");
    685686
    686687var run = -2; // getObservation never called
     
    696697        return false;
    697698
     699    if (irq.toUpperCase()=="RESCHEDULE")
     700        return true;
     701
    698702    if (irq.toUpperCase()=="OFF")
    699703    {
     
    750754    if (lastId!=obs.id) // !Object.isEqual(obs, nextObs)
    751755    {
    752         console.out("");
    753756        dim.log("Starting new observation ["+obs.start.toUTCString()+", id="+obs.id+"]");
    754757
     
    939942
    940943    case "OVTEST":
    941         dim.send("DRIVE_CONTROL/PARK");
     944        var park = Sun.horizon(-27).isUp;
     945        if (park)
     946            dim.send("DRIVE_CONTROL/PARK");
    942947        dim.send("FEEDBACK/STOP");
    943948
     
    945950        CloseLid();
    946951
    947         console.out("Waiting for telescope to park. This may take a while.");
    948         dim.wait("DRIVE_CONTROL", "Locked", 3000);
     952        if (park)
     953        {
     954            console.out("Waiting for telescope to park. This may take a while.");
     955            dim.wait("DRIVE_CONTROL", "Locked", 3000);
     956        }
    949957
    950958        // Check if DRS calibration is necessary
     
    11721180
    11731181    if (nextObs!=undefined && sub==obs.length-1)
    1174     {
    11751182        dim.log("Next observation will start at "+nextObs.start.toUTCString()+" [id="+nextObs.id+"]");
    1176         console.out("");
    1177     }
    11781183
    11791184    sub++;
Note: See TracChangeset for help on using the changeset viewer.