ec icon indicating copy to clipboard operation
ec copied to clipboard

Replace hard-coded fan assumptions with configs

Open crawfxrd opened this issue 1 year ago • 0 comments

There are some hard-coded assumptions around fans that need to be addressed:

  • There is 1 CPU fan
    • It uses PWM2 (DCR2)
  • There is 1 dGPU fan
    • It uses PWM4 (DCR4)

darp10 is a unit without a dGPU, but has 2 CPU fans. They use PWM2 and PWM3.

It should be possible for a board to specify which interface each fan uses.

Info that's probably needed for each fan:

  • PWM index (DCR[0-7]) for setting duty
  • Tachometer (TACH[0-2][AB]) for tracking/reporting RPM?
  • Min/max duty/RPM for each fan

Shoving it all in the Makefile probably won't work, requiring some rewriting of the common and board-level logic.

Additionally, the temperature sensors should be pulled out and be separate from the fan control, but that fits more with #390.

crawfxrd avatar Apr 29 '24 15:04 crawfxrd