-
Notifications
You must be signed in to change notification settings - Fork 71
/
MemDeviceMappedInfo.dpr
67 lines (59 loc) · 2.35 KB
/
MemDeviceMappedInfo.dpr
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
program MemDeviceMappedInfo;
{$APPTYPE CONSOLE}
uses
Classes,
SysUtils,
uSMBIOS in '..\..\Common\uSMBIOS.pas';
procedure GetMemDeviceMappedInfo;
Var
SMBios: TSMBios;
LMemDevMappedAddress: TMemoryDeviceMappedAddressInformation;
begin
SMBios := TSMBios.Create;
try
WriteLn('Memory Device Mapped Address Information');
WriteLn('----------------------------------------');
if SMBios.HasMemoryDeviceMappedAddressInfo
then
for LMemDevMappedAddress in SMBios.MemoryDeviceMappedAddressInformation do
begin
WriteLn(Format('Starting Address %.8x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.StartingAddress]));
WriteLn(Format('Ending Address %.8x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.EndingAddress]));
WriteLn(Format('Memory Device Handle %.4x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.MemoryDeviceHandle]));
WriteLn(Format('Memory Array Mapped Address Handle %.4x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.MemoryArrayMappedAddressHandle]));
WriteLn(Format('Partition Row Position %d',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.PartitionRowPosition]));
WriteLn(Format('Interleave Position %d',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.InterleavePosition]));
WriteLn(Format('Interleaved Data Depth %d',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.InterleavedDataDepth]));
if SMBios.SmbiosVersion >= '2.7'
then
begin
WriteLn(Format('Extended Starting Address %x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.ExtendedStartingAddress]));
WriteLn(Format('Extended Ending Address %x',
[LMemDevMappedAddress.RAWMemoryDeviceMappedAddressInfo.ExtendedEndingAddress]));
end;
WriteLn;
end
else
WriteLn('No Memory Device Mapped Address Info was found');
finally
SMBios.Free;
end;
end;
begin
try
GetMemDeviceMappedInfo;
except
on E: Exception do
WriteLn(E.Classname, ':', E.Message);
end;
WriteLn('Press Enter to exit');
Readln;
end.