tmc2240: Add OTW_OV_VTH to FieldFormatters (#6987)

This register is readable and contains the overvoltage and overtemp
threshold settings.

Signed-off-by: Hendrik Poernama <poernahi@gmail.com>
This commit is contained in:
Hendrik Poernama 2025-08-21 09:33:31 -04:00 committed by GitHub
parent 2ddfa32dd8
commit 3b68769ea5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -262,6 +262,9 @@ FieldFormatters.update({
"adc_temp": (lambda v: "0x%04x(%.1fC)" % (v, ((v - 2038) / 7.7))),
"adc_vsupply": (lambda v: "0x%04x(%.3fV)" % (v, v * 0.009732)),
"adc_ain": (lambda v: "0x%04x(%.3fmV)" % (v, v * 0.3052)),
"overvoltage_vth": (lambda v: "0x%04x(%.3fV)" % (v, v * 0.009732)),
"overtempprewarning_vth": (lambda v:
"0x%04x(%.1fC)" % (v, ((v - 2038) / 7.7))),
})