how can i deploy my matlab GUI code m-file on theweb using matlab websrever and specifically display image results?

1 view (last 30 days)
i created a complex gui with a series of codes i got from the matlab central links below: 1)http://www.mathworks.com/matlabcentral/fileexchange/24369-wimax-physical-layer-simulation/all_files(for the deepwimaxmain) 2)802.16d system english version from matlab central site i created an html input page for the deepwimaxmain code in link(1) with the following inputs rate_id,G(cyclic prefix) and no(number of ofdm symbols)as well as all the other html pages as explained by matlab webserver manual.pdf but i keep getting some errors link 'non-finite end-points or increment for colon operator in index' and no figure is displayed even when i use simple examples.my deepwimax main m-file code for the matlab webserver is shown below function PageString = deepwimaxmain(InputSet, OutFile)
%------------------------------------------------------------ % Parse inputs from the page rate_id = str2double(InputSet.rate_id); G = str2double(InputSet.G); symbol_ofdm = str2double(InputSet.symbol_ofdm);
% Set directory path for storage of graphic files. cd(InputSet.mldir);
% Cleanup jpegs over an hour old. wscleanup('wsrml*.jpeg', 1);
% Check input arguments. if (nzmax(G)~=1) error('Please enter the value of the cyclic_prefix'); elseif ( spot <= 0 ) error('The cyclic_prefix must be positive'); end
if (nzmax(rate_id)>=7) error('Enter a rate_id valus between 0 al 6'); elseif ( rate_id <= 0 ) error('The rate_id must be positive'); end
if (nzmax(symbol_ofdm)~=1) error('Enter a number between 10 and 50'); elseif ( numsim <=0) error('The ofdm symbol must be a positive integer'); end
bit_error_rate=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]; for q=1:no %%% data generation data_get =data_gen(rate_id); %%% data randomization data_rand=randomizer(data_get); %%% FEC ENCODER data_rscoded=rsencodecod(data_rand,rate_id,10); %%convolution encoder data_coded=convolution(data_rscoded,rate_id,10); %%% INTERLEAVING data_interleav=interleav_d(data_coded,rate_id); %%% Digital modulator SYMBOL MAPPER data_mod=mod_d(data_interleav,rate_id); %%% IFFT modulator data_tx=ofdmsymbol_fft_cp(data_mod,G,10);
SNR=[1 2 3 5 7 9 10 12 15 17 20 22 25 27 30]; % specify SNR for p=1:1:15 snr=SNR(p); %%% channel data_rx=channel_d(data_tx,snr); %%% FFT demodulator data_rxp=ofdmsymbol_fft_cp(data_rx,G,01); %%% Digital demodulator SYMBOL DEMEPPER data_demod=demod_d(data_rxp,rate_id); %%% DEINTERLEAVING data_deinterleav=deinterleav_d(data_demod,rate_id); % %%% FEC DECODER %% convolution decoder data_decoded=convolution(data_deinterleav,rate_id,01); %%% RSdecoder data_rsdecoded=rsencodecod(data_decoded,rate_id,01); % removing added tail bits %%% Data Derandomizer data_unrand=randomizer(data_rsdecoded); %% BER calculation [noerr(p),ber(p)] = biterr(data_unrand,data_get); end bit_error_rate=bit_error_rate+ber; end bit_error_rate=bit_error_rate/no %%plot the grapgh result=berplot(SNR,bit_error_rate,rate_id)
%------------------------------------------------------------ % Write the figure file %------------------------------------------------------------ %Render jpeg and write to file PlotFile = sprintf('result%s.jpeg', InputSet.mlid);
drawnow; wsprintjpeg(Fig, PlotFile); close(Fig);
templatefile = which('deepwimax2.html'); if ( exist('OutFile','var') == 1 ) % write Page to a diagnostic file s.GraphFileName = [ PlotFile]; PageString = htmlrep(s, templatefile, OutFile); else s.GraphFileName = ['/icons/' PlotFile]; PageString = htmlrep(s, templatefile); end
please can a matlab webserver expert help me to analyze and compare this code with the code found in link(1) and tell me where i have made mistakes?

Answers (0)

Categories

Find more on Wireless Communications in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!