Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

jp_afni.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002    Major portions of this software are copyrighted by the Medical College
00003    of Wisconsin, 1994-2000, and are released under the Gnu General Public
00004    License, Version 2.  See the file README.Copyright for details.
00005 ******************************************************************************/
00006    
00007 #ifndef _AFNI_EPI_HEADER_
00008 #define _AFNI_EPI_HEADER_
00009 
00010 /*-- Symbols to define what code to include for specific systems;  --*/
00011 /*-- exactly one of these must be #define-d, or things won't work. --*/
00012 
00013 #undef  AFNI_BRUKER_BRI
00014 #define AFNI_SIGNA_KECK
00015 
00016 /*************************  AFNI variables, etc.  ******************************/
00017 
00018 #include "iochan.h"                     /* I/O to other processes              */
00019 
00020 #define AFNI_CONTROL_PORT  7954         /* always send control data to AFNI    */
00021 #define AFNI_TCP_PORT      7953         /* maybe send image data to AFNI       */
00022 
00023 #define AFNI_OPEN_CONTROL_MODE   1      /* 1st time thru: open control channel */
00024 #define AFNI_WAIT_CONTROL_MODE   2      /* waiting for AFNI to open control    */
00025 #define AFNI_OPEN_DATA_MODE      3      /* now can open data channel to AFNI   */
00026 #define AFNI_CATCHUP_MODE        4      /* waiting for AFNI to open data       */
00027 #define AFNI_CONTINUE_MODE       5      /* at last! data channel is ready!     */
00028 
00029 /*-- global control variables --*/
00030 
00031 #ifdef MAIN
00032   int      AFNI_mode        = 0 ;    /* if > 0, then means AFNI is active  */
00033   int      AFNI_use_tcp     = 0 ;    /* if > 0, use TCP/IP to send images */
00034   char     AFNI_host[128]   = "\0" ; /* hostname of CPU AFNI is on       */
00035   char     AFNI_iochan[128] = "\0" ; /* I/O channel name to AFNI        */
00036   IOCHAN * AFNI_ioc         = NULL ; /* ptr to I/O channel itself      */
00037   int      AFNI_atexit_setup= 0    ; /* is AFNI_exit setup yet?       */
00038   char     AFNI_buf[1024]          ; /* temporary space              */
00039   int      AFNI_verbose     = 0    ; /* debugging mode              */
00040 
00041 #if defined(AFNI_BRUKER_BRI)
00042   char     AFNI_infocom[256]= "3T_toafni" ; /* command for AFNI info */
00043 #elif defined(AFNI_SIGNA_KECK)
00044   char     AFNI_infocom[256]= "\0" ;        /* no command for AFNI */
00045 #endif
00046 
00047 #else
00048   extern int      AFNI_mode ;
00049   extern int      AFNI_use_tcp ;
00050   extern char     AFNI_host[] ;
00051   extern char     AFNI_iochan[] ;
00052   extern IOCHAN * AFNI_ioc ;
00053   extern char     AFNI_buf[] ;
00054   extern int      AFNI_atexit_setup ;
00055   extern char     AFNI_infocom[] ;
00056   extern int      AFNI_verbose ;
00057   extern int      read_Signa_cvs() ;
00058 #endif
00059 /*******************************************************************************/
00060 
00061 /*-- prototypes --*/
00062 
00063 extern void AFNI_start_io(int) ;
00064 extern void AFNI_send_image(int) ;
00065 extern void AFNI_exit(void) ;
00066 
00067 /*-- help string --*/
00068 
00069 #ifdef MAIN
00070 #define AFNI_HELP_STRING                                                \
00071   "\n"                                                                  \
00072   "\n-afni host       - Send reconstructed images to AFNI running on"   \
00073   "\n                   computer 'host':"                               \
00074   "\n                    * If 'host' = '%%' or '.', then the local"     \
00075   "\n                      system will be used, and data will be"       \
00076   "\n                      transferred to AFNI with shared memory."     \
00077   "\n                    * For other values of 'host', a TCP/IP socket" \
00078   "\n                      will be used to transfer data to AFNI.  If"  \
00079   "\n                      you want to use TCP/IP on the local system," \
00080   "\n                      use 'localhost'."                            \
00081   "\n                    * You must start AFNI with the command"        \
00082   "\n                      'afni -rt' for it to be able to accept"      \
00083   "\n                      image data in realtime."                     \
00084   "\n-verbose          - turn on debug messages for AFNI I/O"
00085 #endif
00086 
00087 /*-- how to execute a command on another system --*/
00088 
00089 #ifdef HP
00090 # define RSH "remsh"
00091 #else
00092 # define RSH "rsh"
00093 #endif
00094 
00095 /*=============================================================================*/
00096 #endif /* _AFNI_EPI_HEADER_ */
 

Powered by Plone

This site conforms to the following standards: