diff --git a/drivers/sensor/ntc_thermistor/Kconfig b/drivers/sensor/ntc_thermistor/Kconfig index 140d324e9aa..1d0af864a88 100644 --- a/drivers/sensor/ntc_thermistor/Kconfig +++ b/drivers/sensor/ntc_thermistor/Kconfig @@ -8,7 +8,8 @@ config NTC_THERMISTOR depends on DT_HAS_NTC_THERMISTOR_GENERIC_ENABLED || \ DT_HAS_EPCOS_B57861S0103A039_ENABLED || \ DT_HAS_MURATA_NCP15WB473_ENABLED || \ - DT_HAS_TDK_NTCG163JF103FT1_ENABLED + DT_HAS_TDK_NTCG163JF103FT1_ENABLED || \ + DT_HAS_MURATA_NCP15XH103_ENABLED select ADC help Enable driver for Zephyr NTC Thermistor. diff --git a/drivers/sensor/ntc_thermistor/ntc_thermistor.c b/drivers/sensor/ntc_thermistor/ntc_thermistor.c index 185e8c27673..18ed9cd3e04 100644 --- a/drivers/sensor/ntc_thermistor/ntc_thermistor.c +++ b/drivers/sensor/ntc_thermistor/ntc_thermistor.c @@ -243,3 +243,29 @@ static __unused const struct ntc_compensation comp_tdk_ntcg163jf103ft1[] = { DT_INST_FOREACH_STATUS_OKAY_VARGS(NTC_THERMISTOR_DEFINE, DT_DRV_COMPAT, comp_tdk_ntcg163jf103ft1) + +/* murata,ncp15xh103 */ +#undef DT_DRV_COMPAT +#define DT_DRV_COMPAT murata_ncp15xh103 + +static __unused const struct ntc_compensation comp_murata_ncp15xh103[] = { + { -25, 87558 }, + { -15, 53649 }, + { -5, 33892 }, + { 5, 22021 }, + { 15, 14673 }, + { 25, 10000 }, + { 35, 6947 }, + { 45, 4916 }, + { 55, 3535 }, + { 64, 2586 }, + { 75, 1924 }, + { 85, 1452 }, + { 95, 1109 }, + { 105, 858 }, + { 115, 671 }, + { 125, 531 }, +}; + +DT_INST_FOREACH_STATUS_OKAY_VARGS(NTC_THERMISTOR_DEFINE, DT_DRV_COMPAT, + comp_murata_ncp15xh103) diff --git a/dts/bindings/sensor/murata,ncp15xh103.yaml b/dts/bindings/sensor/murata,ncp15xh103.yaml new file mode 100644 index 00000000000..7e53ed3da84 --- /dev/null +++ b/dts/bindings/sensor/murata,ncp15xh103.yaml @@ -0,0 +1,8 @@ +# Copyright (c) 2024 Silicom Connectivity Solutions Ltd. +# SPDX-License-Identifier: Apache-2.0 + +description: MURATA NCP15XH103 thermistor + +compatible: "murata,ncp15xh103" + +include: ntc-thermistor.yaml diff --git a/tests/drivers/build_all/sensor/adc.dtsi b/tests/drivers/build_all/sensor/adc.dtsi index b853ab0cad7..51dc06812fc 100644 --- a/tests/drivers/build_all/sensor/adc.dtsi +++ b/tests/drivers/build_all/sensor/adc.dtsi @@ -85,3 +85,12 @@ test_lm35: lm35 { io-channels = <&adc0 0>; status = "okay"; }; + +test_murata_ncp15xh103: murata-ncp15xh103 { + compatible = "murata,ncp15xh103"; + io-channels = <&test_adc 0>; + pullup-uv = <3300000>; + pullup-ohm = <0>; + pulldown-ohm = <10000>; + connected-positive; +};