ODB Access and Use

From MidasWiki
Revision as of 18:49, 26 June 2014 by Suz (talk | contribs) (Created page with "==== Links ==== <div style="column-count:3;-moz-column-count:3;-webkit-column-count:3"> * odbedit * mhttpd ODB page * * </div> == Introduction == The MIDAS Online D...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Links

Introduction

The MIDAS Online Data Base (ODB) is the main communication platform between MIDAS applications. It contains all the information needed to run an experiment.

The ODB is hierarchically structured, similar to a file system, with directories and sub-directories (or trees and subtrees). The data are stored in key/data pairs, similar to the Windows NT registry. Keys can be dynamically created and deleted. The data associated with a key can be of different types such as: byte, words, double words, float, strings, etc. or arrays of any of those. A key can also be a directory or a symbolic link.

Accessing the ODB

The MIDAS library provides a complete set of functions to manage and operate on these keys (in odb.c) (see odb functions). Scripts can easily access the odb using the odbedit -c argument.

Each field or KEY in the MIDAS ODB can be accessed interactively in two possible ways:


The ODB Structure

The data in the ODB are structured in a tree form with each "directory" dealing with a specific section of the acquisition. Particular system applications will automatically create their own initial ODB structure filled with default values (for example, the data logger creates the /Logger ODB tree. The user may then modify these configurations to fit his/her requirements (see customizing). A list of the trees in the ODB used by the system can be found here.


Customizing

The user customizes the ODB for their experiment by modifying the values of "system" parameters (e.g. Keys in the ODB /Logger tree, and adds extra keys under existing trees as needed, e.g. "Edit on Start" parameters under the /Experiment ODB tree. The user may creates "optional" trees e.g. (/Script, /Custom) populating them with keys as required. The user is also free to create his/her own tree structure under root (/) for his/her own purposes.


Creating the ODB

See creating the ODB

Creating Keys in the ODB

The first time odbedit is run, the trees |/Runinfo, /Experiment, /System will be created and filled with default values. Other applications will add their own trees (see above).

The user may customize the ODB by adding more keys.