| optoMDC

Loading...
Searching...
No Matches
optoMDC.registers.mre2_registers Namespace Reference

## Classes
class | XYPID
class | MRE2MiscFeatures
class | MRE2Status
class | MRE2StaticInput
class | MRE2Analog
class | MRE2SignalGenerator
class | MRE2VectorPatternUnit
class | OpticalFeedback
class | MRE2TemperatureManager
class | ResonantAmplitudeControl

## Functions
| systems ()

## Detailed Description

    Lookup tables / management of System registers specific to the MR-E-2.

    Each System is represented by its own class, with Registers as attributes of that class.
    The registers module can be imported to retrieve information about a given registers.
    Syntax is as follows: registers.SYSTEM_NAME(CHANNEL_NUMBER).REGISTER_NAME

    Returns
    -------
    dict
        A standard lookup will return a Register Record, or dictionary, containing pertinent registers information.

    Notes
    -----
    A handful of helper methods are included to manage registers requests. See corresponding info for the following:
        is_valid_channel(value), is_valid_value(register_dict, value)
        tools.parsing_tools.encode(command_id, register_id)
        system_info()
        system_names()
        register_names(system_name)
        tools.systems_registers_tools.get_register(system_name, register_name, channel)
        parse_error(error_code)
        help()

    Examples
    --------

    For example, this imports the registers module, and collects the registers record of USB channel 0, as well as the
    registers record for setting the input channel system of the Signal Flow Manager.

        >>> from optoMDC.mre2 import Registers
        >>> Registers.StaticInput(0).of

        >>> Registers.StaticInput(0).of
        {'id': 20737, 'type': <class 'float'>, 'unit': None, 'range': [-1, 1], 'default': 0.0}
        >>> Registers.Manager(0).input
        {'id': 16384, 'type': <class 'int'>, 'unit': 'SystemID', 'range': None, 'default': None}
        >>> from optoMDC.tools.systems_registers_tools import is_valid_value
        >>> is_valid_value(Registers.StaticInput(0).xy, 0.8)
        True

    Additional Notes
    ----------------
    For more info on a given registers, see the help text in the corresponding System class.
    This will display ID, Data Type, Units, Range, Default Value, and Comments.
        >>> Registers.SignalGenerator.help()

    For a complete list of registers for a given system, call one of the helper methods from registers module itself.
        >>> Registers.get_registers(system_name='StaticInput', channel=1)

## Function Documentation

## ◆ systems()

optoMDC.registers.mre2_registers.systems | ( |  | ) |