DSPRelated.com
Forums

RTDX for huge data transferring

Started by ahma...@yahoo.com October 9, 2005
hello
How can I exchange image data between host (MATLAB 7) and target program on C6711 dsk?
My hoost and target codes for RTDX are as below this text. When the amount of data to be transfered
is more than 1010 Byte, the MATLAB sends timeout error for reading data from 'ochan';although I set the timeout00s.
Do you know Why? Is it because of parallel port? -------------------------------
THE HOST (MATLAB 7) CODES:
-------------------------

ccdsp('boardnum',0,'procnum',0);
configure(cc.rtdx,2048,4)
open(cc.rtdx,'ichan','w')
open(cc.rtdx,'ochan','r')
enable(cc.rtdx);
enable(cc.rtdx,'ichan');
set(cc.rtdx,'timeout',1000);
I=imread(['d:\image\1475.jpg']);
I1=rgb2gray(I);
I1%5*im2double(I1);
ui8=uint8(I1(1:1020));

if iswritable(cc.rtdx,'ichan'),
writemsg(cc.rtdx,'ichan', ui8)
end pause(9)
enable(cc.rtdx,'ochan');
num_of_msgs = msgcount(cc.rtdx,'ochan')
outdata = readmsg(cc.rtdx,'ochan', 'uint8')
disable(cc.rtdx,'ALL');
% DISABLE RTDX
disable(cc.rtdx);
% CLOSE channels
close(cc.rtdx,'ichan');
clear cc; % Call destructor -----------
THE TARGET APPLICATION CODE ON 6711DSK:(it is very similar to MATLAB RTDX tutorial)
--

#include <rtdx.h> /* RTDX_Data_Read */
#include <stdio.h> /* printf */
#include