The Maximun rate of NI DAQ Card in MATLAB can not reach that in the specification.
12 次查看(过去 30 天)
显示 更早的评论
I'm using PCI 6259 and MATLAB 2020b. The Maximum update rate for a single AO output channel is 2.86MS/S according to the specification, but when I use
daqSession = daq('ni');
daqSession.addoutput('Dev1','ao0','Voltage');
daqSession.Rate = 2000000;
Then it says, Rate cannot exceed 1000000 in the current configuration.
Is it the limited by MATLAB? And can I achieve that specified speed using LabView or c++/c#?
0 个评论
回答(1 个)
Chidvi Modala
2021-3-30
This is a known issue and our developers are aware of it and will try to fix it in future releases.
1 个评论
Edgar Pena
2022-9-14
编辑:Edgar Pena
2022-9-14
Are there any updates on this issue? I am able to achieve the specified sampling rate using Python and then having MATLAB call a Python script (as in the code below), but I am still unable to achieve any sampling rate above 1 MS/s with MATLAB. Doing everything in MATLAB would be much more convenient.
%%% Run Python code to control DAQ
pe = pyenv;
if (~pe.Status==matlab.pyclient.Status.Loaded)
pyenv('Version','C:\Users\myusername\Anaconda3\python.exe')
end
path_to_file = fileparts(which('DAQ_simulation_script.py'));
if count(py.sys.path,path_to_file) == 0
insert(py.sys.path,int32(0),path_to_file);
end
pyrunfile("DAQ_simulation_script.py",...
f_i=freq,Fs_i=sampling_rate_Hz,ramp_rate_i=ramp_rate_mA_per_sec,max_amplitude_i=ramp_peak_amplitude_mA,duration_at_max_i=duration_at_max_amplitude)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 National Instruments Frame Grabbers 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!