Repeated Capabilities

Repeated capabilities attributes are used to set the channel_string parameter to the underlying driver function call. This can be the actual function based on the Session method being called, or it can be the appropriate Get/Set Attribute function, such as niRFSG_SetAttributeViInt32().

Repeated capabilities attributes use the indexing operator [] to indicate the repeated capabilities. The parameter can be a string, list, tuple, or slice (range). Each element of those can be a string or an integer. If it is a string, you can indicate a range using the same format as the driver: '0-2' or '0:2'

Some repeated capabilities use a prefix before the number and this is optional

markers

nirfsg.Session.markers

If no prefix is added to the items in the parameter, the correct prefix will be added when the driver function call is made.

session.markers['0-2'].channel_enabled = True

passes a string of 'marker0, marker1, marker2' to the set attribute function.

If an invalid repeated capability is passed to the driver, the driver will return an error.

You can also explicitly use the prefix as part of the parameter, but it must be the correct prefix for the specific repeated capability.

session.markers['marker0-marker2'].channel_enabled = True

passes a string of 'marker0, marker1, marker2' to the set attribute function.

script_triggers

nirfsg.Session.script_triggers

If no prefix is added to the items in the parameter, the correct prefix will be added when the driver function call is made.

session.script_triggers['0-2'].channel_enabled = True

passes a string of 'scripttrigger0, scripttrigger1, scripttrigger2' to the set attribute function.

If an invalid repeated capability is passed to the driver, the driver will return an error.

You can also explicitly use the prefix as part of the parameter, but it must be the correct prefix for the specific repeated capability.

session.script_triggers['scripttrigger0-scripttrigger2'].channel_enabled = True

passes a string of 'scripttrigger0, scripttrigger1, scripttrigger2' to the set attribute function.

waveforms

nirfsg.Session.waveforms

If no prefix is added to the items in the parameter, the correct prefix will be added when the driver function call is made.

session.waveforms['0-2'].channel_enabled = True

passes a string of 'waveform::0, waveform::1, waveform::2' to the set attribute function.

If an invalid repeated capability is passed to the driver, the driver will return an error.

You can also explicitly use the prefix as part of the parameter, but it must be the correct prefix for the specific repeated capability.

session.waveforms['waveform::0-waveform::2'].channel_enabled = True

passes a string of 'waveform::0, waveform::1, waveform::2' to the set attribute function.

ports

nirfsg.Session.ports
session.ports['0-2'].channel_enabled = True

passes a string of '0, 1, 2' to the set attribute function.

los

nirfsg.Session.los

If no prefix is added to the items in the parameter, the correct prefix will be added when the driver function call is made.

session.los['0-2'].channel_enabled = True

passes a string of 'LO0, LO1, LO2' to the set attribute function.

If an invalid repeated capability is passed to the driver, the driver will return an error.

You can also explicitly use the prefix as part of the parameter, but it must be the correct prefix for the specific repeated capability.

session.los['LO0-LO2'].channel_enabled = True

passes a string of 'LO0, LO1, LO2' to the set attribute function.

device_temperatures

nirfsg.Session.device_temperatures
session.device_temperatures['0-2'].channel_enabled = True

passes a string of '0, 1, 2' to the set attribute function.

channels

nirfsg.Session.channels
session.channels['0-2'].channel_enabled = True

passes a string of '0, 1, 2' to the set attribute function.