Error when trying to start acquisition from Data Translation device.

42 views (last 30 days)
Hi,
I'm trying to connect a Data Translation device (DT9818) using Data Acquisition Toolbox. I have installed the driver and Data Acquisition Toolbox Support for Data Translation Hardware. Everything seems to be fine, however when I want to start acquisition, I receive an error:
Invalid default value for property 'AsynchronousIoChannel' in class 'daq.dt.internal.ChannelGroupOL': Unable to resolve the name 'asyncio.Channel.empty'.
Can anybody tell me if I'm missing something, maybe I need some additional files? Here's the simple code:
v=daq.getVendors;
d=daq.getDevices;
s=daq.createSession('dt');
addAnalogInputChannel(s,'DT9818(00)','1','Voltage');
[data,time]=startForeground(s);
Invalid default value for property
'AsynchronousIoChannel' in class
'daq.dt.internal.ChannelGroupOL':
Unable to resolve the name
'asyncio.Channel.empty'.
Second option I tried:
d=daq('dt');
n=addinput(d,'DT9818(00)','1','Voltage');
data=read(d,seconds(5))
Invalid default value for property
'AsynchronousIoChannel' in class
'daq.dt.internal.ChannelGroupOL':
Unable to resolve the name
'asyncio.Channel.empty'.
I use MATLAB R022a.

Accepted Answer

Darryl Stein
Darryl Stein on 28 Apr 2022
I have same issue also. I recently changed from R2019a to R2022a.
May be a package difference. Under R2019a I used the following package:
Data Translation DT9837 and MATLAB DAQ Adaptor with MATLAB Data Acq Toolbox version 1.0.0.0
I will test this now.
  2 Comments
Darryl Stein
Darryl Stein on 28 Apr 2022
I reverted to R2019a. Installed the following package:
Data Acquisition Toolbox Support Package for Data Translation Hardware
version 1.1
Reboot Computer
And it worked fine.
Maybe in issue with 2022a. I reverted backed to what previously worked for me.
Julia Leszczynska
Julia Leszczynska on 4 May 2022
Apparently there is a different file path for the class 'asyncio.Channel' in R2022a. I found it under 'matlabshared.asyncio.internal.Channel' instead.
However I keep getting different errors now, so I don't know if it's the only issue.

Sign in to comment.

More Answers (2)

Fausto Soares
Fausto Soares on 27 Feb 2023
@Justin Rehak Thank you for your suggestions. I was able to get my DT9834 to work with MATLAB R2022b, Windows 11 64-bit, and DT Open Layers v7.8.9.
Below are the changes I made, which should help clarify the workaround for using the 'Data Acquisition Toolbox Support Package for Data Translation Hardware' with MATLAB R2022a and newer.
In the 'C:\Users\{username}\AppData\Roaming\MathWorks\MATLAB Add-Ons\Toolboxes\Data Acquisition Toolbox Support Package for Data Translation Hardware\+daq\+dt\+internal' folder, I updated two files (AsyncOLChannel.m and ChannelGroupOL.m).
In the 'AsyncOLChannel.m' file, I made the following changes.
Line 1: classdef AsyncOLChannel < matlabshared.asyncio.internal.Channel
Line 21: obj@matlabshared.asyncio.internal.Channel(pluginInfo.devicePath, ...
Line 23: 'Options', channelOptions,...
Line 24: 'StreamLimits', streamLimits);
Line 35: matlabshared.asyncio.internal.DataEventInfo(remainderIn) );
Line 51: matlabshared.asyncio.internal.DataEventInfo(remainderOut) );
In the 'ChannelGroupOL.m' file, I made the following single change.
Line 23: AsynchronousIoChannel = matlabshared.asyncio.internal.Channel.empty();
(Note: There is a known bug with the analog output when using DT Open Layers v7.8.9. Revert back to DT Open Layers v7.8.2. The DT DataAcq OMNI software can be downloaded from BOX using this link: https://datatranslation.box.com/s/8mrbkoxzyv8r9fbsadybvj0btxk2qbni ).
Regards.

Justin Rehak
Justin Rehak on 4 Aug 2022
I was able to fix this by editing the following files of the Data Translation toolbox:
daq.dt.internal.AsyncOLChannel.m
Replace asyncio.Channel with matlabshared.asyncio.internal.Channel
Change line 21-24 constructor inputs to include 'Options' and 'StreamLimits' before the respective inputs.
daq.dt.internal.ChannelGroupOL.m
Replace asyncio.Channel with matlabshared.asyncio.internal.Channel
You can get to the files via the open command.
  6 Comments
Andreas Sprenger
Andreas Sprenger on 27 Feb 2023
After hours of testing: On Windows10 with Matlab R2021b (and previous versions of Matlab) the toolbox seems to work, but analog output is not functional. Installing the MCCDAQ driver version 7.8.0 instead of 7.8.9 fixes this issue. But keep in mind: Window10 does not install DotNetfx3.5 by default which is essential. If you try to install DotNetfx3.5 you will get a 0x80244022 error, which can be fixed (https://social.technet.microsoft.com/Forums/en-US/b20f126a-4478-4efe-8f56-dd94c8b491cd/software-update-error-0x80244022?forum=configmanagersecurity).
The bug with Matlab R2022b 'Data Acquisition Toolbox Support Package for Data Translation Hardware' is independent of the driver version and should be fixed soon.
Fausto Soares
Fausto Soares on 27 Feb 2023
(Note: There is a known bug with the analog output when using DT Open Layers v7.8.9. Revert back to DT Open Layers v7.8.2. The DT DataAcq OMNI software can be downloaded from BOX using this link: https://datatranslation.box.com/s/8mrbkoxzyv8r9fbsadybvj0btxk2qbni ).

Sign in to comment.

Categories

Find more on Data Acquisition Toolbox Supported Hardware in Help Center and File Exchange

Products


Release

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!