Dreaming-Codes / nvidia_oc

A simple command line tool to overclock Nvidia GPUs using the NVML library on Linux. This supports both X11 and Wayland.
https://crates.io/crates/nvidia_oc
MIT License
48 stars 1 forks source link

Add commands to get the current values #11

Open dougg0k opened 1 month ago

dougg0k commented 1 month ago

Hi,

Can you add commands to get the current values of all that is relevant?

Clocks, Temps, Voltages, etc..

Show them all at once.

Also, if possible, add Min, Curr, Max values. Could also have red warns if too high.

Dreaming-Codes commented 1 month ago

I'm not sure if NVML provides a way to do that but I'll check as soon as I have time

dougg0k commented 1 month ago

https://docs.nvidia.com/deploy/nvml-api/group__nvmlDeviceQueries.html Maybe not all, but it does have many.


NvAPI_DLL_GetVoltages


https://github.com/Demion/nvapioc/blob/master/Source/main.cpp#L289


https://docs.rs/nvapi-sys/latest/nvapi_sys/nvid/enum.Api.html

Not related, but I wonder if this would work, as it doesnt seem to be working with nvreg anymore on latest drivers. https://docs.rs/nvapi-sys/latest/nvapi_sys/nvid/enum.Api.html#variant.NvAPI_GPU_SetPowerMizerInfo

crimist commented 3 weeks ago

I don't feel that this tool needs to grow into monitoring software but given it's set index ... syntax a matching get index that returns the currently applied offsets and power limit would be useful.

nvmlDeviceGetClockOffsets seems to fit part of the bill.