Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description
We have a custom board on which four NTC thermistors feed into the TI ADS1115 ADC chip. The devicetree for the board defines four ntc-thermistor-generic devices.
When the four ntc thermistor generic devices are initialized, which only happens once, the ntc thermistor driver calls
adc_channel_setup_dt. Thechannel_setupimplementation in the ads1x1x driver configures the CONFIG register of the TI ADS1115 chip. Among other things, this configuration involves configuring the input multiplexer. This means the MUX bits in the CONFIG register of the ADS1115 chip are set for whichever NTC thermistor device was last initialized. When you go to fetch a sample for any of the four thermistors with a call tosensor_sample_fetch, it will always return value for whatever MUX bits were set to during the last ntc thermistor init. This seems not ideal.Beta Was this translation helpful? Give feedback.
All reactions