Ambitious project? Maybe.

Hey, all.

Let me get straight to the details: I would like to use the Arduino board (which has been collecting dust for over a year) for a fun but possibly ambitious project: Custom Climate control in my car. I do, however, need some hardware help.

Brief project description (the very first steps. I have some plans to expand it if all goes well): 1. Read inside temp from a sensor (LM35, arriving soon). 2. If temp is above threshold: a. Turn on fan. b. Turn on AC - bypass stock controls in both cases 3. Once temp is at or below threshold - turn everything off

Don't worry about threshold and other programming details. That's the easy part for me.

Here's the difficult part: turning on the fan. My car has a knob with 4 speed settings. As I understand (and I am not very good with electrical hardware, but would love to learn), depending on the speed setting, the output current varies. However, I have no idea what type of device I should use to simulate this behavior. Any ideas? Perhaps someone has done something similar? Keep in mind, I don't actually need to control a motor or anything, but basically simulate output of the Fan knob.

Thanks all!

Here's the difficult part: turning on the fan. My car has a knob with 4 speed settings.

You could do this with 4 relays wired across the contacts for the switch. Being car electrics, the motor is likely to draw a fair bit of current so fairly chunky relays should be used. You can find out how much current the fan is drawing by measurement, or by asking on a forum related to that model of car (if one exists).

You would drive the relays from the Arduino output pins using transistors like TIP120s.

Nice project - there are some interesting parts to it.

Mike

  1. Once temp is at or below threshold - turn everything off

Will you bypass the manual fan/AC-controls? I don't like the idea of shutting down the fan to control temperature. It's much better to control the temperature of the incoming air and let the fan run continuously at a low speed. Then you can increase the fan speed when you need to correct the temperature much.

If you have a manual AC and manual ventilation you probably want to replace the manual controls with servos so you can control the flow of hot and cold air as well as the speed of the fan.

If you do this you can do all sorts of cool things: - Recycle the air automatically when reverse gear is selected. This prevents exhaust gases from being drawn into the car when reversing. - Do the same for 30 seconds whenever the windshield washer is used to prevent the smell of windshield washer liquid inside the car. - Automatically adjust the airflow to the windshield depending on the difference between the temperature outside and inside. This will reduce condensation when it's cold.

Another tip is to mount the temperature sensor in the dash, and use a small fan to circulate air over it. This will give you quicker response time.

Here's the difficult part: turning on the fan. My car has a knob with 4 speed settings.

The fan speed is most likely controlled by a voltage divider. It will get very hot so it's usually located near the fan to keep it cool. You can simulate the manual controls using relays or MOSFETs, but a more efficient and flexible solution would probably be to control the fan directly using pulse width modulation and MOSFETs. Then you'll have better control of the fan speed, use less pins on your Arduino and also save some energy by omitting the voltage divider.

Good luck with this project! It's a very interesting subject.

Thanks, guys! This is great info.

You could do this with 4 relays wired across the contacts for the switch.

This an interesting idea. I did not think of it this way. I will most likely find out the current by measurement. I do have a question though: is this the only way to simulate the action of the knob? Does there exist some sort of variable output relay that I could use for this? It could even have continuous output. I guess first I need to find out exactly how my knob operates - 4 different current settings or actually opening/closing 4 different circuits (sounds insane, but possible). Sorry for the possible simplicity/dumbness of the questions, I am a comp sci, not really a hardware person.

Will you bypass the manual fan/AC-controls?

So far it seems like I would have to. I want to keep this project as simple as possible, but at the same time get the functionality I want with minimum risks. For that reason I would probably add a switch, which will allow me to switch between manual or automatic modes. But that will come in much much later.

If you have a manual AC and manual ventilation you probably want to replace the manual controls with servos so you can control the flow of hot and cold air as well as the speed of the fan.

Well, I have a few ideas in regards to this project. Currently I am only looking at this as a "cool-down" project. If everything works, then I'll move to heating up as well :) As far as servos go, though, it seems that they are geared more towards physical state of a certain device (shifting, etc.), where as I would be more than happy with just simulating electrical signals that my current AC control produce. Or am I not understanding something right?

