Main Page | Class List | Directories | File List | Class Members | File Members

iniconfig.c File Reference

configuration files More...

#include <stdlib.h>
#include <stdio.h>
#include <math.h>
#include <string.h>
#include <unistd.h>
#include <time.h>
#include <stdarg.h>
#include "fitsoutput.h"
#include "iniconfig.h"
#include "iniparser.h"
#include "ccu.h"
#include "logfile.h"
#include "instctrl.h"
#include "telescope.h"
#include "error.h"
#include "auto.h"
#include "texoutput.h"

Functions

char * myown_getstring (dictionary *ini, char *key)
 a replacement for the iniparser library getstring routine. It does some file existance checking.
int init_configfile ()
 (constructor) initializes the ini file configuration system and loads the parameter for all other .c files (modules)
int iniconfig_load_database_ini (char *name)
 load the parameters of a ccd chip with associated readout sequence from an .ini file
int inifile_update_sequence_context ()
 updates the sequence context information received from the CCU using the information in the goccia.ini file
int configfileRcheck (char *filename, char *msg)
 checks whether a file can be opend in read mode
int configfileARcheck (char *filename, char *msg)
 checks whether a file can be opend in append and read mode
int configfile_checkfiles (struct instctrl_filename_struct filenames, struct telescope_filename_struct tel_filenames)
 checks all needed files for accessability
int inifile_finish ()
 checks all needed files for accessability

Variables

char ininame [1000]
char fitsoutput_path [1000]
char fitsoutput_prefix [1000]
char fitsoutput_suffix [1000]
char fitsoutput_sextractorname [1000]
char fitsoutput_sexfilename [1000]
char fitsoutput_replacekeyname [1000]
char fitsoutput_fitsmd5name [1000]
char fitsoutput_astrometryname [1000]
char gui_saods9name [1000]
char ini_name [1000] = "../config/gboccia.ini"
int configfile_parsingerror


Detailed Description

configuration files

Copyright (C) 2001-2003 Dirk Huenniger (dhun@astro.uni-bonn.de)

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.


Function Documentation

int configfile_checkfiles struct instctrl_filename_struct  filenames,
struct telescope_filename_struct  tel_filenames
 

checks all needed files for accessability

Parameters:
filenames the filenames of the instrument control system
tel_filenames the filename(s) of the telescope control system
Returns:
int error code
This function checks all needed files for accessability.

int configfileARcheck char *  filename,
char *  msg
 

checks whether a file can be opend in append and read mode

Parameters:
filename the file to be checked
msg a human readable string descibing the purpose of the file
Returns:
int error code
This function checks whether a file can be opend in append and read mode. Otherwise it print an error message.

int configfileRcheck char *  filename,
char *  msg
 

checks whether a file can be opend in read mode

Parameters:
filename the file to be checked
msg a human readable string descibing the purpose of the file
Returns:
int error code
This function checks whether a file can be opend read mode. Otherwise it print an error message.

int iniconfig_load_database_ini char *  name  ) 
 

load the parameters of a ccd chip with associated readout sequence from an .ini file

Parameters:
name the name of the .ini file containing the information to be read
Returns:
int error code
This function load the parameters of a ccd chip with associated readout sequence from an .ini file

int inifile_finish void   ) 
 

checks all needed files for accessability

Returns:
int error code
This function checks all needed files for accessability.

int inifile_update_sequence_context  ) 
 

updates the sequence context information received from the CCU using the information in the goccia.ini file

Returns:
int error code
This function updates the sequence context information received from the CCU using the information in the goccia.ini file

int init_configfile void   ) 
 

(constructor) initializes the ini file configuration system and loads the parameter for all other .c files (modules)

Returns:
int error code
This function initialized the ini file configuration system and loads the parameter for all other .c files (modules)

char* myown_getstring dictionary *  ini,
char *  key
 

a replacement for the iniparser library getstring routine. It does some file existance checking.

Returns:
the string found, "error parsing confile" in case of error.
This function is a replacement for the iniparser library getstring routine. It does some file existance checking.


Variable Documentation

int configfile_parsingerror
 

an error code indicating if something went wrong when parsing the .ini files

char fitsoutput_astrometryname[1000]
 

the command to run a script to optimize the astrometry of the system

char fitsoutput_fitsmd5name[1000]
 

the command to calculate the md5sum of the datasection of a .fits file

char fitsoutput_path[1000]
 

the path to write .fits files

char fitsoutput_prefix[1000]
 

the filename prefix for .fits files

char fitsoutput_replacekeyname[1000]
 

the command to replace a key in a .fits file

char fitsoutput_sexfilename[1000]
 

the name of the output file of sextractor

char fitsoutput_sextractorname[1000]
 

the command to run sextrctor

char fitsoutput_suffix[1000]
 

the filename suffix for .fits files

char gui_saods9name[1000]
 

the command to run a fits viewer

char ini_name[1000] = "../config/gboccia.ini"
 

the name of the main ini file

char ininame[1000]
 

the name of the main ini file (gboccia.ini)


Generated on Fri Dec 16 22:23:38 2005 for gboccia by  doxygen 1.4.2