# This is a CPC configuration file for the SMPS device in Kosetice. # # The configuration file is a Perl code. The names of the variables do not # matter, you will return them as a reference to an anonymous hash at the # end of the file. Anyway, the names are selected in such a way to be # descriptive. Needless to say the variables should be declared as 'my' in # order not to conflict with the program. # # All information is stored in hashes. Some keys are mandatory and the # program will read these variables. You can add other information such as # location of the instrument, serial number etc. This information will be # silently ignored. You can use any key names with the exception that names # in the form of '__name__' are reserved. The module for parsing the # configuration file will add such keys for its internal use. # # The file may contain CPC information for several SMPS/DMPS # instruments. You can thus either create one file per SMPS/DMPS # instrument or put everything into a single file where the instruments # will be identified by names. # This variable is a default timezone that will be used if it is not # specified in the time value. It is a string in the format valid in # ISO-8601 but the plus sign as well as leading zeros may be omitted. # UTC may be specified as 'Z'. my $tz = '+00:00'; # Put all your CPC's here. The hash contains references to hashes, each # hash contains all information on the CPC and its calibration. The CPC # is identified either by nameed as the key (string). # Since the calibration types are defined per # CPC, the type value should be given. Currently 3010 and 3025 are # supported. If the CPC was mostly calibrated at a different timezone # than the default, it may also be given. You can add any key you wish # for identification such as model, serial number etc. The 'calib' # member is a reference to a hash with three members: 'xtime' is the time of # calibration (or first use after calibration, 'type' is the calibration # type, 'par' is the reference to an array of parameters. You can add # arbitrary additional members. The 'type' member will usually be # missing and its value defaults to the CPC's type. The only exception # is type=0 meaning that the CPC is uncalibrated. In such a case 'par' # may be omitted. # As a matter of fact, 'xtime' is the time since calibration is valid. # If you run the CPC uncalibrated, then calibrate it, and you believe # that the calibration was valid even before, set 'timex' to the # date/time from when it is used. my %cpc = ( cpc3022 => { serial_number => 269, produced => 'May 192', type => 3010, detection_limit_ccm => '0.01 1/cm3', calib => [ { xtime => '2006-11-30T00:00:00', par => [88.62269, 128.08304, 1.92156, 5.8902], comment => 'Exact day in November not known' } ] }, cpc3775 => { serial_number => 70721044, produced => 'June 2007', type => 3010, detection_limit_ccm => '0.01 1/cm3', calib => [ { xtime => '2008-01-01T00:00:00Z', par => [93.09654, 235.72992, 9.243e-16, 5.17547], comment => 'Parameter c is effectively zero!' } ] }, cpc3772 => { serial_number => 707229281, type => 3772, detection_limit_ccm => '0.001 1/cm3', calib => [ { xtime => '2011-04-21T00:00:00', par => [1, 5.64566, 3.19005], comment => 'calibrated later' } ] }, uncalibrated => { type => 1, detection_limit_ccm => '0.001 1/cm3', calib => [ { xtime => '1990-01-01T00:00:00', par => 1, comment => 'Generic uncalibrated CPC' } ] } ); # Define assignment of CPC's to the SMPS/DMPS instruments. If you have # just one instrument, use the name 'default', otherwise repeat the # assignment for each instrument using selected names. This means, the # hash will have as many membar as the number of instrtuments. Each # member corresponding to the instrument is a hash reference containing # arbitrary members. The mandatory member is 'cpc', an array reference the # elements of which are hash references with two members: 'xtime' is the # start time when a CPC was connected, 'cpc' is the name of the CPC (the # key used in %cpc). The times need not be the same as the times of # calibration. If timezone is not given in the time value, either the # 'tz' member of the instrument will be ised (if given) or the global # one will be used. my %instr = ( SMPS_KOS => { station => 'CZ03R', cpc => [ { xtime => '2008-04-01T00:00:00', cpc => 'cpc3775', comment => 'Official measurement since 2008-05-01' }, { xtime => '2008-08-05T10:00:00', cpc => 'cpc3022', comment => 'Changed from 08:45 to 11:10' }, { xtime => '2010-08-20T08:50:00', cpc => 'cpc3775' }, { xtime => '2010-08-25T09:20:00', cpc => 'cpc3022' }, { xtime => '2010-12-29T13:00:00', cpc => 'cpc3775' }, { xtime => '2011-03-04T10:30:00', cpc => 'cpc3022' }, { xtime => '2011-04-21T00:00:00', cpc => 'cpc3772' }, ] }, SMPS_Suchdol => { station => 'Suchdol', cpc => [ { xtime => '2012-01-01T00:00:00', cpc => 'cpc3772' }, ] }, NAOK_Ground_MPSS_Tropos_3 => { station => 'NAOK', cpc => [ { xtime => '2022-07-01T00:00:00Z', cpc => 'cpc3775' }, ] }, Prague_Suchdol_MPSS_Tropos_2 => { station => 'Suchdol', cpc => [ { xtime => '2022-01-01T00:00:00Z', cpc => 'uncalibrated' } ] } ); # Make the variables known to the calling program. You should not change # this code. If you remove the 'tz' member, the global timezone will not # be used. Missing timezones in the time specification will then be # considered an error. { tz => $tz, cpc => \%cpc, instr => \%instr };