Skip to content

Instantly share code, notes, and snippets.

@michalzielanski
Created October 16, 2016 14:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save michalzielanski/52356e6116b3fa94b0350c8956433a07 to your computer and use it in GitHub Desktop.
Save michalzielanski/52356e6116b3fa94b0350c8956433a07 to your computer and use it in GitHub Desktop.
lm_sensors config for ASRock AM1H-ITX / AM1B-ITX
#
# ASRock AM1B-ITX / AM1H-ITX
#
# From Nuvoton NCT6776D Data Sheet:
# - 8-bit Analog to Digital Converter (ADC). Voltage range 0 - 2.048V,
# 8mV LSB (256 steps x 8mV = 2.048V).
# - Scaling equation: (Value * 8mV * (R1 + R2)) / R2 [1]
# (*8 already done by driver)
#
# From ASRock A-Tuning Utility config file (AM1BITX.xml):
# - Vcore: Reg: 0x20, R1: 0, R2: 1
# - +3.3V: Reg: 0x23, R1: 0x22 (34), R2: 0x22 (34)
# - +5.0V: Reg: 0x25, R1: 0x14 (20), R2: 0x0A (10)
# - +12V: Reg: 0x21, R1: 0x38 (56), R2: 0x0A (10)
#
# From nct6776 driver source code (nct6775.c) [2]
# - Registers map:
# 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x550, 0x551
# in0 in1 in2 in3 in4 in5 in6 in7 in8
# Vcore +12V +3.3V +5.0V
#
# Sample values read from UEFI and ASRock A-Tuning:
# - 3.3V: 3.344, 3.360, 3.376
# - 5V: 5.112, 5.136, 5.160, 5.184
# - 12V: 11.933, 11.986, 12.038, 12.091, 12.144, 12.197, 12.250
#
# [1] http://forums.tweaktown.com/asrock/56753-asrock-e3c224d2i-e3c226d2i-lm-sensors-linux-configuration-post479087.html#post479087
# [2] http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/hwmon/nct6775.c
#
chip "nct6776-*"
label in0 "VCore"
set in0_min 0.5 * 0.95
set in0_max 1.4 * 1.05
label in3 "+3.3V"
set in3_min 3.3 * 0.95
set in3_max 3.3 * 1.05
label in5 "+5V"
compute in5 @*(30/10), @/(30/10)
set in5_min 5.0 * 0.95
set in5_max 5.0 * 1.05
label in1 "+12V"
compute in1 @*(66/10), @/(66/10)
set in1_min 12.0 * 0.95
set in1_max 12.0 * 1.05
# from /etc/sensors3.conf
label in8 "VBat"
set in8_min 3.0 * 0.90
set in8_max 3.3 * 1.10
# AVCC - Analog +3.3V power input. Internally supply power to all analog
# circuits.
ignore in2
# unknown - not used?
ignore in4
ignore in6
# 3VSB - +3.3V stand-by power supply for the digital circuits.
ignore in7
label temp1 "M/B Temp"
set temp1_max 60
set temp1_max_hyst 55
label temp2 "CPU Temp"
set temp2_max 80
set temp2_max_hyst 75
ignore temp3 # AUXTIN
ignore temp7 # PCH_CHIP_TEMP
ignore temp8 # PCH_CPU_TEMP
ignore temp9 # PCH_MCH_TEMP
label fan1 "Chassis Fan"
ignore fan1 # not connected
label fan2 "CPU Fan"
label fan3 "Power Fan"
# not available on the M/B
ignore fan4
ignore fan5
ignore intrusion0
ignore intrusion1
ignore beep_enable
chip "k10temp-*"
label temp1 "APU Temp"
chip "radeon-*"
label temp1 "GPU Temp"
chip "fam15h_power-*"
label power1 "APU Power"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment