FanControl.Releases icon indicating copy to clipboard operation
FanControl.Releases copied to clipboard

[Feature Request] Custom function curves

Open FabiSahne opened this issue 8 months ago • 6 comments

I'd love a curve widget where I could write my own functions. Similar to a Mix curve, but instead of the five predefined function, the user could write their own JS or Python or whatever. You could give the user access to some object which holds the fan curves and/or temp sources provided by the user themself similar to how it's done in the Mix curve and the user then (maybe behind an edit button, like in the graph widget) writes some code which has to produce an integer representing the percentage or RPM.

--- very crude (nonsensical) mock up Image Image

FabiSahne avatar May 03 '25 14:05 FabiSahne

hmm I was wondering about something similar too. For example a Python script or batch, or whatever gives back a value once or in a loop would be amazing. You can write in a file and read the file with FanControl, but I really don't want to write and read stuff in multiple files every second on SSDs 24hours a day.

IFD3 avatar May 07 '25 12:05 IFD3

I was thinking the same thing. It would be great to be able to test out different PID algorithms.

tylercasper avatar May 08 '25 19:05 tylercasper

That's a fun idea, but how would you got about handling state? Most algorithm, like the "I" part of PID, need some kind of state to be reused from iteration to iteration.

Rem0o avatar May 08 '25 20:05 Rem0o

This could be done by having two code blocks, one for initializing state, and one which gets polled and acts on that state, similar to how some game engines often have a setup function and update function.

FabiSahne avatar May 09 '25 13:05 FabiSahne

At that point I would probably integrate that into the existing plugin system. Could have a generic ui with sensor inputs, and a json field to pass parameters. Then the plugin would receive an interface with all that information.

Rem0o avatar May 09 '25 13:05 Rem0o

Funny, I guess we've come full circle now, since that's what I was looking for originally, before posting this feature request, haha.

FabiSahne avatar May 09 '25 13:05 FabiSahne

At that point I would probably integrate that into the existing plugin system. Could have a generic ui with sensor inputs, and a json field to pass parameters. Then the plugin would receive an interface with all that information.

Yes. Please. It's the thing missing for me right now. The Plugin API has everything but means to define our own control scheme.

Nebur99 avatar Aug 26 '25 08:08 Nebur99