| 362 | |
| 363 | == How do I handle changing Linux names for hwmon deveices (hwmon0, hwmon1, etc) |
| 364 | |
| 365 | It's not a good idea to have the /sys/class/hwmon/hwmon1' path hard coded as devices can move around depending on kernels, kernel config, and sometimes just boot to boot. Instead you should find the device with a name of gsc_hwmon and use that. |
| 366 | |
| 367 | An example is below: |
| 368 | {{{ |
| 369 | |
| 370 | DEV=$(for i in $(ls /sys/class/hwmon); do [ "gsc_hwmon" = $(cat /sys/class/hwmon/$i/name) ] && echo $i; done) |
| 371 | |
| 372 | cat /sys/class/hwmon/$DEV/pwm1_auto_point1_temp |
| 373 | }}} |