Hto3.SimpleSpecsDetector 1.2.9

.NET 5.0 .NET Standard 2.0 .NET Framework 4.6.1
Install-Package Hto3.SimpleSpecsDetector -Version 1.2.9
dotnet add package Hto3.SimpleSpecsDetector --version 1.2.9
<PackageReference Include="Hto3.SimpleSpecsDetector" Version="1.2.9" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Hto3.SimpleSpecsDetector --version 1.2.9
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Hto3.SimpleSpecsDetector, 1.2.9"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install Hto3.SimpleSpecsDetector as a Cake Addin
#addin nuget:?package=Hto3.SimpleSpecsDetector&version=1.2.9

// Install Hto3.SimpleSpecsDetector as a Cake Tool
#tool nuget:?package=Hto3.SimpleSpecsDetector&version=1.2.9
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

logo

Hto3.SimpleSpecsDetector

License Hto3.SimpleSpecsDetector Downloads Build Status

Fully managed .NET library to detect the specs of the hardware, available in .NET Framework or .NET Core flavors (.NET Standard). This library intends to keep direct and simple, don't expect to retrieve all geek info like HWiNFO, AIDA64 or Speccy provides.

This library is ideal for obtaining simple information from Desktops and Servers, perhaps for a troubleshooting or inventory, or simply to use in the log of your application.

Example

example 

Supported Windows Versions

  • Windows 11
  • Windows Server 2022
  • Windows 10
  • Windows Server 2019
  • Windows Server 2016
  • Windows 8.1
  • Windows Server 2012 R2
  • Windows 8
  • Windows Server 2012
  • Windows 7
  • Windows Server 2008 R2
  • Windows Server 2008

Discontinuated support. Use up to version 1.2.3

  • Windows Vista
  • Windows Server 2003 R2
  • Windows Server 2003
  • Windows XP 64-Bit Edition
  • Windows XP

Supported Linux Versions

  • Same as .NET supported list (link).

Supported .NET Versions

  • .NET Framework 4.6.1 to 4.8
  • .NET Core 2.x and 3.x (through .NET Standard)
  • .NET 5.0
  • .NET 6.0

Features

