Changeset 4717
- Timestamp:
- 08/26/07 22:36:46 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
lm-sensors/branches/lm-sensors-3.0.0/prog/sensors/chips.c
r4716 r4717 23 23 #include <stdlib.h> 24 24 #include <string.h> 25 #include <math.h>26 25 27 26 #include "main.h" … … 42 41 43 42 /* symbolic constants for minmax defined above */ 44 static void print_temp_info(float n_cur, float n_over, float n_hyst, 45 int minmax) 46 { 47 /* note: deg_ctof() will preserve HUGEVAL */ 43 static void print_temp_limits(float n_over, float n_hyst, 44 int minmax) 45 { 48 46 if (fahrenheit) { 49 n_cur = deg_ctof(n_cur);50 47 n_over = deg_ctof(n_over); 51 48 n_hyst = deg_ctof(n_hyst); 52 49 } 53 54 if (n_cur != HUGE_VAL)55 printf("%+6.1f%s ", n_cur, degstr);56 else57 printf(" FAULT ");58 50 59 51 if (minmax == MINMAX) … … 231 223 } 232 224 233 if (TEMP_FEATURE(SENSORS_FEATURE_TEMP_FAULT) &&234 TEMP_FEATURE_VAL(SENSORS_FEATURE_TEMP_FAULT))235 val = HUGE_VAL;236 237 225 print_label(label, label_size); 238 226 free(label); 239 227 240 print_temp_info(val, max, min, type); 228 if (TEMP_FEATURE(SENSORS_FEATURE_TEMP_FAULT) && 229 TEMP_FEATURE_VAL(SENSORS_FEATURE_TEMP_FAULT)) { 230 printf(" FAULT "); 231 } else { 232 if (fahrenheit) 233 val = deg_ctof(val); 234 printf("%+6.1f%s ", val, degstr); 235 } 236 print_temp_limits(max, min, type); 241 237 242 238 /* ALARM features */
