home *** CD-ROM | disk | FTP | other *** search
- /*******************************************************************/
- /* */
- /* uio_strc.h - structure definitions for UserIO interface */
- /* arguments */
- /* Author: John C. Fairman August 31, 1990 */
- /* Copyright 1990 by NeuralWare Inc. */
- /* */
- /* $Author : $ */
- /* $Date : $ */
- /* $Source : $ */
- /* $Revision : $ */
- /* $Log : $ */
- /* */
- /*******************************************************************/
-
- #ifndef UIO_STRC_H
- #define UIO_STRC_H 1
-
-
-
- #if 0 /* If you want a full test you must define FULLTEST here
- since THINK_C doesn't have command line defines */
- #ifdef THINK_C
- #define FULLTEST 1
- #endif /* THINK_C */
- #endif
-
-
-
- /**/
- typedef struct {
- SREAL ape_I; /* sum */
- SREAL ape_Tran; /* tran */
- SREAL ape_Output; /* output */
- SREAL ape_Err; /* error */
- SREAL ape_CumErr; /* cumulative error */
- UNINT ape_Flags; /* flags */
- } APE;
-
- typedef struct {
- SL asc_recall; /* recall counter */
- SREAL asc_rcl[5]; /* recall data */
- SL asc_learn; /* learn counter */
- SREAL asc_lrn[4]; /* learn data */
- } ASCOL;
-
- typedef struct {
- TEXT asc_nam[16]; /* schedule name */
- ASCOL asc_col[5]; /* data columns */
- } ASCHED;
-
- typedef struct {
- UNINT start_in;
- UNINT start_out;
- SREAL min_in;
- SREAL max_in;
- SREAL min_out;
- SREAL max_out;
- } IOPARMS;
-
- #ifndef N2PRUNE
- #ifndef NPHIST
- #define NPHIST 100 /* # of items in histogram */
- #endif
- typedef struct {
- SL PRNwts; /* # of weights in network */
-
- SREAL PRMin; /* smallest weight */
- SREAL PRMax; /* maximum weight */
- SREAL PRSum; /* sum of weights */
- SREAL PRAverage; /* average weight */
- SREAL PRMedian; /* median value */
- NINT PRHist[NPHIST]; /* histogram of weights */
-
- SREAL PRMinA; /* min absolute magnitude */
- SREAL PRMaxA; /* max absolute magnitude */
- SREAL PRSumA; /* sum of abs values */
- SREAL PRAverageA; /* average absolute weight */
- SREAL PRMedianA; /* median of magnitudes */
- NINT PRHistA[NPHIST]; /* histogram of magnitudes */
- } PRSTATS; /* prune statistics */
- #endif
-
- /* Window management */
- #if defined(USES_WINDOWS) && !defined(TEST)
- struct _uwin /* user i/o window */
- {
- UB uw_flag; /* flag for in use */
- #define UWF_INUSE 0x01 /* this window is "inuse" */
- #define UWF_UNDISP 0x02 /* window has been erased */
- UB uw_color; /* background color */
- RECTANGLE uw_box; /* coordinates of the box */
- };
- typedef struct _uwin UWIN;
-
- #define NWINS 8
- #endif /* defined(USES_WINDOWS) && !defined(TEST) */
-
- /* Host UIO errors */
- #define UNABLE_TO_ALLOCATE_VEC 0x80
-
- /* Server UIO errors */
- #define BAD_WINDOW_NUMBER 0x90
-
- /* User Return Values */
- #define UIO_OK 0
- #define UIO_UPDATE 1
- #define UIO_EXIT 2
- #define UIO_ERROR -1
-
-
- #ifdef HOME_FOR_UIO_DATA
-
-
- #ifdef UIO_SERVER
- NINT gm_intcolor; /* interior color */
- NINT gm_outcolor; /* outline color */
- NINT gm_txtcolor; /* text color */
- #endif
-
- #if !defined(UIO_SERVER) || !defined(EMULATING)
- NINT UIO_error_value = 0;
- #else /* !defined(UIO_SERVER) || !defined(EMULATING) */
- IMPORT NINT UIO_error_value;
- #endif /* else of !defined(UIO_SERVER) || !defined(EMULATING) */
-
- #else /* HOME_FOR_UIO_DATA */
-
- IMPORT NINT UIO_error_value;
-
-
- #ifdef UIO_SERVER
- IMPORT NINT gm_intcolor; /* interior color */
- IMPORT NINT gm_outcolor; /* outline color */
- IMPORT NINT gm_txtcolor; /* text color */
- #endif
-
- #endif /* HOME_FOR_UIO_DATA */
-
-
- #ifndef SKIP_COMPAT_DATA
-
- #ifdef HOME_FOR_COMPAT_DATA
- SREAL *IODATA = (SREAL *)NULL;
- NINT IOCOUNT = 0;
- NINT IOLAYER = 0;
- NINT IOREQCDE = 0;
- NINT IORTNCDE = 0;
- #else /* HOME_FOR_COMPAT_DATA */
- IMPORT SREAL *IODATA;
- IMPORT NINT IOCOUNT;
- IMPORT NINT IOLAYER;
- IMPORT NINT IOREQCDE;
- IMPORT NINT IORTNCDE;
- #endif /* else of HOME_FOR_COMPAT_DATA */
-
- #endif /* USES_COMPAT_DATA */
-
- /**/
-
- #ifdef MAC
- #include "macuio.h"
- #endif
-
- /* Usual configuration */
- #define GRUPDATE(a, b, c) GRUpdate(a, b, c); /* <- note ';' */
- #define MOVEMEM(a, b, c) memcpy((char *)a, (char *)b, (size_t)c)
- #define SET_STRUCTS_EQ(a, b) a = (b)
- #define CTRIO_T long
- #define TRIAL_NUM_T long
- #define MSGLEN_T int
- #define MSGDIR_T int
-
- /* Variants from the usual configuration */
- #if defined(IBP) || defined(I860) || defined(IBM)
- #ifdef HOST
- #undef CTRIO_T
- #define CTRIO_T int
- #undef TRIAL_NUM_TYPE
- #define TRIAL_NUM_TYPE int
- #endif
- #if defined(NDP) || defined (__ZTC__)
- #define REAL_ARGS_PROBLEM
- #endif
- #endif
-
- #if defined(MAC)
- #ifdef HOST
- #undef MSGLEN_T
- #define MSGLEN_T short
- #undef MSGDIR_T
- #define MSGDIR_T short
- #endif
- #endif
-
- #endif /* ifndef UIO_STRC_H */
-