📄 current2voltage3.m
字号:
switch (Senal55f)
case 'STS-12/STM-4'
Ro55f=60; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.012;
case 'STS-48/STM-16'
Ro55f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.012;
otherwise
Ro55f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.011;
end
case '1550'
switch (Senal55f)
case 'STS-12/STM-4'
Ro55f=60; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.012;
case 'STS-48/STM-16'
Ro55f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.012;
otherwise
Ro55f=20; %Las unidades de la resistencia son "Ohmios".
Ibias55f=0.02;
end
end
set_param(Current2Voltaje55f,'Ibiasf',num2str(Ibias55f));
set_param(Current2Voltaje55f,'Rof',num2str(Ro55f));
end
if isempty(find_system(gcs,'Name','Fotodetector6'))~=1
Current2Voltaje66f=([gcs,'/','Fotodetector6']);
Senal66f=get_param(Current2Voltaje66f,'sel');
Frecuencia66f=get_param(Current2Voltaje66f,'frec');
%==============================================
switch (Frecuencia66f)
case '1310'
switch (Senal66f)
case 'STS-12/STM-4'
Ro66f=60; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.012;
case 'STS-48/STM-16'
Ro66f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.012;
otherwise
Ro66f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.011;
end
case '1550'
switch (Senal66f)
case 'STS-12/STM-4'
Ro66f=60; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.012;
case 'STS-48/STM-16'
Ro66f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.012;
otherwise
Ro66f=20; %Las unidades de la resistencia son "Ohmios".
Ibias66f=0.02;
end
end
set_param(Current2Voltaje66f,'Ibiasf',num2str(Ibias66f));
set_param(Current2Voltaje66f,'Rof',num2str(Ro66f));
end
if isempty(find_system(gcs,'Name','Fotodetector7'))~=1
Current2Voltaje77f=([gcs,'/','Fotodetector7']);
Senal77f=get_param(Current2Voltaje77f,'sel');
Frecuencia77f=get_param(Current2Voltaje77f,'frec');
%==============================================
switch (Frecuencia77f)
case '1310'
switch (Senal77f)
case 'STS-12/STM-4'
Ro77f=60; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.012;
case 'STS-48/STM-16'
Ro77f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.012;
otherwise
Ro77f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.011;
end
case '1550'
switch (Senal77f)
case 'STS-12/STM-4'
Ro77f=60; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.012;
case 'STS-48/STM-16'
Ro77f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.012;
otherwise
Ro77f=20; %Las unidades de la resistencia son "Ohmios".
Ibias77f=0.02;
end
end
set_param(Current2Voltaje77f,'Ibiasf',num2str(Ibias77f));
set_param(Current2Voltaje77f,'Rof',num2str(Ro77f));
end
if isempty(find_system(gcs,'Name','Fotodetector8'))~=1
Current2Voltaje88f=([gcs,'/','Fotodetector8']);
Senal88f=get_param(Current2Voltaje88f,'sel');
Frecuencia88f=get_param(Current2Voltaje88f,'frec');
%==============================================
switch (Frecuencia88f)
case '1310'
switch (Senal88f)
case 'STS-12/STM-4'
Ro88f=60; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.012;
case 'STS-48/STM-16'
Ro88f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.012;
otherwise
Ro88f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.011;
end
case '1550'
switch (Senal88f)
case 'STS-12/STM-4'
Ro88f=60; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.012;
case 'STS-48/STM-16'
Ro88f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.012;
otherwise
Ro88f=20; %Las unidades de la resistencia son "Ohmios".
Ibias88f=0.02;
end
end
set_param(Current2Voltaje88f,'Ibiasf',num2str(Ibias88f));
set_param(Current2Voltaje88f,'Rof',num2str(Ro88f));
end
if isempty(find_system(gcs,'Name','Fotodetector9'))~=1
Current2Voltaje99f=([gcs,'/','Fotodetector9']);
Senal99f=get_param(Current2Voltaje99f,'sel');
Frecuencia99f=get_param(Current2Voltaje99f,'frec');
%==============================================
switch (Frecuencia99f)
case '1310'
switch (Senal99f)
case 'STS-12/STM-4'
Ro99f=60; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.012;
case 'STS-48/STM-16'
Ro99f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.012;
otherwise
Ro99f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.011;
end
case '1550'
switch (Senal99f)
case 'STS-12/STM-4'
Ro99f=60; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.012;
case 'STS-48/STM-16'
Ro99f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.012;
otherwise
Ro99f=20; %Las unidades de la resistencia son "Ohmios".
Ibias99f=0.02;
end
end
set_param(Current2Voltaje99f,'Ibiasf',num2str(Ibias99f));
set_param(Current2Voltaje99f,'Rof',num2str(Ro99f));
end
if isempty(find_system(gcs,'Name','Fotodetector10'))~=1
Current2Voltaje100f=([gcs,'/','Fotodetector10']);
Senal100f=get_param(Current2Voltaje100f,'sel');
Frecuencia100f=get_param(Current2Voltaje100f,'frec');
%==============================================
switch (Frecuencia100f)
case '1310'
switch (Senal100f)
case 'STS-12/STM-4'
Ro100f=60; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.012;
case 'STS-48/STM-16'
Ro100f=36.6666666667; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.012;
otherwise
Ro100f=43.3333333333; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.011;
end
case '1550'
switch (Senal100f)
case 'STS-12/STM-4'
Ro100f=60; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.012;
case 'STS-48/STM-16'
Ro100f=31.4285714285; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.012;
otherwise
Ro100f=20; %Las unidades de la resistencia son "Ohmios".
Ibias100f=0.02;
end
end
set_param(Current2Voltaje100f,'Ibiasf',num2str(Ibias100f));
set_param(Current2Voltaje100f,'Rof',num2str(Ro100f));
end
Vo(:,:)=u(:,:);
end
%[EOF] current2voltage.m
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -