Table of Contents

Class MeasureMuxModule

Namespace
Loehnert.Lisrt.CircuitBoard.L15B63
Assembly
Loehnert.Lisrt.CircuitBoard.L15B63.dll

Represents a measure multiplexer board L15B63 and L2109016. Depends on project L15B63, L2001047.

public class MeasureMuxModule : LisrtModule, ILisrtModule, IInitializable, INotifyPropertyChangedEx, INotifyPropertyChanged, IHasDeviceLabel, IHasServiceView
Inheritance
PropertyChangedBase
MeasureMuxModule
Implements
INotifyPropertyChangedEx
Inherited Members
PropertyChangedBase.Refresh()
PropertyChangedBase.IsNotifying
PropertyChangedBase.PropertyChanged

Constructors

MeasureMuxModule(string, ICanCommunication2)

Initializes a new instance of the MeasureMuxModule class.

public MeasureMuxModule(string name, ICanCommunication2 canCommunication)

Parameters

name string

Name for the module.

canCommunication ICanCommunication2

Can communication.

Exceptions

ArgumentNullException

Thrown name is null or empty or canCommunication is null.

Properties

CardAddress

Gets or sets the card address.

[Configuration(0)]
public uint CardAddress { get; set; }

Property Value

uint

DeviceLabel

Gets or sets the device label.

[Configuration("")]
public string DeviceLabel { get; set; }

Property Value

string

Icon

Gets the icon which is representative for the module.

public override Uri Icon { get; }

Property Value

Uri

InitializationState

Gets the current initialization state.

public InitializationState InitializationState { get; }

Property Value

InitializationState

InstanceID

Gets or sets the ID for the instance.

[Configuration(0)]
public int InstanceID { get; set; }

Property Value

int

SelfTestType

Gets or sets the self test type.

[Configuration(SelfTestType.ExcludingHighPowerPath)]
public SelfTestType SelfTestType { get; set; }

Property Value

SelfTestType

Methods

AcknowledgeErrors()

Acknowledges the device errors.

public State AcknowledgeErrors()

Returns

State

The acknowledged error as State or NoErrors if no error was acknowledged.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

DoFunction(byte, IEnumerable<byte>)

Executes a function.

protected IEnumerable<byte> DoFunction(byte functionCode, IEnumerable<byte> data = null)

Parameters

functionCode byte

Function code.

data IEnumerable<byte>

Data for the function or default.

Returns

IEnumerable<byte>

The answer data of the function.

Exit()

De initializes the object.

public void Exit()

GetAnalogInput(string)

Gets a analog input value [V] by its device labels.

public virtual double GetAnalogInput(string deviceLabel)

Parameters

deviceLabel string

Device label of the analog input. AN02 to AN05.

Returns

double

The analog input voltage in volts.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

GetAnalogOutput()

Gets the analog output value [V].

public double GetAnalogOutput()

Returns

double

The analog output voltage in volts.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

GetDigitalInputsDeviceLabels()

Gets the device labels of active digital inputs and the plugged jumpers.

public IEnumerable<string> GetDigitalInputsDeviceLabels()

Returns

IEnumerable<string>

Device labels of the active digital inputs. Some of: AN09, AN10, RG12 to RG15, RC1, RC2, JP1_1, JP1_2 and JP1_3.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

GetDigitalOutputDeviceLabels()

Gets the device labels of the set digital outputs.

public IEnumerable<string> GetDigitalOutputDeviceLabels()

Returns

IEnumerable<string>

Device labels of the set digital outputs. Some of: RD_9, RD_10.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

GetFirmwareVersion()

Gets the firmware version.

public Version GetFirmwareVersion()

Returns

Version

The firmware version.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

GetRelayCounter(byte)

Gets the cycle count of the relay.

public uint GetRelayCounter(byte relayNumber)

Parameters

relayNumber byte

Relay number from 1 to 72.

Returns

uint

Cycle count of the relay.

GetRelayCounter(string)

Gets the cycle count of the relay.

public uint GetRelayCounter(string deviceLabel)

Parameters

deviceLabel string

Relay device label.

Returns

uint

Cycle count of the relay.

Remarks

The device label can be one of: K_A1 to K_A24, K_E1 to K_E24, K_B1 to K_B4, K_B5_6 to K_B23_24 and K_AP1_A, K_AP1_B, K_AP2_A, K_AP2_B, K_EP1_A, K_EP1_B and K_F10, K_S10, A_RES_1, A_RES_2.

GetRelayDeviceLabels()

Gets the device labels of the set relays.

public IEnumerable<string> GetRelayDeviceLabels()

Returns

IEnumerable<string>

Device labels of the set relays.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

Initialize()

Initializes the module.

public void Initialize()

RunSelftest(CancellationToken)

Runs the self test.

public virtual SelftestResult RunSelftest(CancellationToken cancellationToken = default)

Parameters

cancellationToken CancellationToken

The cancellation token to cancel the self test.

Returns

SelftestResult

The result of the self test.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

OperationCanceledException

Thrown when cancellation requested.

SetAnalogOutput(double)

Sets the analog output value [V].

public void SetAnalogOutput(double value)

Parameters

value double

The voltage in volts for the analog output.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

ArgumentOutOfRangeException

Thrown when value is out of range.

SetDigitalOutputs(IEnumerable<string>)

Sets the digital outputs by its device labels ("RD9" and "RD10" are supported).

public void SetDigitalOutputs(IEnumerable<string> deviceLabels)

Parameters

deviceLabels IEnumerable<string>

Device labels of the digital outputs to set. Must be "RD9" or "RD10".

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

ArgumentException

Thrown when deviceLabels contains a not known device label.

SetRelays(IEnumerable<string>)

Sets the relays by its device labels. K_A1 to K_A24, K_E1 to K_E24, K_B1 to K_B4, K_B5_6 to K_B23_24 and K_AP1_A, K_AP1_B, K_AP2_A, K_AP2_B, K_EP1_A, K_EP1_B and K_F10, K_S10, A_RES_1, A_RES_2.

public void SetRelays(IEnumerable<string> deviceLabels)

Parameters

deviceLabels IEnumerable<string>

Device labels of the relays to set.

Exceptions

InvalidOperationException

Thrown when InitializationState is not Initialized or IsInitializing.

ShowServiceView()

Shows the service window.

public void ShowServiceView()