function outInfo=esiginfo
%ESIGINFO Helper function for keeping list data
%          for the MATLAB Tour


%    Yama Habibzai
%    Copyright (c) 1984-98 by The MathWorks, Inc. All Rights Reserved
%    $Revision: 1.13 $  $Date: 1998/08/19 19:33:54 $


% Flag to show if a Toolbox is installed. Initially, assume none are installed
signal= 0;
dsp= 0;
wavelets = 0;
comm =0;
sysid= 0;
fuzzy= 0;
nnet= 0;
image= 0;
optim= 0;
rtw= 0;
hosa= 0;
freqid =0;

param = get(gcf, 'userdata');
blocksets = param.blocksets;
toolboxes = param.toolboxes;
simExist = exist('siminfo.m');
if simExist
  simdemos = siminfo;
  sizsimu = size(simdemos);
end

n = 1;

tbxList(n).DemoList = {' '
' '
'  The products on the left are'
'  installed on your system and'
'  have demos available.'};

tbxList(n).Name = 'Products installed with demos:';
tbxList(n).FcnList = ' ';
tbxList(n).Help = ' ';

%%%%%%% INSTALLED TOOLBOXES %%%%%%%%

for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Signal Processing')
    n = n + 1;
    signal = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on the Signal Processing Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''signal''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end

% *******
for i = 1:size(blocksets, 2);
  if  strcmp(blocksets(i).Name, 'DSP Blockset')
    n = n+1;
    dsp = 1;
    tbxList(n).DemoList = blocksets(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on The DSP Blockset';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = blocksets(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''dspblks''))';
    tbxList(n).Help = blocksets(i).Help;
    tbxList(n).Name = ['   ',blocksets(i).Name];
  end
end

% *********

for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Wavelet')
   n =n + 1;
   wavelets = 1;
   tbxList(n).DemoList = toolboxes(i).DemoList;
   tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on The Wavelet Toolbox';
   tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
   tbxList(n).FcnList = toolboxes(i).FcnList;
   tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
   tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''wavelet''))';
   tbxList(n).Help = toolboxes(i).Help;
   tbxList(n).Name = ['   ',toolboxes(i).Name];
 end
end

% ********
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Communications')
    n = n+1;
    comm = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on The Communications Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''comm''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end

% ********
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'System Identification')
    n = n+1;
    sysid = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on System Identification' ;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''ident''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end
% *******
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Fuzzy Logic')
    n  = n+1;
    fuzzy = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on Fuzzy Logic Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''fuzzy''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end
% *******
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Neural Networks')
    n = n+1;
    nnet =1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on Neural Network Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''nnet''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end

% *******
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Image Processing')
    n = n+1;
    image = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on The Image Processing Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''images''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end

% *******
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Optimization')
    n = n+1;
    optim = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on the Optimization Toolbox';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''optim''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end
% ****** 
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'RTW')
    n = n+1;
    rtw = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on the Real-Time Workshop';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end
% *******
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Higher-Order Spectral Analysis')
    n = n+1;
    hosa = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on Higher Order Spectral Analysis';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''hosa''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name = ['   ',toolboxes(i).Name];
  end
end

% ********
for i = 1:size(toolboxes, 2);
  if  strcmp(toolboxes(i).Name, 'Frequency Domain System Identification')
    n = n+1;
    freqid = 1;
    tbxList(n).DemoList = toolboxes(i).DemoList;
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'More on Frequency Domain System  Identification';
    tbxList(n).DemoList{size(tbxList(n).DemoList, 2)+1} = 'Help on this Toolbox';
    tbxList(n).FcnList = toolboxes(i).FcnList;
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'evalcb(''toolInfo'')';
    tbxList(n).FcnList{size(tbxList(n).FcnList, 2)+1} = 'helpwin(help(''fdident''))';
    tbxList(n).Help = toolboxes(i).Help;
    tbxList(n).Name =['   ', toolboxes(i).Name];
  end
end
%*******

% *******************
%   Blank space
n  = n+1;
tbxList(n).DemoList = ' ';
tbxList(n).Name = ' ';
tbxList(n).FcnList = ' ';
tbxList(n).Help = ' ';
% *******************

%%%%%%%% TOOLBOXES NOT INSTALLED %%%%%%%%%%
n = n+1;
tbxList(n).DemoList = {' '
' '
'  The MATLAB Tour could not find'
'  demos for these products on your'
'  system.'
' '
'  However, information for these'
'  products is provided.'
'  '};

tbxList(n).Name = 'Information only:';
tbxList(n).FcnList = ' ';
tbxList(n).Help = ' ';

% *******************
if signal== 0
  n = n+1;
  tbxList(n).DemoList={'More on the Signal Processing Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'sig_con'};
  tbxList(n).Help= about('signal');
  tbxList(n).Name=['   ','Signal Processing'];
end

if dsp== 0
  n = n+1;

  tbxList(n).DemoList={'More on DSP Blockset'
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'dsp_con'};
  tbxList(n).Help=  about('dsp');
  tbxList(n).Name=['   ','DSP Blockset'];
end

if wavelets== 0
  n = n+1;
  tbxList(n).DemoList={'More on The Wavelet Toolbox'
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'wav_con'};
  tbxList(n).Help= about('wavelets');
  tbxList(n).Name=['   ','Wavelets Toolbox'];
end

if comm == 0
  n = n+1;
  tbxList(n).DemoList={'More on The Communications Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'comm_con'};
  tbxList(n).Help= about('communications');
  tbxList(n).Name= ['   ','Communications Toolbox'];

end

if sysid== 0
  n = n+1;
  tbxList(n).DemoList={'More on the System Identification Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'idn_con'};
  tbxList(n).Help= about('sysid');
  tbxList(n).Name=['   ','System Identification'];
end

if fuzzy== 0
  n = n+1;
  tbxList(n).DemoList={'More on  Fuzzy Logic Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'fuz_con'};
  tbxList(n).Help= about('fuzzy');
  tbxList(n).Name=['   ','Fuzzy Logic'];

end

if nnet== 0
  n = n+1;
  tbxList(n).DemoList={'More on Neural Network Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'nnt_con'};
  tbxList(n).Help= about('nnet');

  tbxList(n).Name=['   ','Neural Networks'];

end

if image== 0
  n = n+1;
  tbxList(n).DemoList={'More on The Image Processing Toolbo x',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'img_con'};
  tbxList(n).Help= about('image');
  tbxList(n).Name=['   ','Image Processing'];
end

if optim== 0
  n = n+1;
  tbxList(n).DemoList={'More on the Optimization Toolbox',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'opt_con'};
  tbxList(n).Help= about('optim');
  tbxList(n).Name=['   ','Optimization'];
end

if rtw== 0
  n = n+1;
  tbxList(n).DemoList={'More on the Real-Time Workshop'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')'};
  tbxList(n).Help= about('rtw');
  tbxList(n).Name=['   ','Real-Time Workshop'];
end

if hosa== 0
  n = n+1;
  tbxList(n).DemoList={'More on Higher Order Spectral Analysis',
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')',
  'hos_con'};
  tbxList(n).Help=  about('hosa');
  tbxList(n).Name=['   ','Higher Order Spectral Analysis'];
end
if freqid == 0
  n = n+1;
  tbxList(n).DemoList={'More on Frequency Domain System Identification'
  'Partial functions help'};
  tbxList(n).FcnList={'evalcb(''toolInfo'')'
  'fid_con'};
  tbxList(n).Help= about('freqid');
  tbxList(n).Name=['   ','Frequency Domain System Identification'];
 
end
 

outInfo=tbxList;

