Multi-OEM/Retail Project {MRP} - Mk3

Discussion in 'MDL Projects and Applications' started by mxman2k, Oct 15, 2016.

  1. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,769
    7,711
    210
    On my Windows 7, this value does indeed exist.

    For getting over WMIC:
    Code:
    wmic.exe OS GET "SerialNumber" /VALUE
    But I have only one!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    Im re doing the code to try to check for:
    2 internal cards only - ignores externals for now
    1 internal and 1 external
    2 externals only
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    This in theory does the 2 internals or 2 externals or 1 internal and 1 external....

    Code:
    # Get Grfx Adapter Information
     $g=""
    if ((get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.adapterDACType -like "Internal*"})
     {
    
     (get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.DeviceID -like "VideoController1"} | foreach-object -process {
     write-output (@($_.DeviceID,$_.Caption,($_.AdapterRam/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join "|")
     $g="1"
     }
    
      (get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.DeviceID -like "VideoController2"} | foreach-object -process {
      write-output (@($_.DeviceID,$_.Caption,($_.AdapterRam/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join "|")
     $g="2"
      }
    
    }
    
    # Dedicated graphics check only if only 1 internal card...
    
    if ($g -ne "2" )
    {
    
    if ((get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.adapterDACType -like "Integrated*"})
     {
    
     $qwMemorySize0 = (Get-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\0*" -Name HardwareInformation.qwMemorySize -ErrorAction SilentlyContinue)."HardwareInformation.qwMemorySize"
    
     foreach ($VRAM in $qwMemorySize0)
     {
      (get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.DeviceID -like "VideoController1"} | foreach-object -process {
      write-output (@($_.DeviceID,$_.Caption,($VRAM/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join '|')
     }
    
     }
    
     $qwMemorySize1 = (Get-ItemProperty -Path "HKLM:\SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\1*" -Name HardwareInformation.qwMemorySize -ErrorAction SilentlyContinue)."HardwareInformation.qwMemorySize"
    
     foreach ($VRAM in $qwMemorySize1)
     {
      (get-wmiobject Win32_videocontroller) | where-object -filterscript {$_.DeviceID -like "VideoController2"} | foreach-object -process {
      write-output (@($_.DeviceID,$_.Caption,($VRAM/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join '|')
     }
    
     }
    
     }
    }
    
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    fixed i had logic as 0 disabled, 1 enabled, but in reality it is 0 enabled and 1 disabled/unchecked. :oops:

    Fixed the ProductID for w7, also in the saved report you will have the extended ProductID too - it not fit in the GUI box so it just on the saved reports.

    Hopefully the new ps graphics script works - so far on my tests it has, i not have a m/board that can handle two cards to test that.

    Just tidying code and i will upload .33 GUI QT :)

    Saved Report example:
    Code:
    Product ID                      : 00328-00000-00000-AA636  {Extended: 03612-03280-000-000000-00-2057-19043.0000-3302021}
    TimeZone {TZUtil}               : GMT Standard Time
    Hours offset from GMT           : 0
    Daylight Saving In Effect       : No
    Daylight Adjust Clock Mode      : Enabled/Checked
    Hypervisor Present              : No
    Virtual Machine Data            : This computer does not appear to be a virtual machine
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. #9185 Deleted member 1531038, Nov 10, 2022
    Last edited by a moderator: Nov 10, 2022
    i think it will always result in correct pwsh func response .
    can be shortened via using there aliases :
    where or ? for where-object
    filter for filterscript
    -match for -like
    gwmi for get-wmiobject
    etc etc :)

    Code:
    # Get Grfx Adapter Information
     $g=""
    if ((gwmi Win32_videocontroller) | where -filter {$_.adapterDACType -match "Internal*"})
     {
    
     (gwmi Win32_videocontroller) | where -filter {$_.DeviceID -match "VideoController1"} | foreach -process {
     write-output (@($_.DeviceID,$_.Caption,($_.AdapterRam/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join "|")
     $g="1"
     }
    
      (gwmi Win32_videocontroller) | where -filter {$_.DeviceID -match "VideoController2"} | foreach -process {
      write-output (@($_.DeviceID,$_.Caption,($_.AdapterRam/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join "|")
     $g="2"
      }
    
    }
    
    # Dedicated graphics check only if only 1 internal card...
    
    if ($g -ne "2" )
    {
    
    if ((gwmi Win32_videocontroller) | where -filter {$_.adapterDACType -match "Integrated*"})
     {
    
     $qwMemorySize0 = (gp -Path "HKLM:SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\0*" -Name HardwareInformation.qwMemorySize -EA 0)."HardwareInformation.qwMemorySize"
    
     foreach ($VRAM in $qwMemorySize0)
     {
      (gwmi Win32_videocontroller) | where -filter {$_.DeviceID -match "VideoController1"} | foreach -process {
      write-output (@($_.DeviceID,$_.Caption,($VRAM/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join '|')
     }
    
     }
    
     $qwMemorySize1 = (gp -Path "HKLM:SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\1*" -Name HardwareInformation.qwMemorySize -EA 0)."HardwareInformation.qwMemorySize"
    
     foreach ($VRAM in $qwMemorySize1)
     {
      (gwmi Win32_videocontroller) | where -filter {$_.DeviceID -match "VideoController2"} | foreach -process {
      write-output (@($_.DeviceID,$_.Caption,($VRAM/1MB),$_.CurrentBitsPerPixel, $_.VideoMemoryType,$_.VideoModeDescription,$_.adapterDACType) -join '|')
     }
    
     }
    
     }
    }
    
     
  6. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    #9186 mxman2k, Nov 10, 2022
    Last edited: Nov 10, 2022
    (OP)
    Pulled GUI QT for now...
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,769
    7,711
    210
    win7_0.png win7_1.png win7_2.png win7_3.png win7_4.png win7_5.png win7_6.png win7_7.png

    DST fixed. ProductID fixed. Graphics information NOT fixed, it still lists the same card two times.

    Code:
    -------------------------------------------------------------------------------------------------------------------
                                                 Query Tool GUI v0.10.1.33
    -------------------------------------------------------------------------------------------------------------------
    
    Log Date {UTC}: 11/10/2022 -- 11:04 {24-hour}
    
    Some results may be shortened to fit the output stage, such as RAM information.
    
    This is the postable report that does not contain full serial or sensitive information.
    
    On Hypervisors some results may be missing due to unable to detect.
    
    GUI Font Used : Lucida Console Size: 11
    
    ===================================================================================================================
                                                 Operating System Information
    ===================================================================================================================
    Installation Type               : Client
    Name                            : Microsoft Windows 7 Professional
    OS/CPU Architecture             : CPU and OS is 64 bit
    Build                           : 6.1.7601 {UBR:26221}
    Language                        : English (United States)
    Native Language                 : English
    Installed/Available Languages   : en-US
    Stock Keeping Unit {SKU}        : 48
    Experience Pack                 : N/A
    Installation Date               : 9/13/2014 at 2:43 AM {UTC}
    Shipped with Reserved 7GB       : N/A
    Dirty Shutdown Count            : N/A
    Build Branch                    : N/A
    Product ID                      : 00371-868-0000007-85984  {Extended: 00371-00170-868-000000-03-1033-7601.0000-3502019}
    TimeZone {TZUtil}               : W. Europe Standard Time
    Hours offset from GMT           : 1
    Daylight Saving In Effect       : No
    Daylight Adjust Clock Mode      : Enabled/Checked
    Hypervisor Present              : Yes {VBox} 5.2.45.39677
    Virtual Machine Data            : This computer does not appear to be a virtual machine
    
    Windows Key 1 Installed         : GPDD4 (Last 5 digits shown)
    Windows DpID4 Installed         : GPDD4 (Last 5 digits shown)
    Windows Default Installed       : PW487 (Last 5 digits shown)
    Windows Default4 Installed      : PW487 (Last 5 digits shown)
    TPM Information                 : N/A
    
    ===================================================================================================================
                                      System Drive C: Partition Information
    ===================================================================================================================
    Drive Type                      : Non SSD
    BUS Type                        : Serial ATA (SATA)
    Total Space                     : 689.31 GB
    Free Space                      : 420.31 GB
    Partition Type                  : MBR
    Firmware Boot Type              : Legacy/MBR Mode {R:1}
    Secure Boot Status              : N/A
    File System                     : NTFS
    Model Name                      : WDC WD20 EZRZ-00Z5HB0 SATA Disk Device
    
    ===================================================================================================================
                                              Memory Information                                                       
    ===================================================================================================================
    Total Physical                  : 33445712 KB (31.9 GB)
    Available Physical              : 24539988 KB (23.4 GB)
    Total Page Size                 : 100335240 KB (95.69 GB)
    Available Page Size             : 88755276 KB (84.64 GB)
    Total Virtual Size              : 4194176 KB (4 GB)
    Available Virtual               : 4024492 KB (3.84 GB)
    Memory Type                     : N/A
    Memory Error Correction         : Non-ECC
    Memory Slots Fitted             : 4
    DIMM Information {First Four}   : DIMM0 8192MB @ 1600MHz  DIMM1 8192MB @ 1600MHz  DIMM2 8192MB @ 1600MHz  DIMM3 8192MB @ 1600MHz 
    
    ===================================================================================================================
                                              Graphics Information                                                     
    ===================================================================================================================
    Adaptor Name                    : NVIDIA GeForce GTX 980
    Adaptor Physical Memory         : 1024 MB (1 GB) {Routine:P1-7 v2}
    Adaptor DACType                 : Integrated RAMDAC {Addon}
    Adaptor Video Memory Type       : GDDR (2)
    Adaptor Status                  : Active
    
    Adaptor Name                    : NVIDIA GeForce GTX 980
    Adaptor Physical Memory         : 4096 MB (4 GB) {Routine:P1-7 v2}
    Adaptor DACType                 : Integrated RAMDAC {Addon}
    Adaptor Video Memory Type       : GDDR (2)
    Adaptor Status                  : Active
    
    Virtual Desktop Resolution      : 3840 x 2160
    Bits Per Pixel                  : 32
    Video Mode Description          : 3840 x 2160 x 4294967296 colors {Ref:1}
    
    Video Ram may include shared memory.
    Some values may not be accurate due to 32 bit API limitations.
    On Hypervisors some results may be missing due to unable to detect.
    
    ===================================================================================================================
                                            Network Adaptor Information                                               
    ===================================================================================================================
    Adaptor 1 Name                  : VirtualBox Host-Only Ethernet Adapter
    Connection Status               : Connected
    
    Adaptor 2 Name                  : Intel(R) Gigabit CT Desktop Adapter
    Connection Status               : Connected
    
    ===================================================================================================================
                                              Processor 1 Information                                                 
    ===================================================================================================================
    Name                            : AMD FX-8370 Eight-Core Processor               
    Architecture                    : 64
    L2 Cache Size                   : 8192
    L3 Cache Size                   : 8192
    Current Clock Speed             : 4000
    Physical Cores                  : 4
    Logical Cores                   : 8
    Processor Id                    : 178BFBFF00600F20
    Virtualization Mode             : Query not present on this OS
    Manufacturer                    : AuthenticAMD
    Description                     : AMD64 Family 21 Model 2 Stepping 0
    
    ===================================================================================================================
                                                 DMI/BIOS Information                                                 
    ===================================================================================================================
    System Manufacturer             : To be filled by O.E.M.
    System Product Name             : To be filled by O.E.M.
    BaseBoard Manufacturer          : ASUSTeK COMPUTER INC.
    BaseBoard Product               : SABERTOOTH 990FX R2.0
    BaseBoard Version               : Rev 1.xx
    
    BIOS Vendor                     : American Megatrends Inc.
    BIOS Release Date               : 05/04/2016
    BIOS Version                    : 2901
    Primary BIOS                    : True
    SMBIOS Present                  : True
    SMBIOS Version                  : 2.7
    SLIC/BIOS Data                  : _ASUS_ - 1072009
    
    Valid SLIC Name                 : Asus
    Possible Brand Theme            : Asus {BaseBoard Manufacturer}
    
    SLIC Table Status               : Unable to check on this OS
    MSDM Key Description            : No MSDM key Description found
    MSDM Key Detected               : Unable to decode the keys value on this OS
    
    ===================================================================================================================
                                              Miscellaneous Information                                               
    ===================================================================================================================
    Which MRP Version Used          : N/A
    
    Wallpaper Style                 : Fill image to display resolution
    Current Theme Used              : !NT.theme
    
    Installed Dot Net Frameworks    : 2.0  3.0  3.5  4.8  4.0 
    Installed Powershell Versions   : 1.0, 2.0, 3.0, 4.0, 5.0, 5.1
    
    Security Product Name{s}        : COMODO Antivirus
    Defender Tamper Protection      : Disabled
    Defender Service Status         : Disabled
    Windows Firewall Service State  : Disabled
    
    Windows Activation Status       : VL activation expires 174 Days / 251580 minutes
    Windows Licence Reason          : Valid key was used for the product's licensing channel
    Windows Product Key Channel     : KMS Client {VOLUME_KMSCLIENT}
    Device has KMS Enabled          : Yes
    KMS Auto Renewal (hook)         : No
    
    MS Office {MSI/Traditional}     : Not Detected
    C2R MS Office                   : Not Detected
    C2R Excluded Apps               : N/A
    C2R Last Update Channel         : N/A
    C2R Office Activation Status    : N/A
    C2R Partial Product Key         : N/A
    Office Reason Information       : No reason information to show/No Issues
    Office MAK/KMS Information      : No MAK or KMS activation detected
    
    -------------------------------------------------------------------------------------------------------------------
    
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    grfx is getting a total bugger :(

    At least fixed the DST :D
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  9. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    think to save my sanity i am going to scrap the Vram stuff and just list other graphics bits at least that is easier - i just look for videocontroller1 2 3 4 etc :)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  10. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    I have decided to call it a day on the VRam, so re-wrote the routine to show the driver info such as Version and Date instead.

    To find out your VRam use DXDiag or other tool to display the VRam as they are more accurate for that area.

    Example Video Section in the GUI QT
    Code:
    ===================================================================================================================
                                              Graphics Information                                                   
    ===================================================================================================================
    Adaptor Name                    : Intel(R) HD Graphics 4600
    Adaptor DACType                 : Internal {iGPU}
    Adaptor Driver Information      : 20.19.15.4624 {2017/03/08}
    Adaptor Status                  : Active
    
    Adaptor Name                    : NVIDIA GeForce GTX 860M
    Adaptor DACType                 : Integrated RAMDAC {Addon}
    Adaptor Driver Information      : 31.0.15.1659 {2022/06/23}
    Adaptor Status                  : Inactive
    
    Virtual Desktop Resolution      : 1536 x 864
    Bits Per Pixel                  : 32
    Video Mode Description          : 1920 x 1080 x 4294967296 colors {Ref:1}
    
    Some values may not be accurate due to 32 bit API limitations.
    For Video Ram use DXDiag or other tool.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  11. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    I may extend the video section up to 4 adapters, (if they are in the computer) ,but not at the moment, had enough hassle already so need a break from that video routine :D:D
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  12. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    #9192 mxman2k, Nov 10, 2022
    Last edited: Nov 11, 2022
    (OP)
    VRam removed.
    Added Graphics Driver Version and Date.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  13. tcntad

    tcntad MDL Guru

    Oct 26, 2009
    4,589
    1,584
    150
    Not bad:) I'd just like the text aligned centered instead of top:p
     
  14. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    Believe me i have tried to align the result box text entries so it is central, it just dont seem to want to do it :(

    I think it the function that is a addon that someone wrote for autoit. Will look for it and see how it written and edit it if i can.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  15. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    #9195 mxman2k, Nov 10, 2022
    Last edited: Nov 10, 2022
    (OP)
    Working on a update to system ram routine that should show the ram type and error correction for vista/7 , it should now but i think it may only fail on some hypervisors as the info not been set by default.

    That for tomorrow, as time to chill out as been on the gui code since 5:15am.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  16. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,769
    7,711
    210
    Now all that's left to do is adding the DxDiag Link to the optional Windows Tools page. :)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  17. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    #9197 mxman2k, Nov 11, 2022
    Last edited: Nov 11, 2022
    (OP)
    I did add it but it would just 'hang' :g:

    I think i have to run the dxdiag.exe depending on OS because on a 64bit OS the 'windows\system32' one hangs... so i guess i need to check for the 'windows\syswow64' one instead..

    Just 'run'ing dxdiag.exe causes a not responding message.

    Sorted, was running wrong version :oops:
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  18. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    When the DxDiag button is pressed (Optional Tab) a splash screen pops up informing is it being run for a few seconds, it can take a while for DxDiag screen to appear so let it do its thing and it will then present itself. I have told it not to check for whql certs as that can take ages too, you can select it from the DxDiag's main screen if you wish once it has appeared.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  19. mxman2k

    mxman2k MDL Developer

    Jun 20, 2007
    6,320
    21,059
    210
    #9199 mxman2k, Nov 11, 2022
    Last edited: Nov 11, 2022
    (OP)
    Visual change: Almost centralized text within the result boxes, plus sunken area, only way to get the text central.

    Added DxDiag button in the Optional Tab - it can take a while to appear.

    On Vista/7 there is still some results not available, i will see what i can do for a work around but that not a priority for now.

    NewLook.JPG
    Click for larger image to see the new look :)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  20. migascalp

    migascalp MDL Senior Member

    Sep 18, 2009
    447
    762
    10