Go Down

Topic: Replacing thermistor for heater with arduino (Read 1 time) previous topic - next topic

rugnut

I have a few sensors around the house where I collect some data and send it to an MQTT broker. I would like to use this data as temperature input for my house heater. My house heater has an input for a 4k7 thermistor and the interesting range is 3070 ohms (35 degrees C) to 7370 ohms (15 degrees C). I measure 5v between the two terminals on the heater where the thermistor should attach.

My approach to this was simple. Get a digital pot, in this case MCP41010 10k and set it to the apropriate value for the temperature I got from some sensor. The circuit is also simple: Arduino talks SPI to the pot and the heater is connected to the pots wiper and one terminal. I can measure the reisitance changing and I have no problem with the range I need. every step is around 39 ohms and that corresponds to around 0.16 degrees C change between steps. My problem is that when I connect this to the heater the heaters reported temperature fluctuates constantly. The heater can not get a stable reading I am guessing. My ohm meter reports steady resistance but I have no scope to measure the signal.

So my question to the greater internet knowledge is if I am going about this the right way? Is there another solution maybe using PWM, a transistor and a filter circuit? I feel my electronics skills are too limited and I need help!  :smiley-confuse:

/Carl

MarkT

You use of a digital pot requires that the Arduino supply is matched to the heater's 5V, otherwise the
signal will top-out or bottom-out on the digital pot and not work as expected.  So I would first
measure the ac voltage between the grounds on the Arduino and the heater, both with and without a
1k resistor connected between them.

As I understand it you want to measure temperature and relay a (possibly altered) version of this
to the heater?
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

DVDdoug

Is the Arduino electrically isolated?    Since we don't know anything about the heater circuit, the Arduino's power supply and ground should be isolated from the heater circuit.    (of course the digital pot is not isolated, and that's OK.)


Quote
Replacing thermistor for heater with arduino
It might be better to replace the whole thermostat with your Arduino version.   The downside is that you'd probably want to add a display and that would add to the cost.   And, it might actually be more economical to buy a thermostat with Wi-Fi or some other home automation protocol built-in.

Quote
My approach to this was simple. Get a digital pot, in this case MCP41010 10k and set it to the apropriate value for the temperature I got from some sensor.
I don't understand what you're gaining from that...  If you want to control the heat from the external sensor and "fake out" the thermostat, then you don't need an analog  input.    You just need to turn the heater on & off.     If you want to turn-on the heater, send it a voltage (or resistance) that represents very-cold, and vice-versa to turn it off.


dmjlambert

Arduino talks SPI to the pot
I am just wondering if maybe the Arduino talked to the pot less often, what would happen?  Perhaps send an updated value every 120 seconds, instead of pretty much constantly.   Just a thought.

rugnut

The arduino is electricaly isolated from the heater exept the wiper terminal and terminal A on the digital pot which are connected to the two terminals where the thermistor would go.

The heater is a bit more advanced than just on/off. It's acctualy part of a geothermal heating system with built in logic for what temperature to heat the water to depending on the temperature outside. It can then do minor corrections based on internal temperature as well which is what I am trying to make work. The heater is placed in such a way that running a wire and installing a theristor in a good lookation really is not an option and therefor I need something to simulate the thermistor based on other temperature sensors I already have installed. The heater also speaks CANbus but there is no input for indoor temperature that way...

After a day of googeling I still think the digital pot is the best idea. Although I do not understand why the temperature measured would fluctuate as much as it does. I tried with a regular 4k7 resistor and I get 25.1 degrees solid. With the digital pot it fluctuates several degrees. The code I used changed the resistor value every 5 seconds. I will change the code and set it manualy via serial and see if I get more stable values on the heater. As I wrote earlier, the ohm readings I get are solid on my meter.

I will draw out the circuit and post it tomorrow.

/Carl

MarkT

#5
Apr 17, 2016, 09:49 pm Last Edit: Apr 17, 2016, 09:52 pm by MarkT
The arduino is electricaly isolated from the heater exept the wiper terminal and terminal A on the digital pot which are connected to the two terminals where the thermistor would go.
Exactly, as I feared you have no known relationship between the two supplies, which is not on
for a digital pot - the pot's supply ground must be below/equal to the heater's ground and the
pot's supply must be above/equal to the heater's 5V.  That requires the two supplies to be
referenced to each other, not floating.

In general you should never connect signal wires between systems that are not
already sharing a common ground, it is a very easy way to fry electronics since there
may be static or other voltages present that are able to overload a signal input.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

rugnut

Somewhere in my imagination I pictured the digital pot as being isolated from the arduino signal. So I am assuming you are saying I basicaly need to power the arduino from the heater itself somewhere? Or can you guide me how I isolate the digital pot from the arduino?

/Carl

dmjlambert

I read that data sheet for the digital pot, and I didn't really understand it fully.   I don't think it is very clear there is no isolation.   But upon googling it seems digital pots in general are are not isolated, except perhaps a limited number of more expensive ones.    So you can't just drop them into any circuit.    If I were in your shoes, I would  get a 10K linear pot and a 6 or 9g hobby servo, and connect the shafts.   

MarkT

Digital pots are _never_ isolated.  They are a set of transmission gates (analog switches) and on-chip resistor
array.

Usually people use them when the correct device is a DAC.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

Chagrin

If I were in your shoes, I would  get a 10K linear pot and a 6 or 9g hobby servo, and connect the shafts.  
You could avoid the mechanical nature of the servo/pot by taping a low ohm resistor to the thermistor and using it as a mini heater to adjust the resistance of the thermistor. A second thermistor could provide feedback.

This is all getting a little weird though. The heat pump should already have a standard 24VAC interface that could be interfaced with relays.

Go Up