/* **********************************************************************
 * *                                                                    *
 * *               INCLUDE Definitions for IRIS Watchdog                *
 * *                                                                    *
 * **********************************************************************
 * File: iris/watchdog/watchdog.h
 *
 *          COPYRIGHT (c) 1989, 1993, 1996, 1998, 2000, 2003 BY
 *          SIGMET INCORPORATED, WESTFORD MASSACHUSETTS, U.S.A.
 *
 * THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED
 * ONLY  IN  ACCORDANCE WITH  THE  TERMS  OF  SUCH  LICENSE  AND WITH THE
 * INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE  OR  ANY OTHER
 * COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY
 * OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY
 * TRANSFERED.
 */

#define     ANT_SHUTDOWN     1
#define WAT_ANT_SHUTDOWN     (WAT_FACILITY + ANT_SHUTDOWN  )
#define     BITE_ALL_CLEAR   2
#define WAT_BITE_ALL_CLEAR   (WAT_FACILITY + BITE_ALL_CLEAR)
#define     BITE_CRITICAL    3
#define WAT_BITE_CRITICAL    (WAT_FACILITY + BITE_CRITICAL)
#define     BITE_CRITICAL_OK 4
#define WAT_BITE_CRITICAL_OK (WAT_FACILITY + BITE_CRITICAL_OK)
#define     BITE_FAULT       5
#define WAT_BITE_FAULT       (WAT_FACILITY + BITE_FAULT)
#define     BITE_FAULT_OK    6
#define WAT_BITE_FAULT_OK    (WAT_FACILITY + BITE_FAULT_OK)
#define     ING_COUNT        7
#define WAT_ING_COUNT        (WAT_FACILITY + ING_COUNT      )
#define     ING_KEPT_DEL     8
#define WAT_ING_KEPT_DEL     (WAT_FACILITY + ING_KEPT_DEL   )
#define     LEVEL_STUCK      9
#define WAT_LEVEL_STUCK      (WAT_FACILITY + LEVEL_STUCK )
#define     MODE_BLOCKED     10
#define WAT_MODE_BLOCKED     (WAT_FACILITY + MODE_BLOCKED )
#define     MODE_CHANGE_PRO  11
#define WAT_MODE_CHANGE_PRO  (WAT_FACILITY + MODE_CHANGE_PRO )
#define     MODE_CHANGE_RCP  12
#define WAT_MODE_CHANGE_RCP  (WAT_FACILITY + MODE_CHANGE_RCP )
#define     MODE_CHANGE_SOC  13
#define WAT_MODE_CHANGE_SOC  (WAT_FACILITY + MODE_CHANGE_SOC )
#define     MODE_CHANGE_STA  14
#define WAT_MODE_CHANGE_STA  (WAT_FACILITY + MODE_CHANGE_STA )
#define     MODE_RST_MATCH   15
#define WAT_MODE_RST_MATCH   (WAT_FACILITY + MODE_RST_MATCH )
#define     PRO_COUNT        16
#define WAT_PRO_COUNT        (WAT_FACILITY + PRO_COUNT      )
#define     PRO_INUSE        17
#define WAT_PRO_INUSE        (WAT_FACILITY + PRO_INUSE      )
#define     PRO_KEPT_DEL     18
#define WAT_PRO_KEPT_DEL     (WAT_FACILITY + PRO_KEPT_DEL   )
#define     STATUS_TIMEOUT   19
#define WAT_STATUS_TIMEOUT   (WAT_FACILITY + STATUS_TIMEOUT )
#define     ANT_SHUTUP       20
#define WAT_ANT_SHUTUP       (WAT_FACILITY + ANT_SHUTUP     )
#define     ANT_ALIVE        21
#define WAT_ANT_ALIVE        (WAT_FACILITY + ANT_ALIVE      )
#define     ANT_DEAD         22
#define WAT_ANT_DEAD         (WAT_FACILITY + ANT_DEAD       )
#define     BITE_BUTTON      23
#define WAT_BITE_BUTTON      (WAT_FACILITY + BITE_BUTTON    )
#define     TIMEZONE_CHANGED 24
#define WAT_TIMEZONE_CHANGED (WAT_FACILITY + TIMEZONE_CHANGED)

#ifndef MESSAGE_ONLY                      

#ifdef SIGMET_DSP_LIB_H
UINT2 implement_mode_switch     /* File: mode_change.c */
(const struct ymds_time *pCurrentYmds_a,
 Dsp *pDsp_a );          /* Dsp lib pointer, (NULL if not Radar) */
#endif  /* #ifdef SIGMET_DSP_LIB_H */

#ifdef SIGMET_DSP_LIB_H
void implement_schedule_switch  /* File: mode_change.c */
( UINT2 lrst_was_changed_a,
  Dsp *pDsp_a );          /* Dsp lib pointer, (NULL if not Radar) */
#endif  /* #ifdef SIGMET_DSP_LIB_H */

UINT2 lready                    /* File:watchdog.c */
  (UINT4* ilast_time_a,    /* Last time run, updated when going */
   UINT4 icurrent_time_a,  /* Current time */
   SINT4 iwait_time_a );   /* Min time between runs */

void watch_antenna(void);       /* File: fault.c */

void watch_bite(void);          /* File: fault.c */

void watch_status( UINT1 *plShortWait_a );    /* File: status_product.c */

#endif  /* #ifndef MESSAGE_ONLY */
