A quick method is to create a preparsed pseudocode file using the pcode function of your m-file and put the p-file on the network.
or
Use the Matlab Compiler toolbox to create a standalone executable program or a dll.
I'm not that familiar with video grabbing but I can give you some tips...
You will surely benefit from preallocating memory for your image matrices, especially if you collect images inside a loop.
img = zeros(h,w,3,n); h = height, w = width and n = number of images.
Explore the possibility of...
If you had bothered to read the docs, as I suggested, you would have seen an example of the fscanf function. Where the use of the fscanf is exactly the same as in Tom's post.
I believe hexadecimal numbers are always treated as ascii by Matlab. Use the hex2dec or the hex2num function to convert.
The serial port object has some events and callbacks that will help you with the data collection part.
Search the help for BytesAvailableFcn, BytesAvailableFcnCount and...
Change the Position property.
set(gca, 'Position', [x y width height])
The values range from 0 to 1.
Set x=0, y=0, width=1 and height=1 to completely fill the figure.
However, no axis labels or tick labels will be visible.
You need to flip each color separately.
img = imread('photo.jpg');
for i=1:3 % loop through R, G and B
imgflp(:,:,i) = fliplr(img(:,:,i)); % flip 2-D matrix
end
imshow(imgflp) % show flipped image
Sorry, can't help you with that. I'm not an expert I just grabbed this from the Mathworks Support about 2 years ago and I can't find it there now.
"Subsystem" seems to be the keyword to search for in your compilers manual.
Edit the compiler options file before you compile
cd(prefdir)
edit compopts.bat
Add the following line for your compiler
LCC:
set LINKFLAGS=%LINKFLAGS% -subsystem windows
Microsoft Visual C/C++:
set LINKFLAGS=%LINKFLAGS% /SUBSYSTEM:WINDOWS /ENTRY:mainCRTStartup
Borland:
set...
Are both computers set to the same baud-rate? Maybe some of the other serial properties are different on your computers. Use get(s) to get at list of all properties.
Are you using a nullmodem cable? See http://www.zytrax.com/tech/layer_1/cables/tech_rs232.htm#null_db9 for more info.