Os

  • GetOsVersionNumber Windows: Get the correct Windows version following the Microsoft table (https://docs.microsoft.com/en-us/windows/win32/sysinfo/operating-system-version). Linux: Get the VERSION_ID value.
  • GetOsVersionName Get the OS version name.
  • GetInstalledFrameworkVersion Get the higher .NET Framework version installed on machine. This method can detect starting from 4.0 version.
  • GetSystemUpTime Get system up time.
  • GetKernelVersion Get the OS kernel version.

Processor

  • GetProcessorName Get the processor name.
  • GetProcessorUsage Mensure and get the current processor percent usage, where 0 is no load and 1 is full load. Default mensure time is 1 second.

Video

  • GetDisplayAdapterName Get the display adapter name.
  • GetVideoMemory Get amount of memory of the display adapter. Result in bytes.
  • GetCurrentVideoResolution Get the resolution in pixels of the current display in use (focused).

Memory

  • GetFreeMemory Number of bytes of physical memory currently unused and available.
  • GetInstalledMemory Get the amount of installed physical memory in bytes.
  • GetVisibleMemory The total amount of physical memory (in Bytes) available to the OperatingSystem. This value does not necessarily indicate the true amount of physical memory, but what is reported to the OperatingSystem as available to it.

Motherboard

  • GetVendorName Get the vendor name.
  • GetModel Get the motherboard model.
  • GetBIOSVersion Get the BIOS version.

Storage

  • GetDisks Get all connected hard disks. The information available is the hard disk name and size.

Sound

  • GetSoundCards Get all connected sound cards.

Printer

  • GetPrinters Get all installed printers.

Network

  • GetNetworkCards Get all connected network cards.
  • GetNetworkThroughput Mensure 1 second and get the current network traffic throughput. Result in Bytes.

Sample App

class Program
{
    static void Main(string[] args)
    {
        //Os
        Console.WriteLine("Os.GetOsVersionNumber: {0}", HardwareDetector.OsDetector.GetOsVersionNumber());
        Console.WriteLine("Os.GetOsVersionName: {0}", HardwareDetector.OsDetector.GetOsVersionName());
        Console.WriteLine("Os.GetInstalledFrameworkVersion: {0}", HardwareDetector.OsDetector.GetInstalledFrameworkVersion());
        Console.WriteLine("Os.GetSystemUpTime: {0}", HardwareDetector.OsDetector.GetSystemUpTime());
        Console.WriteLine("Os.GetKernelVersion: {0}", HardwareDetector.OsDetector.GetKernelVersion());

        //Video
        Console.WriteLine("Video.GetDisplayAdapterName: {0}", HardwareDetector.VideoDetector.GetDisplayAdapterName());
        Console.WriteLine("Video.GetVideoMemory: {0} bytes", HardwareDetector.VideoDetector.GetVideoMemory());
        Console.WriteLine("Video.GetCurrentVideoResolution: {0}", HardwareDetector.VideoDetector.GetCurrentVideoResolution());

        //Processor
        Console.WriteLine("Processor.GetProcessorName: {0}", HardwareDetector.ProcessorDetector.GetProcessorName());
        Console.WriteLine("Processor.GetProcessorUsage: {0}%", HardwareDetector.ProcessorDetector.GetProcessorUsage().Result * 100);

        //Memory
        Console.WriteLine("Memory.GetFreeMemory: {0} bytes", HardwareDetector.MemoryDetector.GetFreeMemory());
        Console.WriteLine("Memory.GetVisibleMemory: {0} bytes", HardwareDetector.MemoryDetector.GetVisibleMemory());
        Console.WriteLine("Memory.GetInstalledMemory: {0} bytes", HardwareDetector.MemoryDetector.GetInstalledMemory());

        //Motherboard
        Console.WriteLine("Motherboard.GetModel: {0}", HardwareDetector.MotherboardDetector.GetModel());
        Console.WriteLine("Motherboard.GetVendorName: {0}", HardwareDetector.MotherboardDetector.GetVendorName());
        Console.WriteLine("Motherboard.GetBIOSVersion: {0}", HardwareDetector.MotherboardDetector.GetBIOSVersion());

        //Storage
        foreach (var disk in HardwareDetector.StorageDetector.GetDisks())
            Console.WriteLine("Storage.GetDisks: {0}", disk);

        //Printers
        foreach (var printer in HardwareDetector.PrinterDetector.GetPrinters())
            Console.WriteLine("Printer.GetPrinters: {0}", printer);

        //Sound cards
        foreach (var soundCard in HardwareDetector.SoundDetector.GetSoundCards())
            Console.WriteLine("Sound.GetSoundCards: {0}", soundCard);

        //Network cards
        foreach (var networkAdapter in HardwareDetector.NetworkDetector.GetNetworkCards())
            Console.WriteLine("Network.GetNetworkCards: {0}", networkAdapter);
        Console.WriteLine("Network.GetNetworkThroughput: {0}", HardwareDetector.NetworkDetector.GetNetworkThroughput(NetworkInterface.GetAllNetworkInterfaces().Last().Description).Result);
    }
}
Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows
.NET Core netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard2.0 netstandard2.1
.NET Framework net461 net462 net463 net47 net471 net472 net48
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen40 tizen60
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.2.9 103 3/27/2022
1.2.8 103 1/29/2022
1.2.7 120 11/29/2021
1.2.5 127 11/13/2021
1.2.3 242 5/9/2021
1.2.2 148 4/11/2021
1.2.1 143 2/16/2021
1.2.0 191 12/13/2020
1.0.7 231 10/29/2020
1.0.6 317 1/21/2020
1.0.5 326 9/28/2019
1.0.4 326 9/8/2019
1.0.3 335 8/7/2019
1.0.2 330 8/6/2019
1.0.1 329 7/24/2019
1.0.0 339 6/30/2019