from
XPC_COMMAND_CENTER
by Frank González-Morphy
xpc_command_center is a GUI to easily communicate to the xPC Target Application.
|
| xpc_command_center_diag() |
function xpc_command_center_diag()
% XPC_COMMAND_CENTER_DIAG show Diagnostic Info from XPC_COMMAND_CENTER
%
% XPC_COMMAND_CENTER_DIAG does read the File xpc_cmd_diag.mat which has the
% Diagnostics information about the XPC_COMMAND_CENTER GUI if some
% problems where found during execution. The MAT-File will be saved in the
% TEMPDIR of MATLAB current Session.
% Provide the MAT-File for furthermore support of functioanlity to
% Frank Gonzlez-Morphy ... frank.gonzalez-morphy@mathworks.de
%
% The XPC_COMMAND_CENTER is for xPC Target beginners a GUI which should
% help to get familiar with the commands as well the functionality. The
% Buttons where possitioned in execution order as the commands should be
% executed. They have the corresponding xPC Commands shown as Tooltip for
% having an overview of them.
%% AUTHOR : Frank Gonzalez-Morphy
%% $DATE : 13-Jul-2004 12:52:02 $
%% $Revision : 1.00 $
%% DEVELOPED : 7.0.0.19920 (R14)
%% FILENAME : xpc_command_center_diag.m
disp(' ')
disp(' :: xPC-CMD: Diagnostics of XPC_COMMAND_CENTER ... ')
if exist([tempdir 'xpc_cmd_diag.mat']) == 2
disp(' ')
disp(' :: xPC-CMD: ... data found ... ') % disp(' ')
disp(' :: xPC-CMD: ... loading ... ')
load([tempdir 'xpc_cmd_diag']) % disp(' ')
disp(' :: xPC-CMD: ... listning: ') % disp(' ')
disp(' ========================================== ')
disp(xpc_cmd_data.logged)
if isfield(xpc_cmd_data.logged,'pcidevicesinstalled')
show_pci_data(xpc_cmd_data.logged.pcidevicesinstalled)
end
disp(' ========================================== ')
disp(' ')
else
disp(' ')
disp(' :: xPC-CMD: Sorry none Diagnostic Data found!')
disp([' :: ... in (TEMPDIR) ' tempdir])
disp(' ')
end
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%% SHOW_PCI_DATA %%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
function show_pci_data(pcidevs)
disp(' ')
disp(' :: Installed PCI I/O-Boards on Target System:')
disp(' ---------------------------------------------')
% Header of Output
fprintf(1,'%-5s%-5s%-5s%-30s%-20s%-30s%-10s%-10s\n\n',...
'Bus','Slot','IRQ','Vendor Name','Device Name','Device Type','VendorID','DeviceID');
% Sequence of founded Data
for i=1:length(pcidevs)
fprintf(1,'%-5s%-5s%-5s%-30s%-20s%-30s%-10s%-10s\n',...
num2str(pcidevs(i).Bus),...
num2str(pcidevs(i).Slot),...
num2str(pcidevs(i).Interrupt),...
pcidevs(i).VendorName,...
pcidevs(i).DeviceName,...
pcidevs(i).DeviceType,...
pcidevs(i).VendorID,...
pcidevs(i).DeviceID);
end
disp(' ---------------------------------------------')
% ===== EOF ====== [xpc_command_center_diag.m] =====
|
|
Contact us at files@mathworks.com