_matplotlib = None
_matplotlib_import_error = e
-from pycomedi.constant import TRIG_SRC, SDF
+from pycomedi.constant import AREF, TRIG_SRC, SDF
from pycomedi.utility import inttrig_insn, Reader, Writer
from . import LOG as _LOG
config['channel'] = channel.index
config['maxdata'] = channel.get_maxdata()
config['range'] = channel.range.value
- config['analog-reference'] = channel.aref.value
+ config['analog-reference'] = AREF.index_by_value(channel.aref.value)
converter = channel.get_converter()
config['conversion-origin'
] = converter.get_to_physical_expansion_origin()