When using USB-1408FS I get the following error:
count must be integer multiple of packet size for continuous mode.
I know that the packet size is 32 and the count must be a multiple of that. The code only works when the number of repeats (in this code it is 5) is under 7. When I put number 8 on (which makes 32) it gives me that error. And anything above 8 does not work.
nchannel=1;
AO=analogoutput('mcc',0);
set(AO,'BufferingMode','manual');
set(AO,'BufferingConfig',[128 2]);
addchannel(AO, [0:nchannel-1]);
samplerate=500;
sampleinterval=1/samplerate;
set(AO,'SampleRate',samplerate);
set(AO, 'TriggerType','Manual');
ActualRate=get(AO,'SampleRate');
%%set up desired output vector
V4 = 4
outputvector = repmat([0;1;1;0],5,1)*V
%%Load device memory
putdata(AO,outputvector);
start(AO);
%%trigger output
trigger(AO)
Any help will be appreciated.