home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DOS/V Power Report 2000 April
/
VPR0004B.BIN
/
DRIVER
/
COMPAQ
/
SP12255
/
sp12255.exe
/
DMWEBC1.CAB
/
CPU.TPL
< prev
next >
Wrap
Text File
|
1999-06-22
|
5KB
|
190 lines
<HTML>
<!-- $Id: SB-INFO.TPL 1.10 1998/03/17 22:32:54 cboeker Q/A $ -->
<!-- Copyright (C) 1998 Compaq Computer Corporation -->
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!--
<!#COND.JS>
<!#TABLES.JS>
//-->
</SCRIPT>
<!#CPU.JS>
</HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!*, DMTF|FRU|*, 1, FRUIndex>
<!*, DMTF|Operational State|*, 1, OsIndex>
<!-- ==================== CPU ==================== -->
writeTableLabel(sCPUs);
writeTableHead();
<!*, DMTF|Processor|*, 4, Cpu>
<!*, DMTF|Processor|*, 5, CpuSpeed>
<!*, DMTF|Processor|*, 7, CpuUpgrade>
<!*, DMTF|Processor|*, 2, CpuType>
<!*, DMTF|Processor|*, 8, CpuFruIndex>
<!*, DMTF|Processor|*, 9, CpuOs>
<!*, DMTF|Processor|*, 10, CpuL1Cache>
<!*, DMTF|Processor|*, 11, CpuL2Cache>
<!*, DMTF|Processor|*, 12, CpuL3Cache>
<!*, DMTF|System Cache|*, 4, CacheSize>
<!*, DMTF|Operational State|*, 10, OsCurrentErrorStatus>
ErrCond = new Array();
ErrCond[0] = "Other";
ErrCond[1] = "Unknown";
ErrCond[2] = "OK";
ErrCond[3] = "Non-critical";
ErrCond[4] = "Critical";
ErrCond[5] = "Non-recoverable";
cpuSocket = 0;
for (x = 0; x < Cpu.length; x++)
{
TempCond = 1;
if (CpuOs[x] > 0)
{
ActualOsIndex = -1;
for (k = 0; k < OsIndex.length; k++)
{
if (CpuOs[x] == OsIndex[k])
{
ActualOsIndex = k;
break;
}
}
if (ActualOsIndex >= 0)
{
for (j = 0; j <= ErrCond.length - 1; j++)
{
if (OsCurrentErrorStatus[ActualOsIndex] == ErrCond[j])
{
if (j < 2)
TempCond = 1;
else
TempCond = j;
break;
}
}
}
}
CpuStatus = new cpqCondition(TempCond);
proc = "";
proc = proc + CpuStatus.imageSmall() + Cpu[x] + " /" + CpuSpeed[x] + "Mhz";
action = ActionArray[TempCond - 1];
cache = "";
if (CpuL1Cache[x] > 0)
{
if (CacheSize[CpuL1Cache[x] -1] > 1024)
cache = "L1 " + CacheSize[CpuL1Cache[x] -1]/1024 + "MB";
else
cache = "L1 " + CacheSize[CpuL1Cache[x] -1] + "KB";
}
if (CpuL2Cache[x] > 0)
{
if (cache == "")
{
if (CacheSize[CpuL2Cache[x] -1] > 1024)
cache = "L2 " + CacheSize[CpuL2Cache[x] -1]/1024 + "MB";
else
cache = "L2 " + CacheSize[CpuL2Cache[x] -1] + "KB";
}
else
{
if (CacheSize[CpuL2Cache[x] -1] > 1024)
cache = cache + ", L2 " + CacheSize[CpuL2Cache[x] -1]/1024 + "MB";
else
cache = cache + ", L2 " + CacheSize[CpuL2Cache[x] -1] + "KB";
}
}
if (CpuL3Cache[x] > 0)
{
if (cache == "")
{
if (CacheSize[CpuL3Cache[x] -1] > 1024)
cache = "L3 " + CacheSize[CpuL3Cache[x] -1]/1024 + "MB";
else
cache = "L3 " + CacheSize[CpuL3Cache[x] -1] + "KB";
}
else
{
if (CacheSize[CpuL3Cache[x] -1] > 1024)
cache = cache + ", L3 " + CacheSize[CpuL3Cache[x] -1]/1024 + "MB";
else
cache = cache + ", L3 " + CacheSize[CpuL3Cache[x] -1] + "KB";
}
}
if("" == cache)
cache = "none";
Version = "N/A";
CpuSerialNumber = "";
CpuSerialNumberLabel = "";
if (CpuFruIndex[x] > 0)
{
ActualFRUIndex = -1;
for (k = 0; k < FRUIndex.length; k++)
{
if (CpuFruIndex[x] == FRUIndex[k])
{
ActualFRUIndex = k;
break;
}
}
if (ActualFRUIndex >= 0)
{
<!*, DMTF|FRU|*, 7, FRUSerialNumber>
<!*, DMTF|FRU|*, 8, FRURevisionLevel>
CpuSerialNumber = FRUSerialNumber[ActualFRUIndex];
Version = FRURevisionLevel[ActualFRUIndex];
}
}
if (CpuSerialNumber != "")
CpuSerialNumberLabel = sSerialNumber + ":";
if (x > 0)
writeDoubleTableRow("","","","");
if (CpuType[x] == "Central Processor")
cpuSocket = cpuSocket + 1;
writeDoubleTableRow( sProcessor + ":", proc, sCache + ":", cache);
writeDoubleTableRow( sSocket + ":", cpuSocket, sVersion + ":", Version);
writeDoubleTableRow( sType + ":", CpuType[x], sUpgrade + ":", CpuUpgrade[x]);
if (CpuSerialNumber != "")
writeDoubleTableRow( CpuSerialNumberLabel, CpuSerialNumber, "", "");
writeDoubleTableRow( "", "", "", "");
writeSingleTableRowInDoubleTable(sAction + ":", action);
}
writeTableTail();
document.write("<BR>");
</SCRIPT>
</HTML>