ZenitH-AT / nvidia-data

Writes the latest product family (GPU) and operating system data from the NVIDIA Download API (lookupValueSearch) to a JSON file.
The Unlicense
6 stars 4 forks source link

Add OS DCH compability #2

Closed ElPumpo closed 1 year ago

ElPumpo commented 1 year ago

This is a feature request.

The idea is that the OS metadata also contains the OS that are compatiable with DCH. Currently TNUC has a hardcoded list of compatiable OS. I belive nvidia-update has similar implementation. It would be better if the repo contained this information, and it not being hardcoded.

Thanks <3

ZenitH-AT commented 1 year ago

Hi, thanks for bringing this up.

For DCH compatibility, the OS needs to have UWP support. So, that's Windows 10 and newer, as you know (assuming the user didn't mess with their system to break compatibility).

I could add the hardcoded list to the script generating OS data but I'd need to update it every time Windows releases a new OS (which is obviously very infrequently).

Though, I want to try keep this data purely from NVIDIA as much as possible (and not tied too much to Windows), especially since it's possible some tweaked Windows 10 installs don't even support DCH.

Another way that avoids the need for a hardcoded list on either the script generating this data or software using this data, is to just check if the Windows build number is greater than or equal to 10240. In PowerShell, it's done like this:

$dchSupported = (Get-CimInstance -ClassName Win32_OperatingSystem).BuildNumber -ge 10240

I actually just replaced the hard coded list in nvidia-update with this as of https://github.com/ZenitH-AT/nvidia-update/commit/bc7441507a8cfbf0d173647a12febd3b74fabf2f.

In C#, it can probably be done a similar way. A better way would be to check if UWP is actually available on the system but I have no idea how to do that. Maybe theres a registry key with UWP version information or something.


P.S. The actual list of DCH supporting Windows versions is:

The above was retreived from a list here (the link in the Overview section).


If you really, really need this data to be added here then let me know.

ElPumpo commented 1 year ago

Your build check is much smarter. As you said yourself they all now support DCH so its sufficient