⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dplresolutionresult.asv

📁 在MATLAB环境下设计一个加速度计动态校准的数据处理软件附有程序源代码,压缩包中有软件使用说明
💻 ASV
📖 第 1 页 / 共 4 页
字号:
%        str2double(get(hObject,'String')) returns contents of edit1 as a double


% --- Executes during object creation, after setting all properties.
function edit1_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function edit7_Callback(hObject, eventdata, handles)
% hObject    handle to edit7 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of edit7 as text
%        str2double(get(hObject,'String')) returns contents of edit7 as a double


% --- Executes during object creation, after setting all properties.
function edit7_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit7 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function edit8_Callback(hObject, eventdata, handles)
% hObject    handle to edit8 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of edit8 as text
%        str2double(get(hObject,'String')) returns contents of edit8 as a double


% --- Executes during object creation, after setting all properties.
function edit8_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit8 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function edit9_Callback(hObject, eventdata, handles)
% hObject    handle to edit9 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of edit9 as text
%        str2double(get(hObject,'String')) returns contents of edit9 as a double


% --- Executes during object creation, after setting all properties.
function edit9_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit9 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

% --- Executes during object creation, after setting all properties.
function edit13_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit13 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

% --- Executes during object creation, after setting all properties.
function edit12_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit12 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

% --- Executes during object creation, after setting all properties.
function edit11_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit11 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

% --- Executes during object creation, after setting all properties.
function edit10_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit10 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

function edit14_Callback(hObject, eventdata, handles)
% hObject    handle to edit14 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of edit14 as text
%        str2double(get(hObject,'String')) returns contents of edit14 as a double


% --- Executes during object creation, after setting all properties.
function edit14_CreateFcn(hObject, eventdata, handles)
% hObject    handle to edit14 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


% --- Executes on button press in pushbutton19.
function pushbutton19_Callback(hObject, eventdata, handles)
% hObject    handle to pushbutton19 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
DPRResult_RadioV_Value=get(findobj('Tag','radiobutton1'),'Value');
save DPR_DataSupport DPRResult_RadioV_Value -append;
close;
run DPLResolution;



% --- Executes on button press in pushbutton21.
function pushbutton21_Callback(hObject, eventdata, handles)
% hObject    handle to pushbutton21 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
DPRResult_RadioV_Value=get(findobj('Tag','radiobutton1'),'Value');
save DPR_DataSupport DPRResult_RadioV_Value -append;
close 
close DPLResolution;
clear; 



% --- Executes on button press in radiobutton1.
function radiobutton1_Callback(hObject, eventdata, handles)
% hObject    handle to radiobutton1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of radiobutton1
set(hObject,'Value',1);
%重复初始化中的操作
%设置速度峰值的名称和单位
load DPR_DataSupport DPRCover_PopMenuSTD_Value DPRCover_PopMenuTEA_Value DPRCover_PopMenuTEB_Value;
load DPR_DataSupport V_TEA_max V_TEB_max V_STD_max...
                     Sens_TEA_V Sens_TEB_V...
                     T_STD_V;
set(findobj('Tag','text90'),'String','速度峰值');
set(findobj('Tag','text67'),'String','m/s');
set(findobj('Tag','edit1'),'String',num2str(V_STD_max));
if DPRCover_PopMenuTEA_Value~=4
    if DPRCover_PopMenuTEA_Value==1
        set(findobj('Tag','text23'),'String','速度峰值');
        set(findobj('Tag','text82'),'String','m/s');
    elseif DPRCover_PopMenuTEA_Value==2  | DPRCover_PopMenuTEA_Value==3
        set(findobj('Tag','text23'),'String','电压峰值');
        set(findobj('Tag','text82'),'String','mV');
    end
    set(findobj('Tag','edit9'),'String',num2str(V_TEA_max));
end
if DPRCover_PopMenuTEB_Value~=4
    if DPRCover_PopMenuTEB_Value==1
        set(findobj('Tag','text26'),'String','速度峰值');
        set(findobj('Tag','text85'),'String','m/s');
    elseif DPRCover_PopMenuTEB_Value==2 | DPRCover_PopMenuTEB_Value==3
        set(findobj('Tag','text26'),'String','电压峰值');
        set(findobj('Tag','text85'),'String','mV');
    end
    set(findobj('Tag','edit52'),'String',num2str(V_TEB_max));
