next up previous
Next: Reference Up: Librdsmafits.a : a C Previous: 2. Description of librdsmafits.a

3. Usages and examples

The library is located at /home/tsutsumi/sniffer/lib on smadata(Cambrdige). Programs that make use of librdsmafits.a need fits_reader.h and smadb.h to be included. To compile such programs, the following command could be used.
gcc -o main_program main_program.c -I/home/tsutsumi/lib librdsmafits.a

To demonstrate how these routines can be used, a sample program is given in Appendix. This program reads all tables in an SMA FITS file and print out some of the parameters on console.


Figure 1: SMA off-line data flow. A forked process, FITStoDB, will call the librdsmafits.a to extract the header information from the SMA FITS tables and store the data into SYBASE. A FITS-IDI loader, SMALD, will use the librdsmafits.a to convert SMA FITS file into a format that can be handled in a specified radio interferometry data reduction package.


Takahiro (Tak) Tsutsumi
9/30/1999