Skip to content

core: confirm the fans-off release with sustained cold, not the first below-stopTemp tick - #73

Open
iBobbyTS wants to merge 1 commit into
ProducerGuy:mainfrom
iBobbyTS:fix/fanoff-sustained-cold
Open

iBobbyTS wants to merge 1 commit into
ProducerGuy:mainfrom
iBobbyTS:fix/fanoff-sustained-cold

Conversation

@iBobbyTS

Copy link
Copy Markdown

Problem

The peak sensor is a max over all CPU/GPU cores, and an idle core's reading drops 20-30°C the instant its workload ends. With stopTemp at idle-core resting level the peak oscillates across the threshold on a 100ms scale, and the instant "Fans off" release (temp <= stopTemp && fansCurrentlyRunning → resetAuto) hands the fans to Apple mid-ramp over and over. Measured on this hardware over three days of logs: 2,182 releases, fans slamming 3000+→1300 RPM every 3-7 seconds — start/stop cycling is the #1 bearing wear factor.

Fix

New FanOffGate (pure decision logic, hardware-free): releasing to Apple auto now requires the peak to stay at/below stopTemp for FanProfile.stopSustainSeconds (5s); a warm tick anywhere in the window restarts the streak. Until cold is confirmed, fans hold at minimum RPM — the same treatment the hysteresis band already gives (the existing 0.001 minimum signal), so a dip-and-recover never stops the fans. The start-side sustainedTriggerSec behavior is untouched.

Testing

swift build + full swift test pass, including six new behavior regressions in FanOffGateTests (momentary dip holds minimum, release exactly at the window, warm tick restarts the streak, post-release re-earn, inclusive threshold, window mirrors FanProfile).

… below-stopTemp tick

The peak sensor is a max over all CPU/GPU cores, and an idle core's
reading drops 20-30°C the instant its workload ends. With stopTemp at
idle-core resting level the peak oscillates across the threshold on a
100ms scale, and the instant "Fans off" release hands the fans to Apple
mid-ramp over and over — in three days of logs: 2,182 releases, fans
slamming 3000+→1300 RPM every 3-7 seconds (start/stop cycling is the ProducerGuy#1
bearing wear factor).

New FanOffGate (pure decision logic, hardware-free): releasing to Apple
auto now requires the peak to stay at/below stopTemp for
FanProfile.stopSustainSeconds (5s); a warm tick anywhere in the window
restarts the streak. Until cold is confirmed, fans hold at minimum RPM —
the same treatment the hysteresis band already gives — so a
dip-and-recover never stops the fans. Six behavior regressions in
FanOffGateTests.
@iBobbyTS
iBobbyTS force-pushed the fix/fanoff-sustained-cold branch from 45fefaa to 1cb3235 Compare October 20, 2026 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant