wiki:ShTools/Shtosac

Version 3 (modified by mbianchi, 15 years ago) (diff)

Update for version 0.2 of the release code induced by a user list question.

sh2sac

This is a draft page for the sh2sac tool.

Program description

This tool can help you to convert your Q-files to SAC file format. It can transcribe most of the default Q-files header variables. Also station coordinates are gathered from STATINF.DAT and filed into the SAC header. This program is coded in C language and tested on 32-bit linux machines only, no needs for libraries, only the basic C libraries.

Download

You can download it from here (version 0.2 - released 27/01/2009) or go for older versions at foo4fun.net.

Compile

To compile just type make.

Install

After you uncompress it, to install adjust the location where you want to install inside the Makefile and just type 'make install'.

Usage

Type sh2sac and it will show you a little help. But basically you should do:

  • If you have seismic handler installed and wants stations coordinates to be filled
sh2sac -h <QHD file> -b <QBN file> -stash
  • If you don't need station coordinates filled
sh2sac -h <QHD file> -b <QBN file>
  • If you DONT have seismic handler installed, and you want coordinates, them you must prepare a 4 column mode file and type:
   sh2sac -h <QHD file> -b <QBN file> -sta mycoordinatefile.txt

Any comments are very welcome !

Bianchi