!-------------------------------------------------------------------------------
!
!      BC_ACS RESOURCE FILE
!
!
!      This file is used to construct the trigger, error, and success status
!      fields in the observation status file.
!
!
!-------------------------------------------------------------------------------
!                          REVISION HISTORY
!-------------------------------------------------------------------------------
!   DATE     PR  Developer  Description
! -------- ----- ---------- ----------------------------------------------------
! 10/08/01 44598 MSwam      first version
! 11/02/01 44524 J.Baum     add ENV variables for exposure_times.pl
! 01/30/02 44524 J.Baum     fix value of OK_TO_UPDATE_DATABASE
! 10/08/03 49496 MSwam      change OTFR_WORLD to UPDATE_EXPOSURE_TIMES
! 11/13/03 49799 J.Baum     Add FGS_DATA_ID ENV parameter 
! 07/19/06 52625 Sherbert   Remove extraneous OSF_RANK entry
! 11/13/06 49671 Hamilton   Changed HT to FT
!
!-------------------------------------------------------------------------------

PROCESS_NAME = bc_acs  ! Short name for process id
TASK = <xpoll -p $PATH_FILE -r bc_acs>
COMMAND = bc_acs.csh  ! Name of the command procedure
DESCRIPTION = 'ACS Before Calibration'
SYSTEM = OPUS
CLASS = ACS

OSF_RANK = 1                ! OSF Triggers
OSF_TRIGGER1.BC = w         ! wait in pre calibration
OSF_TRIGGER1.DATA_ID = aca  ! ACS association normally

OSF_TRIGGER2.BC = w         ! wait in pre calibration
OSF_TRIGGER2.DATA_ID = acs  ! ACS singletons too

OSF_PROCESSING.BC  = p      ! Set flag while 'Processing'

XPOLL_STATE.00 = OSF_NORMAL ! Normal: Completed pre calibration successfully
OSF_NORMAL.BC      = c      ! 
OSF_NORMAL.CA      = w      ! Wait for next stage

XPOLL_STATE.01 = OSF_ERROR  ! Error during pre calibration
OSF_ERROR.BC       = e      ! 

XPOLL_STATE.02 = OSF_NOCAL  ! Bypass calibration
OSF_NOCAL.BC       = n      ! No calibration required.
OSF_NOCAL.CA       = n      !
OSF_NOCAL.AC       = n      !
OSF_NOCAL.FT       = w      !

XPOLL_ERROR.BC = x          ! Set osf to this if exit state is undefined.

POLLING_TIME       = 10     ! Wait (seconds) before polling for next 
MINBLOCKS     = 1000000     ! blocks required on output disk
ENV.INPATH         = ACS_SIS_DIR       ! Where the .trx file is found
ENV.OUTPATH        = ACS_CAL_DIR       ! Directory where output files are written
ENV.CAL_OUTFILE_EXT = acs_cal_file_ext ! file extension for deleting CAL products
ENV.ARCH_SERVER    = ARCH_SERVER
ENV.ARCH_DB        = ARCH_DB

ENV.OPUS_DB = OPUS_DB
ENV.SPSS_DB = SPSS_DB
ENV.DSQUERY = DSQUERY
ENV.ASSIST_DB = ASSIST_DB
ENV.OK_TO_UPDATE_DATABASE = OK_TO_UPDATE_DATABASE ! determined by path file
ENV.UPDATE_EXPOSURE_TIMES = update_exposure_times
ENV.FGS_PATH_NAME = FGS_PATH      ! fgs path name or NULL, set in path file
ENV.FGS_DATA_ID = fgs             ! data_id used in FGS pipeline for jitter
ENV.FGS_RCHECK_COLUMN = RJ        ! RCHECK stage in fgs pipeline
ENV.FGS_HOLD_STATUS = h           ! RJ value indicating a hold status  
ENV.FGS_RESTART_STATUS = w        ! RJ value to restart RCHECK process
