Private
Public Access
11
1
1
Config_Instrument
watts edited this page 2022-10-17 15:50:56 +02:00

Instrument

This file defines the content of the NXinstrument group of the scan file (hdf5). It is a json object with as many entries as needed. One group is made inside the NXinstrument group per entry of this settings file, with the key used as group name.

See source:trunk/PixelatorController/config/instrument.json for an example.

NeXus class

Every top level entry may have a "class" member that is used as the NeXus class of the group. Without the "class" member, the NeXus class of the group is built using the groups name: "NX" + lower(name)

Values can be

Conditional Writing

A group may be written conditionally. When a settings object has a "condition" member, its value defines a condition that must be met in order to write the entire group. The value of the condition has the form:
{"operator" : [values]}

values can be

Only one operator is implemented so far:
{"==" : [value1, value2]}

Positioner Values

To write the (numeric) value of a positioner to the NXinstrument section or to use it in a condition, a value can be a json object with the following members:

  • positioner: Name of a Positioner
  • factor (optional): float value. The positioners value is multiplied with this factor.
  • offset (optional): float value. The positioners value is added to this offset.

Epics Channel Values

To use the (string) value of an epics channel in a condition, a value can be a json object with the following member:

  • epicsChannel: Address of an EPICS channel

Value with Unit

As all numeric values should be written with a unit, a value can be a json object with value and unit:
{"value" : value, "unit" : unit}

value can be

  • numbers
  • arrays of numbers

unit must be a string