FTP freezing Problem.

4 views (last 30 days)
Gordon Jones
Gordon Jones on 18 Mar 2011
I have been using MATLAB to FTP large quantities of data from the British Atmospheric Data Centre, however I have an issue that MATLAB keeps freezing up on me without giving an error message of any kind, it simply stops working and needs to be closed using the task manager. The data begins downloading and some files are downloaded, but then the process simply stops.
the code that I'm using is below with some parts cut out although the code is still applicable.
E=eomday(2007,1:12);
f=ftp('ftp.badc.rl.ac.uk','user','pwd');
binary(f)
FTP_diryear=cd(f,'badc/ukmo-um/');
for i = 10:12
month = sprintf('%02d',i);
FTP_dirmonth=cd(f,month);
days=dir(f);
for j = 1:5 %use this line to download an entire month
day=days(j).name;
FTP_dirday=cd(f, [FTP_dirmonth '/' day]);
dir(f)
disp('Downloading')
outdir=['E:\UKMO_Data\' month '\' day];
if ~exist(outdir,'dir');
mkdir(outdir);end
mget(f,'*_00002_*.pp',outdir);
FTP_dirday=cd(f,'../..');
end
end
close(f)
I'm using V7.11.0.584 on Win64.
Any suggestions for why this would be happening and how it could be solved would be greatly appreciated.

Answers (0)

Categories

Find more on Downloads in Help Center and File Exchange

Tags

Products

Community Treasure Hunt

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

Start Hunting!