1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
| function choixFibre_Callback(hObject, eventdata, handles)
liste1 = get(handles.choixFibre, 'String');
indice1 = get(handles.choixFibre, 'Value');
Element_selectionne1 = liste1{indice1}; %sélection du nom du fichier
repertoire1 = 'C:\Users\Aristide\Desktop\Interface GUIDe\Fibres';
paramfibre = Element_selectionne1;
paramfibre2= 'fib.mat';
chemin1 = fullfile(repertoire1, paramfibre,paramfibre2);
fib=importdata(chemin1); %importation du fichier
set(handles.valDopage,'string',fib.Ntot);
set(handles.Valreff,'string',fib.reff);
set(handles.Valgammapompe,'string',fib.gammap);
set(handles.Valgammasignal,'string',fib.gammas);
function Choixampli_Callback(hObject, eventdata, handles)
liste2 = get(handles.Choixampli, 'String');
indice2 = get(handles.Choixampli, 'Value');
Element_selectionne2 = liste2{indice2} %sélection du nom du fichier;
repertoire2 = 'C:\Users\Aristide\Desktop\Interface GUIDe\Ampli';
paramampli = Element_selectionne2;
paramampli2= 'amp.mat';
chemin2 = fullfile(repertoire2, paramampli,paramampli2);
amp=importdata(chemin2); %importation du fichier
set(handles.Puissance_pompe,'string',amp.Pip);
set(handles.Puissance_signal,'string',amp.Pis);
set(handles.Lambda_pompe,'string',amp.LambdaP); |
Partager