To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

Commit b26aa6e3 authored by holukas's avatar holukas
Browse files

Reworked binary conversion

parent fdd99c58
......@@ -4,8 +4,20 @@
<list default="true" id="254ecb79-655b-4854-8af6-177bb7347e8a" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/bico.py" beforeDir="false" afterPath="$PROJECT_DIR$/bico/bico.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/ops/bin.py" beforeDir="false" afterPath="$PROJECT_DIR$/bico/ops/bin.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/ops/vis.py" beforeDir="false" afterPath="$PROJECT_DIR$/bico/ops/vis.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/Bico.settings" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/Bico.settings" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/Bico.settingsOld" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/Bico.settingsOld" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/_version.py" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/_version.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/HS100-A.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/HS100-A.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA72-A.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA72-A.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA75-A-GN1.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA75-A-GN1.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA75-A.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/IRGA75-A.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/LGR-A.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/LGR-A.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/LGR-A.md" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/LGR-A.md" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/QCL-C.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/QCL-C.dblock" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/QCL-C.md" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/QCL-C.md" afterDir="false" />
<change beforePath="$PROJECT_DIR$/bico/settings/data_blocks/R350-A.dblock" beforeDir="false" afterPath="$PROJECT_DIR$/bico/settings/data_blocks/R350-A.dblock" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
......@@ -300,6 +312,16 @@
<workItem from="1609370919139" duration="36000" />
<workItem from="1609372690529" duration="1334000" />
<workItem from="1609375009054" duration="500000" />
<workItem from="1609407617084" duration="8821000" />
<workItem from="1609420602361" duration="87000" />
<workItem from="1609420737495" duration="7485000" />
<workItem from="1609540524549" duration="3746000" />
<workItem from="1609624902209" duration="1284000" />
<workItem from="1609752869076" duration="5434000" />
<workItem from="1609768185696" duration="14099000" />
<workItem from="1609852670010" duration="24000" />
<workItem from="1609859126683" duration="11243000" />
<workItem from="1609921205302" duration="15275000" />
</task>
<servers />
</component>
......@@ -308,6 +330,13 @@
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
<breakpoints>
<line-breakpoint enabled="true" suspend="THREAD" type="python-line">
<url>file://$PROJECT_DIR$/bico/ops/bin.py</url>
<line>231</line>
<option name="timeStamp" value="27" />
</line-breakpoint>
</breakpoints>
<default-breakpoints>
<breakpoint type="python-exception">
<properties notifyOnTerminate="true" exception="BaseException">
......@@ -325,7 +354,7 @@
<SUITE FILE_PATH="coverage/BICO$main.coverage" NAME="bico Coverage Results" MODIFIED="1598258463691" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/bico" />
<SUITE FILE_PATH="coverage/BICO_Binary_Converter$gui.coverage" NAME="gui Coverage Results" MODIFIED="1606435918815" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/bico" />
<SUITE FILE_PATH="coverage/BICO_Binary_Converter$main.coverage" NAME="main Coverage Results" MODIFIED="1596498134562" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/bico" />
<SUITE FILE_PATH="coverage/BICO_Binary_Converter$start_bico.coverage" NAME="start_bico Coverage Results" MODIFIED="1609375455556" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/bico" />
<SUITE FILE_PATH="coverage/BICO_Binary_Converter$start_bico.coverage" NAME="start_bico Coverage Results" MODIFIED="1609945717534" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/bico" />
<SUITE FILE_PATH="coverage/BICO_Binary_Converter$example.coverage" NAME="example Coverage Results" MODIFIED="1606348759035" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$/example" />
</component>
</project>
\ No newline at end of file
......@@ -15,7 +15,7 @@ from gui.gui import Ui_MainWindow
from ops import bin, format_data, vis, file, stats
from settings import _version
# TODO dataok check for hist
# TODO hs-50 status code format
# TODO LATER parallelize, multiprocessing?
# import multiprocessing as mp
......@@ -305,6 +305,7 @@ class Bico(qtw.QMainWindow, Ui_MainWindow):
def loop(self, bin_found_files_dict, dblocks_props, stats_coll_df, logger):
"""Process files"""
logger.info("Processing files ...")
num_bin_files = len(bin_found_files_dict)
# Get header for all data blocks
logger.info("Found variables:")
......@@ -332,7 +333,7 @@ class Bico(qtw.QMainWindow, Ui_MainWindow):
logger.info(f"[{bin_file}]")
logger.info("=" * (len(bin_file) + 2))
logger.info(" Reading binary file ...")
logger.info(f" Reading binary file #{counter_bin_files} of {num_bin_files}: {bin_file}...")
logger.info(f" Data block sequence: {self.dblocks_seq}")
# Read binary data
......
This diff is collapsed.
......@@ -266,7 +266,7 @@ def check_plot_data(ax, df, col):
dataok = False
isnumeric = False if df[col].dtypes == object else True
ishex = False if 'hexadecimal_value' not in col[1] else True
# isoctal = False if 'octal' not in col[1] else True
# isoctal = False if 'status_code_irga' not in col[1] else True
isemtpy = False if not df[col].dropna().empty else True
txt_warning = "-NOT-FOUND-"
......
run_id=BICO-20201231-014417
run_id=BICO-20210106-160838
# INSTRUMENTS
# ===========
......@@ -16,39 +16,39 @@ instrument_3=LGR-A
# ========
# Source Folder
dir_source=Y:/CH-INO_InnoFarm/20_sonic_ghg/2020/06
dir_source=Y:/CH-INO_InnoFarm/20_sonic_ghg/2020/05
# Time Range
start_date=2020-06-01 00:00
end_date=2020-06-02 00:00
start_date=2020-05-13 13:00
end_date=2020-05-13 13:00
# File Settings
filename_datetime_format=yyyymmddHH.XMM
file_ext=*.X*
file_size_min=900
file_limit=1
row_limit=100
file_limit=0
row_limit=0
# Special
select_random_files=0
# OUTPUT
# ======
dir_out=A:/FLUXES/x-TEST-OUT/holz
dir_out_run=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417
dir_out_run_log=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417\log
dir_out_run_plots=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417\plots
dir_out_run_plots_hires=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417\plots\hires
dir_out_run_plots_agg=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417\plots\agg
dir_out_run_raw_data_csv=A:\FLUXES\x-TEST-OUT\holz\_BICO-20201231-014417\raw_data_csv
dir_out=A:/FLUXES/x-TEST-OUT
dir_out_run=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838
dir_out_run_log=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\log
dir_out_run_plots=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots
dir_out_run_plots_hires=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots\hires
dir_out_run_plots_agg=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots\agg
dir_out_run_raw_data_csv=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\raw_data_csv
output_folder_name_prefix=
file_compression=gzip
output_folder_name_prefix=AES
file_compression=None
plot_file_availability=1
plot_ts_hires=1
plot_histogram_hires=1
plot_ts_agg=1
plot_file_availability=0
plot_ts_hires=0
plot_histogram_hires=0
plot_ts_agg=0
# DIRECTORIES
# ===================
......
run_id=BICO-20201231-014347
run_id=BICO-20210106-160838
# INSTRUMENTS
# ===========
......@@ -16,39 +16,39 @@ instrument_3=LGR-A
# ========
# Source Folder
dir_source=Y:/CH-INO_InnoFarm/20_sonic_ghg/2020/06
dir_source=Y:/CH-INO_InnoFarm/20_sonic_ghg/2020/05
# Time Range
start_date=2020-06-01 00:00
end_date=2020-06-02 00:00
start_date=2020-05-13 13:00
end_date=2020-05-13 13:00
# File Settings
filename_datetime_format=yyyymmddHH.XMM
file_ext=*.X*
file_size_min=900
file_limit=1
row_limit=100
file_limit=0
row_limit=0
# Special
select_random_files=0
# OUTPUT
# ======
dir_out=A:/FLUXES/x-TEST-OUT/holz
dir_out_run=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449
dir_out_run_log=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449\log
dir_out_run_plots=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449\plots
dir_out_run_plots_hires=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449\plots\hires
dir_out_run_plots_agg=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449\plots\agg
dir_out_run_raw_data_csv=A:\FLUXES\x-TEST-OUT\BICO-20201230-141449\raw_data_csv
dir_out=A:/FLUXES/x-TEST-OUT
dir_out_run=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838
dir_out_run_log=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\log
dir_out_run_plots=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots
dir_out_run_plots_hires=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots\hires
dir_out_run_plots_agg=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\plots\agg
dir_out_run_raw_data_csv=A:\FLUXES\x-TEST-OUT\AES_BICO-20210106-160838\raw_data_csv
output_folder_name_prefix=
file_compression=gzip
output_folder_name_prefix=AES
file_compression=None
plot_file_availability=1
plot_ts_hires=1
plot_histogram_hires=1
plot_ts_agg=1
plot_file_availability=0
plot_ts_hires=0
plot_histogram_hires=0
plot_ts_agg=0
# DIRECTORIES
# ===================
......
__version__ = "0.0.3"
__date__ = "31 Dec 2020"
__version__ = "0.0.5"
__date__ = "6 Jan 2021"
__link_source_code__ = "https://gitlab.ethz.ch/holukas/bico"
__link_releases__ = "https://gitlab.ethz.ch/holukas/bico/-/releases"
__link_wiki__ = "https://gitlab.ethz.ch/holukas/bico/-/wikis/home"
......
......@@ -3,13 +3,13 @@
# =========================
U == {'order': 1, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS50-A'}
V == {'order': 2, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS50-A'}
W == {'order': 3, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS50-A'}
T_SONIC == {'order': 4, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'K', 'datablock': 'HS50-A'}
STAA == {'order': 5, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'HS50-A'}
STAD == {'order': 6, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'HS50-A'}
INC_XY == {'order': 7, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'HS50-A'}
U == {'order': 1, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS100-A'}
V == {'order': 2, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS100-A'}
W == {'order': 3, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1_s-1', 'datablock': 'HS100-A'}
T_SONIC == {'order': 4, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'K', 'datablock': 'HS100-A'}
STAA == {'order': 5, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'HS100-A'}
STAD == {'order': 6, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'HS100-A'}
INC_XY == {'order': 7, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'HS100-A'}
# NOTES
......@@ -22,9 +22,9 @@ INC_XY == {'order': 7, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'off
# 'apply_gain' ... gain that is applied during conversion, e.g. to convert to different units if needed
# 'add_offset' ... offset that is added during conversion, e.g. to convert to different units if needed
#
# BICO ID: HS50-A
# Old ID in FCT: hs-50_extended
# Old data block in FCT: data_block_sonic_hs_50_extended
# BICO ID: HS100-A
# Old ID in FCT: hs_100
# Old data block in FCT: data_block_sonic_hs_100
#
# FCT FluxCalcTool source code:
# https://gitlab.ethz.ch/holukas/fct-flux-calculation-tool
......
......@@ -5,7 +5,7 @@
DATA_SIZE == {'order': 1, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Bytes', 'datablock': 'IRGA72-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'octal', 'datablock': 'IRGA72-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'status_code_irga', 'datablock': 'IRGA72-A'}
GA_DIAG_CODE == {'order': 3, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'bit_map', 'datablock': 'IRGA72-A'}
H2O_DRY == {'order': 4, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'mmol+1_mol-1', 'datablock': 'IRGA72-A'}
CO2_DRY == {'order': 5, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 10000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'umol+1_mol-1', 'datablock': 'IRGA72-A'}
......@@ -19,16 +19,16 @@ FLOW_VOLRATE == {'order': 12, 'bytes': 2, 'format': 'B B', 'gain_on_signal
# Values extracted from GA_DIAG_CODE:
# -------------------------------
UNUSED == {'order': 3.01, 'bit_pos_start': 0, 'bit_pos_end': 3, 'apply_gain': 1, 'add_offset': 0, 'units': 'unused', 'output': 1, 'datablock': 'IRGA72-A'}
HEAD_DETECT == {'order': 3.02, 'bit_pos_start': 3, 'bit_pos_end': 4, 'apply_gain': 1, 'add_offset': 0, 'units': '1=LI-7200', 'output': 1, 'datablock': 'IRGA72-A'}
T_OUTLET == {'order': 3.03, 'bit_pos_start': 4, 'bit_pos_end': 5, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
T_INLET == {'order': 3.04, 'bit_pos_start': 5, 'bit_pos_end': 6, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
AUX_INPUT == {'order': 3.05, 'bit_pos_start': 6, 'bit_pos_end': 7, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
DIFF_PRESS == {'order': 3.06, 'bit_pos_start': 7, 'bit_pos_end': 8, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
CHOPPER == {'order': 3.07, 'bit_pos_start': 8, 'bit_pos_end': 9, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
DETECTOR == {'order': 3.08, 'bit_pos_start': 9, 'bit_pos_end': 10, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
PLL == {'order': 3.09, 'bit_pos_start': 10, 'bit_pos_end': 11, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
SYNC == {'order': 3.10, 'bit_pos_start': 11, 'bit_pos_end': 12, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 1, 'datablock': 'IRGA72-A'}
UNUSED == {'order': 3.01, 'bit_pos_start': 0, 'bit_pos_end': 3, 'apply_gain': 1, 'add_offset': 0, 'units': 'unused', 'output': 0, 'datablock': 'IRGA72-A'}
HEAD_DETECT == {'order': 3.02, 'bit_pos_start': 3, 'bit_pos_end': 4, 'apply_gain': 1, 'add_offset': 0, 'units': '1=LI-7200', 'output': 0, 'datablock': 'IRGA72-A'}
T_OUTLET == {'order': 3.03, 'bit_pos_start': 4, 'bit_pos_end': 5, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
T_INLET == {'order': 3.04, 'bit_pos_start': 5, 'bit_pos_end': 6, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
AUX_INPUT == {'order': 3.05, 'bit_pos_start': 6, 'bit_pos_end': 7, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
DIFF_PRESS == {'order': 3.06, 'bit_pos_start': 7, 'bit_pos_end': 8, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
CHOPPER == {'order': 3.07, 'bit_pos_start': 8, 'bit_pos_end': 9, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
DETECTOR == {'order': 3.08, 'bit_pos_start': 9, 'bit_pos_end': 10, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
PLL == {'order': 3.09, 'bit_pos_start': 10, 'bit_pos_end': 11, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
SYNC == {'order': 3.10, 'bit_pos_start': 11, 'bit_pos_end': 12, 'apply_gain': 1, 'add_offset': 0, 'units': '1=OK', 'output': 0, 'datablock': 'IRGA72-A'}
SIGNAL_STRENGTH == {'order': 3.11, 'bit_pos_start': 12, 'bit_pos_end': 16, 'apply_gain': 6.6666666666666666, 'add_offset': 0, 'units': '%', 'output': 1, 'datablock': 'IRGA72-A'}
......@@ -3,7 +3,7 @@
# ====================================
DATA_SIZE == {'order': 1, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Bytes', 'datablock': 'IRGA75-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'octal', 'datablock': 'IRGA75-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'status_code_irga', 'datablock': 'IRGA75-A'}
DIAG_VAL == {'order': 3, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'bit_map', 'datablock': 'IRGA75-A'}
H2O_CONC == {'order': 4, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'mmol+1 m-3', 'datablock': 'IRGA75-A'}
CO2_CONC == {'order': 5, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 10000, 'offset_on_signal': 0, 'apply_gain': 0.974, 'add_offset': 0, 'units': 'mmol+1 m-3', 'datablock': 'IRGA75-A'}
......
......@@ -3,12 +3,12 @@
# ================================
DATA_SIZE == {'order': 1, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Bytes', 'datablock': 'IRGA75-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'octal', 'datablock': 'IRGA75-A'}
DIAG_VAL == {'order': 3, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'bit_map', 'datablock': 'IRGA75-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'status_code_irga', 'datablock': 'IRGA75-A'}
GA_DIAG_CODE == {'order': 3, 'bytes': 1, 'format': 'B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'bit_map', 'datablock': 'IRGA75-A'}
H2O_CONC == {'order': 4, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'mmol+1 m-3', 'datablock': 'IRGA75-A'}
CO2_CONC == {'order': 5, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 10000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'mmol+1 m-3', 'datablock': 'IRGA75-A'}
T_BOX == {'order': 6, 'bytes': 2, 'format': 'B B', 'gain_on_signal': 100, 'offset_on_signal': 100, 'apply_gain': 1, 'add_offset': 0, 'units': 'degC', 'datablock': 'IRGA75-A'}
PRESS_BOX == {'order': 7, 'bytes': 2, 'format': 'B B', 'gain_on_signal': 10, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'hPa', 'datablock': 'IRGA75-A'}
P_BOX == {'order': 7, 'bytes': 2, 'format': 'B B', 'gain_on_signal': 10, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'hPa', 'datablock': 'IRGA75-A'}
COOLER_V == {'order': 8, 'bytes': 3, 'format': 'B B B', 'gain_on_signal': 10000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'V', 'datablock': 'IRGA75-A'}
# Values extracted from DIAG_VAL:
......
......@@ -4,7 +4,7 @@
DATA_SIZE == {'order': 1, 'bytes': 1, 'format': '>B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Bytes', 'datablock': 'LGR-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': '>B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'octal_lgr', 'datablock': 'LGR-A'}
STATUS_CODE == {'order': 2, 'bytes': 1, 'format': '>B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'status_code_lgr', 'datablock': 'LGR-A'}
CH4_DRY == {'order': 3, 'bytes': 4, 'format': '>B B B B', 'gain_on_signal': 10000000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'umol+1 mol-1', 'datablock': 'LGR-A'}
N2O_DRY == {'order': 4, 'bytes': 4, 'format': '>B B B B', 'gain_on_signal': 10000000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'umol+1 mol-1', 'datablock': 'LGR-A'}
H2O == {'order': 5, 'bytes': 4, 'format': '>B B B B', 'gain_on_signal': 10000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'umol+1 mol-1', 'datablock': 'LGR-A'}
......
......@@ -3,12 +3,12 @@
## Variables
- DATA_SIZE ... Data size of current data block, number of bytes in LGR record
(2 = missing, 33 = available)
- STATUS_CODE ... Status of LGR data aquisition, see Table 11 in WE's sonicread.pdf
- octal value converted to integer yields:
- 0 .. Status OK, no problems (octal yy00)
- 1 .. IRGA did not respond (yy01)
- 2 .. Status OK, old data used (yy02)
- 10 .. not OK, IRGA data are missing (yy10)
- STATUS_CODE ... Status of LGR data aquisition, see Table 11 and 13 in WE's sonicread.pdf
- status code converted to integer yields:
- 0 .. Status OK, no problems (corresponds to binary 0000)
- 1 .. Old LGR record replicated (0001)
- ? .. LGR did not respond (this is never used)
- 8 .. not OK, LGR data are missing (1000)
- CH4_DRY ... CH4 dry mole fraction (in **dry** air), mixing ratio, ppm (parts per million)
- N2O_DRY ... N2O dry mole fraction (in **dry** air), mixing ratio, ppm
- H2O ... H2O molar fraction (in **humid** air), wet mole fraction
......
......@@ -10,12 +10,12 @@ CH4_DMF == {'order': 3, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal'
N2O_DMF == {'order': 4, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'nmol+1 mol-1', 'datablock': 'QCL-C'}
CO2_DMF == {'order': 5, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'nmol+1 mol-1', 'datablock': 'QCL-C'}
H2O_DMF == {'order': 6, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'nmol+1 mol-1', 'datablock': 'QCL-C'}
T_CELL == {'order': 7, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'K+1', 'datablock': 'QCL-C'}
P_CELL == {'order': 8, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Torr+1', 'datablock': 'QCL-C'}
T_CELL == {'order': 7, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'K', 'datablock': 'QCL-C'}
P_CELL == {'order': 8, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'Torr', 'datablock': 'QCL-C'}
STATUS_WORD == {'order': 9, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'QCL-C'}
VICI == {'order': 10, 'bytes': 4, 'format': 'B B B B', 'gain_on_signal': 1000, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'dimensionless', 'datablock': 'QCL-C'}
# Values extracted from STATUS_CODE:
# ----------------------------------
STATUS == {'order': 2.01, 'bit_pos_start': 4, 'bit_pos_end': 8, 'apply_gain': 1, 'add_offset': 0, 'units': 'unused', 'output': 1, 'datablock': 'QCL-C'}
VARIANT == {'order': 2.02, 'bit_pos_start': 0, 'bit_pos_end': 4, 'apply_gain': 1, 'add_offset': 0, 'units': 'unused', 'output': 1, 'datablock': 'QCL-C'}
STATUS == {'order': 2.01, 'bit_pos_start': 4, 'bit_pos_end': 8, 'apply_gain': 1, 'add_offset': 0, 'units': '0=OK', 'output': 1, 'datablock': 'QCL-C'}
VARIANT == {'order': 2.02, 'bit_pos_start': 0, 'bit_pos_end': 4, 'apply_gain': 1, 'add_offset': 0, 'units': '#', 'output': 0, 'datablock': 'QCL-C'}
......@@ -4,22 +4,22 @@
- DATA_SIZE ... Data size of current data block, number of bytes in QCL record
(2 = missing, 34 = available)
- STATUS_CODE ... Status information and extension variant information
- Most significant bits of this byte (bits 4–7) contain the variant information
- Most significant bits of this byte (bits 4–7) contain the VARIANT information
- On Windows systems (LSB): bits 0-3
- Gives variant information according to Table 2 in WE's sonicread.pdf
- Example: "6" means variant 6 as listed in Table 2
- Least significant bits (bits 0–3) contain status information
- Least significant bits (bits 0–3) contain STATUS information
- On Windows systems (LSB): bits 4-7
- converted to integers yields:
- 0 ... Status OK (0000)
- 1 ... Old data used (0001)
- 2 ... QCL did not respond (0002)
- 10 ... QCL data missing (0010)
- 0 ... Status OK (binary 0000), no bits set
- 1 ... Old data used (0001), bit 1 set
- 2 ... QCL did not respond (0010), bit 2 set
- 8 ... QCL data missing (1000), bit 4 set
- Original information found in ```extdata.h```:
- define QCL_STATUS_OK 0000 /* no bits set */
- define QCL_OLD_DATA_USED 0001 /* bit 1 set */
- define QCL_DID_NOT_RESPOND 0002 /* bit 2 set */
- define QCL_DATA_MISSING 0010 /* bit 4 set */
- define QCL_DID_NOT_RESPOND 0002 /* bit 2 set */
- define QCL_DATA_MISSING 0010 /* bit 4 set */
- CH4_DRY ... CH4 dry mole fraction, mixing ratio, ppb
- N2O_DRY ... N2O dry mole fraction, mixing ratio, ppb
- CO2_DRY ... CO2 dry mole fraction, mixing ratio, ppb
......
......@@ -7,5 +7,5 @@ U == {'order': 1, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'o
V == {'order': 2, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1 s-1', 'datablock': 'R350-A'}
W == {'order': 3, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'm+1 s-1', 'datablock': 'R350-A'}
T_SONIC == {'order': 4, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'K', 'datablock': 'R350-A'}
INC_X == {'order': 5, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'R350-A'}
INC_Y == {'order': 6, 'bytes': 2, 'format': '>h', 'gain_on_signal': 1, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'R350-A'}
INC_X == {'order': 5, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'R350-A'}
INC_Y == {'order': 6, 'bytes': 2, 'format': '>h', 'gain_on_signal': 100, 'offset_on_signal': 0, 'apply_gain': 1, 'add_offset': 0, 'units': 'deg', 'datablock': 'R350-A'}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment