diff --git a/.bin/Scripts/functions/hw_diags.py b/.bin/Scripts/functions/hw_diags.py index 38559540..79123b3c 100644 --- a/.bin/Scripts/functions/hw_diags.py +++ b/.bin/Scripts/functions/hw_diags.py @@ -1598,9 +1598,7 @@ def run_mprime_test(state, test): if isinstance(err, KeyboardInterrupt): test.update_status('Aborted') elif isinstance(err, ThermalLimitReachedError): - test.failed = True test.thermal_abort = True - test.update_status('FAIL') update_progress_pane(state) # Restart live monitor @@ -1614,6 +1612,13 @@ def run_mprime_test(state, test): tmux_kill_pane(state.panes.pop('Prime95', None)) countdown_proc.kill() + # Check max temp + cpu_max_temp = get_cpu_max_temp(test.sensor_data) + if cpu_max_temp >= THERMAL_FAIL: + test.failed = True + test.update_status('FAIL') + update_progress_pane(state) + # Get cooldown temp run_program(['apple-fans', 'auto'], check=False) clear_screen() @@ -1711,6 +1716,11 @@ def run_mprime_test(state, test): ' {RED}CPU reached temperature limit of {temp}°C{CLEAR}'.format( temp=THERMAL_LIMIT, **COLORS)) + elif cpu_max_temp >= THERMAL_FAIL: + test.report.append( + ' {RED}CPU reached failing temperature of {temp}°C{CLEAR}'.format( + temp=THERMAL_FAIL, + **COLORS)) # Done update_progress_pane(state) diff --git a/.bin/Scripts/settings/hw_diags.py b/.bin/Scripts/settings/hw_diags.py index 1cd7aa36..58bd8b80 100644 --- a/.bin/Scripts/settings/hw_diags.py +++ b/.bin/Scripts/settings/hw_diags.py @@ -104,6 +104,7 @@ KEY_SMART = 'ata_smart_attributes' # Tests: Prime95 MPRIME_LIMIT = 7 # of minutes to run Prime95 +THERMAL_FAIL = 90 # Fail temperature in Celsius THERMAL_LIMIT = 99 # Abort temperature in Celsius