end
%设置脉宽
set(findobj('Tag','edit7'),'String',num2str(T_STD_V));
%设置灵敏度的单位和数值
if DPRCover_PopMenuSTD_Value==1 
    if DPRCover_PopMenuTEA_Value~=4
        if DPRCover_PopMenuTEA_Value==1
            set(findobj('Tag','text80'),'String','');
        elseif DPRCover_PopMenuTEA_Value==2
            set(findobj('Tag','text80'),'String','m/s/V');
        elseif DPRCover_PopMenuTEA_Value==3
            set(findobj('Tag','text80'),'String','mV/m/s');
        end
        set(findobj('Tag','edit50'),'String',num2str(Sens_TEA_V));
    end
    if DPRCover_PopMenuTEB_Value~=4
        if DPRCover_PopMenuTEB_Value==1
            set(findobj('Tag','text84'),'String','');
        elseif DPRCover_PopMenuTEB_Value==2
            set(findobj('Tag','text84'),'String','m/s/V');
        elseif DPRCover_PopMenuTEB_Value==3
            set(findobj('Tag','text84'),'String','mV/m/s');
        end
        set(findobj('Tag','edit93'),'String',num2str(Sens_TEB_V));
    end
elseif DPRCover_PopMenuSTD_Value==2
    if DPRCover_PopMenuTEA_Value~=4
        if DPRCover_PopMenuTEA_Value==1
            set(findobj('Tag','text80'),'String','');
        elseif DPRCover_PopMenuTEA_Value==2
            set(findobj('Tag','text80'),'String','m/s/V');
        elseif DPRCover_PopMenuTEA_Value==3
            set(findobj('Tag','text80'),'String','mV/m/s');
        end
        set(findobj('Tag','edit50'),'String',num2str(Sens_TEA_V));
    end
    if DPRCover_PopMenuTEB_Value~=4
        if DPRCover_PopMenuTEB_Value==1
            set(findobj('Tag','text84'),'String','');
        elseif DPRCover_PopMenuTEB_Value==2
            set(findobj('Tag','text84'),'String','m/s/V');
        elseif DPRCover_PopMenuTEB_Value==3
            set(findobj('Tag','text84'),'String','mV/m/s');
        end
        set(findobj('Tag','edit93'),'String',num2str(Sens_TEB_V));
    end
elseif DPRCover_PopMenuSTD_Value==3
    if DPRCover_PopMenuTEA_Value~=4
        if DPRCover_PopMenuTEA_Value==1
            set(findobj('Tag','text80'),'String','');
        elseif DPRCover_PopMenuTEA_Value==2
            set(findobj('Tag','text80'),'String','m/s/V');
        elseif DPRCover_PopMenuTEA_Value==3
            set(findobj('Tag','text80'),'String','mV/m/s');
        end
        set(findobj('Tag','edit50'),'String',num2str(Sens_TEA_V));
    end
    if DPRCover_PopMenuTEB_Value~=4
        if DPRCover_PopMenuTEB_Value==1
            set(findobj('Tag','text84'),'String','');
        elseif DPRCover_PopMenuTEB_Value==2
            set(findobj('Tag','text84'),'String','m/s/V');
        elseif DPRCover_PopMenuTEB_Value==3
            set(findobj('Tag','text84'),'String','mV/m/s');
        end
        set(findobj('Tag','edit93'),'String',num2str(Sens_TEB_V));
    end
end
%绘制速度波形
load DPR_DataSupport V_STD V_TEA V_TEB;
[size_x,size_y]=size(V_STD);
x=1:size_x;
if DPRCover_PopMenuSTD_Value==1 
    plot(x,V_STD,'r')
    set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
    grid on;zoom off;zoom xon;
    hold on;
    if DPRCover_PopMenuTEA_Value==1
        plot(x,V_TEA,'c')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
        hold on;   
    elseif DPRCover_PopMenuTEA_Value==2
        plot(x,V_TEA.*Sens_TEA_V,'c')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
        hold on;    
    elseif DPRCover_PopMenuTEA_Value==3
        plot(x,(V_TEA.*1000)./Sens_TEA_V,'c')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
        hold on;    
    end
    if DPRCover_PopMenuTEB_Value==1
        plot(x,V_TEB,'y')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
    elseif DPRCover_PopMenuTEB_Value==2
        plot(x,V_TEB.*Sens_TEB_V,'y')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
    elseif DPRCover_PopMenuTEB_Value==3
        plot(x,(V_TEB.*1000)./Sens_TEB_V,'y')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
    end
 elseif DPRCover_PopMenuSTD_Value==2
    plot(x,V_STD,'r')
    set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
    grid on;zoom off;zoom xon;
    hold on;
    if DPRCover_PopMenuTEA_Value==1
        plot(x,V_TEA,'c')
        set(gca,'Color',[0,0,0],'XColor',[0,1/2,0],'YColor',[0,1/2,0]);
        grid on;zoom off;zoom xon;
        hold on;     
    elseif DPRCover_PopMenuTEA_Value==2
        plot(x,V_TEA.*Sens_TEA_V,'c')

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -