# Control GPU fan speed

**URL:** <https://discourse.processing.org/t/control-gpu-fan-speed/5820>\
**Category:** Libraries\
**Created:** [November 22, 2018, 8:10am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820 "2018-11-22T08:10:03Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![shoaibmirza](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/shoaibmirza/32/923_2.png) [@shoaibmirza](https://discourse.processing.org/u/shoaibmirza)\
**Post date:** [November 22, 2018, 8:10am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/1 "2018-11-22T08:10:03Z")

</div>

Hi. i am trying to control my **GPU(Graphics card) fan speed** using processing. is there any library or API to do that ?

- my GPU : **nvidia GTX1070**
- my OS : **windows 10 / 64bit**

Thanks in advance.  
shoaib

---

<div class="post-metadata">

**Author:** ![Lexyth](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/lexyth/32/7403_2.png) [@Lexyth](https://discourse.processing.org/u/Lexyth)\
**Post date:** [November 22, 2018, 9:17am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/2 "2018-11-22T09:17:37Z")

</div>

I don’t know about processing internal comands, and not even about java methods for this, but i just searched for methods that would work with java in general and i didn’t find much useful… and if it’s not doable in java, then it can’t be done in Processing. But there are some ways to monitorize fanspeed apparently.

So i’d say no, it’s not doable, but i might have overlooked something. But i highly doubt that there is a special processing library for it.

---

<div class="post-metadata">

**Author:** ![neilcsmith](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/neilcsmith/32/144_2.png) [@neilcsmith](https://discourse.processing.org/u/neilcsmith)\
**Post date:** [November 22, 2018, 10:49am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/3 "2018-11-22T10:49:23Z")

</div>

If this was Linux then there’s likely a terminal program to do this. You can then exec that from Processing / Java. Of course, it would almost certainly require admin rights, which is another issue.

I would see if there’s any Windows terminal program for this, and if there is see if you can call it from your sketch.

---

<div class="post-metadata">

**Author:** ![TfGuy44](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/tfguy44/32/41_2.png) [@TfGuy44](https://discourse.processing.org/u/TfGuy44)\
**Post date:** [November 22, 2018, 11:11am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/4 "2018-11-22T11:11:43Z")

</div>

Agreeing that this is unlikely.

Of course, if your GPU is being used to render your sketch, you do have a small amount of control over it. Render a billion polygons with it and the fan will probably kick onto high…

---

<div class="post-metadata">

**Author:** ![shoaibmirza](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/shoaibmirza/32/923_2.png) [@shoaibmirza](https://discourse.processing.org/u/shoaibmirza)\
**Post date:** [November 22, 2018, 11:20am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/5 "2018-11-22T11:20:03Z")

</div>

> [@TfGuy44](#):
>
> Agreeing that this is unlikely.
> 
> Of course, if your GPU is being used to render your sketch, you do have a small amount of control over it. Render a billion polygons with it and the fan will probably kick onto high…

yeah! i know that. but its not useful actually. i need to control fan more precisely. thanks anyway: 😄

---

<div class="post-metadata">

**Author:** ![Jakub](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jakub/32/2192_2.png) [@Jakub](https://discourse.processing.org/u/Jakub)\
**Post date:** [November 22, 2018, 11:32am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/6 "2018-11-22T11:32:47Z")

</div>

NVidia has [NVAPI](https://developer.nvidia.com/nvapi) which allows you to control fan speed and other stuff like voltage and frequencies of their cards, however not all cards support this (e.g. on my laptop the only way to control nvidia gpu fan speed is through manufacturer utility).

If you can control the fan speed with Afterburner it should be possible with NVAPI.

Now Processing runs on Java, so you would need to figure out how to call NVAPI from Java, either through JNA which is not super hard, or through JNI, for which you need to write some C code as well.

---

<div class="post-metadata">

**Author:** ![neilcsmith](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/neilcsmith/32/144_2.png) [@neilcsmith](https://discourse.processing.org/u/neilcsmith)\
**Post date:** [November 22, 2018, 11:48am UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/7 "2018-11-22T11:48:36Z")

</div>

Interesting! Putting our two answers together suggests this might be a possibility - [https://github.com/arcnmx/nvoclock](https://github.com/arcnmx/nvoclock)

---

<div class="post-metadata">

**Author:** ![Kevin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kevin/32/2297_2.png) [@Kevin](https://discourse.processing.org/u/Kevin)\
**Post date:** [November 22, 2018, 5:20pm UTC](https://discourse.processing.org/t/control-gpu-fan-speed/5820/8 "2018-11-22T17:20:33Z")

</div>

Out of curiosity, why do you need to do this?