Btw, did I mention adding a 16x2/20x4 screen down the road? And some buttons 8-)

Thanks again!

This an interesting idea. I did not think of it this way. I will most likely find out the current by measurement. I do have a question though: is this the only way to simulate the action of the knob? Does there exist some sort of variable output relay that I could use for this? It could even have continuous output. I guess first I need to find out exactly how my knob operates - 4 different current settings or actually opening/closing 4 different circuits (sounds insane, but possible).

There's two resistors near the fan, they're connected in series with the positive terminal on the fan. There are three wires connected besides ground - one directly to the positive terminal (full speed), one between the two resistors (slower) and one on the end of the two resistors (slowest). So your switch actually opens and close three different circuits.

I would again suggest controlling the fan speed with a simple motor controller. There are loads of example circuits on this site. You need three transistors, three diodes, three resistors and three relays to emulate the physical switch. Controlling the motor directly will require less components, save a lot of space and produce less heat.

As far as servos go, though, it seems that they are geared more towards physical state of a certain device (shifting, etc.), where as I would be more than happy with just simulating electrical signals that my current AC control produce. Or am I not understanding something right?

I mean using servos to control the vents in the heater unit. This is how it works on cars with climate control. You can do just about anything you want when you can control the vents, the fan and switch AC on/off. It's just a matter of software :-)

I would again suggest controlling the fan speed with a simple motor controller. There are loads of example circuits on this site. You need three transistors, three diodes, three resistors and three relays to emulate the physical switch. Controlling the motor directly will require less components, save a lot of space and produce less heat.

Can you post a link to a suitable circuit on this site?

Whilst I agree with using a motor controller, I have one reservation - that is the power of the motor. The motor control shields shown on this site will not be able to supply the motor. A bigger beast is required leading to complexity and expense.

Regards,

Mike

Can you post a link to a suitable circuit on this site?

I could be mistaken, it's possible that I've seen these circuits on other sites. Google "RC ESC schematics" and you'll find plenty of useful information.

Whilst I agree with using a motor controller, I have one reservation - that is the power of the motor. The motor control shields shown on this site will not be able to supply the motor. A bigger beast is required leading to complexity and expense.

I disagree. DC motors used in electric RC cars and buggys draws more current than a typical car ventilation fan, and you can control them with one or two FETs. One MOSFET with heatsink, one resistor and possibly one diode (depending on the MOSFET) will suffice to control the fan. Controlling a DC motor with pulse width modulation is simple as long as you only need the motor to turn in just one direction.

OK - I'll accept what you say.

So, will an RC ESC do the job? If so, then that part of the project is sorted - just control it with a RC servo like PWM.

I like the idea of controlling all the air flow flaps - though that could be quite involved. If it were me, I'd leave it for version 2.

Regards,

Mike

So, will an RC ESC do the job? If so, then that part of the project is sorted - just control it with a RC servo like PWM.

Yes, that would work as long as the ESC can handle 14V. Some of the really cheap one doesn't. But an ESC is overkill for this, it contains a lot of stuff you really don't need (like brakes and reverse) and it's more complex to control than just feeding a MOSFET with PWM.

an ESC is overkill but for less than 9 dollars shipped something like this is actually a lot less hassle to get going then wiring up FET's to the PWM output.

http://www.dealextreme.com/details.dx/sku.15581

It can be driven using the servo library.

Another thing to keep in mind if you intend to control the compressor is not to short cycle it. If it has been running, it should sit off for a couple minutes before restarting. The high and low side of the TXV should equalize before restarting and that also gives the system some time for any liquid refrigerant in the suction line to evaporate so it doesn't slug the compressor. At least, that's what you have to do with most refrigeration-A/C units; I'm assuming automotive is the same.

Second, the A/C in a car will for sure have a low pressure switch to prevent the compressor from turning on and burning up when the refrigerant is low. Make sure you don't bypass that or you could destroy the compressor.